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

Add easy access to parameter errors #1069

Merged
merged 1 commit into from Jun 21, 2017

Conversation

Projects
None yet
2 participants
@joleroi
Contributor

joleroi commented Jun 20, 2017

At the moment there's no simple possibility to access the errors of model parameters, except via fiddling with the covariance matrix oder the hidden _ufloats parameter.

This PR add a function error to ParameterList to over come this, of course it's just a temporary solution until we have a proper covariance matrix class.

cc @Ozi1Kenobi

@joleroi joleroi added the feature label Jun 20, 2017

@joleroi joleroi self-assigned this Jun 20, 2017

@joleroi joleroi added this to the 0.7 milestone Jun 20, 2017

@cdeil

cdeil approved these changes Jun 20, 2017

raise ValueError('Covariance matrix not set.')
for i, parameter in enumerate(self.parameters):
if parameter.name == parname:

This comment has been minimized.

@cdeil

cdeil Jun 20, 2017

Member

This lookup of parameter by name could / should be a separate method that takes the name and returns the int index, no? If you don't want to implement that here, OK to merge anyways of course.

@cdeil

cdeil Jun 20, 2017

Member

This lookup of parameter by name could / should be a separate method that takes the name and returns the int index, no? If you don't want to implement that here, OK to merge anyways of course.

@joleroi joleroi merged commit 173458e into gammapy:master Jun 21, 2017

1 of 2 checks passed

continuous-integration/travis-ci/pr The Travis CI build failed
Details
continuous-integration/appveyor/pr AppVeyor build succeeded
Details

@joleroi joleroi deleted the joleroi:par_error branch Jun 21, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment