[yt-users] Trouble plotting 1D scatter data from 3D Athena vtk data.

Matthew Turk matthewturk at gmail.com
Tue Aug 20 11:51:40 PDT 2013


On Tue, Aug 20, 2013 at 2:44 PM, Timothy Waters
<waterst3 at unlv.nevada.edu> wrote:
> Hi again,
>
> That did the trick!!!!  So there was a small bug with that dictionary I take
> it.  I've been sweating bullets because my advisor wanted me to just use IDL
> if I couldn't get up and running with yt.  And I am so very tired of the
> wasted hours that accompany IDL scripts!!!

Oh, awesome!  That's great to hear.  :)  As a quick note, this bug was
discovered in the process of adding answer testing for Athena; Athena
has been a pretty active area of development, especially thanks to
John ZuHone, Sam Skillman and Nathan Goldbaum.

If you run into any other problems, let us know!

-Matt

>
> Many thanks,
> Tim
>
>
> On Tue, Aug 20, 2013 at 11:06 AM, Matthew Turk <matthewturk at gmail.com>
> wrote:
>>
>> Hi Tim,
>>
>> On Tue, Aug 20, 2013 at 1:03 PM, Timothy Waters
>> <waterst3 at unlv.nevada.edu> wrote:
>> > Hi Matt,
>> >
>> > I greatly appreciate the help.  The pictures you see are what I get on a
>> > first run using
>> > %run scatter3DAthenaData.py
>> > Whether or not I then close the plot window, issuing %run
>> > scatter3DAthenaData.py again brings up a new plot with the mess of
>> > points.
>> > So maybe this is just specific to my install?  I suppose I should try
>> > running it on my linux box then.
>>
>> It's possible, but I'm not entirely sure yet.  There were some recent
>> changes to Athena, which actually relate to retaining state in between
>> iterations, so let's have a shot at that first.  (There was a
>> dictionary being put in the class structure which could be mutable in
>> between iterations.)
>>
>> After activating, try:
>>
>> cd /Users/Macbook/Virtualenvs/yt/yt-x86_64/src/yt-hg
>> hg pull -r yt
>> hg up -C -r yt
>> python2.7 setup.py build_ext -i -f
>>
>> and try running again?
>>
>> -Matt
>>
>> >
>> > Here is the output of yt instinfo:
>> > (yt-x86_64)Macbook$ yt instinfo:
>> > %
>> > yt module located at:
>> >     /Users/Macbook/Virtualenvs/yt/yt-x86_64/src/yt-hg
>> > The supplemental repositories are located at:
>> >     /Users/Macbook/Virtualenvs/yt/yt-x86_64/src/yt-supplemental
>> >
>> > The current version of the code is:
>> >
>> > ---
>> > cde0a641f1bf
>> > ---
>> >
>> > This installation CAN be automatically updated.
>> > yt dependencies were last updated on
>> > Tue Aug 13 16:45:11 PDT 2013
>> > %
>> >
>> > Also, here is the output from %run scatter3DAthenaData.py:
>> >
>> > %
>> > yt : [INFO     ] 2013-08-20 09:59:25,321 Temporarily setting
>> > domain_right_edge = -domain_left_edge. This will be corrected
>> > automatically
>> > if it is not the case.
>> > yt : [INFO     ] 2013-08-20 09:59:25,323 Parameters: current_time
>> > = 15.0
>> > yt : [INFO     ] 2013-08-20 09:59:25,323 Parameters: domain_dimensions
>> > = [32 32 32]
>> > yt : [INFO     ] 2013-08-20 09:59:25,324 Parameters: domain_left_edge
>> > = [-0.5 -0.5 -0.5]
>> > yt : [INFO     ] 2013-08-20 09:59:25,325 Parameters: domain_right_edge
>> > = [ 0.5  0.5  0.5]
>> > yt : [INFO     ] 2013-08-20 09:59:25,325 Parameters:
>> > cosmological_simulation
>> > = 0.0
>> > Nx,Ny,Nz =  [40 40 40]
>> > cell sizes (x,y,z) =  [ 0.03125  0.03125  0.03125]
>> > yt : [INFO     ] 2013-08-20 09:59:25,327 Getting field x from 1
>> > yt : [INFO     ] 2013-08-20 09:59:25,345 Getting field y from 1
>> > yt : [INFO     ] 2013-08-20 09:59:25,353 Getting field z from 1
>> > yt : [INFO     ] 2013-08-20 09:59:25,361 Getting field density from 1
>> > yt : [INFO     ] 2013-08-20 09:59:25,370 Getting field momentum_x from 1
>> > yt : [INFO     ] 2013-08-20 09:59:25,381 Getting field momentum_y from 1
>> > yt : [INFO     ] 2013-08-20 09:59:25,389 Getting field momentum_z from 1
>> > %
>> >
>> > Thanks again!
>> >
>> >
>> > On Tue, Aug 20, 2013 at 8:43 AM, Matthew Turk <matthewturk at gmail.com>
>> > wrote:
>> >>
>> >> Hi Tim,
>> >>
>> >> Thanks for writing, and welcome to yt!
>> >>
>> >> On Sun, Aug 18, 2013 at 8:53 PM, Timothy Waters
>> >> <waterst3 at unlv.nevada.edu> wrote:
>> >> > Hi,
>> >> >
>> >> > Here is the data and simple script to make a scatter or profile plot
>> >> > of
>> >> > my
>> >> > simulation output,
>> >> > https://www.dropbox.com/sh/ibpda938ltsxl0j/2AA2FYDUH8#/
>> >> >
>> >> > This is a spherically symmetric (cartesian [-0.5,0.5]^3, 32cells^3)
>> >> > hydro
>> >> > simulation with initial conditions
>> >> > density = 1.0 if radius <= 1/3;
>> >> > density falls off as 1/r^2 if r > 1/3;
>> >> > velocity is everywhere 0
>> >> >
>> >> > The output with these ICs is WP12.0000.vtk.  When I run my script the
>> >> > first
>> >> > time using iyt I get the first image with the expected ICs.  Running
>> >> > it
>> >> > again gives the second image and I don't know why.  I'm hoping those
>> >> > other
>> >> > points don't actually exist in my data.  Maybe I am just missing
>> >> > something
>> >> > simple?
>> >>
>> >> I'm not sure.  I haven't been able to replicate the problem here, but
>> >> I have a handful of suspicions.  I was able to generate these two
>> >> images, one for the 0000 dataset and the second for 0030.
>> >>
>> >> http://i.imgur.com/cxnDVjO.png
>> >> http://i.imgur.com/MPUSQVH.png
>> >>
>> >> Can you tell me a bit more specifically how you're running the script?
>> >>  You start up iyt, then do %run , and then %run again?  Does it happen
>> >> if you do:
>> >>
>> >> %run scatter3DAthenaData.py
>> >> %run scatter3DAthenaData.py
>> >>
>> >> and look at the resultant plot?  (It does not for me, FWIW.)  Does it
>> >> happen if you do multiple datasets in a row?
>> >>
>> >> What's the output of:
>> >>
>> >> yt instinfo
>> >>
>> >> specifically, the changeset hash it provides.
>> >>
>> >> >
>> >> > The evolved data, WP12.0030.vtk, is provided as well.  Running this
>> >> > data
>> >> > 'cleans the slate' so that I can then go back to see the problem with
>> >> > my
>> >> > initial conditions again.  Of course, the problem shows up in this
>> >> > data
>> >> > too.
>> >>
>> >> Interesting.  I do not believe that there is a problem with your data,
>> >> but we'll get to the bottom of it!
>> >>
>> >> Best,
>> >>
>> >> Matt
>> >>
>> >> >
>> >> > Thanks in advance!
>> >> > Tim
>> >> >
>> >> >
>> >> > _______________________________________________
>> >> > yt-users mailing list
>> >> > yt-users at lists.spacepope.org
>> >> > http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
>> >> >
>> >> _______________________________________________
>> >> yt-users mailing list
>> >> yt-users at lists.spacepope.org
>> >> http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
>> >
>> >
>> >
>> > _______________________________________________
>> > yt-users mailing list
>> > yt-users at lists.spacepope.org
>> > http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
>> >
>> _______________________________________________
>> yt-users mailing list
>> yt-users at lists.spacepope.org
>> http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
>
>
>
> _______________________________________________
> yt-users mailing list
> yt-users at lists.spacepope.org
> http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
>



More information about the yt-users mailing list