Skip to content

DGGRIDv8: grid_cell_polygons_from_cellids and grid_cell_centroids_from_cellids not returning correct zone IDs and geometries. #37

@tik65536

Description

@tik65536

@fmigneault ,

DGGRIDv8 :
When using the functions grid_cell_polygons_from_cellids and grid_cell_centroids_from_cellids with address parameters as follows:

address_params = {
            'input_address_type': 'HIERNDX',
            'input_hier_ndx_system': 'Z7',
            'input_hier_ndx_form': 'DIGIT_STRING',
            'output_address_type': 'HIERNDX',
            'output_cell_label_type': 'OUTPUT_ADDRESS_TYPE',
            'output_hier_ndx_system': 'Z7',
            'output_hier_ndx_form': 'DIGIT_STRING'
}

The result zone ID and geometry are not correct. For example :

centroids_gdf = dggridv8.grid_cell_polygons_from_cellids(['0213624'], 'IGEO7', resolution=5, **address_params)
Image

It is found that the metafile is missing the input_hier_ndx_form DIGIT_STRING, so it uses INT64 (by default).

The metafiles are attached for reference:

metafile_working.txt

metafile_notworking.txt

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions