[AstroPy] numpy; bulk coordinate conversions

Andrew Jaffe a.jaffe at imperial.ac.uk
Fri May 12 04:48:36 CDT 2006

Hi Victoria,

Victoria G. Laidler writes:
 > Andrew Jaffe wrote:
 > >Hi-
 > >
 > >Actually, I wasn't talking about offline storage, really -- I was
 > >really talking nted to know what sort of array/list/etc to use
 > >within python. I was already planning on using the routines from
 > >coord.position, but it seems that there's likely a lot of overhead
 > >in storing many individual position objects, especially when I'll
 > >want to do the same conversions on each of them.
 > >
 > Hi Andrew,
 > I would give it a try, anyway - I've worked with a catalog of 10**4
 > objects without difficulty, although I was doing angular separation
 > calculations rather than coordinate transformations.
 > I used a simple list of Positions, if I recall correctly, since I was
 > just looping through them. Or maybe a dictionary, with object id as
 > key and Position as value.

Well, I think it would be useful to be well-integrated into numpy as it
becomes more and more standard. I'm not sure if that argues for an
object array or some sort of specific array subclass to avoid
duplication of information.

 > Eventually we do want to either:
 >    - enhance Position so it can internally hold an array of positions, 
 > all with the same equinox, coordinate system, etc; or,
 >    - define a new Catalog object, which would be an array of positions, 
 > all with the same equinox, coordinate system, etc; and had a similar
 > set of methods as Position that would operate on the whole catalog --
 > as well as some methods that only make sense on Catalogs.
 > The latter makes more sense to me, but there may be some software
 > maintenance reasons to opt for the former.

Both of these sound very much like an internal representation of at
least some aspects of the VOTable object. Are there thoughts about doing
any of this in a VO context? [I guess one interesting question not quite
on the same topic is whether there are plans to make something similar
to pyfits for VOTable files...]

 > What else are you going to do with these positions, besides transform
 > them? Maybe a real use case will help settle this question.

And for my personal work -- CMB -- the 'catalog' isn't really the
fundamental object; rather it's a 'map' with some pixelization (usually
healpix for large-ish maps). Indeed for me the ideal object would carry
along all of healpix's capabilities, including transformations to
spherical-harmonic components. Additionally, I would need to be able to
get angular separations between points (potentially O(N^2) operations
like correlation functions), compare to other maps (and catalogs!), etc.



Andrew Jaffe				        a.jaffe at imperial.ac.uk
Astrophysics Group                                    +44 207 594-7526
Blackett Laboratory, Room 1013                    FAX             7541
Imperial College, Prince Consort Road
London SW7 2AZ ENGLAND              http://astro.imperial.ac.uk/~jaffe

More information about the AstroPy mailing list