bug fix with typing
This commit is contained in:
parent
944a3edbf6
commit
e4b164a34b
|
@ -168,9 +168,14 @@ class Components :
|
||||||
# How many rows sub-partition must we divide this into ?
|
# How many rows sub-partition must we divide this into ?
|
||||||
# let us fix the data types here every _id field will be an np.int64...
|
# let us fix the data types here every _id field will be an np.int64...
|
||||||
#
|
#
|
||||||
|
|
||||||
for name in df.columns.tolist():
|
for name in df.columns.tolist():
|
||||||
|
|
||||||
if name.endswith('_id') :
|
if name.endswith('_id') :
|
||||||
df[name] = df[name].astype(np.int64)
|
if df[name].isnull().sum() > 0 :
|
||||||
|
df[name].fillna(0,inplace=True)
|
||||||
|
else:
|
||||||
|
df[name] = df[name].astype(np.int64)
|
||||||
|
|
||||||
|
|
||||||
_dc = pd.DataFrame()
|
_dc = pd.DataFrame()
|
||||||
|
|
Loading…
Reference in New Issue