Skip to content

Commit

Permalink
remove negatives from sim before bias correction
Browse files Browse the repository at this point in the history
  • Loading branch information
rileyhales authored Feb 23, 2021
1 parent 7b8a25d commit 0d1cefa
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tethysapp/geoglows_hydroviewer/controllers.py
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,9 @@ def get_bias_adjusted(request):
# get the data you need to correct bias
sim_data = gsf.historic_simulation(reach_id)
forecast_stats = gsf.forecast_stats(reach_id)

# remove negative flows from the historical simulation
sim_data[sim_data["streamflow_m^3/s"] < 0] = 0

# corrected data
fixed_hist = gbc.correct_historical(sim_data, obs_data)
Expand Down

0 comments on commit 0d1cefa

Please sign in to comment.