adrn / thejoker

A custom Monte Carlo sampler for the (gravitational) two-body problem
MIT License
30 stars 8 forks source link

Error when writing to h5py file #99

Closed stephtdouglas closed 4 years ago

stephtdouglas commented 4 years ago

When trying to write out samples to an h5py group, I get the following error: "Error: local variable 'ext' referenced before assignment"

I'm calling it as samples.write(group,overwrite=True)

I think this line is the culprit: https://github.com/adrn/thejoker/blob/4d42d1639bda377d9d5e5d295c7daed613fe7fb9/thejoker/samples.py#L395 Since I'm not passing in a string, the preceding if statement doesn't execute and "ext" is not defined.

adrn commented 4 years ago

Oops! Yep, totally a bug. I think I just fixed it on master - could you try updating? Sorry, things are crazy right now so I've been a bit sloppier 😬

stephtdouglas commented 4 years ago

Yep, it runs now!

No worries, I'm happy to beta test :)