IDL


I use HDF5 quite a bit and have developed some utility routines, mg_h5_dump (docs, code) and mg_h5_getdata (docs, code), that are quite useful for me.

mg_h5_dump gives similar output to the command line utility h5dump with -A set. mg_h5_getdata allows slices of data to be extracted using IDL's normal indexing rules.

For example,

IDL> f = filepath('hdf5_test.h5', subdir=['examples', 'data'])
IDL> data = mg_h5_getdata(f, '/arrays/3D int array', $
IDL>                      bounds='3, 5:*:2, 0:49:3')

For more examples, run the main-level programs at the end of the routines:

IDL> .run mg_h5_getdata
IDL> .run mg_h5_dump

Mort Canty, author of Image Analysis, Classification and Change Detection in Remote Sensing: With Algorithms for ENVI/IDL, is using GPULib and has started blogging his comments on it. So far, so good!

Full disclosure: I work for Tech-X Corporation and worked on the IDL bindings and examples for GPULib.

Thumbnail of DocBook output I have the framework in place to have IDLdoc produce output besides HTML. This has been a long process beginning in IDLdoc 2.0 when I switched to using templates instead of embedding the HTML code in the IDL code. I have started by writing a set of templates for DocBook output, but intend to write a LaTeX set as well.

Here's an example PDF of IDLdoc output for a library of routines for visualization I've been thinking about.

lic_thumb.png While producing some flow visualizations lately, I've found that smoothing a random texture gives less pixellated looking result than using a purely random texture. I added a texture keyword a while ago so that a common texture could be used for several LIC images, but now I've discovered that playing around with the texture a bit can be useful. I've been creating the texture with:

IDL> r = randomu(seed, xsize, ysize)
IDL> t = bytscl(smooth(r, 3, /edge_truncate))

Click on the thumbnail image to see the full image.

I just released IDLdoc 3.1 (see full release notes are below). As per this short blog post, IDLdoc is getting integrated into the IDL Workbench. This release adds some rst markup features that the IDL Workbench will use -- my favorite is to be able to link to images with:

.. image:: filename

IDLdoc will link to the image and also copy the image file into the output directory (if OUTPUT keyword to IDLDOC routine is used).

  1. Added ability to reference images in rst markup. IDLdoc will automatically copy referenced images into the output.
  2. In rst markup, illegal characters like < and > are automatically converted to character entities.
  3. Added `:Description:` tag for compatibility with IDL Workbench update.
  4. Changed default markup parser to rst when format parser is rst.
  5. Miscellaneous small bug fixes.

IDLdoc support will be added to the IDL Workbench in an update planned for June. This will add some really cool features for those who use IDLdoc and the Workbench:

  1. enhanced hover help on routines with an IDLdoc header
  2. content assistant on tag names when writing IDLdoc comments
  3. menu item and keyboard shortcut to insert an IDLdoc routine or file header (and preferences to define what tags you want inserted)

The Workbench will recognize comments in the rst format.

There will be an IDLdoc 3.1 release any day now to add some features necessary to support this and fix a couple bugs.

I have not been a big fan of the online help in the IDL 7.0 Workbench, but one feature I have been using regularly is the "Send us a comment on this topic" link at the bottom of every help page. Now I click it for every problem in the documentation I see. It doesn't have the same immediate effect that a Wiki would, but it has a similar feel when I get the response back that it's fixed and I will see it in the next version. Hopefully, others are doing the same (hint, hint).

In this recent IT Conversations interview, Jon Udell discusses topics from Greg Wilson's recent talk "High-Performance Computing Considered Dangerous". Wilson places a new emphasis on testing and usability over more power and speed.

The interview focused on the difficulties of learning techniques in High-Performance Computing and, in general, about the split between scientific computing and "commercial" software development. Tools have to improve because there is no more time in the science curriculum to teach science graduate students more about software engineering practices. In particular, I thought the comments about version control aiding in the reproducibility of computations were interesting (version control as a "software lab notebook"). He also mentions that tools like "Matlab, IDL, and Mathematica" are scoffed at by the HPC gurus, but are the tools that many scientists are using to solve their problems (he put Excel in a category of popularity above these). Our focus should be adding easy to use HPC techniques to these platforms.

David Fanning made some fixes to the Brewer color tables addressing the issues reported in the comments of the last update by Philippe Le Sage. The update includes the following:

  1. Fixing values in sequential and diverging color tables.
  2. Fixed up names of diverging color tables
  3. I also realized that it was unnecessary to include multiple versions of each of qualitative color table because the one with the most colors is a superset of the other versions.

See the last update for routines to access these color tables.

Thanks David and Philippe!

I just received a copy of IDL Primer by Ronn Kling. (Full disclousre: I received a free copy because Ronn used my Periodic Table of IDL Operators on the back cover.) It's a pocket sized “quick reference” that provides a quick introduction to the main functional areas of IDL: the IDL Environment (DE is covered, get Kling's Navigating the Workbench for coverage of the Workbench), syntax, array operations, program flow, 2D and 3D graphics, image processing, object graphics, file I/O, mapping, and animation. I have found it to be a quite handy reference, particularly the list of “Important Routines by Function” at the back (similar to the Functional List of IDL Routines in the online help).

« Previous PageNext Page »