diff --git a/src/hipscat_import/catalog/map_reduce.py b/src/hipscat_import/catalog/map_reduce.py index a29ccc29..1fff4eff 100644 --- a/src/hipscat_import/catalog/map_reduce.py +++ b/src/hipscat_import/catalog/map_reduce.py @@ -285,9 +285,9 @@ def reduce_pixel_shards( dataframe["Dir"] = np.full( rows_written, fill_value=int(destination_pixel_number / 10_000) * 10_000, - dtype=np.uint32, + dtype=np.uint64, ) - dataframe["Npix"] = np.full(rows_written, fill_value=destination_pixel_number, dtype=np.uint32) + dataframe["Npix"] = np.full(rows_written, fill_value=destination_pixel_number, dtype=np.uint64) if add_hipscat_index: ## If we had a meaningful index before, preserve it as a column. diff --git a/src/hipscat_import/index/map_reduce.py b/src/hipscat_import/index/map_reduce.py index 06c6ad23..f728e3df 100644 --- a/src/hipscat_import/index/map_reduce.py +++ b/src/hipscat_import/index/map_reduce.py @@ -28,8 +28,8 @@ def create_index(args): if args.include_order_pixel: ## Take out the hive dictionary behavior. data["Norder"] = data["Norder"].astype(np.uint8) - data["Dir"] = data["Dir"].astype(np.uint32) - data["Npix"] = data["Npix"].astype(np.uint32) + data["Dir"] = data["Dir"].astype(np.uint64) + data["Npix"] = data["Npix"].astype(np.uint64) data = data.reset_index() if not args.include_hipscat_index: data = data.drop(columns=[HIPSCAT_ID_COLUMN]) diff --git a/tests/hipscat_import/catalog/test_run_import.py b/tests/hipscat_import/catalog/test_run_import.py index aae8467b..c0bbabe0 100644 --- a/tests/hipscat_import/catalog/test_run_import.py +++ b/tests/hipscat_import/catalog/test_run_import.py @@ -183,8 +183,8 @@ def test_dask_runner( pa.field("ra_error", pa.float32()), pa.field("dec_error", pa.float32()), pa.field("Norder", pa.uint8()), - pa.field("Dir", pa.uint32()), - pa.field("Npix", pa.uint32()), + pa.field("Dir", pa.uint64()), + pa.field("Npix", pa.uint64()), pa.field("_hipscat_index", pa.uint64()), ] ) @@ -203,8 +203,8 @@ def test_dask_runner( "ra_error": np.float32, "dec_error": np.float32, "Norder": np.uint8, - "Dir": np.uint32, - "Npix": np.uint32, + "Dir": np.uint64, + "Npix": np.uint64, } ) assert data_frame.dtypes.equals(expected_dtypes) diff --git a/tests/hipscat_import/index/test_run_index.py b/tests/hipscat_import/index/test_run_index.py index b6749e17..f969fc1d 100644 --- a/tests/hipscat_import/index/test_run_index.py +++ b/tests/hipscat_import/index/test_run_index.py @@ -50,8 +50,8 @@ def test_run_index( [ pa.field("_hipscat_index", pa.uint64()), pa.field("Norder", pa.uint8()), - pa.field("Dir", pa.uint32()), - pa.field("Npix", pa.uint32()), + pa.field("Dir", pa.uint64()), + pa.field("Npix", pa.uint64()), pa.field("id", pa.int64()), ] )