[AstroPy] A simple python module, wrapping pytfits+matplotlib: fits I/O + graphic/display environment

Eric Emsellem emsellem at obs.univ-lyon1.fr
Fri May 5 11:49:27 CDT 2006


>>
>> Image1.fits = Image2.fits / (Image3.fits + 3.4)
>>
> This kind of syntax would not work in Python without some sort of 
> special interpretation since Python would not find ImageX.fits in the 
> current namespace. That means you have to think about what context you 
> want this kind of capability to work in. As a special, non-Python 
> command language that gets translated into python (pyraf does that for 
> IRAF-like commands)?
yes indeed this was a puzzle I wanted to solve (include the potential of 
a syntax interpretation) but did not know how to address. I will first 
see if this is really necessary at this stage since it may a major 
complication (for me).

>>
> I suppose I would say the idea needs a bit more definition as to whether 
> it is enhancement to python libraries or a new kind of shell.
agreed. I need to first work a little more on this, see what I really 
need to develop and what I can just inherit from  python+pyfits etc .
I guess I will have a try at it, send the whole thing with some examples 
and wait for reactions...


> Yes, but this is a bad time for us at STScI for the next month or two 
> (we are really spread thinly over several projects; hopefully it won't 
> be so bad in a couple months)
> So I'd say that it would be hard for us to provide much help or even 
> advice in the very short term.

well, it is always good to know there are experts around. I have waited 
1 year so far to really start things. Waiting another number of months 
is not a problem (the sooner the better, but this is only a "best 
effort", so..).

On May 4, 2006, at 6:56 PM, James Turner wrote:
>> If you would rather work with FITS files, I'm guessing it's for one of
>> three (good) reasons: 1) you want to save all your intermediate results
>> to disk, 2) you need to propagate headers, variance extensions etc.,

>Note that 2) is a common desire, but think about how easy it is in practice. 
>When presented with two headers with conflicting header info, which does one use, 
>the first,  or some combination when adding two fits files? This is always much harder 
>to do well in practice. Given the complex arrangements FITS files can have, I have my
>doubts about this being a really useful reason outside of doing very simple things 
>(in essence, saying that one doesn't care that much about what is in the headers or 
>how different entities are related in fits files)

agreed, If this is the way to go, we need CLEAR but also USEFUL! rules.
I already thought a little about this and there are simple cases we can 
treat (as when we wish to do spec1 + spec2, where we check the step and 
start - to see if these are concomitant - and then do the work on the 
intersection only for example). Again, this has to be worth it.

and thanks for the warning about pyraf and ipython. Useful indeed. (but 
I am not an Iraf fan here, as a practical tool I mean)

thanks a lot for the input.

Cheers
Eric
-- 
====================================================================
Eric Emsellem                             emsellem at obs.univ-lyon1.fr
                            Centre de Recherche Astrophysique de Lyon
9 av. Charles-Andre                        tel: +33 (0)4 78 86 83 84
69561 Saint-Genis Laval Cedex              fax: +33 (0)4 78 86 83 86
France                    http://www-obs.univ-lyon1.fr/eric.emsellem
====================================================================



More information about the AstroPy mailing list