-
Notifications
You must be signed in to change notification settings - Fork 1
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
Model redesign #30
Model redesign #30
Conversation
The local storage of volume data is meant as a temporary measure for reviewing/testing out this PR, correct (i.e. wouldn't be merged to master)? This configuration makes it otherwise pesky to do a local wipe of the database. |
Sure, this change can be removed before merging. I find it convenient that I can see the volume-mounted folders in the project location, but I understand that's just a personal preference. Besides, it deviates from the Girder 4 setup, so this change can just be scoped to this WIP. |
I made another iteration on the design (aaa1c7f), with the following changes @AlmightyYakob and I have discussed:
|
I think the problem with this is that derived regions can be "derived" from regions taken from multiple datasets. I've been thinking about the lingering gaps in our modeling, and I'm starting to think we need an additional data source, I also think that rather than point to a ---
UVDAT ER Diagram
---
erDiagram
Dataset {
CharField name
TextField description
ForeignKey city
}
DerivedRegionDataSource {
CharField name
ForeignKey city
S3FileField geojson_data
ManyToManyField source_regions
}
VectorDataSource {
ForeignKey dataset
JSONField metadata
S3FileField geojson_data
}
Region {
BigAutoField id
CharField name
JSONField properties
MultiPolygonField boundary
ForeignKey data_source
}
%% Relations
Dataset }|--|| City : city
VectorDataSource }|--|| Dataset: dataset
Region }|--|| VectorDataSource : data_source
DerivedRegionDataSource }|--|{ Region: source_regions
DerivedRegionDataSource }|--|| City: city
|
I'm not sure we would be able to capture all we want to represent for the The way I think of the |
With the above consideration of how I think of |
ea9abbd
to
bdcece6
Compare
This makes sense to me, and resolves my questions/concerns with My only other concern then is making sure the original use case regarding time series is covered. I'm a bit fuzzy on that, maybe we should discuss this offline at some point. |
Sounds good to me. I spent today on bdcece6, which fits our data into these new models. I tried combining the flood area datasets (grouping them by type) as a test for multiple |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I pushed 0a2c9ca, which mostly just ensures that newRegionName
is set back to ""
when a derived region selection is canceled (the rest is formatting/ergonomics). If that looks good to you, then this is ready.
This PR is the first in a series of three PRs in a large redesign effort. This PR is scoped to include changes to database models, their rest endpoints, their conversion functions, and the ingest process that creates objects from our sample data (the
populate
management command).Follow-up PRs address the other facets of the redesign effort. Ideally, we should prepare and review them all together so that they can be merged all at once.