From embray at stsci.edu Wed Jan 2 18:33:29 2013 From: embray at stsci.edu (Erik Bray) Date: Wed, 2 Jan 2013 18:33:29 -0500 Subject: [AstroPy] [ANN] Happy New Year: It's a new PyFITS version Message-ID: <50E4C3C9.90302@stsci.edu> Hello all, Today two new versions of PyFITS were released: 3.0.10 and 3.1.1. These are both bug fix releases without any significant new features. Many of the bug fixes in 3.1.1 were backported to 3.0.10 where applicable for those who have not yet upgraded to 3.1.x. 3.0.10 also included some slight tweaks to the header interface that should help ease the transition to 3.1.x. Otherwise most of the issues fixed are rare or minor. The full changelogs for both versions can be read here: http://packages.python.org/pyfits/appendix/changelog.html As usual, both new versions are available for download from PyPI: http://pypi.python.org/pypi/pyfits/3.1.1 http://pypi.python.org/pypi/pyfits/3.0.10 PyFITS 3.1.1 will likely be the version included in the next release of stsci_python as well, barring any major issues that need to be fixed in the meantime. Let me know if there are any problems, Erik From sergiopr at fis.ucm.es Thu Jan 3 20:14:20 2013 From: sergiopr at fis.ucm.es (=?ISO-8859-1?Q?Sergio_Pascual_Ram=EDrez?=) Date: Fri, 4 Jan 2013 02:14:20 +0100 Subject: [AstroPy] [ANN] Happy New Year: It's a new PyFITS version In-Reply-To: <50E4C3C9.90302@stsci.edu> References: <50E4C3C9.90302@stsci.edu> Message-ID: Hi Erik, the header files inside pyfits-3.0.10/src seem to be missing When installing from PyPI, I get the following: src/fits_hcompress.c:109:20: fatal error: fitsio.h: No such file or directory compilation terminated. error: command 'gcc' failed with exit status 1 2013/1/3 Erik Bray : > Hello all, > > Today two new versions of PyFITS were released: 3.0.10 and 3.1.1. These are > both bug fix releases without any significant new features. Many of the bug > fixes in 3.1.1 were backported to 3.0.10 where applicable for those who have not > yet upgraded to 3.1.x. 3.0.10 also included some slight tweaks to the header > interface that should help ease the transition to 3.1.x. > > Otherwise most of the issues fixed are rare or minor. The full changelogs for > both versions can be read here: > http://packages.python.org/pyfits/appendix/changelog.html > > As usual, both new versions are available for download from PyPI: > > http://pypi.python.org/pypi/pyfits/3.1.1 > http://pypi.python.org/pypi/pyfits/3.0.10 > > PyFITS 3.1.1 will likely be the version included in the next release of > stsci_python as well, barring any major issues that need to be fixed in the > meantime. > > Let me know if there are any problems, > > Erik > _______________________________________________ > AstroPy mailing list > AstroPy at scipy.org > http://mail.scipy.org/mailman/listinfo/astropy -- Sergio Pascual http://guaix.fis.ucm.es/~spr +34 91 394 5018 gpg fingerprint: 5203 B42D 86A0 5649 410A F4AC A35F D465 F263 BCCC Departamento de Astrof?sica -- Universidad Complutense de Madrid (Spain) From embray at stsci.edu Fri Jan 4 10:47:55 2013 From: embray at stsci.edu (Erik Bray) Date: Fri, 4 Jan 2013 10:47:55 -0500 Subject: [AstroPy] [ANN] Happy New Year: It's a new PyFITS version In-Reply-To: References: <50E4C3C9.90302@stsci.edu> Message-ID: <50E6F9AB.6070604@stsci.edu> Thanks Sergio, I have updated and re-uploaded the archive. I think I had this problem with the 3.0.9 release too--an annoyance related to setuptools' lack of support for Subversion 1.7. Not likely to be a problem in future releases. Erik On 01/03/2013 08:14 PM, Sergio Pascual Ram?rez wrote: > Hi Erik, > > the header files inside pyfits-3.0.10/src seem to be missing > > When installing from PyPI, I get the following: > > src/fits_hcompress.c:109:20: fatal error: fitsio.h: No such file or directory > > compilation terminated. > > error: command 'gcc' failed with exit status 1 > > 2013/1/3 Erik Bray: >> Hello all, >> >> Today two new versions of PyFITS were released: 3.0.10 and 3.1.1. These are >> both bug fix releases without any significant new features. Many of the bug >> fixes in 3.1.1 were backported to 3.0.10 where applicable for those who have not >> yet upgraded to 3.1.x. 3.0.10 also included some slight tweaks to the header >> interface that should help ease the transition to 3.1.x. >> >> Otherwise most of the issues fixed are rare or minor. The full changelogs for >> both versions can be read here: >> http://packages.python.org/pyfits/appendix/changelog.html >> >> As usual, both new versions are available for download from PyPI: >> >> http://pypi.python.org/pypi/pyfits/3.1.1 >> http://pypi.python.org/pypi/pyfits/3.0.10 >> >> PyFITS 3.1.1 will likely be the version included in the next release of >> stsci_python as well, barring any major issues that need to be fixed in the >> meantime. >> >> Let me know if there are any problems, >> >> Erik >> _______________________________________________ >> AstroPy mailing list >> AstroPy at scipy.org >> http://mail.scipy.org/mailman/listinfo/astropy > > > From derek at astro.physik.uni-goettingen.de Mon Jan 7 10:50:05 2013 From: derek at astro.physik.uni-goettingen.de (Derek Homeier) Date: Mon, 7 Jan 2013 16:50:05 +0100 Subject: [AstroPy] With Python to your first Nature paper... Message-ID: Happy New Year everyone! I thought this might be of interest to the list as confirmation and motivation of your work: how a 15-year old started out learning Python as part of a summer research project and ended up co-author of a Nature paper on galaxy formation (and he is the son of Rodrigo Ibata, so a bit of it must be running in the family? ;-) http://www.rfi.fr/france/20130106-france-lyceen-neil-ibata-15-archimede-decouverte-cnrs-galaxie-nature http://www.nature.com/nature/journal/v493/n7430/full/nature11717.html Cheers, Derek -- ---------------------------------------------------------------- Derek Homeier Centre de Recherche Astrophysique de Lyon ENS Lyon 46, All?e d'Italie 69364 Lyon Cedex 07, France +33 47272-8894 ---------------------------------------------------------------- From colin.navin at students.mq.edu.au Thu Jan 10 01:13:39 2013 From: colin.navin at students.mq.edu.au (COLIN NAVIN) Date: Thu, 10 Jan 2013 17:13:39 +1100 Subject: [AstroPy] Newbie installation problems Message-ID: Hi I am trying to install some packages as part of the installation process outlined in Installing Scientific Python on the Python4Astronomers site. I chose the EDP Academic distribution for Mac OSX 10.8 and installed the core Python okay including gcc and gfortran. When I come to the section about installing and checking additional packages, some install fine (asciitable, pyfits and pyparsing). Others (pywcs, atpy, aplpy, and pyregion) give installation errors. For example pip install --upgrade pywcs stops with an error message wcslib/C/wcserr.c:140: internal compiler error: Segmentation fault: 11 Please submit a full bug report, with preprocessed source if appropriate. See for instructions. error: command 'gcc' failed with exit status 1 Any help appreciated. thanks Colin -------------- next part -------------- An HTML attachment was scrubbed... URL: From mdroe at stsci.edu Thu Jan 10 15:51:56 2013 From: mdroe at stsci.edu (Michael Droettboom) Date: Thu, 10 Jan 2013 15:51:56 -0500 Subject: [AstroPy] Newbie installation problems In-Reply-To: References: Message-ID: <50EF29EC.3050901@stsci.edu> Unfortunately, this is a known bug in the default compiler that ships with OS X 10.7 and 10.8. The workaround is to set the environment variable CC to "clang". This bug has a built-in workaround in astropy (the successor to pywcs). Mike On 01/10/2013 01:13 AM, COLIN NAVIN wrote: > Hi > > I am trying to install some packages as part of the installation > process outlined in Installing Scientific Python on the > Python4Astronomers site. > > I chose the EDP Academic distribution for Mac OSX 10.8 and installed > the core Python okay including gcc and gfortran. > > When I come to the section about installing and checking additional > packages, some install fine (asciitable, pyfits and pyparsing). Others > (pywcs, atpy, aplpy, and pyregion) give installation errors. For example > >> pip install --upgrade pywcs > > > stops with an error message > >> wcslib/C/wcserr.c:140: internal compiler error: Segmentation fault: 11 >> >> Please submit a full bug report, >> >> with preprocessed source if appropriate. >> >> See > > for instructions. >> >> error: command 'gcc' failed with exit status 1 > > > Any help appreciated. > > thanks > > Colin > > > _______________________________________________ > AstroPy mailing list > AstroPy at scipy.org > http://mail.scipy.org/mailman/listinfo/astropy -------------- next part -------------- An HTML attachment was scrubbed... URL: From colin.navin at students.mq.edu.au Thu Jan 10 20:22:39 2013 From: colin.navin at students.mq.edu.au (COLIN NAVIN) Date: Fri, 11 Jan 2013 12:22:39 +1100 Subject: [AstroPy] Newbie installation problems Message-ID: Hi thanks for the reply. I use bash so I tried export CC=clang but that did not seem to fix the problem. I also tried using $ enpkg pywcs and got the response: prefix: /Library/Frameworks/EPD64.framework/Versions/7.3 No egg found for requirement 'pywcs'. So I guess that means that pywcs is not in the EDP repository - makes sense. So I tried adding the astrolib repository where pywcs is held https://trac6.assembla.com/astrolib $ enpkg --add-url 'https://trac6.assembla.com/astrolib' and got TypeError: coercing to Unicode: need string or buffer, NoneType found So I think I may just stop there for now as I seem to be spending a lot of time on this (unless someone can see an obvious mistake). As I have installed astropy successfully, hopefully that will include everything that I need. Thanks for your help -------------- next part -------------- An HTML attachment was scrubbed... URL: From thomas.robitaille at gmail.com Mon Jan 14 11:00:18 2013 From: thomas.robitaille at gmail.com (Thomas Robitaille) Date: Mon, 14 Jan 2013 17:00:18 +0100 Subject: [AstroPy] Short survey: your scientific Python installation In-Reply-To: References: Message-ID: Hi everyone, A couple of months ago, I sent out an announcement for a survey to find out what Python installation scientists are using, and have finally had a chance to write up the results, which I've posted on a new blog I created for the occasion! http://astrofrog.github.com/blog/2013/01/13/what-python-installations-are-scientists-using/ I have enabled comments on the blog post, so you can leave comments on the results there if you wish! I've also included a link to the raw results. Cheers, Tom On 19 November 2012 10:45, Thomas Robitaille wrote: > Hi everyone, > > I am interested in finding out what versions of a few basic Python > packages (Python, Numpy, and Scipy) you are all using for everyday > scientific work, and how you are installing packages. This will help > developers for other packages (such as astronomy packages) determine > which versions of dependencies and which distribution methods they > need to support. > > I would be very grateful if you could take 30 seconds to answer 5 > short questions in the following form: > > https://docs.google.com/spreadsheet/viewform?formkey=dDNzTDVTVnFqSjNCYm44aEZIdkxfNmc6MQ > > Once the survey closes, the data will be publicly available! > > Thanks, > Tom From deil.christoph at googlemail.com Tue Jan 15 02:42:45 2013 From: deil.christoph at googlemail.com (Christoph Deil) Date: Tue, 15 Jan 2013 08:42:45 +0100 Subject: [AstroPy] Missing some statistical method for your astronomy analyses in Python? Message-ID: <0B034A89-3B69-45CD-A67B-C4FA77DF1504@gmail.com> Dear all, we would like to know which statistical methods you want to use for you astronomy work with Python that are not readily available e.g. in scipy or one of the existing scientific Python packages like e.g. statsmodels, scikit-learn, astroML, ? Please visit the wiki page for what has already been suggested, then reply to this email or make an addition to the https://github.com/astropy/astropy/wiki/What-methods-do-we-want-in-astropy.stats%3F wiki page directly. The plan is to add these methods either to astropy.stats or, if they are not astronomy-specific, to one of the existing scientific Python packages. Christoph PS: This discussion started as a thread on astropy-dev ( https://groups.google.com/d/topic/astropy-dev/Zwgafam171E/discussion ), but it was suggested to also ask here. -------------- next part -------------- An HTML attachment was scrubbed... URL: From deil.christoph at googlemail.com Tue Jan 15 02:58:44 2013 From: deil.christoph at googlemail.com (Christoph Deil) Date: Tue, 15 Jan 2013 08:58:44 +0100 Subject: [AstroPy] Move this mailing list to a Google group? Message-ID: <8203EAA6-3A7B-42DF-BDC5-5E240D592320@gmail.com> Hi, I would like to suggest to move this mailing list to a Google group. Compare these two mailing lists: - astropy -- what we currently have for this mailing list - astropy-dev -- what it would look like as a Google group I know switching a mailing list involves some pain, so let me highlight some of the advantages: - Easily search the mailing list archives - Easily respond to a thread even if you can't find the post you want to reply to in your mailing client. - Easier signup / configuration of your membership If we don't want to make the switch for this mailing list, my alternative suggestion would be to create a new astropy-users Google group specifically for the Astropy project ( http://www.astropy.org ). What do you think? Christoph -------------- next part -------------- An HTML attachment was scrubbed... URL: From jerome_caron_astro at ymail.com Tue Jan 15 04:51:53 2013 From: jerome_caron_astro at ymail.com (Jerome Caron) Date: Tue, 15 Jan 2013 09:51:53 +0000 (GMT) Subject: [AstroPy] Missing some statistical method for your astronomy analyses in Python? In-Reply-To: <0B034A89-3B69-45CD-A67B-C4FA77DF1504@gmail.com> References: <0B034A89-3B69-45CD-A67B-C4FA77DF1504@gmail.com> Message-ID: <1358243513.55459.YahooMailNeo@web171402.mail.ir2.yahoo.com> Dear Christoph I think the calculation of median values in Numpy is not optimal. I don't know if there are other libraries that do better? On my machine I get these results: >>> data = numpy.random.rand(5000,5000) >>> t0=time.time();print numpy.ma.median(data);print time.time()-t0 0.499845739822 15.1949999332 >>> t0=time.time();print numpy.median(data);print time.time()-t0 0.499845739822 4.32100009918 >>> t0=time.time();print aspylib.astro.get_median(data);print time.time()-t0 [ 0.49984574] 0.90499997139 >>> The median calculation in Aspylib is using C code from Nicolas Devillard (can be found here: http://ndevilla.free.fr/median/index.html) interfaced with ctypes. It could be easily re-used for other, more official packages. I think the code also finds quantiles efficiently. Kind regards Jerome Caron ? ________________________________ De?: Christoph Deil ??: "astropy at scipy.org list" Envoy? le : Mardi 15 janvier 2013 8h42 Objet?: [AstroPy] Missing some statistical method for your astronomy analyses in Python? Dear all,? we would like to know which statistical methods you want to use for you astronomy work with Python that are not readily available e.g. in scipy or one of the existing scientific Python packages like e.g.?statsmodels,?scikit-learn, astroML,?? Please visit the wiki page for what has already been suggested, then reply to this email or make an addition to the?https://github.com/astropy/astropy/wiki/What-methods-do-we-want-in-astropy.stats?? wiki page directly. The plan is to add these methods either to astropy.stats or, if they are not astronomy-specific, to one of the existing?scientific?Python packages. Christoph PS: This discussion started as a thread on astropy-dev?(?https://groups.google.com/d/topic/astropy-dev/Zwgafam171E/discussion?), but it was suggested to also ask here. _______________________________________________ AstroPy mailing list AstroPy at scipy.org http://mail.scipy.org/mailman/listinfo/astropy -------------- next part -------------- An HTML attachment was scrubbed... URL: From thomas.robitaille at gmail.com Tue Jan 15 05:29:58 2013 From: thomas.robitaille at gmail.com (Thomas Robitaille) Date: Tue, 15 Jan 2013 11:29:58 +0100 Subject: [AstroPy] Missing some statistical method for your astronomy analyses in Python? In-Reply-To: <1358243513.55459.YahooMailNeo@web171402.mail.ir2.yahoo.com> References: <0B034A89-3B69-45CD-A67B-C4FA77DF1504@gmail.com> <1358243513.55459.YahooMailNeo@web171402.mail.ir2.yahoo.com> Message-ID: I think this is something that should be brought up with the Numpy developers, and it would probably benefit everyone to have a faster median calculation function (not just astronomers). At the moment, Numpy just uses a quicksort, but if one could achieve speedups of 5x, then I think the Numpy devs might be interested. Cheers, Tom On 15 January 2013 10:51, Jerome Caron wrote: > Dear Christoph > I think the calculation of median values in Numpy is not optimal. I don't > know if there are other libraries that do better? > On my machine I get these results: >>>> data = numpy.random.rand(5000,5000) >>>> t0=time.time();print numpy.ma.median(data);print time.time()-t0 > 0.499845739822 > 15.1949999332 >>>> t0=time.time();print numpy.median(data);print time.time()-t0 > 0.499845739822 > 4.32100009918 >>>> t0=time.time();print aspylib.astro.get_median(data);print time.time()-t0 > [ 0.49984574] > 0.90499997139 >>>> > The median calculation in Aspylib is using C code from Nicolas Devillard > (can be found here: http://ndevilla.free.fr/median/index.html) interfaced > with ctypes. > It could be easily re-used for other, more official packages. I think the > code also finds quantiles efficiently. > Kind regards > Jerome Caron > > De : Christoph Deil > ? : "astropy at scipy.org list" > Envoy? le : Mardi 15 janvier 2013 8h42 > Objet : [AstroPy] Missing some statistical method for your astronomy > analyses in Python? > > Dear all, > > we would like to know which statistical methods you want to use for you > astronomy work with Python that are not readily available e.g. in scipy or > one of the existing scientific Python packages like e.g. statsmodels, > scikit-learn, astroML, ? > > Please visit the wiki page for what has already been suggested, then reply > to this email or make an addition to the > https://github.com/astropy/astropy/wiki/What-methods-do-we-want-in-astropy.stats? > wiki page directly. > > The plan is to add these methods either to astropy.stats or, if they are not > astronomy-specific, to one of the existing scientific Python packages. > > Christoph > > PS: This discussion started as a thread on astropy-dev ( > https://groups.google.com/d/topic/astropy-dev/Zwgafam171E/discussion ), but > it was suggested to also ask here. > > _______________________________________________ > AstroPy mailing list > AstroPy at scipy.org > http://mail.scipy.org/mailman/listinfo/astropy > > > > _______________________________________________ > AstroPy mailing list > AstroPy at scipy.org > http://mail.scipy.org/mailman/listinfo/astropy > From deil.christoph at googlemail.com Tue Jan 15 06:45:17 2013 From: deil.christoph at googlemail.com (Christoph Deil) Date: Tue, 15 Jan 2013 12:45:17 +0100 Subject: [AstroPy] Missing some statistical method for your astronomy analyses in Python? In-Reply-To: References: <0B034A89-3B69-45CD-A67B-C4FA77DF1504@gmail.com> <1358243513.55459.YahooMailNeo@web171402.mail.ir2.yahoo.com> Message-ID: <8AFD41FE-57A8-47C6-95F5-4C2D227E507B@gmail.com> Hi Jerome, thanks for your suggestion. As Tom said, a fast median should be implemented in numpy. Actually this is an existing feature request from 2009. I've added this section for things that should go into numpy / scipy on the wiki page: Whishlist for numpy / scipy Here we collect features that really belong in numpy / scipy. Even if someone implements them it will take a year or two until it is released and the updated by the majority of users, so we might decide to implement these features in astropy for now. numpy issue #1811: "median in average O(n) time" from 2009-09-01. There is a fast median in bottleneck, see speed comparison of numpy/scipy/bottleneck/pandas here. I don't know if there is a plan to merge parts of bottleneck into numpy. numpy issue #2448, "Numerical-stable sum (similar to math.fsum)" from 2011-06-02 Christoph On Jan 15, 2013, at 11:29 AM, Thomas Robitaille wrote: > I think this is something that should be brought up with the Numpy > developers, and it would probably benefit everyone to have a faster > median calculation function (not just astronomers). At the moment, > Numpy just uses a quicksort, but if one could achieve speedups of 5x, > then I think the Numpy devs might be interested. > > Cheers, > Tom > > On 15 January 2013 10:51, Jerome Caron wrote: >> Dear Christoph >> I think the calculation of median values in Numpy is not optimal. I don't >> know if there are other libraries that do better? >> On my machine I get these results: >>>>> data = numpy.random.rand(5000,5000) >>>>> t0=time.time();print numpy.ma.median(data);print time.time()-t0 >> 0.499845739822 >> 15.1949999332 >>>>> t0=time.time();print numpy.median(data);print time.time()-t0 >> 0.499845739822 >> 4.32100009918 >>>>> t0=time.time();print aspylib.astro.get_median(data);print time.time()-t0 >> [ 0.49984574] >> 0.90499997139 >>>>> >> The median calculation in Aspylib is using C code from Nicolas Devillard >> (can be found here: http://ndevilla.free.fr/median/index.html) interfaced >> with ctypes. >> It could be easily re-used for other, more official packages. I think the >> code also finds quantiles efficiently. >> Kind regards >> Jerome Caron >> >> De : Christoph Deil >> ? : "astropy at scipy.org list" >> Envoy? le : Mardi 15 janvier 2013 8h42 >> Objet : [AstroPy] Missing some statistical method for your astronomy >> analyses in Python? >> >> Dear all, >> >> we would like to know which statistical methods you want to use for you >> astronomy work with Python that are not readily available e.g. in scipy or >> one of the existing scientific Python packages like e.g. statsmodels, >> scikit-learn, astroML, ? >> >> Please visit the wiki page for what has already been suggested, then reply >> to this email or make an addition to the >> https://github.com/astropy/astropy/wiki/What-methods-do-we-want-in-astropy.stats? >> wiki page directly. >> >> The plan is to add these methods either to astropy.stats or, if they are not >> astronomy-specific, to one of the existing scientific Python packages. >> >> Christoph >> >> PS: This discussion started as a thread on astropy-dev ( >> https://groups.google.com/d/topic/astropy-dev/Zwgafam171E/discussion ), but >> it was suggested to also ask here. >> >> _______________________________________________ >> AstroPy mailing list >> AstroPy at scipy.org >> http://mail.scipy.org/mailman/listinfo/astropy >> >> >> >> _______________________________________________ >> AstroPy mailing list >> AstroPy at scipy.org >> http://mail.scipy.org/mailman/listinfo/astropy >> > _______________________________________________ > AstroPy mailing list > AstroPy at scipy.org > http://mail.scipy.org/mailman/listinfo/astropy -------------- next part -------------- An HTML attachment was scrubbed... URL: From jerome_caron_astro at ymail.com Tue Jan 15 14:34:53 2013 From: jerome_caron_astro at ymail.com (Jerome Caron) Date: Tue, 15 Jan 2013 19:34:53 +0000 (GMT) Subject: [AstroPy] Missing some statistical method for your astronomy analyses in Python? In-Reply-To: References: <0B034A89-3B69-45CD-A67B-C4FA77DF1504@gmail.com> <1358243513.55459.YahooMailNeo@web171402.mail.ir2.yahoo.com> Message-ID: <1358278493.30662.YahooMailNeo@web171402.mail.ir2.yahoo.com> Dear Tom, You are completely right. I sent a message on Numpy-discussion. http://mail.scipy.org/pipermail/numpy-discussion/2013-January/065213.html Let's see what happens.. Cheers Jerome? ________________________________ De?: Thomas Robitaille ??: Jerome Caron Cc?: "astropy at scipy.org list" Envoy? le : Mardi 15 janvier 2013 11h29 Objet?: Re: [AstroPy] Missing some statistical method for your astronomy analyses in Python? I think this is something that should be brought up with the Numpy developers, and it would probably benefit everyone to have a faster median calculation function (not just astronomers). At the moment, Numpy just uses a quicksort, but if one could achieve speedups of 5x, then I think the Numpy devs might be interested. Cheers, Tom On 15 January 2013 10:51, Jerome Caron wrote: > Dear Christoph > I think the calculation of median values in Numpy is not optimal. I don't > know if there are other libraries that do better? > On my machine I get these results: >>>> data = numpy.random.rand(5000,5000) >>>> t0=time.time();print numpy.ma.median(data);print time.time()-t0 > 0.499845739822 > 15.1949999332 >>>> t0=time.time();print numpy.median(data);print time.time()-t0 > 0.499845739822 > 4.32100009918 >>>> t0=time.time();print aspylib.astro.get_median(data);print time.time()-t0 > [ 0.49984574] > 0.90499997139 >>>> > The median calculation in Aspylib is using C code from Nicolas Devillard > (can be found here: http://ndevilla.free.fr/median/index.html) interfaced > with ctypes. > It could be easily re-used for other, more official packages. I think the > code also finds quantiles efficiently. > Kind regards > Jerome Caron > > De : Christoph Deil > ? : "astropy at scipy.org list" > Envoy? le : Mardi 15 janvier 2013 8h42 > Objet : [AstroPy] Missing some statistical method for your astronomy > analyses in Python? > > Dear all, > > we would like to know which statistical methods you want to use for you > astronomy work with Python that are not readily available e.g. in scipy or > one of the existing scientific Python packages like e.g. statsmodels, > scikit-learn, astroML, ? > > Please visit the wiki page for what has already been suggested, then reply > to this email or make an addition to the > https://github.com/astropy/astropy/wiki/What-methods-do-we-want-in-astropy.stats? > wiki page directly. > > The plan is to add these methods either to astropy.stats or, if they are not > astronomy-specific, to one of the existing scientific Python packages. > > Christoph > > PS: This discussion started as a thread on astropy-dev ( > https://groups.google.com/d/topic/astropy-dev/Zwgafam171E/discussion ), but > it was suggested to also ask here. > > _______________________________________________ > AstroPy mailing list > AstroPy at scipy.org > http://mail.scipy.org/mailman/listinfo/astropy > > > > _______________________________________________ > AstroPy mailing list > AstroPy at scipy.org > http://mail.scipy.org/mailman/listinfo/astropy > -------------- next part -------------- An HTML attachment was scrubbed... URL: From goldbaum at ucolick.org Tue Jan 15 18:53:33 2013 From: goldbaum at ucolick.org (Nathan Goldbaum) Date: Tue, 15 Jan 2013 15:53:33 -0800 Subject: [AstroPy] Announcing the 2013 yt developer conference - March 6-8, Santa Cruz California Message-ID: <66B66B76-D225-452C-9911-B59B3AF15D6D@ucolick.org> Dear Colleagues, We are proud to officially announce the upcoming 2013 yt developer workshop. This three day event, to be held on the campus of the University of California, Santa Cruz on March 6th through 8th, will bring together a diverse group of students, researchers, and developers. yt is a community-developed analysis and visualization toolkit, primarily directed at astrophysical hydrodynamics simulations, offering full support for output from the Enzo, FLASH, Orion, and Nyx codes, with preliminary support for several others. It provides access to simulation data using an intuitive python interface, can quickly and easily perform many common visualization and analysis tasks, and offers a framework for conducting data reductions and analysis of simulation data. More details about yt, including download and installation instructions as well as full documentation are available on our website: http://yt-project.org. Up to this point, yt development has proceeded largely over the internet, leveraging e-mail lists, our online code repository (http://bitbucket.org/yt_analysis), and IRC to track, discuss, and evaluate changes to the code. Unfortunately, this model makes it difficult to jump in to development as a newcomer. This workshop will not only allow experienced developers to collaborate in person on new features, but will also be a means for new developers to learn what yt is about and begin contributing. The workshop will include several training sessions, constituting a primer in distributed version control, test-based development, and best practices for scientific programming. The workshop will also serve as a venue to plan and execute some of the major new features we are planning for the upcoming yt 3.0 release, including full support for outputs of Lagrangian codes like Gadget, Gasoline and AREPO, better support for oct-based codes like ART and RAMSES, initial conditions generation, the new Grid Data Format, a new way of handling units and unit conversion, non-cartesian geometries, and advanced graphical browser widgets inside the iPython notebook. More information and a registration form for the workshop are available on the workshop website: http://yt-project.org/workshop2013/. We have limited funding support for hotels and airfare. Funds will be preferentially distributed to students and the level of individual support will depend on demand. If you have questions or concerns about the workshop, please feel free to contact the organizers at workshop2013 at yt-project.org. On behalf of the organizing committee, Nathan Goldbaum -------------- next part -------------- An HTML attachment was scrubbed... URL: From thomas.robitaille at gmail.com Sat Jan 19 13:54:36 2013 From: thomas.robitaille at gmail.com (Thomas Robitaille) Date: Sat, 19 Jan 2013 19:54:36 +0100 Subject: [AstroPy] Move this mailing list to a Google group? In-Reply-To: <8203EAA6-3A7B-42DF-BDC5-5E240D592320@gmail.com> References: <8203EAA6-3A7B-42DF-BDC5-5E240D592320@gmail.com> Message-ID: I personally think that it would be nice to move this to a Google group. However, we can't have 'astropy', since that is already used for an Astronomical group in Paraguay. I did create an astropy-users mailing list at the same time as astropy-dev, so we could go with your second idea of having it just for Astropy users, though I don't like the idea of fragmenting things too much. What do others think? Cheers, Tom On 15 January 2013 08:58, Christoph Deil wrote: > Hi, > > I would like to suggest to move this mailing list to a Google group. > > Compare these two mailing lists: > - astropy -- what we currently have for this mailing list > - astropy-dev -- what it would look like as a Google group > > I know switching a mailing list involves some pain, so let me highlight some > of the advantages: > - Easily search the mailing list archives > - Easily respond to a thread even if you can't find the post you want to > reply to in your mailing client. > - Easier signup / configuration of your membership > > If we don't want to make the switch for this mailing list, my alternative > suggestion would be to create a new astropy-users Google group specifically > for the Astropy project ( http://www.astropy.org ). > > What do you think? > > Christoph > > > _______________________________________________ > AstroPy mailing list > AstroPy at scipy.org > http://mail.scipy.org/mailman/listinfo/astropy > From ambrosc at ymail.com Tue Jan 29 15:49:49 2013 From: ambrosc at ymail.com (Christian Ambros) Date: Tue, 29 Jan 2013 20:49:49 +0000 (GMT) Subject: [AstroPy] Need some help with wcs Message-ID: <1359492589.56321.YahooMailClassic@web171905.mail.ir2.yahoo.com> Hi guys, I'm new to astropy but as I see the potential, I like to use it my Ph.d thesis. After I had fun with some of the tuts and their data I started out to use some of my own data and ran into some problems with wcs. After I opend up a fits with pyfits.open I tried to use wcs= pywcs.WCS(hdulist[0].header) to get the wcs data. I got the error mesg: 312 # The header may have SIP or distortions, but no core 313 # WCS. That isn't an error -- we want a "default" A typical header of the images I want to work with looks like this: SIMPLE = T / Fits standard BITPIX = -32 / Bits per pixel NAXIS = 2 / Number of axes NAXIS1 = 1023 / Axis length NAXIS2 = 1023 / Axis length ORIGIN = 'NOAO-IRAF FITS Image Kernel July 1999' / FITS file originator EXTEND = F / File may contain extensions DATE = '2000-08-24T17:53:06' / Date FITS file was generated IRAF-TLM= '18:52:47 (24/08/2000)' / Time of last modification TIMESYS = 'UTC ' / P0S| time scale specification RADESYS = 'FK5 ' / P2S| WCS for this file EQUINOX = 2.000000E+03 / P0R| equinox OBSERVER= 'Reiprich / Englhauser' / P0R| observer(s) TELESCOP= 'Skinakas 1.3m' / P0R| telescope INSTRUME= 'CH 360 ' / P0R| instrument name OBS_MODE= 'DIRECT MODE' / RDF| observing mode FILTER = 'R ' / RDF| filter ID OBJECT = 'R1825.3+30' / P0R| name of object DATE-OBS= '2000-06-07T23:54:40' / P0R| time of obs start (UTC) EXPOSURE= 3.000000E+02 / JER| exposure time (s) DATE_CCD= '2000-06-08T00:00:20' / JER| end of CCD readout (UTC) AIRMASS1= '1.005 ' / JER| air mass at obs start AIRMASS2= '1.007 ' / JER| air mass at obs end BLANK = 65535 / P0R| undefined integer values CTYPE1 = 'RA---TAN' / P0R| (assumed) axis type for dim 1 CTYPE2 = 'DEC--TAN' / P0R| (assumed) axis type for dim 2 CRPIX1 = 511.5 / P0R| 'pixel 1 from 0.5 to 1.5' convention CRPIX2 = 5.125000E+02 / P0R| 'pixel 1 from 0.5 to 1.5' convention CRVAL1 = 2.763750E+02 / P0R| (assumed) sky coord of 1st axis (deg) CRVAL2 = 3.045000E+01 / P0R| (assumed) sky coord of 2nd axis (deg) CDELT1 = -1.3944444444E-04 / P0R| (assumed) X degrees per pixel CDELT2 = 1.3944444444E-04 / P0R| (assumed) Y degrees per pixel OBSGROUP= '07JUN00 ' / JER| group ID of observations OBSFNAME= 'DATA0134' / JER| file ID of observation HISTORY Changes by FIXQSRC: HISTORY * add new keywords (everything except for SIMPLE,BITPIX,NAXIS.); HISTORY filled by information from the observation log files HISTORY * fix I2 bug of PMIS (negative pixel values) COMMENT Keyword types: COMMENT * P0R - reserved in Paper 0 COMMENT * P0S - suggested in Paper 0 COMMENT * P2S - suggested in Paper 2 COMMENT * RDF - present in ROSAT RDF FITS files COMMENT * JER - introduced by JER COMMENT References: COMMENT * Paper 0: NOST 100-2.0, FITS Definition, http://fits.gsfc.nasa.gov/ COMMENT * Paper 2: Paper II in http://fits.gsfc.nasa.gov/documents.html#WCS WCSDIM = 2 CD1_1 = -1.3944444444000E-4 CD2_2 = 1.39444444440000E-4 LTM1_1 = 1. LTM2_2 = 1. WAT0_001= 'system=image' WAT1_001= 'wtype=tan axtype=ra' WAT2_001= 'wtype=tan axtype=dec' ZEROCOR = 'Aug 21 19:55 Zero level correction image is Zerom' CCDSEC = '[1:1024,1:1024]' CCDMEANT= 651373512 CCDPROC = 'Aug 22 1:05 CCD processing done' FLATCOR = 'Aug 22 1:05 Flat field image is FlatRm with scale=40679.34' LTV1 = -1. NCOMBINE= 11 As it is written in the documantation the values i.e. CRPIX j, PC i j or CD i j, CDELT i,CTYPE i, CRVAL i, or CUNIT i have to be present. As you can see in the middle of the header they exist ok the WCSAXES value ist missing but there is WCSDIM instead. The error message says something about a 'default'. Do those values have to stand in a particular order at a particular position in the header? I ran verify() but with no negativ result. Is there, maybe, an example header to which I can refer to? If so I will write myself a tool to re-write the header of all of those 169 targets I have already in my databank. I would revise my header correcting program which update the header after camera output to get the 'right' header once and for all. Thanks in advance, Christian -- "A little learning never caused anyone's head to explode!" "Ein wenig Lernen hat noch niemandens Kopf zum Explodieren gebracht!" From d.berry at jach.hawaii.edu Tue Jan 29 18:07:20 2013 From: d.berry at jach.hawaii.edu (David Berry) Date: Tue, 29 Jan 2013 13:07:20 -1000 Subject: [AstroPy] Need some help with wcs In-Reply-To: <1359492589.56321.YahooMailClassic@web171905.mail.ir2.yahoo.com> References: <1359492589.56321.YahooMailClassic@web171905.mail.ir2.yahoo.com> Message-ID: That looks like a valid header to me. WCSDIM is non-standard, but that should not be a problem since it is not needed to interpret the header. The pyast package reads the header successfully, and can convert between pixel and sky coords. David On 29 January 2013 10:49, Christian Ambros wrote: > Hi guys, > > I'm new to astropy but as I see the potential, I like to use it my Ph.d thesis. > After I had fun with some of the tuts and their data I started out to use some of my own data and ran into some problems with wcs. > > After I opend up a fits with pyfits.open I tried to use wcs= pywcs.WCS(hdulist[0].header) to get the wcs data. I got the error mesg: 312 # The header may have SIP or distortions, but no core > 313 # WCS. That isn't an error -- we want a "default" > > A typical header of the images I want to work with looks like this: > > SIMPLE = T / Fits standard > BITPIX = -32 / Bits per pixel > NAXIS = 2 / Number of axes > NAXIS1 = 1023 / Axis length > NAXIS2 = 1023 / Axis length > ORIGIN = 'NOAO-IRAF FITS Image Kernel July 1999' / FITS file originator > EXTEND = F / File may contain extensions > DATE = '2000-08-24T17:53:06' / Date FITS file was generated > IRAF-TLM= '18:52:47 (24/08/2000)' / Time of last modification > TIMESYS = 'UTC ' / P0S| time scale specification > RADESYS = 'FK5 ' / P2S| WCS for this file > EQUINOX = 2.000000E+03 / P0R| equinox > OBSERVER= 'Reiprich / Englhauser' / P0R| observer(s) > TELESCOP= 'Skinakas 1.3m' / P0R| telescope > INSTRUME= 'CH 360 ' / P0R| instrument name > OBS_MODE= 'DIRECT MODE' / RDF| observing mode > FILTER = 'R ' / RDF| filter ID > OBJECT = 'R1825.3+30' / P0R| name of object > DATE-OBS= '2000-06-07T23:54:40' / P0R| time of obs start (UTC) > EXPOSURE= 3.000000E+02 / JER| exposure time (s) > DATE_CCD= '2000-06-08T00:00:20' / JER| end of CCD readout (UTC) > AIRMASS1= '1.005 ' / JER| air mass at obs start > AIRMASS2= '1.007 ' / JER| air mass at obs end > BLANK = 65535 / P0R| undefined integer values > CTYPE1 = 'RA---TAN' / P0R| (assumed) axis type for dim 1 > CTYPE2 = 'DEC--TAN' / P0R| (assumed) axis type for dim 2 > CRPIX1 = 511.5 / P0R| 'pixel 1 from 0.5 to 1.5' convention > CRPIX2 = 5.125000E+02 / P0R| 'pixel 1 from 0.5 to 1.5' convention > CRVAL1 = 2.763750E+02 / P0R| (assumed) sky coord of 1st axis (deg) > CRVAL2 = 3.045000E+01 / P0R| (assumed) sky coord of 2nd axis (deg) > CDELT1 = -1.3944444444E-04 / P0R| (assumed) X degrees per pixel > CDELT2 = 1.3944444444E-04 / P0R| (assumed) Y degrees per pixel > OBSGROUP= '07JUN00 ' / JER| group ID of observations > OBSFNAME= 'DATA0134' / JER| file ID of observation > HISTORY Changes by FIXQSRC: > HISTORY * add new keywords (everything except for SIMPLE,BITPIX,NAXIS.); > HISTORY filled by information from the observation log files > HISTORY * fix I2 bug of PMIS (negative pixel values) > COMMENT Keyword types: > COMMENT * P0R - reserved in Paper 0 > COMMENT * P0S - suggested in Paper 0 > COMMENT * P2S - suggested in Paper 2 > COMMENT * RDF - present in ROSAT RDF FITS files > COMMENT * JER - introduced by JER > COMMENT References: > COMMENT * Paper 0: NOST 100-2.0, FITS Definition, http://fits.gsfc.nasa.gov/ > COMMENT * Paper 2: Paper II in http://fits.gsfc.nasa.gov/documents.html#WCS > WCSDIM = 2 > CD1_1 = -1.3944444444000E-4 > CD2_2 = 1.39444444440000E-4 > LTM1_1 = 1. > LTM2_2 = 1. > WAT0_001= 'system=image' > WAT1_001= 'wtype=tan axtype=ra' > WAT2_001= 'wtype=tan axtype=dec' > ZEROCOR = 'Aug 21 19:55 Zero level correction image is Zerom' > CCDSEC = '[1:1024,1:1024]' > CCDMEANT= 651373512 > CCDPROC = 'Aug 22 1:05 CCD processing done' > FLATCOR = 'Aug 22 1:05 Flat field image is FlatRm with scale=40679.34' > LTV1 = -1. > NCOMBINE= 11 > > As it is written in the documantation the values i.e. CRPIX j, PC i j or CD i j, CDELT i,CTYPE i, CRVAL i, or CUNIT i have to be present. As you can see in the middle of the header they exist ok the WCSAXES value ist missing but there is WCSDIM instead. > The error message says something about a 'default'. Do those values have to stand in a particular order at a particular position in the header? > I ran verify() but with no negativ result. > > Is there, maybe, an example header to which I can refer to? If so I will write myself a tool to re-write the header of all of those 169 targets I have already in my databank. I would revise my header correcting program which update the header after camera output to get the 'right' header once and for all. > > Thanks in advance, > Christian > -- > "A little learning never caused anyone's head to explode!" > > "Ein wenig Lernen hat noch niemandens Kopf zum Explodieren gebracht!" > _______________________________________________ > AstroPy mailing list > AstroPy at scipy.org > http://mail.scipy.org/mailman/listinfo/astropy From mdroe at stsci.edu Tue Jan 29 18:12:28 2013 From: mdroe at stsci.edu (Michael Droettboom) Date: Tue, 29 Jan 2013 18:12:28 -0500 Subject: [AstroPy] Need some help with wcs In-Reply-To: <1359492589.56321.YahooMailClassic@web171905.mail.ir2.yahoo.com> References: <1359492589.56321.YahooMailClassic@web171905.mail.ir2.yahoo.com> Message-ID: <5108575C.1020107@stsci.edu> On 01/29/2013 03:49 PM, Christian Ambros wrote: > Hi guys, > > I'm new to astropy but as I see the potential, I like to use it my Ph.d thesis. > After I had fun with some of the tuts and their data I started out to use some of my own data and ran into some problems with wcs. > > After I opend up a fits with pyfits.open I tried to use wcs= pywcs.WCS(hdulist[0].header) to get the wcs data. I got the error mesg: 312 # The header may have SIP or distortions, but no core > 313 # WCS. That isn't an error -- we want a "default" This isn't an error message -- it's merely a comment in the code around the point where the error occurred. Can you post the full output from running the command? > > A typical header of the images I want to work with looks like this: > > SIMPLE = T / Fits standard > BITPIX = -32 / Bits per pixel > NAXIS = 2 / Number of axes > NAXIS1 = 1023 / Axis length > NAXIS2 = 1023 / Axis length > ORIGIN = 'NOAO-IRAF FITS Image Kernel July 1999' / FITS file originator > EXTEND = F / File may contain extensions > DATE = '2000-08-24T17:53:06' / Date FITS file was generated > IRAF-TLM= '18:52:47 (24/08/2000)' / Time of last modification > TIMESYS = 'UTC ' / P0S| time scale specification > RADESYS = 'FK5 ' / P2S| WCS for this file > EQUINOX = 2.000000E+03 / P0R| equinox > OBSERVER= 'Reiprich / Englhauser' / P0R| observer(s) > TELESCOP= 'Skinakas 1.3m' / P0R| telescope > INSTRUME= 'CH 360 ' / P0R| instrument name > OBS_MODE= 'DIRECT MODE' / RDF| observing mode > FILTER = 'R ' / RDF| filter ID > OBJECT = 'R1825.3+30' / P0R| name of object > DATE-OBS= '2000-06-07T23:54:40' / P0R| time of obs start (UTC) > EXPOSURE= 3.000000E+02 / JER| exposure time (s) > DATE_CCD= '2000-06-08T00:00:20' / JER| end of CCD readout (UTC) > AIRMASS1= '1.005 ' / JER| air mass at obs start > AIRMASS2= '1.007 ' / JER| air mass at obs end > BLANK = 65535 / P0R| undefined integer values > CTYPE1 = 'RA---TAN' / P0R| (assumed) axis type for dim 1 > CTYPE2 = 'DEC--TAN' / P0R| (assumed) axis type for dim 2 > CRPIX1 = 511.5 / P0R| 'pixel 1 from 0.5 to 1.5' convention > CRPIX2 = 5.125000E+02 / P0R| 'pixel 1 from 0.5 to 1.5' convention > CRVAL1 = 2.763750E+02 / P0R| (assumed) sky coord of 1st axis (deg) > CRVAL2 = 3.045000E+01 / P0R| (assumed) sky coord of 2nd axis (deg) > CDELT1 = -1.3944444444E-04 / P0R| (assumed) X degrees per pixel > CDELT2 = 1.3944444444E-04 / P0R| (assumed) Y degrees per pixel > OBSGROUP= '07JUN00 ' / JER| group ID of observations > OBSFNAME= 'DATA0134' / JER| file ID of observation > HISTORY Changes by FIXQSRC: > HISTORY * add new keywords (everything except for SIMPLE,BITPIX,NAXIS.); > HISTORY filled by information from the observation log files > HISTORY * fix I2 bug of PMIS (negative pixel values) > COMMENT Keyword types: > COMMENT * P0R - reserved in Paper 0 > COMMENT * P0S - suggested in Paper 0 > COMMENT * P2S - suggested in Paper 2 > COMMENT * RDF - present in ROSAT RDF FITS files > COMMENT * JER - introduced by JER > COMMENT References: > COMMENT * Paper 0: NOST 100-2.0, FITS Definition, http://fits.gsfc.nasa.gov/ > COMMENT * Paper 2: Paper II in http://fits.gsfc.nasa.gov/documents.html#WCS > WCSDIM = 2 > CD1_1 = -1.3944444444000E-4 > CD2_2 = 1.39444444440000E-4 > LTM1_1 = 1. > LTM2_2 = 1. > WAT0_001= 'system=image' > WAT1_001= 'wtype=tan axtype=ra' > WAT2_001= 'wtype=tan axtype=dec' > ZEROCOR = 'Aug 21 19:55 Zero level correction image is Zerom' > CCDSEC = '[1:1024,1:1024]' > CCDMEANT= 651373512 > CCDPROC = 'Aug 22 1:05 CCD processing done' > FLATCOR = 'Aug 22 1:05 Flat field image is FlatRm with scale=40679.34' > LTV1 = -1. > NCOMBINE= 11 Can you attach the original FITS file (or at least just the header?) E-mail clients tend to garble this stuff, and it's easiest for me to get to the bottom of what's going on with an actual file to test with. > > As it is written in the documantation the values i.e. CRPIX j, PC i j or CD i j, CDELT i,CTYPE i, CRVAL i, or CUNIT i have to be present. As you can see in the middle of the header they exist ok the WCSAXES value ist missing but there is WCSDIM instead. > The error message says something about a 'default'. Do those values have to stand in a particular order at a particular position in the header? There shouldn't be any dependency on ordering of the keywords. > I ran verify() but with no negativ result. > > Is there, maybe, an example header to which I can refer to? If so I will write myself a tool to re-write the header of all of those 169 targets I have already in my databank. I would revise my header correcting program which update the header after camera output to get the 'right' header once and for all. You can always create a WCS object without passing it a header to get a "default" header and write it out using to_header_string(). But first we should get to the bottom of what the error actually is -- it may be simpler than all that. Cheers, Mike > > Thanks in advance, > Christian > -- > "A little learning never caused anyone's head to explode!" > > "Ein wenig Lernen hat noch niemandens Kopf zum Explodieren gebracht!" > _______________________________________________ > AstroPy mailing list > AstroPy at scipy.org > http://mail.scipy.org/mailman/listinfo/astropy From ghang.naoc at gmail.com Wed Jan 30 13:33:51 2013 From: ghang.naoc at gmail.com (gonghang.naoc) Date: Thu, 31 Jan 2013 02:33:51 +0800 Subject: [AstroPy] point in ellipse Message-ID: hi?everybody? I believe many people here use ds9 and know its region file format.For example?we can make an ellipse if we know its center ra?dec and main aixs direction.Is there a pythonic way to judge whether a point is in an ellipse if we know ra&dec of the point? Thank you. Best wishes. Hang -------------- next part -------------- An HTML attachment was scrubbed... URL: From tim.jenness at gmail.com Wed Jan 30 13:47:52 2013 From: tim.jenness at gmail.com (Tim Jenness) Date: Wed, 30 Jan 2013 11:47:52 -0700 Subject: [AstroPy] point in ellipse In-Reply-To: References: Message-ID: [now replying to list] You can use the Region class in pyast for that (it's not part of astropy). It has support for all the STC regions. https://github.com/timj/starlink-pyast AST is the library used internally by DS9. -- Tim Jenness On Wed, Jan 30, 2013 at 11:33 AM, gonghang.naoc wrote: > hi?everybody? > I believe many people here use ds9 and know its region file > format.For example?we can make an ellipse if we know its center ra?dec and > main aixs direction.Is there a pythonic way to judge whether a point is in > an ellipse if we know ra&dec of the point? > Thank you. > Best wishes. > Hang > > _______________________________________________ > AstroPy mailing list > AstroPy at scipy.org > http://mail.scipy.org/mailman/listinfo/astropy > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From perry at stsci.edu Wed Jan 30 13:48:01 2013 From: perry at stsci.edu (Perry Greenfield) Date: Wed, 30 Jan 2013 13:48:01 -0500 Subject: [AstroPy] point in ellipse In-Reply-To: References: Message-ID: Sure. But I'm assuming you wanted more than that. I presume you are looking for a function to test if a coordinate (or array of coordinates) lies inside the ellipse or not. Yes, that can be done analytically. You want a python function that does that specifically? (No, I don't have one handy, but it shouldn't be hard to code). Perry On Jan 30, 2013, at 1:33 PM, gonghang.naoc wrote: > hi?everybody? > I believe many people here use ds9 and know its region file format.For example?we can make an ellipse if we know its center ra?dec and main aixs direction.Is there a pythonic way to judge whether a point is in an ellipse if we know ra&dec of the point? > Thank you. > Best wishes. > Hang > _______________________________________________ > AstroPy mailing list > AstroPy at scipy.org > http://mail.scipy.org/mailman/listinfo/astropy From tim.jenness at gmail.com Wed Jan 30 13:56:34 2013 From: tim.jenness at gmail.com (Tim Jenness) Date: Wed, 30 Jan 2013 11:56:34 -0700 Subject: [AstroPy] point in ellipse In-Reply-To: References: Message-ID: On Wed, Jan 30, 2013 at 11:48 AM, Perry Greenfield wrote: > Sure. > > But I'm assuming you wanted more than that. I presume you are looking for > a function to test if a coordinate (or array of coordinates) lies inside > the ellipse or not. Yes, that can be done analytically. You want a python > function that does that specifically? (No, I don't have one handy, but it > shouldn't be hard to code). > > pyast has this built in. Create an ellipse object and then ask whether a position (or set of positions) is inside or outside it. -- Tim Jenness -------------- next part -------------- An HTML attachment was scrubbed... URL: From ghang.naoc at gmail.com Thu Jan 31 08:41:28 2013 From: ghang.naoc at gmail.com (gonghang.naoc) Date: Thu, 31 Jan 2013 21:41:28 +0800 Subject: [AstroPy] point in ellipse In-Reply-To: References: Message-ID: Thank you very much. http://dsberry.github.com/starlink/node1.html is helpful. Hang On Thu, Jan 31, 2013 at 2:56 AM, Tim Jenness wrote: > > > > On Wed, Jan 30, 2013 at 11:48 AM, Perry Greenfield wrote: > >> Sure. >> >> But I'm assuming you wanted more than that. I presume you are looking for >> a function to test if a coordinate (or array of coordinates) lies inside >> the ellipse or not. Yes, that can be done analytically. You want a python >> function that does that specifically? (No, I don't have one handy, but it >> shouldn't be hard to code). >> >> > pyast has this built in. Create an ellipse object and then ask whether a > position (or set of positions) is inside or outside it. > > -- > Tim Jenness > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ghang.naoc at gmail.com Thu Jan 31 08:49:11 2013 From: ghang.naoc at gmail.com (gonghang.naoc) Date: Thu, 31 Jan 2013 21:49:11 +0800 Subject: [AstroPy] point in ellipse In-Reply-To: References: Message-ID: Thank you.oh, I thought a graphic way might be more convenient than a mathematical way .I am lazy to calculate.. Hang On Thu, Jan 31, 2013 at 2:48 AM, Perry Greenfield wrote: > Sure. > > But I'm assuming you wanted more than that. I presume you are looking for > a function to test if a coordinate (or array of coordinates) lies inside > the ellipse or not. Yes, that can be done analytically. You want a python > function that does that specifically? (No, I don't have one handy, but it > shouldn't be hard to code). > > Perry > > On Jan 30, 2013, at 1:33 PM, gonghang.naoc wrote: > > > hi?everybody? > > I believe many people here use ds9 and know its region file > format.For example?we can make an ellipse if we know its center ra?dec and > main aixs direction.Is there a pythonic way to judge whether a point is in > an ellipse if we know ra&dec of the point? > > Thank you. > > Best wishes. > > Hang > > _______________________________________________ > > AstroPy mailing list > > AstroPy at scipy.org > > http://mail.scipy.org/mailman/listinfo/astropy > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From philrose at astro.washington.edu Thu Jan 31 13:12:37 2013 From: philrose at astro.washington.edu (Phil Rosenfield) Date: Thu, 31 Jan 2013 10:12:37 -0800 Subject: [AstroPy] point in ellipse Message-ID: I use nxutils for this: http://matplotlib.org/api/nxutils_api.html On Thu, Jan 31, 2013 at 10:00 AM, wrote: > Send AstroPy mailing list submissions to > astropy at scipy.org > > To subscribe or unsubscribe via the World Wide Web, visit > http://mail.scipy.org/mailman/listinfo/astropy > or, via email, send a message with subject or body 'help' to > astropy-request at scipy.org > > You can reach the person managing the list at > astropy-owner at scipy.org > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of AstroPy digest..." > > > Today's Topics: > > 1. point in ellipse (gonghang.naoc) > 2. Re: point in ellipse (Tim Jenness) > 3. Re: point in ellipse (Perry Greenfield) > 4. Re: point in ellipse (Tim Jenness) > 5. Re: point in ellipse (gonghang.naoc) > 6. Re: point in ellipse (gonghang.naoc) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 31 Jan 2013 02:33:51 +0800 > From: "gonghang.naoc" > Subject: [AstroPy] point in ellipse > To: astropy > Message-ID: > < > CABb23mvkRamvf-7m-atj+5moB3z2y4dRvvjQ8H3iUwoZNYxo6Q at mail.gmail.com> > Content-Type: text/plain; charset="utf-8" > > hi?everybody? > I believe many people here use ds9 and know its region file > format.For example?we can make an ellipse if we know its center ra?dec and > main aixs direction.Is there a pythonic way to judge whether a point is in > an ellipse if we know ra&dec of the point? > Thank you. > Best wishes. > Hang > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > http://mail.scipy.org/pipermail/astropy/attachments/20130131/87c11093/attachment-0001.html > > ------------------------------ > > Message: 2 > Date: Wed, 30 Jan 2013 11:47:52 -0700 > From: Tim Jenness > Subject: Re: [AstroPy] point in ellipse > To: "gonghang.naoc" > Cc: astropy > Message-ID: > 7RhG2iwbUuUC84Z+QuSoJEh2CA at mail.gmail.com> > Content-Type: text/plain; charset="utf-8" > > [now replying to list] > > You can use the Region class in pyast for that (it's not part of astropy). > It has support for all the STC regions. > > https://github.com/timj/starlink-pyast > > AST is the library used internally by DS9. > > -- > Tim Jenness > > > On Wed, Jan 30, 2013 at 11:33 AM, gonghang.naoc >wrote: > > > hi?everybody? > > I believe many people here use ds9 and know its region file > > format.For example?we can make an ellipse if we know its center ra?dec > and > > main aixs direction.Is there a pythonic way to judge whether a point is > in > > an ellipse if we know ra&dec of the point? > > Thank you. > > Best wishes. > > Hang > > > > _______________________________________________ > > AstroPy mailing list > > AstroPy at scipy.org > > http://mail.scipy.org/mailman/listinfo/astropy > > > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > http://mail.scipy.org/pipermail/astropy/attachments/20130130/38b2b5d6/attachment-0001.html > > ------------------------------ > > Message: 3 > Date: Wed, 30 Jan 2013 13:48:01 -0500 > From: Perry Greenfield > Subject: Re: [AstroPy] point in ellipse > To: "gonghang.naoc" > Cc: astropy > Message-ID: > Content-Type: text/plain; charset=utf-8 > > Sure. > > But I'm assuming you wanted more than that. I presume you are looking for > a function to test if a coordinate (or array of coordinates) lies inside > the ellipse or not. Yes, that can be done analytically. You want a python > function that does that specifically? (No, I don't have one handy, but it > shouldn't be hard to code). > > Perry > > On Jan 30, 2013, at 1:33 PM, gonghang.naoc wrote: > > > hi?everybody? > > I believe many people here use ds9 and know its region file > format.For example?we can make an ellipse if we know its center ra?dec and > main aixs direction.Is there a pythonic way to judge whether a point is in > an ellipse if we know ra&dec of the point? > > Thank you. > > Best wishes. > > Hang > > _______________________________________________ > > AstroPy mailing list > > AstroPy at scipy.org > > http://mail.scipy.org/mailman/listinfo/astropy > > > > ------------------------------ > > Message: 4 > Date: Wed, 30 Jan 2013 11:56:34 -0700 > From: Tim Jenness > Subject: Re: [AstroPy] point in ellipse > To: Perry Greenfield > Cc: astropy > Message-ID: > < > CA+G92Rc4YowNQ2kqpVzVW0n+Cs41YHwLk__kLyoeQSnD9HimYg at mail.gmail.com> > Content-Type: text/plain; charset="iso-8859-1" > > On Wed, Jan 30, 2013 at 11:48 AM, Perry Greenfield > wrote: > > > Sure. > > > > But I'm assuming you wanted more than that. I presume you are looking for > > a function to test if a coordinate (or array of coordinates) lies inside > > the ellipse or not. Yes, that can be done analytically. You want a python > > function that does that specifically? (No, I don't have one handy, but it > > shouldn't be hard to code). > > > > > pyast has this built in. Create an ellipse object and then ask whether a > position (or set of positions) is inside or outside it. > > -- > Tim Jenness > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > http://mail.scipy.org/pipermail/astropy/attachments/20130130/6b2b8edf/attachment-0001.html > > ------------------------------ > > Message: 5 > Date: Thu, 31 Jan 2013 21:41:28 +0800 > From: "gonghang.naoc" > Subject: Re: [AstroPy] point in ellipse > To: Tim Jenness , astropy > Message-ID: > < > CABb23mtsqd6Y2-qE4Dgpm8KoHOhj-f6ftkoOFM84TNpT3b8QXQ at mail.gmail.com> > Content-Type: text/plain; charset="iso-8859-1" > > Thank you very much. http://dsberry.github.com/starlink/node1.html is > helpful. > Hang > > On Thu, Jan 31, 2013 at 2:56 AM, Tim Jenness > wrote: > > > > > > > > > On Wed, Jan 30, 2013 at 11:48 AM, Perry Greenfield >wrote: > > > >> Sure. > >> > >> But I'm assuming you wanted more than that. I presume you are looking > for > >> a function to test if a coordinate (or array of coordinates) lies inside > >> the ellipse or not. Yes, that can be done analytically. You want a > python > >> function that does that specifically? (No, I don't have one handy, but > it > >> shouldn't be hard to code). > >> > >> > > pyast has this built in. Create an ellipse object and then ask whether a > > position (or set of positions) is inside or outside it. > > > > -- > > Tim Jenness > > > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > http://mail.scipy.org/pipermail/astropy/attachments/20130131/edd5670b/attachment-0001.html > > ------------------------------ > > Message: 6 > Date: Thu, 31 Jan 2013 21:49:11 +0800 > From: "gonghang.naoc" > Subject: Re: [AstroPy] point in ellipse > To: astropy > Message-ID: > 8FD67BuJ_KwtymPK9uCutASitZUhJ9WfY7w at mail.gmail.com> > Content-Type: text/plain; charset="utf-8" > > Thank you.oh, I thought a graphic way might be more convenient than a > mathematical way .I am lazy to calculate.. > Hang > > On Thu, Jan 31, 2013 at 2:48 AM, Perry Greenfield wrote: > > > Sure. > > > > But I'm assuming you wanted more than that. I presume you are looking for > > a function to test if a coordinate (or array of coordinates) lies inside > > the ellipse or not. Yes, that can be done analytically. You want a python > > function that does that specifically? (No, I don't have one handy, but it > > shouldn't be hard to code). > > > > Perry > > > > On Jan 30, 2013, at 1:33 PM, gonghang.naoc wrote: > > > > > hi?everybody? > > > I believe many people here use ds9 and know its region file > > format.For example?we can make an ellipse if we know its center ra?dec > and > > main aixs direction.Is there a pythonic way to judge whether a point is > in > > an ellipse if we know ra&dec of the point? > > > Thank you. > > > Best wishes. > > > Hang > > > _______________________________________________ > > > AstroPy mailing list > > > AstroPy at scipy.org > > > http://mail.scipy.org/mailman/listinfo/astropy > > > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > http://mail.scipy.org/pipermail/astropy/attachments/20130131/227dd97f/attachment-0001.html > > ------------------------------ > > _______________________________________________ > AstroPy mailing list > AstroPy at scipy.org > http://mail.scipy.org/mailman/listinfo/astropy > > > End of AstroPy Digest, Vol 76, Issue 11 > *************************************** > -- Phil Rosenfield Graduate Student: UW Astronomy Additional contact info: http://www.astro.washington.edu/philrose -------------- next part -------------- An HTML attachment was scrubbed... URL: From ghang.naoc at gmail.com Thu Jan 31 22:26:45 2013 From: ghang.naoc at gmail.com (gonghang.naoc) Date: Fri, 1 Feb 2013 11:26:45 +0800 Subject: [AstroPy] point in ellipse In-Reply-To: References: Message-ID: Thanks. I used that too,but it seems it could only be used in polygon and you should know the vertices of the polygon?And you should convert ra&dec to physical coordinate on ccd first? Hang On Fri, Feb 1, 2013 at 2:12 AM, Phil Rosenfield < philrose at astro.washington.edu> wrote: > > I use nxutils for this: > http://matplotlib.org/api/nxutils_api.html > > > On Thu, Jan 31, 2013 at 10:00 AM, wrote: > >> Send AstroPy mailing list submissions to >> astropy at scipy.org >> >> To subscribe or unsubscribe via the World Wide Web, visit >> http://mail.scipy.org/mailman/listinfo/astropy >> or, via email, send a message with subject or body 'help' to >> astropy-request at scipy.org >> >> You can reach the person managing the list at >> astropy-owner at scipy.org >> >> When replying, please edit your Subject line so it is more specific >> than "Re: Contents of AstroPy digest..." >> >> >> Today's Topics: >> >> 1. point in ellipse (gonghang.naoc) >> 2. Re: point in ellipse (Tim Jenness) >> 3. Re: point in ellipse (Perry Greenfield) >> 4. Re: point in ellipse (Tim Jenness) >> 5. Re: point in ellipse (gonghang.naoc) >> 6. Re: point in ellipse (gonghang.naoc) >> >> >> ---------------------------------------------------------------------- >> >> Message: 1 >> Date: Thu, 31 Jan 2013 02:33:51 +0800 >> From: "gonghang.naoc" >> Subject: [AstroPy] point in ellipse >> To: astropy >> Message-ID: >> < >> CABb23mvkRamvf-7m-atj+5moB3z2y4dRvvjQ8H3iUwoZNYxo6Q at mail.gmail.com> >> Content-Type: text/plain; charset="utf-8" >> >> hi?everybody? >> >> I believe many people here use ds9 and know its region file >> format.For example?we can make an ellipse if we know its center ra?dec and >> >> main aixs direction.Is there a pythonic way to judge whether a point is in >> an ellipse if we know ra&dec of the point? >> >> Thank you. >> Best wishes. >> Hang >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: >> http://mail.scipy.org/pipermail/astropy/attachments/20130131/87c11093/attachment-0001.html >> >> ------------------------------ >> >> Message: 2 >> Date: Wed, 30 Jan 2013 11:47:52 -0700 >> From: Tim Jenness >> Subject: Re: [AstroPy] point in ellipse >> To: "gonghang.naoc" >> Cc: astropy >> Message-ID: >> > 7RhG2iwbUuUC84Z+QuSoJEh2CA at mail.gmail.com> >> Content-Type: text/plain; charset="utf-8" >> >> >> [now replying to list] >> >> You can use the Region class in pyast for that (it's not part of astropy). >> It has support for all the STC regions. >> >> https://github.com/timj/starlink-pyast >> >> AST is the library used internally by DS9. >> >> -- >> Tim Jenness >> >> >> On Wed, Jan 30, 2013 at 11:33 AM, gonghang.naoc > >wrote: >> >> > hi?everybody? >> >> > I believe many people here use ds9 and know its region file >> > format.For example?we can make an ellipse if we know its center ra?dec >> and >> >> > main aixs direction.Is there a pythonic way to judge whether a point is >> in >> > an ellipse if we know ra&dec of the point? >> >> > Thank you. >> > Best wishes. >> > Hang >> > >> > _______________________________________________ >> > AstroPy mailing list >> > AstroPy at scipy.org >> > http://mail.scipy.org/mailman/listinfo/astropy >> > >> > >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: >> http://mail.scipy.org/pipermail/astropy/attachments/20130130/38b2b5d6/attachment-0001.html >> >> ------------------------------ >> >> Message: 3 >> Date: Wed, 30 Jan 2013 13:48:01 -0500 >> From: Perry Greenfield >> Subject: Re: [AstroPy] point in ellipse >> To: "gonghang.naoc" >> Cc: astropy >> Message-ID: >> Content-Type: text/plain; charset=utf-8 >> >> >> Sure. >> >> But I'm assuming you wanted more than that. I presume you are looking for >> a function to test if a coordinate (or array of coordinates) lies inside >> the ellipse or not. Yes, that can be done analytically. You want a python >> function that does that specifically? (No, I don't have one handy, but it >> shouldn't be hard to code). >> >> Perry >> >> On Jan 30, 2013, at 1:33 PM, gonghang.naoc wrote: >> >> > hi?everybody? >> > I believe many people here use ds9 and know its region file >> format.For example?we can make an ellipse if we know its center ra?dec and >> main aixs direction.Is there a pythonic way to judge whether a point is in >> an ellipse if we know ra&dec of the point? >> >> > Thank you. >> > Best wishes. >> > Hang >> > _______________________________________________ >> > AstroPy mailing list >> > AstroPy at scipy.org >> > http://mail.scipy.org/mailman/listinfo/astropy >> >> >> >> ------------------------------ >> >> Message: 4 >> Date: Wed, 30 Jan 2013 11:56:34 -0700 >> From: Tim Jenness >> Subject: Re: [AstroPy] point in ellipse >> To: Perry Greenfield >> Cc: astropy >> Message-ID: >> < >> CA+G92Rc4YowNQ2kqpVzVW0n+Cs41YHwLk__kLyoeQSnD9HimYg at mail.gmail.com> >> Content-Type: text/plain; charset="iso-8859-1" >> >> >> On Wed, Jan 30, 2013 at 11:48 AM, Perry Greenfield >> wrote: >> >> > Sure. >> > >> > But I'm assuming you wanted more than that. I presume you are looking >> for >> > a function to test if a coordinate (or array of coordinates) lies inside >> > the ellipse or not. Yes, that can be done analytically. You want a >> python >> > function that does that specifically? (No, I don't have one handy, but >> it >> > shouldn't be hard to code). >> > >> > >> pyast has this built in. Create an ellipse object and then ask whether a >> position (or set of positions) is inside or outside it. >> >> -- >> Tim Jenness >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: >> http://mail.scipy.org/pipermail/astropy/attachments/20130130/6b2b8edf/attachment-0001.html >> >> ------------------------------ >> >> Message: 5 >> Date: Thu, 31 Jan 2013 21:41:28 +0800 >> From: "gonghang.naoc" >> Subject: Re: [AstroPy] point in ellipse >> To: Tim Jenness , astropy >> Message-ID: >> < >> CABb23mtsqd6Y2-qE4Dgpm8KoHOhj-f6ftkoOFM84TNpT3b8QXQ at mail.gmail.com> >> Content-Type: text/plain; charset="iso-8859-1" >> >> >> Thank you very much. http://dsberry.github.com/starlink/node1.html is >> helpful. >> Hang >> >> On Thu, Jan 31, 2013 at 2:56 AM, Tim Jenness >> wrote: >> >> > >> > >> > >> > On Wed, Jan 30, 2013 at 11:48 AM, Perry Greenfield > >wrote: >> >> > >> >> Sure. >> >> >> >> But I'm assuming you wanted more than that. I presume you are looking >> for >> >> a function to test if a coordinate (or array of coordinates) lies >> inside >> >> the ellipse or not. Yes, that can be done analytically. You want a >> python >> >> function that does that specifically? (No, I don't have one handy, but >> it >> >> shouldn't be hard to code). >> >> >> >> >> > pyast has this built in. Create an ellipse object and then ask whether a >> > position (or set of positions) is inside or outside it. >> > >> > -- >> > Tim Jenness >> > >> > >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: >> http://mail.scipy.org/pipermail/astropy/attachments/20130131/edd5670b/attachment-0001.html >> >> ------------------------------ >> >> Message: 6 >> Date: Thu, 31 Jan 2013 21:49:11 +0800 >> From: "gonghang.naoc" >> Subject: Re: [AstroPy] point in ellipse >> To: astropy >> Message-ID: >> > 8FD67BuJ_KwtymPK9uCutASitZUhJ9WfY7w at mail.gmail.com> >> Content-Type: text/plain; charset="utf-8" >> >> >> Thank you.oh, I thought a graphic way might be more convenient than a >> mathematical way .I am lazy to calculate.. >> Hang >> >> On Thu, Jan 31, 2013 at 2:48 AM, Perry Greenfield >> wrote: >> >> > Sure. >> > >> > But I'm assuming you wanted more than that. I presume you are looking >> for >> > a function to test if a coordinate (or array of coordinates) lies inside >> > the ellipse or not. Yes, that can be done analytically. You want a >> python >> > function that does that specifically? (No, I don't have one handy, but >> it >> > shouldn't be hard to code). >> > >> > Perry >> > >> > On Jan 30, 2013, at 1:33 PM, gonghang.naoc wrote: >> > >> > > hi?everybody? >> >> > > I believe many people here use ds9 and know its region file >> > format.For example?we can make an ellipse if we know its center ra?dec >> and >> >> > main aixs direction.Is there a pythonic way to judge whether a point is >> in >> > an ellipse if we know ra&dec of the point? >> >> > > Thank you. >> > > Best wishes. >> > > Hang >> > > _______________________________________________ >> > > AstroPy mailing list >> > > AstroPy at scipy.org >> > > http://mail.scipy.org/mailman/listinfo/astropy >> > >> > >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: >> http://mail.scipy.org/pipermail/astropy/attachments/20130131/227dd97f/attachment-0001.html >> >> ------------------------------ >> >> >> _______________________________________________ >> AstroPy mailing list >> AstroPy at scipy.org >> http://mail.scipy.org/mailman/listinfo/astropy >> >> >> End of AstroPy Digest, Vol 76, Issue 11 >> *************************************** >> > > > > -- > Phil Rosenfield > Graduate Student: UW Astronomy > Additional contact info: > http://www.astro.washington.edu/philrose > > _______________________________________________ > AstroPy mailing list > AstroPy at scipy.org > http://mail.scipy.org/mailman/listinfo/astropy > > -------------- next part -------------- An HTML attachment was scrubbed... URL: