Read the Beforeitsnews.com story here. Advertise at Before It's News here.
Profile image
Story Views
Now:
Last hour:
Last 24 hours:
Total:

Parallel Astronomical Data Processing with Python: Recipes for multicore machines

% of readers think this story is Fact. Add your two cents.


Most astronomers (myself included) have a high performance compute engine on their desktops. Modern computers now contain multicore processors, whose development was prompted by the need to reduce heat dissipation and power consumption but which give users a powerful processing machine at their fingertips. Singh, Browne and Butler have recently posted a preprint on astro-ph, submitted to Astronomy and Computing, that offers recipes in Python for running data parallel processing on multicore machines. Such machines offer an alternative to grids, clouds and clusters for many tasks, and the authors give examples based on commonly used astronomy toolkits.

The paper restricts itself to the use of CPython’s native  multiprocessing module, for two reasons: much astronomical software is written in it, and it places sufficiently strong restrictions on managing threads launched by the OS that it can make parallel jobs run slower than serial jobs (not so for other flavors of Python, though, such as PyPy and Jython). The authors also chose to study data parallel applications, which are common in astronomy, rather than task parallel applications. The heart of the paper is a comparison of three approaches to multiprocessing in Python, with sample code snippets for each:

  • Pool/Map, which spawns a pool of worker processes and returns a list of results;
  • Process/Queue, which supports multiple arguments as input to a function through the process class; and
  • Parallel Python, an open source cross-platform module (distinct from the multiprocessing module) that offers dynamic computation resource allocation as well as dynamic load balancing at runtime.

The study ran benchmarks on three quad-core machines -  a homebuilt one with an AMD processor, a Dell Studio XPS, and and an iMac for three use cases, all embarrassingly parallel, as described below. These examples all use modules from widely used astronomy toolkits such as IRAF and DAOPHOT.

Coordinate Transformation of CCD Pixel Data to Sky Coordinates for HST Images.

The performance – speed-up vs. number of processes, is shown below:

The principal conclusions are:

  • Best performance was achieved when the number of processes was equal to the number of physical cores on the machine.
  • The Intel Core i7 based machine showed the best speedup because it uses use hyperthreading technology (but bottlenecks such as I/O restrict performance gains).
  • The iMac (iCore i5) showed the poorest performance, most likely because performance optimization technologies used in the other tow machines are not implemented here.

Completeness Test using a parallelized Monte Carlo routine operating on an image of M17 that included artificial stars.

The figure below summarizes performance:

  • As before, maximum speedup is achieved when the number of processes is equal to the number of physical cores.
  • After four processes, speedup flattens out for the AMD and Core i5 processors whereas it increases for the Core i7 machine (although not as steeply as from 1 to 4 processes).

Parallel Sub-Sampled Deconvolution with a spatially varying point spread function (PSF).

Performance is roughly the same as in the previous example:

Altogether, astronomers can take advantage of existing astronomy tools and run them in parallel on their multicore machines. While performance does vary across platforms, even the poorest performer gives reasonably good speed-up. You can get further performance enhancements  by using a load balancer or a scheduler. The paper investigates two types – static schedulers divide equal chunks of data on each node, and guided schedulers subdivide data into small chunks and then distribute them across nodes. The figure below summarizes the performance of each:


Source: http://astrocompute.wordpress.com/2013/08/16/parallel-astronomical-data-processing-with-python-recipes-for-multicore-machines/


Before It’s News® is a community of individuals who report on what’s going on around them, from all around the world.

Anyone can join.
Anyone can contribute.
Anyone can become informed about their world.

"United We Stand" Click Here To Create Your Personal Citizen Journalist Account Today, Be Sure To Invite Your Friends.

Please Help Support BeforeitsNews by trying our Natural Health Products below!


Order by Phone at 888-809-8385 or online at https://mitocopper.com M - F 9am to 5pm EST

Order by Phone at 866-388-7003 or online at https://www.herbanomic.com M - F 9am to 5pm EST

Order by Phone at 866-388-7003 or online at https://www.herbanomics.com M - F 9am to 5pm EST


Humic & Fulvic Trace Minerals Complex - Nature's most important supplement! Vivid Dreams again!

HNEX HydroNano EXtracellular Water - Improve immune system health and reduce inflammation.

Ultimate Clinical Potency Curcumin - Natural pain relief, reduce inflammation and so much more.

MitoCopper - Bioavailable Copper destroys pathogens and gives you more energy. (See Blood Video)

Oxy Powder - Natural Colon Cleanser!  Cleans out toxic buildup with oxygen!

Nascent Iodine - Promotes detoxification, mental focus and thyroid health.

Smart Meter Cover -  Reduces Smart Meter radiation by 96%! (See Video).

Report abuse

    Comments

    Your Comments
    Question   Razz  Sad   Evil  Exclaim  Smile  Redface  Biggrin  Surprised  Eek   Confused   Cool  LOL   Mad   Twisted  Rolleyes   Wink  Idea  Arrow  Neutral  Cry   Mr. Green

    MOST RECENT
    Load more ...

    SignUp

    Login

    Newsletter

    Email this story
    Email this story

    If you really want to ban this commenter, please write down the reason:

    If you really want to disable all recommended stories, click on OK button. After that, you will be redirect to your options page.