[AstroPy] Inheriting HDUList

Joe Philip Ninan indiajoe at gmail.com
Mon Feb 3 06:35:12 EST 2014


Hi John,
Thanks a lot for the link.
On a quick look, it doesn't seem very obvious to me how exactly to
load the data along with initialising the HDUList.
But i shall go through it more carefully to understand.
Thanks again,
-cheers
joe

On 2 February 2014 20:04, John ZuHone <jzuhone at gmail.com> wrote:
> Hi Joe,
>
> Have a look at this one:
>
> https://bitbucket.org/yt_analysis/yt/src/6120c77c828f195f8691806fc724bb730fe90680/yt/utilities/fits_image.py?at=yt-3.0
>
> Best,
>
> John Z
>
> On Feb 2, 2014, at 9:10 AM, Joe Philip Ninan <indiajoe at gmail.com> wrote:
>
>> Hi,
>> Is there any online example of how to create a new child object from HDUList of astropy.io.fits ?  (The object astropy.io.fits.open() returns).
>> I want to create an object class which inherits everything from HDUList, and then add some additional functions.
>> The part i cannot figure out is how to initialize the HDUList inside the new class.
>>
>> class MyFitsObject(HDUList):
>>     def __init__(self,filename):
>>     # How do i initialise HDUList here, when all i have is the Fits File name?
>>
>> -cheers
>> joe
>>
>>
>> --
>> /---------------------------------------------------------------
>> "GNU/Linux: because a PC is a terrible thing to waste" -  GNU Generation
>>
>> ************************************************
>> Joe Philip Ninan
>> Research Scholar        /________________\
>> DAA,                            | Vadakeparambil |
>> TIFR,                           | Pullad P.O.         |
>> Mumbai-05, India.      | Kerala, India      |
>> Ph: +917738438212   | PIN:689548       |
>> ------------------------------\_______________/--------------
>> _______________________________________________
>> AstroPy mailing list
>> AstroPy at scipy.org
>> http://mail.scipy.org/mailman/listinfo/astropy
>



-- 
/---------------------------------------------------------------
"GNU/Linux: because a PC is a terrible thing to waste" -  GNU Generation

************************************************
Joe Philip Ninan
Research Scholar        /________________\
DAA,                            | Vadakeparambil |
TIFR,                           | Pullad P.O.         |
Mumbai-05, India.      | Kerala, India      |
Ph: +917738438212   | PIN:689548       |
------------------------------\_______________/--------------



More information about the AstroPy mailing list