Hi all,

So one of the main reasons why this is so messy, IMO, is that we don't have a self-describing image.  All we have is a numpy array.  Would it worthwhile to do something like create an ImageArray, which subclasses numpy ndarray? 

http://docs.scipy.org/doc/numpy/user/basics.subclassing.html#simple-example-adding-an-extra-attribute-to-ndarray

We could then append on things like x-axis, y-axis, optionally things like field names, and who knows what else?  For example:
http://nbviewer.ipython.org/url/hub.yt-project.org/notebooks/2225815c19a844c9974838543f09e267.ipynb

This would significantly help manage the rendering output since we lose info about the image as soon as we lose the camera.  We could additionally write a thin layer to save these images out in hdf5, looping over the info dictionary for attributes.  

Thoughts?

Sam

On Fri, Sep 28, 2012 at 1:00 PM, Matthew Turk <matthewturk@gmail.com> wrote:
Hi all,

We got an anonymous bug today.  My guess is this is related to the
transpose in write_image.

-Matt


---------- Forwarded message ----------
From: Anonymous <issues-reply@bitbucket.org>
Date: Fri, Sep 28, 2012 at 7:32 AM
Subject: [yt_analysis/yt] annotate_image (issue #430)
To: matthewturk@gmail.com


--- you can reply above this line ---

New issue 430: annotate_image
https://bitbucket.org/yt_analysis/yt/issue/430/annotate_image

Anonymous:

Text is transposed with annotate_image.


--

This is an issue notification from bitbucket.org. You are receiving
this either because you are the owner of the issue, or you are
following the issue.
_______________________________________________
yt-dev mailing list
yt-dev@lists.spacepope.org
http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org