-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Subregional planning support #208
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…son schemas. upgrade to typescript 4.9 to support satisfies operator, upgrade typedoc and inquirer to get ts4.9 support.
…Datasources tests Co-authored-by: Abby Meyer <[email protected]>
…itor Co-authored-by: Abby Meyer <[email protected]>
…offer user selection and create eez geography using it, stub out precalcData questions, drop Datasources type
…pers and accompanying schemas/types, update contributing docs for example-project
…a, add isVectorDatasource helper and VectorDatasource type
…trics, drop unused filterDatasource
… all datasource types, add isImportRasterDatasourceConfig and isImportVectorDatasourceConfig, ensure formats passed for all import/reimport
…geography groups, and default to "planning boundary" group
…er to datasource and geography, add firstMatching helper
…bPath for testing. Fix external subdivided test, add raster precalc tests
… data, other nits
…ming/comments underneath precalc
…ProjectClientConfig for precalc testing
twelch
commented
Nov 6, 2023
avmey
reviewed
Nov 7, 2023
avmey
reviewed
Nov 7, 2023
avmey
reviewed
Nov 7, 2023
avmey
reviewed
Nov 7, 2023
avmey
reviewed
Nov 7, 2023
avmey
reviewed
Nov 7, 2023
…meric value, force string-based indexing when inserting zero metrics for clipped feature classes
This was referenced Nov 10, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Resolves
Requirements
Geographies
Create first-class support for project
geographies
, which can be the entire world, a planning region and/or one or more subregions within it.Geography pointing at internal datasource:
geojson
format containing a feature collection of Polygon or MultiPolygon features. Should error if not. Flatgeobuf ran into an issue and support can be added in the future.propertyFilter
to identify a specific feature and geographic area within the datasource where that features is located. Otherwise defaults to using all features in the collection as the geography.Geography pointing at external datasource:
External datasource geography is expected to be available in
flatgeobuf
orsubdivided
format containing an array/collection of Polygon or MultiPolygon features. Throw error if not.Geography must be configured with a
propertyFilter
andbboxFilter
to identify a specific feature and geographic area within the external datasource to quickly fetch the features.should be able to filter to a single geography within a multiple polygon datasource
should be able to filter to multiple geography polygons within a multiple polygon datasource
A
groups
property should allow the geography to be associated with one or more geography groups. Default toproject boundary
group identifying the top-level geography. Report client can use groups to retrieve precalculated metrics for the appropriate set of geographies, even if the the geographies change.Should be able to exclude geography from precalculations (precalc: false), so that the geography can stay present in config, without being used.
Should be able to exclude datasource from precalculations (precalc: false) but still used for a geography.
Global datasources
How to use global datasources going forward in projects:
OSM land polygons have been traditionally used by SeaSketch as a baseline (coastline) because it matches basemaps that use OSM (like Mapbox used by SeaSketch). Its accuracy wasn't questioned until it was seen that for small island nations it can be missing small landmasses. This matters when defining for example a nearshore boundary for planning, if you are missing small islands, the nearshore area around them will not be included in the planning area or in drawn sketches. The % of area relative to the whole EEZ is small, but it could have localized impacts particularly regarding enforcement.
global-eez-with-land-mr-v3
and then clip toglobal-land-osm
.global-eez-mr-v11
(eez with mr land baseline cut out), because it's available right now in global form. This will create a small misalignment with the osm land baseline used by the preprocessor.After creating a new report project, developers can then decide which baseline is best:
global-eez-mr-v11
. Keep the geography usingglobal-eez-mr-v11
.global-eez-with-land-mr-v3
and a local geography can be created that takes the MR EEZ boundary and subtracts out OSM land, as we have traditionally done for all projects.Project init
data/default/world.json
which gets copied in. defaultgeographies.json
pointing at world geography should also be used.global-eez-mr-v11
datasourcegeographies.json
file will be created witheez
datasource pointing atglobal-eez-mr-v11
datasource and user-selected EEZ ID and display value. It should include both apropertyFilter
andbboxFilter
since this is a global datasource.Precalc command
precalc:data
commandExternal datasource precalc
mr-eez
external datasource, precalculate bbox and turf_area and providemr-eez.ts
file for reading. Actual eez boundaries will be published at a later date in global-reports project.Report Client
Geoprocessing Functions
project.getGeographyById
should allows for a caller-defined fallback geography specified with group nameproject-boundary
. This will be default group name forworld
oreez
geography installed on init.ToDo:
in
andout
directory. Drop intermediatestart-data-testing
commandFuture
Docs:
happens when no features for a data class overlap with a given
geography. In this scenario a NaN metric value is produced by
toPercentMetric(), because the denominator value is zero. ClassTable
picks up on this and displays more information to the user()
Post merge doc updates: