Skip to content
This repository has been archived by the owner on May 28, 2024. It is now read-only.

analysis of baseline states #53

Merged
merged 5 commits into from
Mar 4, 2022
Merged

Conversation

jsadler2
Copy link
Collaborator

This PR is code used to look into:

Specifically the code

  • outputs the model hidden states to csv files
  • outputs the hidden states across 6 replicates
  • makes plots to visualize the hidden state data
  • pulls auxiliary data from nwis (flow, water temp, specific conductivity) for comparison with hidden states
  • makes a plot that compares predicted and observed DO with water temperature

@jsadler2 jsadler2 changed the title baseline states analysis of baseline states Feb 23, 2022
Copy link
Collaborator

@galengorski galengorski left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This all looks good to me, I just had a few clarifying questions to make sure I understood it. I think I'm still trying to get my head around the code architecture a little bit

m = LSTMModel(10, 3)

# %%
m.load_weights("../../2a_model/out/models/0_baseline_LSTM/train_weights/")
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm a little confused where these weights come from

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These are weights produced by the snakemake workflow:

directory("{outdir}/train_weights/"),

m.load_weights("../../2a_model/out/models/0_baseline_LSTM/train_weights/")

# %%
data = np.load("../../2a_model/out/models/0_baseline_LSTM/prepped.npz", allow_pickle=True)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also confused here as to what you are loading, are these input data to use for plotting

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes these are input data. They are used to just run the model once so I can get the weight values. ... now that I think of it, I'm not 100% sure this step is necessary.

@jsadler2 jsadler2 merged commit 7c99e50 into USGS-R:main Mar 4, 2022
@jsadler2 jsadler2 deleted the 45-baseline-states branch March 4, 2022 21:50
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants