Steven Rieder
Steven Rieder
Simple concept for a conversion script (hardcoded only for meters): ```python import astropy.units as astropyunits from amuse.units import units as amuseunits def amuse_equivalent_unit( astropyunit, ): # Check if the named...
I agree switching over probably won't work, at least it's not quite worth the huge effort.
Thanks for responding @adrn! Yes, I would be very happy to discuss this at some point. @ipelupessy should also be included in that discussion as he has more knowledge about...
> Am on vacation, so reading e-mail randomly, but units at least seems relatively straightforward as it would seem one should be able to go via the string representation, perhaps...
Assigned this to the AMUSE 13 milestone, as I hope that by that version we can have some conversion process in place from the AMUSE side, perhaps similar to the...
Reassigning to AMUSE 14.
Here's a working conversion function from AMUSE -> Astropy. Two things to note: - it always returns to base (SI) units (not really a problem) - the values can/will change...
> * the values can/will change slightly, since AMUSE and Astropy use slightly different constants (#171) (this is a problem) Or perhaps this is not so much a problem (since...
Ok, here are to/from functions that can be added to AMUSE to convert between AMUSE/Astropy: ``` def from_astropy(ap_quantity): "Convert a unit from Astropy to AMUSE" # Find SI bases of...
I suggest I add them to a new 'amuse.units.astropy' file