FAQ

  • How to get started with GeoNet on Mac OS-X?

GeoNet is a cross platform MATLAB package. Please refer to the section How - to to get started on MAC OS-X.

  • How to get started with GeoNet on MS- Windows?

GeoNet is a cross platform MATLAB package. Please refer to the section How - to to get started on Windows.

  • How to add input data to GeoNet?

GeoNet requires a TIFF file as an input. A TIFF file can be prepared by using ArcGIS or Adobe Photoshop. Any other TIFF preparing

software can be used for this purpose. Upon successfully creating the TIFF file, the steps illustrated in the Customizing section can

be followed to add the input data to GeoNet.

  • How to change the defaults in GeoNet?

GeoNet uses global parameters to assign default values required to complete GeoNet processing. GeoNet only takes a

TIFF file as an input and performs a sequence of operations to produce a rich subset of figures and plots and Shapefiles of

the channel network and also write raster files.

All the default values are set and prepared inside the geonet_defaults.m and geonet_prepare.m files. In order to change or

overwrite default values, it is recommended that all the Parameters values be overwritten in the executable files. Parameters

belonging to the geonet_defaults.m file should be over written after the geonet_defaults function is called in the exec file. Similarly

parameters belonging to the geonet_prepare.m file should be over written after the geonet_prepare function is called in the exec file.

  • How to create a shortcut in MATLAB to run GeoNet?

A MATLAB shortcut is an easy way to run a group of MATLAB language statements that will be used regularly.

Although similar to a MATLAB script, MATLAB does not save it as a script. MATLAB maintains shortcut information in the

shortcut.xml file. You can create a MATLAB shortcut to run from the desktop start button, or from the shortcuts toolbar.

Please refer to this help document for more information

http://www.mathworks.com/help/techdoc/matlab_env/bq37azl-1.html#bq37azl-3

  1. Right click on the shortcuts toolbar and then select new shortcut.
  2. Complete the shortcut editor as shown in the figures below and click save:
  • How to compile MEX binaries on Linux?

Please follow the process below to compile mex files. We used Ubuntu 11.10 for the compilation ( It should be same process for any Linux installation).

Note: Ubuntu 10.10 used gcc-4.4 as system default gcc, and MATLAB was happy to compile MEX files using that version.

Since Ubuntu still supports the 4.4.x packages, installation with dependencies is as easy as APT:

Follow from step 1 if you don't have gcc installed , else start from step 2.

  1. $ sudo apt-get install gcc-4.4 g++-4.4 gfortran-4.4
  2. At the MATLAB command prompt, execute mex -setup and select either option 1 or 2 to ensure you have a MEX options file in your home directory: ~/.matlab/mexopts.sh
  3. Edit this file with your favorite text editor. I used: $ sudo gedit ~/.matlab/R2012a/mexopts.sh ( in the terminal)
  4. Replace ALL instances of CC='gcc' with CC='gcc-4.4'
  5. Replace ALL instances of CC='g++' with CC='g++-4.4'
  6. Replace -ansi with -std=c99, to allow use of C++ style // comments. And save and exit from mexopts.sh file
  7. Go to GeoNet2/mex in MATLAB and run compile_mex , this should be able to compile the mex files properly.
  8. Before running the shortcut, make sure you have set the Parameters.demDataFilePath and the Parameters.fileOutputPath properly in the *_exec.m file
  9. Run the Shortcut and MATLAB should be able to run the files properly.
  • How to compile MEX binaries on Windows when MATLAB can't find any supported compilers for mex setup?

If the above message is displayed while you are trying to compile the mex files as explained in the getting started guide with GeoNet 2.0, then the machine does not have a suitable compiler for building MEX files. There are two possible solutions to this error:

  1. Either use the pre-compiled MEX files for 64 bit processors available for downloads on the download page, or
  2. Download Microsoft Windows SDK for Windows 7 and .NET Framework 4 and install the SDK framework. This is a free Microsoft developer software tool kit and should be sufficient to compile the MEX files.

Upon successfully installing the above framework, you can now run the mex -setup command on MATLAB command window and should be able to see a compiler and select it for MEX files as shown below:

This should solve the issue with the mex compiler for you. In case you have any problem with compiling the MEX files, please reach out to the GeoNet team and we will be happy to help.

  • What are some of the limitations that users with older MATLAB versions face when using GeoNet 2.0?

Some of the limitations with using the function such as rng might be annoying to users with older versions of MATLAB (older than R2011). Here is a good site, where you might find the compatibility errors with MATLAB http://www.dynare.org/DynareWiki/MatlabVersionsCompatibility.

In case the rng function is not running in older MATLAB versions, simply comment out the line in the code and you should be able to complete the GeoNet script without any errors.