File tree 1 file changed +5
-2
lines changed
modin/core/storage_formats/pandas
1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -272,6 +272,7 @@ def cast_to_qc(arg):
272
272
qc_type = calculator .calculate ()
273
273
if qc_type is None or qc_type is type (arg ):
274
274
return arg
275
+ # TODO: Should use the factory dispatcher here to switch backends
275
276
return qc_type .from_pandas (
276
277
arg .to_pandas (), data_cls = calculator .result_data_cls ()
277
278
)
@@ -294,8 +295,10 @@ def cast_to_qc(arg):
294
295
# args since it references self on the original argument
295
296
# call
296
297
if result_qc_type != current_qc :
297
- data_cls = current_qc ._modin_frame
298
- new_qc = result_qc_type .from_pandas (current_qc .to_pandas (), data_cls )
298
+ # TODO: Should use the factory dispatcher here to switch backends
299
+ new_qc = result_qc_type .from_pandas (
300
+ current_qc .to_pandas (), data_cls = calculator .result_data_cls ()
301
+ )
299
302
obj_new = getattr (new_qc , obj .__name__ )
300
303
return obj_new (* args [1 :], ** kwargs )
301
304
You can’t perform that action at this time.
0 commit comments