Re: [yt-users] cutting plane not working or changed
Hi Nathan,
I finally got around to testing your code on LodegIt that uses the
IsolatedGalaxy data. I ran it as is except I added some plotting
statements (using matplotlib) at the end. I again do get the problem of
NaNs:
In [2]: run slice_prob_test.py
Parsing Hierarchy : 100%|██████████████████| 173/173 [00:00<00:00,
23359.45it/s]
/export/slavin/python/anaconda/lib/python2.7/site-packages/yt/visualization/fixed_resolution.py:546:
RuntimeWarning: invalid value encountered in divide
bounds).transpose()
(nan g/cm**3, nan g/cm**3)
True
Where the (nan g/cm**3... line is from the print(image.max()...
statement. Also np.any(np.isnan(image)) returns True. The image that is
produced is shown in the attached png file.
The RuntimeWarning is apparently associated with this statement:
buff = pixelize_off_axis_cartesian(
self.data_source['x'],
self.data_source['y'], self.data_source['z'],
self.data_source['px'],
self.data_source['py'],
self.data_source['pdx'],
self.data_source['pdy'], self.data_source['pdz'],
self.data_source.center,
self.data_source._inv_mat, indices,
self.data_source[item],
self.buff_size[0], self.buff_size[1],
bounds).transpose()
which is in the __getitem__ method of the ObliqueFixedResolutionBuffer
class. That's about all I could tell you at this point.
The package versions I'm using are yt 3.3.5, python 2.7.12, matplotlib
2.0.0 (running on Linux CentOS 6.8 if that matters).
Regards,
Jon
On Fri, Mar 10, 2017 at 4:05 PM,
Date: Fri, 10 Mar 2017 12:14:55 -0800 From: Nathan Goldbaum
To: Discussion of the yt analysis package Subject: Re: [yt-users] cutting plane not working or changed behavior Message-ID: Content-Type: text/plain; charset="utf-8" Hi Jonathan,
I'm not able to reproduce the behavior you're seeing with a test dataset (e.g. see http://paste.yt-project.org/show/7080/, this uses a dataset from yt-project.org/data).
Is there any chance you can share a dataset that triggers this? Alternatively, can you reproduce this using one of the test datasets on yt-project.org/data?
The yt curldrop might be useful to share a dataset that triggers the issue you're seeing, see docs.hub.yt. If you're not comfortable sharing the dataset publicly, feel free to share it with me off-list.
-Nathan
-- ________________________________________________________ Jonathan D. Slavin Harvard-Smithsonian CfA jslavin@cfa.harvard.edu 60 Garden Street, MS 83 phone: (617) 496-7981 Cambridge, MA 02138-1516 cell: (781) 363-0035 USA ________________________________________________________
Ah, apologies for not checking how yt behaves on a stable release. I'm able
to reproduce the behavior you're seeing on yt 3.3.5. It looks like this
behavior doesn't manifest itself on the yt branch, so it looks like some
changes we've made have "fixed" this since we branched off for yt 3.4 last
summer. I suspect this has something to do with the pixelizers being
rewritten to use compositing but I'd need to check in detail with hg bisect
to be sure.
Can you try testing out the development version of yt? You should be able
to build yt from source by uninstalling your current version of yt, cloning
the repository, checking out the "yt" branch, and running "python setup.py
develop". See this page for more details:
http://yt-project.org/docs/dev/installing.html#installing-yt-using-pip-or-fr...
Is the new behavior (wtihout the NaNs) what you expect?
I might try to backport this to the stable branch, but given that a lot of
code has changed in the pixelizers it might be difficult to backport just
this fix. Would you be ok with running on the development branch for now?
I'd ideally like to get yt 3.4.0 out the door by this summer.
On Wed, Mar 15, 2017 at 1:00 PM, Slavin, Jonathan
Hi Nathan,
I finally got around to testing your code on LodegIt that uses the IsolatedGalaxy data. I ran it as is except I added some plotting statements (using matplotlib) at the end. I again do get the problem of NaNs:
In [2]: run slice_prob_test.py Parsing Hierarchy : 100%|██████████████████| 173/173 [00:00<00:00, 23359.45it/s] /export/slavin/python/anaconda/lib/python2.7/site- packages/yt/visualization/fixed_resolution.py:546: RuntimeWarning: invalid value encountered in divide bounds).transpose() (nan g/cm**3, nan g/cm**3) True
Where the (nan g/cm**3... line is from the print(image.max()... statement. Also np.any(np.isnan(image)) returns True. The image that is produced is shown in the attached png file.
The RuntimeWarning is apparently associated with this statement: buff = pixelize_off_axis_cartesian( self.data_source['x'], self.data_source['y'], self.data_source['z'], self.data_source['px'], self.data_source['py'], self.data_source['pdx'], self.data_source['pdy'], self.data_source['pdz'], self.data_source.center, self.data_source._inv_mat, indices, self.data_source[item], self.buff_size[0], self.buff_size[1], bounds).transpose()
which is in the __getitem__ method of the ObliqueFixedResolutionBuffer class. That's about all I could tell you at this point.
The package versions I'm using are yt 3.3.5, python 2.7.12, matplotlib 2.0.0 (running on Linux CentOS 6.8 if that matters).
Regards, Jon
On Fri, Mar 10, 2017 at 4:05 PM,
wrote: Date: Fri, 10 Mar 2017 12:14:55 -0800 From: Nathan Goldbaum
To: Discussion of the yt analysis package Subject: Re: [yt-users] cutting plane not working or changed behavior Message-ID: Content-Type: text/plain; charset="utf-8" Hi Jonathan,
I'm not able to reproduce the behavior you're seeing with a test dataset (e.g. see http://paste.yt-project.org/show/7080/, this uses a dataset from yt-project.org/data).
Is there any chance you can share a dataset that triggers this? Alternatively, can you reproduce this using one of the test datasets on yt-project.org/data?
The yt curldrop might be useful to share a dataset that triggers the issue you're seeing, see docs.hub.yt. If you're not comfortable sharing the dataset publicly, feel free to share it with me off-list.
-Nathan
-- ________________________________________________________ Jonathan D. Slavin Harvard-Smithsonian CfA jslavin@cfa.harvard.edu 60 Garden Street, MS 83 phone: (617) 496-7981 Cambridge, MA 02138-1516 cell: (781) 363-0035 USA ________________________________________________________
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
participants (2)
-
Nathan Goldbaum
-
Slavin, Jonathan