-
Notifications
You must be signed in to change notification settings - Fork 0
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
Min model error #28
Min model error #28
Conversation
…d more stat outpus
added option to save or reload a merged data object
If `filters = []` the previous version threw an error because it tries to apply string methods to `None`. This is just a quick fix.
This allow arbitrary keyword args to be based to the inversion function. For instance: `python run_hbmcmc.py -c example.ini --kwargs="{'outputpath': '/user/work/ab12345'}"` will override the output path specified in `example.ini`.
This can be passed to `fixedbasisMCMC`, via a .ini file, or as a command line argument (using the kwargs feature added in a previous commit.)
This allows merged data to be used without having access to the object store used to create the merged data. NOTE: currently this just takes the first `FluxData` object in the `fp_all['.flux']` dictionary.
…ssions_name variable in get_data
…post mean country fluxes and create shared netCDF flux files
…ssing fails for that site
…ding frothe pickle
…orrect prior flux month is found. This includes correctly selecting prior fluxes from annual fluxes and multi-month inversions
6792032
to
5182034
Compare
Updates to min_model_error, to bring it up to date with changes in eric_devel etc.
`flux` is no longer needed as a parameter in `inferpymc_postprocess` due to changes recently added by Alice.
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.
Looks good to me.
Hi @brendan-m-murphy, I'm getting an error in get_data when it tries to read in obs when there isn't any available that month. It gets to line 153 in get_data ( |
Hi @aliceramsden , I guess it depends what we want to happen in this case. If we already have a value for Another issue is that I thought Could you tell me start/end date, species, and sites? If the species is fixed, we only need to get the units once. (I guess it would be best if we could specify it ahead of time so it doesn't need to be inferred.) |
Sorry I just realised that skipping would sort this problem in the short term. Although I don't think it's the ideal behaviour, since either we know the units from some site, or none of the sites will be used and we'll have no data for that inversion period. |
You're right about this: the |
So apparently |
Changes:
run_hbmcmc.py
,kwargs
tofixedbasisMCMC
, so that additional keyword args can be used (currently they are just passed toinferpymc
)min_error
as an argument toinferpymc
; the default value is 0.0, so it has no effect, but it can be specified in the ini file or via the command line.Syntax for
run_hbmcmc.py
:In this case, the
outputpath
argument inexample.ini
would be replaced with "/user/home/ab12345", and the argumentmin_error=20.0
would be passed toinferpymc
.Note that the value passed to
--kwargs
is a "dictionary in string form". Use single quotes for the outside of the string, and use double quotes for the keys inside the curly braces, as well as for any values that are strings. The argument is parsed byjson.loads
, which will convert a json in string format to a dictionary. (Note: do not put integer or float keyword values in double quotes, unless you want them to be parsed as strings.)