Hi Chien-Chang,

I can reproduce this and have filed an issue here: https://github.com/yt-project/yt/issues/2116

I think it’s related to axis naming issue under curvilinear geometries. And at the same time, you could try the workaround by getting the sphere object first, and use cut region to get z > 0 later.

Best regards,

Suoqing Ji
Sherman Fairchild Fellow
TAPIR & Walter Burke Institute for Theoretical Physics
California Institue of Technology
http://www.tapir.caltech.edu/~suoqing

On Dec 7, 2018, at 12:03 AM, Chien-Chang Feng <ccfeng@astron.s.u-tokyo.ac.jp> wrote:

Hi, 

I’m trying to make a selected region in a 2D cylindrical dataset from FLASH using cut_region
and calculate some quantities like this:

ds = yt.load('WDMerger_hdf5_chk_1000.hdf5')
ad = ds.all_data()
upper_ad = ad.cut_region(["obj['z'] > 0 “])

sp = ds.sphere((0, 0, 0), (6E10, 'cm'), data_source=upper_ad)
sp.quantities.total_mass()

And I got this error:

_______________________________________________
yt-users mailing list -- yt-users@python.org
To unsubscribe send an email to yt-users-leave@python.org