You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, the dggrs_zoneid_repr (added in #52, relates to #11) is tightly coupled with the collections[*].collection_provider.
Using the following configuration as example:
dggrs:
"1":
IGEO7:
classname: igeo7_dggrs_provider.IGEO7Provider"2":
ISEA7H-Z7:
classname: dggal_dggrs_provider.DGGALProviderparameters: {"grid": "ISEA7H_Z7"} # no-op compared to IGEO7Provider, just naming alias for convenience"3":
ISEA7H:
classname: dggal_dggrs_provider.DGGALProviderparameters: {"grid": "ISEA7H_Z7"} # ideally "ISEA7H", but not currently available in the provider implementation"4":
ISEA7H-HEX:
classname: igeo7_dggrs_provider.IGEO7Provider # ??parameters: { "dggrs_zoneid_repr": "hex" } # new property? not the datasource encoding, but *desired* representationcollections:
"2":
manitoba-rcm-ard:
# ... other metadata ...collection_provider:
providerId: "igeo7-parquet-manitoba-rcm-ard"dggrsId: "IGEO7"dggrs_zoneid_repr: "textual"# defaultdatasource_id: "igeo7-parquet-manitoba-rcm-ard"collection_providers:
"1":
igeo7-parquet-manitoba-rcm-ard:
datasources: { "igeo7-parquet-manitoba-rcm-ard": {...} }
Providing the following equivalent endpoints is not possible (unless the DGGRS providers implement a convert() for it):
/collections/manitoba-rcm-ard/dggs/IGEO7/...
/collections/manitoba-rcm-ard/dggs/ISEA7H/...
/collections/manitoba-rcm-ard/dggs/ISEA7H-Z7/...
/collections/manitoba-rcm-ard/dggs/ISEA7H-HEX/...
Note
Above are equivalent since only the ZIRS changes, but the underlying DGGH is the same.
Currently, the above would require creating a "duplicate" manitoba-rcm-ard-IGEO7, manitoba-rcm-ard-ISEA7H, etc. collections pointing at their respective datasources with pre-converted zone IDs, since the collections[*].collection_provider.dggrs_zoneid_repr is a tight link. This can potentially consist of a lot of data duplication between the datasources for otherwise easily obtainable ZIRS correspondence. It also makes the "equivalent data" access less obvious to users since different collection IDs would represent the same results, rather than offering the same "collection of data" with different DGGS encodings.
It would make sense to implement dggal_dggrs_provider.DGGALProvider.convert for this case. In general, the int/str representation could always be converted for any DGGRS (via DGGAL), and hex from the int representation. Furthermore, the igeo7_dggrs_provider.IGEO7Provider.convert could handle the specific IGEO7/ISEA7H/ISEA7H-Z7 combination that has an additional case of different str representations (root rhombus vs Z7).
Another limitation of the current configuration structure seems to relate to the 1->1 mapping of collections[*].collection_provider.datasource_id.
If certain DGGRS cannot be easily converted between each other (eg: a hexagonal vs a square DGGRS), but happen to have been pre-processed into distinct collection_providers[*].datasources for corresponding "data", they still cannot be conceptually combined into a single collection ID.
It would be helpful if the global mapping of collections[*].collection_provider allowed multiple entries, for which "conceptual" collection of data can be provided by distinct collection_provider implementations, essentially "abstracting" the multi-provider configuration from the user's perspective accessing this "data concept".
Currently, the
dggrs_zoneid_repr(added in #52, relates to #11) is tightly coupled with thecollections[*].collection_provider.Using the following configuration as example:
Providing the following equivalent endpoints is not possible (unless the DGGRS providers implement a
convert()for it):/collections/manitoba-rcm-ard/dggs/IGEO7/.../collections/manitoba-rcm-ard/dggs/ISEA7H/.../collections/manitoba-rcm-ard/dggs/ISEA7H-Z7/.../collections/manitoba-rcm-ard/dggs/ISEA7H-HEX/...Note
Above are equivalent since only the ZIRS changes, but the underlying DGGH is the same.
Currently, the above would require creating a "duplicate"
manitoba-rcm-ard-IGEO7,manitoba-rcm-ard-ISEA7H, etc. collections pointing at their respectivedatasourceswith pre-converted zone IDs, since thecollections[*].collection_provider.dggrs_zoneid_repris a tight link. This can potentially consist of a lot of data duplication between thedatasourcesfor otherwise easily obtainable ZIRS correspondence. It also makes the "equivalent data" access less obvious to users since different collection IDs would represent the same results, rather than offering the same "collection of data" with different DGGS encodings.It would make sense to implement
dggal_dggrs_provider.DGGALProvider.convertfor this case. In general, the int/str representation could always be converted for any DGGRS (via DGGAL), andhexfrom theintrepresentation. Furthermore, theigeo7_dggrs_provider.IGEO7Provider.convertcould handle the specific IGEO7/ISEA7H/ISEA7H-Z7 combination that has an additional case of differentstrrepresentations (root rhombus vs Z7).Another limitation of the current configuration structure seems to relate to the 1->1 mapping of
collections[*].collection_provider.datasource_id.If certain DGGRS cannot be easily converted between each other (eg: a hexagonal vs a square DGGRS), but happen to have been pre-processed into distinct
collection_providers[*].datasourcesfor corresponding "data", they still cannot be conceptually combined into a singlecollectionID.It would be helpful if the global mapping of
collections[*].collection_providerallowed multiple entries, for which "conceptual" collection of data can be provided by distinctcollection_providerimplementations, essentially "abstracting" the multi-provider configuration from the user's perspective accessing this "data concept".