generated from NOAA-OWP/owp-open-source-project-template
-
Notifications
You must be signed in to change notification settings - Fork 52
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
Added functionality to output to parquet #761
Merged
Merged
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
4ddffea
Added functionality to write flow, velocity and depth to parquet
karnesh 2a8a10f
Modified parquet output format to match TEEHR input
karnesh 6d23372
cleaned the code
karnesh 4260674
cleaned the code
karnesh e5b45c4
sample yaml file changes for parquet output
karnesh 68d0f76
added functionality to include user defined prefix for IDs
karnesh 3fd4d4b
reverted back the formatting changes
karnesh 9cdd4fe
reverted back the formatting changes
karnesh be18931
reverted back the formatting changes
karnesh 7068e17
reverted back the formatting changes
karnesh 0f58ae6
removed parquet from streamOutput_allowedTypes
karnesh de8d8ab
added missing parameter in nwm_output_generator function and fixed fo…
karnesh File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
Oops, something went wrong.
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.
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 think if you use
value_vars=[ 'q', 'v', 'd' ]
as a kwarg to melt, you might have an easier time extracting from un-pivoted table?The below method seems like there should be a better way besides casting to string, manipulating the string, and recasting to numeric/datetime types.
I'm not sure exactly what the
df
looks like that is trying to be manipulated at this point, but I would try to consider a different method(s) for extracting the needed data from it.If for some reason this is the only way, then please comment this implementation to describe what the state of the df is and why this is the way it needs to be manipulated.
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 looked into options and this seems to be the only way. I cannot use
value_vars=[ 'q', 'v', 'd' ]
as a kwarg to melt because of the format ofdf
column names. Also, the column names needed to be manipulated as strings. Please look at the screenshot below.Each column name consists of a time step and a variable name (
q
,v
ord
) in string format. The time steps values are used to get the value_time.