python
132 posts — page 7
-
Zero based indexing
For Europeans zero based indexing feels reasonable if we think of floors in a house, the lowest floor is ground floor, then 1st floor and so on.
-
Write unit tests as cells of IPython notebooks
Plugin for py.test to write unit tests as cells in IPython notebooks: Homepage on Github:
-
Machine learning at scale with Python
My talk for the San Diego Data Science meetup: http://www.meetup.com/San-Diego-Data-Science-R-Users-Group/events/170967362/
-
Python on Gordon
Gordon has already a python environment setup which can be activated by loading the python module: module load python add this to .bashrc to load it at every login
-
Build Software Carpentry lessons with Pelican
Software Carpentry offers bootcamps for scientist to teach basic programming skills. All the material, mainly about bash, git, Python and R is available on Github under Creative Commons.
-
openproceedings - Github/FigShare based publishing platform for conference proceedings
Github provides a great interface for gathering, peer reviewing and accepting papers for conference proceedings, the second step is to publish them on a website either in HTML or PDF form or both. The Scipy conference is at the forefront on this and did great work in peer reviewing on Github, see: .
-
Run IPython Notebook on a HPC cluster via PBS
The IPython notebook is a great tool for data exploration and visualization. It is suitable in particular for analyzing a large amount of data remotely on a computing node of a HPC cluster and visualize it in a browser that runs on a local machine.
-
Published paper on destriping Cosmic Microwave Background polarimeter data
TL;DR version: Preprint on arxiv: Destriping Cosmic Microwave Background Polarimeter data
-
Jiffylab multiuser IPython notebooks
jiffylab is a very interesting project by Preston Holmes to provide sandboxed IPython notebooks instances on a server using docker. There are several user cases, for example:
-
How to log exceptions in Python
Sometimes it is useful to just catch any exception, write details to a log file and continue execution. In the Python standard library, it is possible to use the logging and exceptions modules to achieve this. First of all, we want to catch any exception, but also being able to access all information about it:
-
Google Plus comments plugin for Pelican
There has been recently several discussions about whether comments are any useful on blogs I think it is important to find better ways to connect blogs to social networks. In my opinion the most suitable social network for this is Google+, because there is space for larger discussion, without Twitter's character limit.
-
How to automatically build your Pelican blog and publish it to Github Pages
Something I like a lot about Jekyll, the Github static blog generator, is that you just push commits to your repository and Github takes care of re-building and publishing your website.
-
clviewer, interactive plot of CMB spectra
Today it was HackDay at .Astronomy, so I felt compelled to hack something around myself, creating something I have been thinking for a while after my previous work on Interactive CMB power spectra in the browser
-
Planck CMB map at high resolution
Prompted by a colleague, I created a high-resolution version of the Cosmic Microwave Background map in MollWeide projection released by the Planck collaboration, available on the Planck Data Release Website in FITS format.
-
Run Hadoop Python jobs on Amazon with mrjob
First we need to install mrjob with: pip install mrjob I am starting with a simple example of word counting. MrJob makes the implementation of the reducer particularly simple. Using hadoop-streaming directly, we needed also to first parse back the output of the mapper into python objects, while MrJob does it for you and gives directly the key and the list of count, that we just need to sum.