tag:blogger.com,1999:blog-56443421611451121772024-03-13T16:01:27.501-07:00BTDA blog about astrophysics & computing. More info about me @ <a href="http://casa.colorado.edu/~ginsbura/index.htm">Adam Ginsburg's page</a>Buffalohttp://www.blogger.com/profile/04395047681760378615noreply@blogger.comBlogger161125tag:blogger.com,1999:blog-5644342161145112177.post-21212394885845036752013-09-22T12:23:00.002-07:002013-09-22T12:23:10.804-07:00Blog moved!<div dir="ltr" style="text-align: left;" trbidi="on">
This blog has moved! It is now hosted at<br />
<a href="http://keflavich.github.io/blog/">http://keflavich.github.io/blog/</a></div>
<div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-38979817779017341512010-11-03T09:03:00.000-07:002010-11-03T09:03:06.068-07:00Repositories for observersI should have posted these a while ago....<br />
<a href="http://code.google.com/p/casaradio/"> casaradio </a> is a subversion repository for folks at <a href="http://casa.colorado.edu">The Center for Astrophysics and Space Astronomy at CU Boulder</a> to post radio astronomy related codes. So far, emphasizes single dish (GBT, Arecibo), but will include EVLA, CARMA, and ALMA eventually.<br />
<a href="http://code.google.com/p/aposoftware/">aposoftware</a> is a similar page, but is a mercurial repository and is meant to include instrument-specific software for the <a href="http://www.apo.nmsu.edu/"> Apache Point Observatory </a> <a href="http://www.apo.nmsu.edu/arc35m/GeneralInfo_ARC35m.html"> 3.5m telescope</a>. Right now includes a TUI script or two and the TSPEC and DIS IRAF-twodspec pipelines.<br />
<br />
I'd be remiss to leave out the <a href="http://code.google.com/p/bgpspipeline/">BGPS pipeline</a> even though it's mentioned on the previous post.<br />
<br />
Also, <a href="http://code.google.com/p/agpy/">agpy</a> is my personal code repository.<div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-89201473695157773032010-11-03T08:57:00.000-07:002010-11-03T08:57:54.321-07:00BGPS data paper publishedMetalinking! The BGPS paper finally made it onto astro-ph today. It will be published in ApJS before the year's end.<br />
<br />
<a href="http://bolocam.blogspot.com/2010/11/bgps-data-paper-published.html"> Links to all of the published BGPS papers at the Bolocam Data Team website</a><br />
<br />
And just because I want more linking, here they all are again:<br />
<a href="http://irsa.ipac.caltech.edu/data/BOLOCAM_GPS/bgps_methods.pdf"> The Bolocam Galactic Plane Survey I. Survey Description and Data Reduction</a> <a href=http://arxiv.org/abs/1011.0691> arXiv</a><br />
<a href="http://adsabs.harvard.edu/abs/2010ApJS..188..123R"> The Bolocam Galactic Plane Survey II. Catalog of the Image Data</a> <a href="http://arxiv.org/abs/0909.2871"> arXiv</a><br />
<a href="http://adsabs.harvard.edu/abs/2010ApJ...717.1157D"> The Bolocam Galactic Plane Survey III. Characterizing Physical Properties of Massive Star-Forming Regions in the Gemini OB1 Molecular Cloud </a> <a href="http://arxiv.org/abs/1005.4969"> arXiv</a><br />
<a href="http://adsabs.harvard.edu/abs/2010ApJ...721..137B"> The Bolocam Galactic Plane Survey IV: λ = 1.1 and 0.35 mm Dust Continuum Emission in the Galactic Center Region</a><br />
<br />
The same set of links is reproduced at <a href="http://code.google.com/p/bgpspipeline/">the pipeline googlecode page</a>.<div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-32356737502840669622010-08-16T17:37:00.000-07:002010-08-16T17:56:13.776-07:00Neat new things....1. <a href="http://www.pas.rochester.edu/~mpecaut/sptool/"> sptool </a> is a quick way to compare standards to stellar spectra. Nice, I'd been looking for a tool like that.<br />
2. <a href="http://blog.bigsmoke.us/2008/12/04/gnu-screen-window-captions-as-xterm-tabs"> GNU screen captions </a> are useful especially when working in a screen-within-a-screen environment (who does that, really?)<br />
3. finally got <a href="http://www.starlink.ac.uk/splat/"> SPLAT </a> to work... turns out I just hadn't reduced my damned data<br />
4. <a href="http://www.serverwatch.com/tutorials/article.php/3607246/Fresh-From-the-Linux-Kill.htm"> kill -STOP and kill -CONT </a> are really useful ways to pause programs that are sucking up resources if you want to resume them later. Haven't tried this on "real" code yet.<div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com1tag:blogger.com,1999:blog-5644342161145112177.post-85959035395629235502010-08-13T12:20:00.000-07:002010-08-13T12:21:56.223-07:00Filled step plots in matplotlibIt's not possible to do a simple filled step plot in matplotlib using default<br />
commands. Workaround:<br />
<br><br />
<code><pre>def steppify(arr,isX=False,interval=0):
"""
Converts an array to double-length for step plotting
"""
if isX and interval==0:
interval = abs(arr[1]-arr[0]) / 2.0
newarr = array(zip(arr-interval,arr+interval)).ravel()
return newarr
plot(xx,yy,linestyle='steps-mid',color='b',linewidth=1.5)
fill_between(steppify(xx[x1:x2],isX=True),
steppify(yy[x1:x2])*0,
steppify(yy[x1:x2]),
facecolor='b',alpha=0.2)
</pre></code><div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-437560088965814472010-07-28T08:09:00.000-07:002010-07-28T08:09:05.946-07:00Histogram in Google SpreadsheetIt's not easy to make a histogram in google spreadsheets without replicating data. The "countif" function would be great, except it only allows very simple criteria. However, there's a workaround:<br />
=count(Filter('Grades'!V2:V30,'Grades'!V2:V30>0.9))<br />
=count(Filter('Grades'!V2:V30,'Grades'!V2:V30<0.9,'Grades'!V2:V30>0.8))<br />
<br />
The Filter() function returns an array, which can be operated on like any other set of cells. <br />
<br />
It's still not easy to make a nice-looking histogram, but the output of this process is at least usable.<div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-42601889483860492192010-07-09T07:55:00.000-07:002010-07-09T07:55:14.952-07:00IDL-to-Pythonastrobetter started up an <a href="http://www.astrobetter.com/wiki/tiki-index.php?page=Python+Switchers+Guide">idl-to-python guide</a> on their wiki.<div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-40839360569794477882010-06-13T00:04:00.000-07:002010-06-13T00:04:05.326-07:00Ghostscript error?I've been receiving the following error when attempting to compile (ps2pdf) my w5 outflows paper:<br />
<br />
<pre>Error: /rangecheck in --get--
Operand stack:
pdfmark --dict:20/25(ro)(L)-- --nostringval-- 50
Execution stack:
%interp_exit .runexec2 --nostringval-- --nostringval-- --nostringval-- 2 %stopped_push --nostringval-- --nostringval-- --nostringval-- false 1 %stopped_push 1878 1 3 %oparray_pop 1877 1 3 %oparray_pop 1861 1 3 %oparray_pop 1755 1 3 %oparray_pop --nostringval-- %errorexec_pop .runexec2 --nostringval-- --nostringval-- --nostringval-- 2 %stopped_push --nostringval-- %finish_show --nostringval-- --nostringval-- 8 6 1 --nostringval-- (pdf_text_enum_t) %op_show_continue --nostringval--
Dictionary stack:
--dict:1153/1684(ro)(G)-- --dict:0/20(G)-- --dict:71/200(L)-- --dict:125/300(L)-- --dict:44/200(L)-- --dict:138/224(L)--
Current allocation mode is local
Last OS error: 2
Current file position is 267478928
GPL Ghostscript 8.71: Unrecoverable error, exit code 1
</pre><br />
I get the same error with Ghostscript 8.64, but on my laptop, using the fink version, it works. Similarly, there are errors with the postscript, so I'm led to believe it's an error in latex:<br />
<br />
<pre>$ latex --version
pdfTeX 3.1415926-1.40.10-2.2 (TeX Live 2009)
kpathsea version 5.0.0
Copyright 2009 Peter Breitenlohner (eTeX)/Han The Thanh (pdfTeX).
There is NO warranty. Redistribution of this software is
covered by the terms of both the pdfTeX copyright and
the Lesser GNU General Public License.
For more information about these matters, see the file
named COPYING and the pdfTeX source.
Primary author of pdfTeX: Peter Breitenlohner (eTeX)/Han The Thanh (pdfTeX).
Compiled with libpng 1.2.39; using libpng 1.2.39
Compiled with zlib 1.2.3; using zlib 1.2.3
Compiled with xpdf version 3.02pl3
</pre><br />
No idea what the cause is but it's time to start documenting steps and looking for a workaround. Compiling on the lappy isn't a good option.<div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-30495659504861296312010-05-26T14:01:00.001-07:002010-05-26T14:01:32.243-07:00EVLA informationIt has been really hard to find EVLA information like beam size, largest angular scale, sensitivity, etc. on the VLA pages because all of the google searches point to old VLA information. The most useful and recent <a href="http://evlaguides.nrao.edu/index.php?title=Category:Status">EVLA information on beam size and largest angular scale is here</a><div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-15891463652943670212010-05-25T15:35:00.000-07:002010-05-25T15:35:42.044-07:00usetex failure in latex documentsWhen I use matplotlib's internal tex (rcParams['text.useTex']=False), the postscript files generated cause errors that look like this when you try to ps2pdf them:<br />
<br />
<code><br />
ps2pdf h2co_pilot.ps<br />
Error: /rangecheck in --get--<br />
Operand stack:<br />
--dict:20/25(ro)(L)-- --nostringval-- 71<br />
Execution stack:<br />
%interp_exit .runexec2 --nostringval-- --nostringval-- --nostringval-- 2 %stopped_push --nostringval-- --nostringval-- --nostringval-- false 1 %stopped_push 1862 1 3 %oparray_pop 1861 1 3 %oparray_pop 1845 1 3 %oparray_pop 1739 1 3 %oparray_pop --nostringval-- %errorexec_pop .runexec2 --nostringval-- --nostringval-- --nostringval-- 2 %stopped_push --nostringval-- %finish_show --nostringval-- --nostringval-- 9 6 0 --nostringval-- (pdf_text_enum_t) %op_show_continue --nostringval--<br />
Dictionary stack:<br />
--dict:1147/1684(ro)(G)-- --dict:0/20(G)-- --dict:70/200(L)-- --dict:116/300(L)-- --dict:44/200(L)-- --dict:25/42(L)--<br />
Current allocation mode is local<br />
Last OS error: 2<br />
Current file position is 791626<br />
GPL Ghostscript 8.64: Unrecoverable error, exit code 1<br />
make: *** [h2co_pilot.pdf] Error 1<br />
</code><br />
<br />
They will not open in MacOS's Preview.app either.<br />
<br />
Solution: Make figures with rcParams['text.useTex'] = True<div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-84821298382612601002010-05-01T11:31:00.001-07:002010-06-26T16:18:39.027-07:00RATRAN on Mac OS XMac OS X doesn't like the defaults built in to <a href="http://www.sron.rug.nl/~vdtak/ratran/frames.html">RATRAN</a>. It died unhappily with errors like:<br />
<br />
<code> ld_classic: can't locate file for: -lcrt0.o </code><br />
and<br />
<code>ld: warning: in /usr/local/lib//libcfitsio.a, file is not of required architecture</code><br />
<br />
<br />
In order to get it to run, I had to do the following:<br />
<ol><li> Install CFITSIO with <code>CFLAGS="-arch x86_64 -arch i386 -g -O2" </code> to /usr/local/lib<br />
<li> Edit the sky/Makefile OPT variable (line 23) to read:<br />
<code>OPT = -I. -O2 -fno-automatic -arch x86_64</code><br />
</ol>Also, you need to set up system variables:
<pre><code>
export RATRAN=/path/to/Ratran
export RATRANRUN=/path/to/Ratran/run
</code>
</pre><div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com6tag:blogger.com,1999:blog-5644342161145112177.post-15729383876993337402010-04-22T08:55:00.000-07:002010-04-22T08:55:01.433-07:00Gildas CLASSIt's absurdly difficult to find help on GILDAS Class, probably because you can't google "class" and most people probably don't label every piece of code with "GILDAS class".<br />
<br />
Anyway, here are some scripts that I refer back to often:<br />
<code><br />
file in August2009BGPS.dat<br />
file out August2009fits.dat multiple<br />
on error "file out August2009fits.dat"<br />
say "READ IN FILES"<br />
define character sourcelist*10[300]<br />
accept sourcelist /column observed_sources.txt<br />
on error "continue"<br />
get 1001<br />
set window -100 160<br />
set mask -400 -100 160 400<br />
set mode x -400 400<br />
set align velocity<br />
for i 1 to 161<br />
say "Working on SOURCE "'i'<br />
find /source 'sourcelist[i]' /telescope "CSO 4GHZ IF1" /offset 0 0 /quality 5<br />
average<br />
on error "@avplot2 'sourcelist[i]' 'i'; next"<br />
base 3<br />
line 0<br />
min<br />
plot<br />
vis<br />
write i<br />
! on error "continue"<br />
next<br />
</code><br />
<br />
and<br />
<br />
<code><br />
file in araya-2004.cls<br />
find<br />
define character filename*20<br />
for i 1 to 20 <br />
say "Working on source "'i'<br />
get next<br />
let filename "araya-2004_"'i'".fits" <br />
say "fits write "'filename'" /mode spectrum"<br />
fits write 'filename' /mode spectrum<br />
next<br />
<br />
!file in araya-2002.cls<br />
!find<br />
!define character filename*20<br />
!for i 1 to 42 <br />
! say "Working on source "'i'<br />
! get i<br />
! let filename "araya-2002_"'i'".fits" <br />
! say "fits write "'filename'" /mode spectrum"<br />
! fits write 'filename' /mode spectrum<br />
!next<br />
</code><div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-36762620706171712882010-03-28T10:25:00.001-07:002010-03-28T10:25:14.170-07:00IRAF append/prepend/replaceIRAF has special syntax to append/replace, so you can do something like:<br />
<code>imarith *.fits - dark.fits ds_//*.fits</code><br />
...though I can't remember right now how to do replacement etc.<div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com2tag:blogger.com,1999:blog-5644342161145112177.post-82811222216508104882010-03-18T15:29:00.000-07:002010-03-18T15:31:03.742-07:00command line & escape keyProblem: in both the bash command line and ipython, if I hit escape twice, I can never again do history-search-backwards (i.e. when you type part of a command and type "up" and reverse-search through your command history). Any idea how to fix this?<div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-11894209769722809402010-03-05T07:55:00.001-08:002010-03-05T10:52:35.518-08:00Rebuilding python from scratch againI got scipy working a week or two ago, but doing so killed matplotib's tkagg. So, I switched to the MacOSX backend, which worked ok until I realized that the interactive (connect) features of macosx failed miserably. This led me to try to get matplotlib working.... which broke with those awful "symbol not found" errors in ft2font.so and _path.so, which I've determined all have to do with linking to the wrong library files.<br /><br />The most worrisome part of this process was discovering that a full Time Machine recovery of /usr and /Library/Frameworks and /Library/Python did *not* restore python - it stayed dead with IDENTICAL errors. So there are probably additional layers of hidden links.<br /><br />The process below is based on <a href="http://blog.hyperjeff.net/?p=160">hyperjeff's blog post</a> but differs substantially based on <a href="http://casa.colorado.edu/~skillman/research_and_codes/files/649710e82f85745eb65a90535f0f3098-5.html"> Sam Skillman's recommendations </a> and the very big issue I ran into that my /usr/local files appeared to be corrupted. After this install, my path no longer includes /usr/local/bin and /sw has been moved to /_sw... hopefully one of these days I'll be ballsy enough to delete it.<br /><br /><ol><li> Install python 2.6.4<br /><ol type="a"><li> Needed a clean terminal with no flags set at all. Don't know why - all I had set were a bunch of -arch x86_64 flags.<br /><code><br />export LD_LIBRARY_PATH="/usr/local/lib:/usr/X11/lib"<br />./configure --enable-framework=/Library/Frameworks MACOSX_DEPLOYMENT_TARGET=10.6 <br />make -j 17<br />sudo make install<br /></code><br /><li> Reset PYTHONPATH to blank<br /><li> <code> alias clearflags='export CFLAGS=""; export CCFLAGS=""; export CXXFLAGS=""; export LDFLAGS=""; export FFLAGS="";'</code> to make sure<br /></ol><br /><li> Install FFTW<br /><code><br />cd ~/tmp<br />curl -O http://www.fftw.org/fftw-3.2.2.tar.gz<br />tar xf fftw-3.2.2.tar.gz<br />cd fftw-3.2.2<br />clearflags<br />./configure CC="gcc -arch x86_64" CXX="g++ -arch x86_64" CPP="gcc -E" CXXCPP="g++ -E"<br />make -j 17<br />sudo make install<br /></code><br /><li> Install UMFPACK<br /><code><br />cd ~/tmp<br />curl -O http://www.cise.ufl.edu/research/sparse/umfpack/current/UMFPACK.tar.gz<br />curl -O http://www.cise.ufl.edu/research/sparse/UFconfig/current/UFconfig.tar.gz<br />curl -O http://www.cise.ufl.edu/research/sparse/amd/current/AMD.tar.gz<br />tar xf AMD.tar.gz<br />tar xf UFconfig.tar.gz<br />tar xf UMFPACK.tar.gz<br />sed -ibck 's/F77 = f77/F77 = gfortran/' UFconfig/UFconfig.mk <br />sed -ibck '299,303s/# //' UFconfig/UFconfig.mk<br />cp UFconfig/UFconfig.h AMD/Include/<br />cp UFconfig/UFconfig.h UMFPACK/Include/<br />cd UMFPACK<br />make -j 17<br />make hb<br />make clean<br /></code><br /><li> Install numpy<br /><ol type="a"><li> Set environment variables<br /><code><br />export MACOSX_DEPLOYMENT_TARGET=10.6<br />export CFLAGS="-arch x86_64"<br />export FFLAGS="-m64"<br />export LDFLAGS="-Wall -undefined dynamic_lookup -bundle -arch x86_64"<br />export PYTHONPATH="/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/"<br />echo "[amd]<br />library_dirs = /Users/adam/tmp/AMD/Lib<br />include_dirs = /Users/adam/tmp/AMD/Include<br />amd_libs = amd<br /><br />[umfpack]<br />library_dirs = /Users/adam/tmp/UMFPACK/Lib<br />include_dirs = /Users/adam/tmp/UMFPACK/Include<br />umfpack_libs = umfpack" > site.cfg<br /></code><br /><li> Setup & Install<br /><code><br />python setup.py build --fcompiler=gnu95<br />sudo python setup.py install<br /></code><br /><li> Test: python -c "import numpy"<br /></ol><br /><li> Install scipy. The important thing is to use g++-4.2 because g++-4.5 doesn't accept the -arch flag. Also, get rid of /sw if it's on your computer at all.<br /><code><br />sudo mv /System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/numpy /System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/numpyX<br />cd ~/repos/scipy-0.7.1<br />python setup.py clean<br />rm -rf build<br />clearflags<br />FFLAGS="-m64" CFLAGS="-arch x86_64 -I/usr/local/include/freetype2 -I/usr/X11/include -L/usr/X11/lib" LDFLAGS="-Wall -undefined dynamic_lookup -bundle -lpng -arch x86_64" CXX="/usr/bin/g++-4.2" CC="/usr/bin/gcc-4.2" python setup.py build<br />python setup.py install<br /></code><br />Test the install:<br /><code><br />python -c "import scipy, scipy.fftpack, scipy.interpolate"<br /></code><br /><li> <ol type='a'> <li> Install matplotlib. MAKE SURE /usr/bin/texbin is in front of /usr/local/bin and /sw/bin so that dvipng comes from MacTEX. I also ended up having to remove /usr/local/bin from my path completely<br /><code><br />sudo mv /System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/numpy /System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/numpyX<br />cd ~/repos/matplotlib-svn<br />python setup.py clean<br />rm -rf build<br />clearflags<br /></code><br /><li> Do hyperjeff's recommended edits except don't use /usr/local because it's f'd: <br />make.osx:<br /><code><br />MACOSX_DEPLOYMENT_TARGET=10.6<br />PREFIX=/usr<br />PYTHON=/Library/Frameworks/Python.framework/Versions/Current/bin/python<br /><br />## You shouldn't need to configure past this point (and yet…)<br /><br />PKG_CONFIG_PATH="${PREFIX}/lib/pkgconfig"<br />CFLAGS="-arch i386 -arch x86_64 -I${PREFIX}/include -I${PREFIX}/include/freetype2 -isysroot /Developer/SDKs/MacOSX10.6.sdk"<br />LDFLAGS="-arch i386 -arch x86_64 -L${PREFIX}/lib -syslibroot,/Developer/SDKs/MacOSX10.6.sdk"<br />FFLAGS="-arch i386 -arch x86_64"<br /></code><br />setup.cfg:<br /><code><br />wxagg = False<br /></code><br /><li> Do the install (different from hyperjeff b/c I don't want root)<br /><code> sudo make -f make.osx fetch deps <br />make -f mpl_build mpl_install<br />python setup.py install<br /></code><br /></ol><br /><li> Install setuptools<br /><li> easy_install ipython<br /><li> install everything else pythonically<br /></ol><div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com4tag:blogger.com,1999:blog-5644342161145112177.post-3125272518808976122010-03-01T12:53:00.000-08:002010-03-01T12:54:30.777-08:00apache/php/mysql on snow leopard<a href="http://maestric.com/doc/mac/apache_php_mysql_snow_leopard">This post</a> helped me out<div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-90853052052803281952010-02-25T12:14:00.000-08:002010-02-25T12:15:40.844-08:00macvim crashwell, it finally happened.... my reliable, trusty editor crashed. That should be impossible. I am ready to call it quits for the week....<br /><br /><pre><br />Process: MacVim [650]<br />Path: /Applications/Vim.app/Contents/MacOS/MacVim<br />Identifier: org.vim.MacVim<br />Version: 7.2 (49)<br />Code Type: X86 (Native)<br />Parent Process: Vim [649]<br /><br />Date/Time: 2010-02-25 13:12:43.001 -0700<br />OS Version: Mac OS X 10.6.2 (10C540)<br />Report Version: 6<br /><br />Interval Since Last Report: 871676 sec<br />Crashes Since Last Report: 26<br />Per-App Interval Since Last Report: 938504 sec<br />Per-App Crashes Since Last Report: 1<br />Anonymous UUID: 03159B9E-2257-4E38-8C4A-4D4DAF5641A7<br /><br />Exception Type: EXC_BAD_ACCESS (SIGSEGV)<br />Exception Codes: 0x000000000000000d, 0x0000000000000000<br />Crashed Thread: 0 Dispatch queue: com.apple.main-thread<br /><br />Thread 0 Crashed: Dispatch queue: com.apple.main-thread<br />0 com.apple.CoreFoundation 0x99119480 __CFSetCallback + 0<br />1 com.apple.CoreFoundation 0x990c78bc ___CFBasicHashFindBucket1 + 444<br />2 com.apple.CoreFoundation 0x990cfaac CFBasicHashFindBucket + 252<br />3 com.apple.CoreFoundation 0x990e8293 CFSetGetValue + 131<br />4 com.apple.AppKit 0x961bae7e -[NSWindow _discardTrackingRect:] + 59<br />5 com.apple.AppKit 0x961badca -[NSView(NSInternal) _uninstallTrackingArea:] + 123<br />6 com.apple.AppKit 0x960d2c32 -[NSView(NSInternal) _uninstallRemovedTrackingAreas] + 293<br />7 com.apple.AppKit 0x960dac40 -[NSView(NSInternal) _updateTrackingAreas] + 646<br />8 com.apple.CoreFoundation 0x990ea4e0 CFArrayApplyFunction + 224<br />9 com.apple.AppKit 0x960daefb -[NSView(NSInternal) _updateTrackingAreas] + 1345<br />10 com.apple.CoreFoundation 0x990ea4e0 CFArrayApplyFunction + 224<br />11 com.apple.AppKit 0x960daefb -[NSView(NSInternal) _updateTrackingAreas] + 1345<br />12 com.apple.CoreFoundation 0x990ea4e0 CFArrayApplyFunction + 224<br />13 com.apple.AppKit 0x960daefb -[NSView(NSInternal) _updateTrackingAreas] + 1345<br />14 com.apple.AppKit 0x960da8db _handleInvalidCursorRectsNote + 392<br />15 com.apple.CoreFoundation 0x99135892 __CFRunLoopDoObservers + 1186<br />16 com.apple.CoreFoundation 0x990f218d __CFRunLoopRun + 557<br />17 com.apple.CoreFoundation 0x990f1864 CFRunLoopRunSpecific + 452<br />18 com.apple.CoreFoundation 0x990f1691 CFRunLoopRunInMode + 97<br />19 com.apple.HIToolbox 0x936f6f0c RunCurrentEventLoopInMode + 392<br />20 com.apple.HIToolbox 0x936f6bff ReceiveNextEventCommon + 158<br />21 com.apple.HIToolbox 0x936f6b48 BlockUntilNextEventMatchingListInMode + 81<br />22 com.apple.AppKit 0x960b0ac5 _DPSNextEvent + 847<br />23 com.apple.AppKit 0x960b0306 -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] + 156<br />24 com.apple.AppKit 0x9607249f -[NSApplication run] + 821<br />25 com.apple.AppKit 0x9606a535 NSApplicationMain + 574<br />26 org.vim.MacVim 0x0000238b _start + 209<br />27 org.vim.MacVim 0x000022b9 start + 41<br /><br />Thread 1: Dispatch queue: com.apple.libdispatch-manager<br />0 libSystem.B.dylib 0x98d0c0ea kevent + 10<br />1 libSystem.B.dylib 0x98d0c804 _dispatch_mgr_invoke + 215<br />2 libSystem.B.dylib 0x98d0bcc3 _dispatch_queue_invoke + 163<br />3 libSystem.B.dylib 0x98d0ba68 _dispatch_worker_thread2 + 234<br />4 libSystem.B.dylib 0x98d0b4f1 _pthread_wqthread + 390<br />5 libSystem.B.dylib 0x98d0b336 start_wqthread + 30<br /><br />Thread 2:<br />0 libSystem.B.dylib 0x98ce58da mach_msg_trap + 10<br />1 libSystem.B.dylib 0x98ce6047 mach_msg + 68<br />2 com.apple.CoreFoundation 0x990f277f __CFRunLoopRun + 2079<br />3 com.apple.CoreFoundation 0x990f1864 CFRunLoopRunSpecific + 452<br />4 com.apple.CoreFoundation 0x990f1691 CFRunLoopRunInMode + 97<br />5 com.apple.Foundation 0x91b24430 +[NSURLConnection(NSURLConnectionReallyInternal) _resourceLoadLoop:] + 329<br />6 com.apple.Foundation 0x91aeb8d8 -[NSThread main] + 45<br />7 com.apple.Foundation 0x91aeb888 __NSThread__main__ + 1499<br />8 libSystem.B.dylib 0x98d12fbd _pthread_start + 345<br />9 libSystem.B.dylib 0x98d12e42 thread_start + 34<br /><br />Thread 3:<br />0 libSystem.B.dylib 0x98d04856 select$DARWIN_EXTSN + 10<br />1 com.apple.CoreFoundation 0x99131ddd __CFSocketManager + 1085<br />2 libSystem.B.dylib 0x98d12fbd _pthread_start + 345<br />3 libSystem.B.dylib 0x98d12e42 thread_start + 34<br /><br />Thread 4:<br />0 libSystem.B.dylib 0x98d0b182 __workq_kernreturn + 10<br />1 libSystem.B.dylib 0x98d0b718 _pthread_wqthread + 941<br />2 libSystem.B.dylib 0x98d0b336 start_wqthread + 30<br /><br />Thread 0 crashed with X86 Thread State (32-bit):<br /> eax: 0x00515db0 ebx: 0x990c7711 ecx: 0x00516460 edx: 0xbfffcabc<br /> edi: 0x00001041 esi: 0x00504270 ebp: 0xbfffca38 esp: 0xbfffc99c<br /> ss: 0x0000001f efl: 0x00010246 eip: 0x99119480 cs: 0x00000017<br /> ds: 0x0000001f es: 0x0000001f fs: 0x00000000 gs: 0x00000037<br /> cr2: 0x97a20000<br /></pre><div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-1114777349812165422010-02-17T14:20:00.001-08:002010-02-17T14:21:07.416-08:00Command of the Day<code> ls | wc </code><br /><br />and for when <code> ls * </code> fails<br /><br /><code> find . -name "*" | xargs -I {} mv {} away/ </code><div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-85113427433888798692010-02-16T20:44:00.001-08:002010-02-16T20:45:51.622-08:00DS9 gaussian fittingOne thing DS9 desperately needs is an interactive gaussian fitter. I have NOT implemented one yet, but it is high on my to do list. Has anyone else (googlers?) tried or succeeded in implementing such a thing? Ideally, something with NO dependencies: if I write one, it will require python, numpy, and probably pyds9 - ick. Straight-up TCL would be very much preferable.<div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-51288777101545261542010-02-16T13:47:00.000-08:002010-02-16T13:49:05.202-08:00Another attempt to get 64 bit python on Snow LeopardSam Skillman posted <a href="http://casa.colorado.edu/~skillman/research_and_codes/files/5426de84108df075adee2e9a5c23d90e-4.html"> his attempt to get 64 bit python on snow leopard</a>. It worked, but you need to install python with --enable-framework and NOT --prefix and NOT --enable-universalSDK. It is 64-bit only, not universal: universal causes trouble.<div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-53976895005319839462010-02-15T08:57:00.000-08:002010-02-15T09:23:42.634-08:00Python 64-bit on Mac OS X 10.6 Snow LeopardAfter <a href="http://buffalothedestroyer.blogspot.com/2010/02/installing-snow-leopard.html">yesterday's disastrous attempt</a> to install various python packages, I started from scratch. First, I got rid of all of my python frameworks (backed up but removed from the path). Then, I compiled python 2.7 from scratch:<br /><br />I got some help from <a href="http://blog.mahmoudimus.com/2009/12/python-2-6-4-and-twisted-9-on-os-x-10-6-snow-leopard/">http://blog.mahmoudimus.com/2009/12/python-2-6-4-and-twisted-9-on-os-x-10-6-snow-leopard/</a><br /><br /><code>./configure --enable-framework --enable-universalsdk=/Developer/SDKs/MacOSX10.6.sdk MACOSX_DEPLOYMENT_TARGET=10.6 --with-universal-archs=intel -with-readline-dir=/usr/local<br />make -j 17<br />make -j 17 test </code><br /><br /><code> make </code> results:<br /><pre>Python build finished, but the necessary bits to build these modules were not found:<br />_bsddb dl gdbm <br />imageop linuxaudiodev ossaudiodev <br />spwd sunaudiodev <br />To find the necessary bits, look in setup.py in detect_modules() for the module's name.<br /></pre><br /><br />I'm not concerned about these - I don't use any of them and I assume I need to install some other packages to get them to work.<br /><br />During make test, I had two failures that resulted in "python crash" pop-up boxes:<br /><pre>test_subprocess<br />.<br /> this bit of output is from a test of stdout in a different process ...<br />.<br /> this bit of output is from a test of stdout in a different process ...<br />test_sunaudiodev</pre><br /><br />Then, I got some malloc errors:<br /><pre>test_io<br /><br />Testing large file ops skipped on darwin.<br />It requires 2147483648 bytes and a long time.<br />Use 'regrtest.py -u largefile test_io' to run it.<br /><br />Testing large file ops skipped on darwin.<br />It requires 2147483648 bytes and a long time.<br />Use 'regrtest.py -u largefile test_io' to run it.<br />python.exe(22914,0x7fff70d3ebe0) malloc: *** mmap(size=9223372036854775808) failed (error code=12)<br />*** error: can't allocate region<br />*** set a breakpoint in malloc_error_break to debug<br />python.exe(22914,0x7fff70d3ebe0) malloc: *** mmap(size=9223372036854775808) failed (error code=12)<br />*** error: can't allocate region<br />*** set a breakpoint in malloc_error_break to debug<br />python.exe(22914,0x7fff70d3ebe0) malloc: *** mmap(size=9223372036854775808) failed (error code=12)<br />*** error: can't allocate region<br />*** set a breakpoint in malloc_error_break to debug<br />test_ioctl</pre><div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com1tag:blogger.com,1999:blog-5644342161145112177.post-69331780112104123112010-02-14T12:23:00.000-08:002010-03-02T08:16:27.165-08:00Installing Snow LeopardI'm going to attempt to install snow leopard today. This post will serve as a record of the difficulties I run into.<br /><br />Things to install (and ensure they are 64-bit):<br /><ul><br /><li>ipython<br /><li>numpy<br /><li>scipy<br /><li>matplotlib<br /><li>stsci-python<br /><li>starlink<br /><li>gfortran<br /><li>latex<br /><li>idl (check)<br /></ul><br /><br />Things that have happened:<br /><ol><br /><li> Had to restart again (twice) to install additional updates<br /><li> My bash command line looked funny - something about bash changed, but I don't know what. The fix was easy: commented out some code from <a href="http://pseudogreen.org/blog/set_tab_names_in_leopard_terminal.html">http://pseudogreen.org/blog/set_tab_names_in_leopard_terminal.html</a> that I had been using to set the tab title<br /><li> My locate db broke. Needed repair: <code>sudo /usr/libexec/locate.updatedb </code><br /><li> numpy svn failed to build:<br /><code> python setup.py build<br />Running from numpy source directory.non-existing path in 'numpy/distutils': 'site.cfg'<br />F2PY Version 2_8111<br />numpy/core/setup_common.py:86: MismatchCAPIWarning: API mismatch detected, the C API version numbers have to be updated. Current C api version is 4, with checksum 59750b518272c8987f02d66445afd3f1, but recorded checksum for C API version 4 in codegen_dir/cversions.txt is 3d8940bf7b0d2a4e25be4338c14c3c85. If functions were added in the C API, you have to update C_API_VERSION in numpy/core/setup_common.pyc.<br /> MismatchCAPIWarning)<br />blas_opt_info:<br /> FOUND:<br /> extra_link_args = ['-Wl,-framework', '-Wl,Accelerate']<br /> define_macros = [('NO_ATLAS_INFO', 3)]<br /> extra_compile_args = ['-faltivec', '-I/System/Library/Frameworks/vecLib.framework/Headers']<br /><br />lapack_opt_info:<br /> FOUND:<br /> extra_link_args = ['-Wl,-framework', '-Wl,Accelerate']<br /> define_macros = [('NO_ATLAS_INFO', 3)]<br /> extra_compile_args = ['-faltivec']<br /><br />running build<br />running config_cc<br />unifing config_cc, config, build_clib, build_ext, build commands --compiler options<br />running config_fc<br />unifing config_fc, config, build_clib, build_ext, build commands --fcompiler options<br />running build_src<br />build_src<br />building py_modules sources<br />building library "npymath" sources<br />customize NAGFCompiler<br />Found executable /usr/local/bin/f95<br />customize AbsoftFCompiler<br />Could not locate executable f90<br />Found executable /usr/bin/f77<br />absoft: no Fortran 90 compiler found<br />absoft: no Fortran 90 compiler found<br />customize IBMFCompiler<br />Could not locate executable xlf90<br />Could not locate executable xlf<br />customize IntelFCompiler<br />Could not locate executable ifort<br />Could not locate executable ifc<br />customize GnuFCompiler<br />Found executable /usr/local/bin/g77<br />gnu: no Fortran 90 compiler found<br />gnu: no Fortran 90 compiler found<br />customize Gnu95FCompiler<br />Found executable /usr/local/bin/gfortran<br />customize Gnu95FCompiler<br />customize Gnu95FCompiler using config<br />C compiler: gcc -arch i386 -arch ppc -arch ppc64 -arch x86_64 -isysroot /Developer/SDKs/MacOSX10.5.sdk -fno-strict-aliasing -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes<br /><br />compile options: '-Inumpy/core/src/private -Inumpy/core/src -Inumpy/core -Inumpy/core/src/npymath -Inumpy/core/src/multiarray -Inumpy/core/src/umath -Inumpy/core/include -I/Library/Frameworks/Python.framework/Versions/2.6/include/python2.6 -c'<br />gcc: _configtest.c<br />gcc _configtest.o -o _configtest<br />ld: library not found for -lcrt1.10.5.o<br />collect2: ld returned 1 exit status<br />ld: library not found for -lcrt1.10.5.o<br />collect2: ld returned 1 exit status<br />failure.<br />removing: _configtest.c _configtest.o<br />Traceback (most recent call last):<br /> File "setup.py", line 210, in <module><br /> setup_package()<br /> File "setup.py", line 203, in setup_package<br /> configuration=configuration )<br /> File "/Users/adam/repos/numpy-svn/numpy/distutils/core.py", line 186, in setup<br /> return old_setup(**new_attr)<br /> File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/distutils/core.py", line 152, in setup<br /> dist.run_commands()<br /> File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/distutils/dist.py", line 975, in run_commands<br /> self.run_command(cmd)<br /> File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/distutils/dist.py", line 995, in run_command<br /> cmd_obj.run()<br /> File "/Users/adam/repos/numpy-svn/numpy/distutils/command/build.py", line 37, in run<br /> old_build.run(self)<br /> File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/distutils/command/build.py", line 134, in run<br /> self.run_command(cmd_name)<br /> File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/distutils/cmd.py", line 333, in run_command<br /> self.distribution.run_command(command)<br /> File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/distutils/dist.py", line 995, in run_command<br /> cmd_obj.run()<br /> File "/Users/adam/repos/numpy-svn/numpy/distutils/command/build_src.py", line 152, in run<br /> self.build_sources()<br /> File "/Users/adam/repos/numpy-svn/numpy/distutils/command/build_src.py", line 163, in build_sources<br /> self.build_library_sources(*libname_info)<br /> File "/Users/adam/repos/numpy-svn/numpy/distutils/command/build_src.py", line 298, in build_library_sources<br /> sources = self.generate_sources(sources, (lib_name, build_info))<br /> File "/Users/adam/repos/numpy-svn/numpy/distutils/command/build_src.py", line 385, in generate_sources<br /> source = func(extension, build_dir)<br /> File "numpy/core/setup.py", line 670, in get_mathlib_info<br /> raise RuntimeError("Broken toolchain: cannot link a simple C program")<br />RuntimeError: Broken toolchain: cannot link a simple C program</code><br /><br><b>SOLUTION:</b> Use the Mac OS X 10.6 python (/usr/bin/python). I will do this until I run into another problem. Numpy build successfully<br /><li> Build/install matplotlib - failed! Completely!<br /><li> Acquired gcc/gfortran from <a href="http://hpc.sourceforge.net/">hpc</a><br /><li> Followed instructions from <a href="http://blog.hyperjeff.net/?p=160">hyperjeff</a> on fortran install...<br /><li> Get rid of numpy 1.2.1: <code> mv /System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/numpy /System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/.not_numpy.bak</code><br /><li> Try to install scipy. Fail on missing umfpack, follow <a href="http://blog.hyperjeff.net/?p=160">hyperjeff</a>'s instructions (but make sure to edit the site.cfg in scipy, not just the one in numpy)<br /><br> Had to add the following code:<br /><code> <br />sudo cp AMD/Lib/libamd.a /System/Library/Frameworks/Python.framework/Versions/2.6/lib<br />sudo cp UMFPACK/Lib/libumfpack.a /System/Library/Frameworks/Python.framework/Versions/2.6/lib<br />sudo cp AMD/Include/amd.h /System/Library/Frameworks/Python.framework/Versions/2.6/include<br />sudo cp UFconfig/UFconfig.h /System/Library/Frameworks/Python.framework/Versions/2.6/include<br />sudo cp UMFPACK/Include/*.h /System/Library/Frameworks/Python.framework/Versions/2.6/include<br /></code><br /><li> Installed fftw from <a href="http://www.fftw.org/">fftw.org</a> with simple ./configure, make, sudo make install - no compiler opts as they killed the install<br /><li> Get SoundSource from <a href="http://www.rogueamoeba.com/freebies/">rogueamoeba</a><br /><li> Updated <a href="http://www.islayer.com/apps/istatmenus/"> istatmenus </a><br /></ol><div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-42916442177627083062010-02-12T08:01:00.000-08:002010-03-13T09:57:34.840-08:00PSDs, cross-correlation...scipy is capable of doing fft-base cross-correlation, convolution, etc., but it requires the stsci package, which is not generally easy to install. For that matter, scipy can be a pain some of the time. So agpy now includes a 2D cross-correlation code and a power spectrum / power spectral density code. These are pure-numpy codes that should be easy to use without any other bothersome dependencies.<br /><br />EDIT: I have them check for scipy (which can cause crashes if you have a bad scipy install, e.g. 32 bit executables on a 64 bit system) because scipy uses FFTW and numpy appears not to. Also, this code & related stuff has been <a href="http://www.astrobetter.com/fourier-transforms-of-images-in-python/">discussed on astrobetyter</a><br /><br /><a href="http://code.google.com/p/agpy/"> agpy </a><br /><a href="http://code.google.com/p/agpy/source/browse/trunk/agpy/correlate2d.py"> correlate2d</a><br /><a href="http://code.google.com/p/agpy/source/browse/trunk/agpy/psds.py"> psds </a><div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-16238127196258769812010-02-04T18:31:00.000-08:002010-02-04T19:05:07.811-08:00Logarithmic Colormap / Other Colormap in MatplotlibThis is kind of a pain to find out:<br /><br /><code><br />from matplotlib.colors import LogNorm<br /><br />im = imshow(.... cmap=... , norm=LogNorm(vmin=clevs[0], vmax=clevs[-1])) <br /></code><br /><br />It also works for contours, and can be particularly useful if you only want to display contours at a few levels, but you want the colormap to start at a different point. e.g.:<br /><code><br />contour(xx,levels=[2,3,4,5,6,7,8,9,10],norm=matplotlib.colors.Normalize(vmin=0,vmax=10))<br /></code><br />will start at light blue instead of dark blue in the default colormap<div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0tag:blogger.com,1999:blog-5644342161145112177.post-40606236183770062142010-01-27T17:52:00.001-08:002010-01-27T17:54:14.777-08:00wrapping text around a figure in latexAn example from Devin:<br /><br />%\begin{wrapfigure}{l}{0.5\textwidth}<br />% \vspace{-27pt}<br />% \begin{center}<br />% \includegraphics[width=0.48\textwidth]{nsf_fig3.ps}<br />% \end{center}<br />% \vspace{-27pt}<br />% \caption{\it{}}<br />% \vspace{-12pt}<br />%\end{wrapfigure}<br />1:16<br />\usepackage{wrapfig}<div class="blogger-post-footer"><a href="http://casa.colorado.edu/~ginsbura/">Home</a></div>Adamhttp://www.blogger.com/profile/14242933152559633074noreply@blogger.com0