[yt-dev] filtered_type kwarg in @particle_filter
Matthew Turk
matthewturk at gmail.com
Tue Dec 3 11:07:58 PST 2013
Hi Britton,
On Tue, Dec 3, 2013 at 1:56 PM, Matthew Turk <matthewturk at gmail.com> wrote:
> Hi Britton,
>
> On Tue, Dec 3, 2013 at 1:48 PM, Britton Smith <brittonsmith at gmail.com> wrote:
>> Hi all,
>>
>> I'm working with particle filters for the first time and I'm unclear on the
>> role of the filtered_type keyword. For example, in the following script:
>> http://paste.yt-project.org/show/4099/
>> I define filters that should catch every single particle in an Enzo-3.0
>> dataset. My understanding of the filtered_type keyword is that is
>> preselected which type of particles to pass through the filter.
>> In this dataset, I have the following particles:
>> Type Number
>> DarkMatter 32768
>> CenOstriker 10543
>> Total 43311
>>
>> So, my understanding is that
>> print ad['finest_all', 'particle_mass'].size
>> should print 43311 and
>> print ad['finest_all', 'particle_mass'].size
>> should print 32768.
>>
>> However, they both print 43311. Is this a bug or am I not understanding
>> what filtered_type is supposed to do?
I modified your example slightly:
http://paste.yt-project.org/show/4100/
and got output that looks right to me.
CenOstriker 824
DarkMatter 32765
all 33589
finest 32765
finest_all 33589
finest 32765
finest_all 33589
I'm on 500acd8e6551; which one are you on? (If it's the units
refactor, that has not been updated yet to the latest tip of yt-3.0.)
-Matt
>
> Can you upload the dataset -- which I think will be a good,
> representative example of Enzo-3.0 -- to the data directory?
>
> -Matt
>
>>
>> Britton
>>
>> _______________________________________________
>> yt-dev mailing list
>> yt-dev at lists.spacepope.org
>> http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org
>>
More information about the yt-dev
mailing list