[yt-users] line annotations, center and zooming

David Collins dcollins4096 at gmail.com
Mon Aug 12 12:58:35 PDT 2013


It's certainly not urgent.  I was expecting it to be something dumb I'm
doing, if it takes some work on your end it's pretty low priority.


On Mon, Aug 12, 2013 at 2:20 PM, Nathan Goldbaum <nathan12343 at gmail.com>wrote:

> Hey Dave,
>
> I'm looking at this but unfortunately it doesn't look like it will be a
> quick fix. I'm currently in Sunnyvale getting my car serviced but I'll need
> to drive back to Santa Cruz and head up to the office in 20 minutes or so.
>  Is this issue urgent or can it wait for a couple of days?  If it is I'll
> try to look at this tonight.
>
> -Nathan
>
>
>
>
> On Mon, Aug 12, 2013 at 9:25 AM, David Collins <dcollins4096 at gmail.com>wrote:
>
>> Hi again--
>>
>> Sorry, my last email didn't actually have a question in it.
>>
>> Does anyone know how to get the coordinates that the plot window uses
>> (after re-centering and zooming) and the coordinates of the
>> annotate_image_line to agree?
>>
>> Thanks,
>> d.
>>
>>
>> On Mon, Aug 12, 2013 at 12:14 PM, David Collins <dcollins4096 at gmail.com>wrote:
>>
>>> Hi, everybody--
>>>
>>> I'm having trouble getting plot_window coordinages and
>>> annotate_image_line coordinates to agree.  I have a small region that I'm
>>> trying to annotate with lines, and zoom in on.  I'm having trouble getting
>>> my coordinates working together.
>>>
>>> If I do
>>> proj = oober.pf.h.proj(ax,'Density',source=source)
>>> pw = proj.to_pw(center=proj_center,origin='domain' )
>>> pw.zoom( 1/size)
>>>
>>> I have the object centered on the plot and zoomed appropriately.  If I
>>> do
>>>
>>> proj = oober.pf.h.proj(ax,'Density',source=source)
>>> pw = proj.to_pw()
>>> pw.annotate_image_line(p1, p2, data_coords=True)
>>>
>>> the lines show up in the position I expect relative to my object.
>>> However, if I include both the re-centering in to_pw and the call to
>>> annotate_image_line, the line doesn't show up where I want relative to the
>>> object.  If I skip the data_coords or origin argument it doesn't seem to
>>> help.  I've dug around the docs and source but haven't sorted how to make
>>> the plot window coordinages and annotate_image_line coordinates agree.
>>>
>>> Thanks!
>>> d.
>>>
>>>
>>> --
>>> -- Sent from a computer.
>>>
>>
>>
>>
>> --
>> -- Sent from a computer.
>>
>> _______________________________________________
>> 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
>
>


-- 
-- Sent from a computer.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.spacepope.org/pipermail/yt-users-spacepope.org/attachments/20130812/60b8f1e2/attachment.html>


More information about the yt-users mailing list