Thursday, March 24, 2005

Designing a better (Linux) desktop

Seth at designfu is working on improving x-windows for Linux. There is other good stuff there as well. The wobbly windows are great...

Wednesday, March 23, 2005

Parameter space exploration in ROMS

Often, I find that I want to run roms over some set of parameters. The best way to do this is to make critical parameters dependent on the USER parameters in the roms.in file. I have written a program in python which does just this, automatically.

Monday, March 21, 2005

Changed NetCDF fixed dimension to record dimension

Sometimes it is neccissary to change a fixed length dimension to a record dimension (an UNLIMITED) dimension. There is no straightforward way to do this, unfortunately, but I have found this relatively simple hack to be useful:

First make a new NetCDF file that contains only one record dimension, the same name as the dimension you wish to change, say time. I do this in MATLAB like this

f = nc('rec_dim.nc','noclobber');
f('time') = 0;
close(f);


Now, simply append the information in the NetCDF file using ncks (part of the nco package), like this

ncks -A orig.nc rec_dim.nc


You can now delete orig.nc. (You could also overwrite the origional directly).

Wednesday, March 9, 2005

Geowall 3D visualization

Information on hardware and software required to set up a 3D visualization lab can be found at geowall.org.

Tuesday, March 8, 2005

MexCDF now at sourceforge

The invaluable MexCDF (MATLAB NetCDF interface) may now be found here [sourceforge]. I was having issues with the old MexCDF versions, where MATLAB was complaining about the subrutine "subs" also being a variable. I installed this package on my mac using the Mac OS X binary provided. This binary requires a few shared libraries in the /sw/lib directory -- i.e., from fink. You need to get the NetCDF and TIFF (wtf?) shared libraries. You also need to adjust the matlab path as:


addpath('/Users/rob/matlab/mexnc');
addpath('/Users/rob/matlab/snctools');
addpath('/Users/rob/matlab/netcdf_toolbox/netcdf');
addpath('/Users/rob/matlab/netcdf_toolbox/netcdf/ncutility');
addpath('/Users/rob/matlab/netcdf_toolbox/netcdf/nctype');


After I did this, everything seems to be working fine. You may want to add


ncquiet


to prevent your screen from filling up with "ncattinq: ncid 12; varid 0; attname "_FillValue": Attribute not found" and the like.

Friday, March 4, 2005

Compiling NetCDF on Mac OS X

Based on this script, I compiled NetCDF 3.6.0 on my Mac, using xlf.

export CC=/usr/bin/cc
export CPPFLAGS="-O -DNDEBUG -DIBMR2Fortran"
export CFLAGS="-O"
export CXX=/usr/bin/c++
export CXXFLAGS="-O"


export FC=xlf
export F77=xlf
export F90=xlf90
export FFLAGS="-O5 -qtune=auto -qarch=auto -qhot -qinitauto -qsave"
export F90FLAGS=-qsuffix=f=f90:cpp=F90

./configure - -prefix=/usr/local

make
make test
make install


This configuration also compiled udunits.

I also, finally, got nco to work using

./configure - -disable-regex - -disable-shared

It was also recommended to use the latest version of bison, but it seems that the version that ships with the latest Apple developer tools was fine.

del.icio.us

The bookmark site to end all bookmark sites: del.icio.us. You can save your own links, and see everybody elses as well.

Thursday, March 3, 2005

Direct gigabit connection from mac to cluster

Using the last hint to get my mac recognized by the cluster (I run a wire from a second NIC card to the switch), I tested by throughput using NetPIPE. I used netpipe to compare the gigabit connection to the normal university connection, and this was the result:



Both seem pretty close to the theoretical limits for large packet sizes, so I can expect to get about a ten-fold increase in the speed of my network mounted disks over the private, gigabit network.

External devices on Rocks

I inserted a new appliance into the set of Rocks nodes by hacking the mysql database containing the node information. This was started with

[root@frontend-0 root]# mysql -u apache cluster

then I added a database entry (for dbreport to use) with:

mysql> insert into nodes (MAC, Name, Membership, CPUs, Rack, Rank, IP)
-> values ("xx:xx:xx:xx:xx", "external-0-0", 4, 0, 0, 0, "10.255.255.1");

You can update the database entry with the command:

mysql> update nodes set IP="10.255.255.1" where Name="external-0-0";

(since, at first, I put in the wrong IP address).