-
Notifications
You must be signed in to change notification settings - Fork 283
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
Make yt.units a shim that wraps unyt #1785
Comments
Consistent with our discussion two weeks ago on a PR in |
Yes, that's why I included "MKS is the default unit system" in the bullet points. |
I saw that, but I guess we're talking past each other. So your bullet points list the changes in |
@chummels my view is that the experience from the point of view of |
Though I should say that I consider the first three bullet points enhancements and yt 4.0 should have those changes. |
Yup, exactly, although with the qualification that data from fields that we don't support yet might load data with MKS or other unit systems that are commonly used in that field. The astrophysics domain context will definitely have CGS units by default. |
OK cool, then we're all on the same page. Sorry for my mis-reading of your description. |
I think this is is satisfied now, so I'm going to close it. Feel free to reopen if you all think that yt.units still hasn't outsourced enough to unyt. |
This issue tracks the task of replacing
yt.units
withunyt
: https://github.com/yt-project/unytThere are some differences in
unyt
with respect toyt.units
so we will need to be careful to make sure that everything works the same after integrating. We also need to check the codebase to see if there are places where we can clean things up. These differences are summarized below:unyt
allows you to doe.g.
data_with_units + data_without_units*data_with_units.units
, which obviates the need to useunit_quantity
oruq
.erg * cm/km
, by default the result will be presented inerg
(e.g. thecm/km
will be converted to a constant that gets multiplied by the value of the object).unyt_array([1, 2, 3], 'code_length')
you don't get a yt-specific error message suggesting to useds.arr
like if you doYTArray([1, 2, 3], 'code_length')
.The text was updated successfully, but these errors were encountered: