12 2019 档案
摘要:##检查数据为空(nan) import math x=float('nan') math.isnan(x) ## 检查 def typeof(variate): type=None if isinstance(variate,int): type = "int" elif isinstance(v
阅读全文
摘要:平常会经常用到多进程,可以用进程池pool来进行自动控制进程,下面介绍一下pool的简单使用。 需要注意的是,在Windows上要想使用进程模块,就必须把有关进程的代码写if name == ‘main’ :语句的下面,才能正常使用Windows下的进程模块。Unix/Linux下则不需要。 Poo
阅读全文
摘要:Set your merge columns as index, and use df1.join(df2) instead https://stackoverflow.com/questions/40860457/improve-pandas-merge-performance
阅读全文
浙公网安备 33010602011771号