Dear all: I need use the "project_light_core" in my work. If the key word "weight_field " = None, I can obtain my results. But I should set a weighted field, when I set weight_filed = 'density', I received a error like: I found that the 'density' can not be set to weight_field, I have no ideal about this. Traceback (most recent call last): File "./light_core_projection.py", line 37, in <module> njobs=1) File "/mnt/ddnfs/data_users/xllian/software/yt/yt/analysis_modules/cosmological_observation/light_cone/light_cone.py", line 343, in project_light_cone frb["weight_field"]), File "/mnt/ddnfs/data_users/xllian/software/yt/yt/visualization/fixed_resolution.py", line 134, in __getitem__ int(self.antialias)) File "/mnt/ddnfs/data_users/xllian/software/yt/yt/geometry/coordinates/cartesian_coordinates.py", line 158, in pixelize antialias, dimension, periodic) File "/mnt/ddnfs/data_users/xllian/software/yt/yt/geometry/coordinates/cartesian_coordinates.py", line 225, in _ortho_pixelize finfo = self.ds._get_field_info(field) File "/mnt/ddnfs/data_users/xllian/software/yt/yt/data_objects/static_output.py", line 773, in _get_field_info raise YTFieldNotFound((ftype, fname), self) yt.utilities.exceptions.YTFieldNotFound: Could not find field '('all', 'weight_field')' in RD0033. Thanks all
Even I got the same error when I tested it with the available yt-ENZO data set (enzo_tiny_cosmology) and also with my simulations. It gives the result if weight_field = None otherwise showing the same error. I tried with many weight fields even with the ENZO fields like "Density" instead of yt one "density".
May somebody can help in this regard. Thanks -Prateek
On Fri, Nov 2, 2018 at 7:39 AM lianxiaoli87@sjtu.edu.cn wrote:
Dear all: I need use the "project_light_core" in my work. If the key word "weight_field " = None, I can obtain my results. But I should set a weighted field, when I set weight_filed = 'density', I received a error like: I found that the 'density' can not be set to weight_field, I have no ideal about this. Traceback (most recent call last): File "./light_core_projection.py", line 37, in <module> njobs=1) File "/mnt/ddnfs/data_users/xllian/software/yt/yt/analysis_modules/cosmological_observation/light_cone/light_cone.py", line 343, in project_light_cone frb["weight_field"]), File "/mnt/ddnfs/data_users/xllian/software/yt/yt/visualization/fixed_resolution.py", line 134, in __getitem__ int(self.antialias)) File "/mnt/ddnfs/data_users/xllian/software/yt/yt/geometry/coordinates/cartesian_coordinates.py", line 158, in pixelize antialias, dimension, periodic) File "/mnt/ddnfs/data_users/xllian/software/yt/yt/geometry/coordinates/cartesian_coordinates.py", line 225, in _ortho_pixelize finfo = self.ds._get_field_info(field) File "/mnt/ddnfs/data_users/xllian/software/yt/yt/data_objects/static_output.py", line 773, in _get_field_info raise YTFieldNotFound((ftype, fname), self) yt.utilities.exceptions.YTFieldNotFound: Could not find field '('all', 'weight_field')' in RD0033. Thanks all
yt-users mailing list -- yt-users@python.org To unsubscribe send an email to yt-users-leave@python.org
Hi,
Thanks to you both for reporting and confirming. This looks like a genuine bug to me. I've opened an issue up in the yt_astro_analysis package, where the LightCone module has moved. https://github.com/yt-project/yt_astro_analysis/issues/36
I should be able to check this out in the next few days.
Britton
On Fri, Nov 2, 2018 at 12:17 AM Prateek Gupta prateekgidolia@gmail.com wrote:
Even I got the same error when I tested it with the available yt-ENZO data set (enzo_tiny_cosmology) and also with my simulations. It gives the result if weight_field = None otherwise showing the same error. I tried with many weight fields even with the ENZO fields like "Density" instead of yt one "density".
May somebody can help in this regard. Thanks -Prateek
On Fri, Nov 2, 2018 at 7:39 AM lianxiaoli87@sjtu.edu.cn wrote:
Dear all: I need use the "project_light_core" in my work. If the key word "weight_field " = None, I can obtain my results. But I should set a weighted field, when I set weight_filed = 'density', I received a error like: I found that the 'density' can not be set to weight_field, I have no ideal about this. Traceback (most recent call last): File "./light_core_projection.py", line 37, in <module> njobs=1) File "/mnt/ddnfs/data_users/xllian/software/yt/yt/analysis_modules/cosmological_observation/light_cone/light_cone.py", line 343, in project_light_cone frb["weight_field"]), File "/mnt/ddnfs/data_users/xllian/software/yt/yt/visualization/fixed_resolution.py", line 134, in __getitem__ int(self.antialias)) File "/mnt/ddnfs/data_users/xllian/software/yt/yt/geometry/coordinates/cartesian_coordinates.py", line 158, in pixelize antialias, dimension, periodic) File "/mnt/ddnfs/data_users/xllian/software/yt/yt/geometry/coordinates/cartesian_coordinates.py", line 225, in _ortho_pixelize finfo = self.ds._get_field_info(field) File "/mnt/ddnfs/data_users/xllian/software/yt/yt/data_objects/static_output.py", line 773, in _get_field_info raise YTFieldNotFound((ftype, fname), self) yt.utilities.exceptions.YTFieldNotFound: Could not find field '('all', 'weight_field')' in RD0033. Thanks all
yt-users mailing list -- yt-users@python.org To unsubscribe send an email to yt-users-leave@python.org
yt-users mailing list -- yt-users@python.org To unsubscribe send an email to yt-users-leave@python.org
Hi again,
I've issued a pull request to the yt_astro_analysis module that should fix this issue. Please have a look at that at the link below if you like. https://github.com/yt-project/yt_astro_analysis/pull/37
Note that you'll need to install yt_astro_analysis (from source) and update the imports in your script accordingly. You can find information on how to do both of those here: https://yt-astro-analysis.readthedocs.io/
Let us know if you have any questions or something still doesn't work right.
Britton
On Sat, Nov 3, 2018 at 8:09 PM lianxiaoli87@sjtu.edu.cn wrote:
Thanks, Looking forward to your solution!
yt-users mailing list -- yt-users@python.org To unsubscribe send an email to yt-users-leave@python.org
Hi Britton:
I obtain a projected temperate map weighted by density using light_core
projection. I received a filed named "temperature_density" in unit of "K*g*cm**2", and
another field named "weight_field_density" in unit of "g*cm**2". Is the unit of
"temperature _density" right? Or yay I get the pure "temperature" in unit of "K" by
dividing "temperature_density"/"weight_field_density" ?
Looking forwards to your reply! Thanks!
Hi,
Yes, you get the final values by doing temperature_density / weight_field_density.
Britton
On Wed, Nov 14, 2018 at 7:01 PM lianxiaoli87@sjtu.edu.cn wrote:
Hi Britton:
I obtain a projected temperate map weighted by density using
light_core projection. I received a filed named "temperature_density" in unit of "Kgcm2", and another field named "weight_field_density" in unit of "g*cm2". Is the unit of "temperature _density" right? Or yay I get the pure "temperature" in unit of "K" by dividing "temperature_density"/"weight_field_density" ?
Looking forwards to your reply! Thanks!
yt-users mailing list -- yt-users@python.org To unsubscribe send an email to yt-users-leave@python.org