[MITgcm-support] Matlab query ?

Martin Losch mlosch at awi-bremerhaven.de
Mon Jun 13 07:59:57 EDT 2005


Hi,
it's not a problem of disk space, but of RAM, you simply don't have  
enough core memory to run the matlab script mit_loadglobal (which  
wouldn't work for anything but the 90x4015 configuration anyway). The  
following line:
> [dummy, timesteps] = rdmds('D:\MITrun\uVeltave',NaN);
makes matlab read all files that are called uVeltave.*.data. For a 1x1  
deg resolution, each of these files is 360x160x15(?)=864000Words =  
6912000bytes = almost 7MB (hope I am right with this). Depending on how  
many output file you have, your RAM will overflow quickly.
In order to read the data, use rdmds with different options (you can  
specify the iteration number that you want to read or "Inf" for the  
last output) and use matlab visualization functions such as  
contour/contourf/pcolor to plot the data.
mit_loadglobal.m is meant to be an example of how to do that and also  
conveniently computes some diagnostics.  I have to admit that loading  
all the data is not very clever and works only, if your domain size is  
small (as in 90x40x15 = 432000byes < 0.5MB for one file such as  
uVeltave.0000000000.001.001.data)

Alternatively, you can use any other plotting software that you know  
how to use. The *.meta files contain information on the array size and  
the precision of your output (ieee big endian binary data), so that you  
should be able to load the data into the plotting tool of your choice.

Good luck,
Martin




On Jun 13, 2005, at 12:23 PM, Amitabh Mitra wrote:

>   
>  Dear sir,
>
>    I have run the global_ocean.90x40x15 experiment
>
>  for one year with a resolution of 1x1 for the region
>
>  80S to 80N.(Data file is Attached).I transferred all the output files
>
>  to my PC (in D:) which has free space of 1.37 GB in C: drive.
>
>  When I run the program mit_loadglobal.m in Matlab
>
>  an error message is displayed showing shortage of
>
>  memory space as shown below:
>   
> -----------------------------------------------------------------------
>  Warning: buoyancyRelation not found in D:\MITrun\data
>  assuming buoyancyRelation = OCEANIC
>  Reading 36 time levels: 5 10 15 20 25 30 35 40 45 50 55 60 65 70 75  
> 80 85 90 95 100 105 110 115 120 125 130 135 140 145 150 155 160 165  
> 170 175 180
>  ??? Out of memory. Type HELP MEMORY for your options.
>
>  Error in ==> C:\matlabR12\work\rdmds.m
>  On line 131  ==>  AA(r0(1):rN(1),r0(2):rN(2),r0(3):rN(3),iter)=A;
>
>  Error in ==> C:\matlabR12\work\mit_timesteps.m
>  On line 16  ==>    [dummy, timesteps] =  
> rdmds('D:\MITrun\uVeltave',NaN);
>
>    Error in ==> C:\matlabR12\work\mit_loadglobal.m
>  On line 31  ==> mit_timesteps
>
>  ----------------------------------------------------------------------
>  Also I am unable to install Matlab in SGI-Origin.
>
>  So how could I plot my output?
>
>  Thanking You,
>
>  With regards,
>
>  Amitabh Mitra
>
>
>
> <inbox.gif><data>_______________________________________________
> MITgcm-support mailing list
> MITgcm-support at mitgcm.org
> http://mitgcm.org/mailman/listinfo/mitgcm-support





More information about the MITgcm-support mailing list