[yt-users] create_profile in 3.0

Matthew Turk matthewturk at gmail.com
Mon Nov 17 06:56:58 PST 2014


Hi John,

This comes from the difference in how "particle_mass" and "all_density" are
generated -- all_density is a deposited field, where it's deposited onto
the mesh, so it will work if you use a mesh quantity.  particle_mass is
discrete, so it needs a discrete field, like particle_radius.

I think if you specify a weight that is a discrete, your latter command
will work too.

-Matt

On Mon Nov 17 2014 at 8:55:03 AM John Regan <johnanthonyregan at gmail.com>
wrote:

> Hi All,
>
>
> I was wondering about the behaviour of create_profile in 3.0.
>
> If I do something like
>
> yt.create_profile(sphere, 'particle_radius',  'all_density')
>
> it will fail but
>
> yt.create_profile(sphere, 'radius',  'all_density')
>
> will succeed.
>
> And
> yt.create_profile(sphere, 'particle_radius', 'particle_mass',
>                             weight_field=None)
>
> will also be OK as long as I set the weight_field = None otherwise it
> fails.
>
>
> I'm able to plot enclosed dark matter profiles but when it comes to
> density profiles the above difficulties are proving troublesome :)
>
> Any tips would be appreciated! Simple script attached.
>
> John
>
>
> _______________________________________________
> yt-users mailing list
> yt-users at lists.spacepope.org
> http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.spacepope.org/pipermail/yt-users-spacepope.org/attachments/20141117/91f4dae1/attachment.htm>


More information about the yt-users mailing list