We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 51c07b7 commit 1fb3dbbCopy full SHA for 1fb3dbb
modin/core/dataframe/pandas/dataframe/dataframe.py
@@ -4698,6 +4698,8 @@ def to_pandas(self):
4698
df = self._partition_mgr_cls.to_pandas(self._partitions)
4699
if df.empty:
4700
df = pandas.DataFrame(columns=self.columns, index=self.index)
4701
+ if len(df.columns) and self.has_materialized_dtypes:
4702
+ df = df.astype(self.dtypes)
4703
else:
4704
for axis, has_external_index in enumerate(
4705
["has_materialized_index", "has_materialized_columns"]
0 commit comments