# I/O API Updates

**URL:** <https://forum.cmascenter.org/t/i-o-api-updates/5737>\
**Category:** m3tools\
**Created:** [April 15, 2025, 1:45pm UTC](https://forum.cmascenter.org/t/i-o-api-updates/5737 "2025-04-15T13:45:39Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![cjcoats](https://avatars.discourse-cdn.com/v4/letter/c/ac8455/32.png) [@cjcoats](https://forum.cmascenter.org/u/cjcoats)\
**Post date:** [April 15, 2025, 1:45pm UTC](https://forum.cmascenter.org/t/i-o-api-updates/5737/1 "2025-04-15T13:45:39Z")

</div>

The currently authoritative site for the I/O API is on GitHub:

- For source code and downloads: [https://github.com/cjcoats/ioapi-3.2](https://github.com/cjcoats/ioapi-3.2)
- For documentation: [https://cjcoats.github.io/ioapi/AA.htm](https://cjcoats.github.io/ioapi/AA.htm)
- For download `git clone https://github.com/cjcoats/ioapi-3.2`

The CMAS web site is more than a year out-of-date; I do not have the  
access to update it.

As of January 2025, support was added for GNU Version 10 (`gfort10`) or later, AMD Optimizing Compiler Collection (_aoccflang_), LLVM (_llvmflang_), Oracle (_of95_), nVidia (_nvfort_), and Intel OneAPI (_ifx_) compilers, using the following Makeinclude.${BIN} files:

```
Makeinclude.Linux2_x86_64gfort10
Makeinclude.Linux2_x86_64gfort10mpi
Makeinclude.Linux2_x86_64gfort10dbg
Makeinclude.Linux2_x86_64gfort10_mediumdbg
Makeinclude.Linux2_x86_64gfort10_medium
Makeinclude.Linux2_x86_64aoccflangdbg
Makeinclude.Linux2_x86_64aoccflang_medium
Makeinclude.Linux2_x86_64aoccflang
Makeinclude.Linux2_x86_64llvmflang
Makeinclude.Linux2_x86_64llvmflangdbg
Makeinclude.Linux2_x86_64of95mpi
Makeinclude.Linux2_x86_64of95dbg
Makeinclude.Linux2_x86_64of95
Makeinclude.Linux2_x86_64nvfortmpi
Makeinclude.Linux2_x86_64nvfortdbg
Makeinclude.Linux2_x86_64nvfort_mediumdbg
Makeinclude.Linux2_x86_64nvfort_medium
Makeinclude.Linux2_x86_64nvfort
Makeinclude.Linux2_x86_64ifxmpidbg
Makeinclude.Linux2_x86_64ifxmpi
Makeinclude.Linux2_x86_64ifxdbg
Makeinclude.Linux2_x86_64ifx_mediumdbg
Makeinclude.Linux2_x86_64ifx_medium
Makeinclude.Linux2_x86_64ifx_365
Makeinclude.Linux2_x86_64ifx_360
Makeinclude.Linux2_x86_64ifx

```

I/O API initialization routine `INIT3()` now reports its the full _\<major version\>.\<minor version\>.\<release number\>_ I/O API version to the log, e.g.,

```
Version 3.2.74 with PARMS3.EXT/PARAMETER::MXVARS3=2048

```

**I/O API-4.0** is the new (currently beta) version with all the source code  
converted to “free” (.f90) Standard conforming source-code format.  
This was aided by Willem Vermin’s findent utility: see [https://gitlab.com/wvermin/findent](https://gitlab.com/wvermin/findent). Except for the source-code format, this version is completely upwards-compatible with I/O API-3.2. Minor bug-fixes were made to various prompts and error-messages but there are no usage nor interface changes.

Note that this version should not be installed “on top of” previous  
versions, because of name-collisions between older .f source files and  
their newer .f90 counterparts, and the resulting make problems that  
causes. To download I/O API version 4.0

```
git clone https://github.com/cjcoats/ioapi-3.2 -b ioapi-4.0 ioapi-4.0

```

and follow the usual instructions for building the I/O API and _M3Tools_ [https://cjcoats.github.io/ioapi/AVAIL.html#build](https://cjcoats.github.io/ioapi/AVAIL.html#build)

_M3Tools_ program _ **m3cple** _ has a new environment-variable option `SCALEFAC` for emissions interpolation (necessary because SMOKE gridded emissions data uses non-interpolatable, non-MKS units of the form mass per unit time **per grid-cell** , and one must re-scale the data by the ratio of the output cell-area to the input cell-area).

**New /O API-4.0 Fortran-90`MODULE MODGISIO`** (see [https://cjcoats.github.io/ioapi/MODGISIO.html](https://cjcoats.github.io/ioapi/MODGISIO.html))  
This `MODULE` provides routines for reading and writing various GIS-format files: ASCII formatted `ARC` and `ASC`, and binary (32-bit `REAL`) `GRIDFLOAT` and (8-bit `INTEGER`) `BIL1`, (16-bit) `BIL2`, and (32-bit) `BIL4` GIS-style files, with on-the-fly transpose from GIS scan-line row-order to normal-model bottom-to-top row-order, with optional on-the-fly gzip compatible compression or de-compression. These routines reference the files by logical name, following the usual I/O API conventions.

These formats are frequently used for “foundation data” for modeling, like NLCD land cover and NHD terrain elevation; note that this data is typically gridded on an Albers Equal Area map projection (not the Lambert Conformal Conic frequently used for air quality modeling).

**New I/O API-4.0 _M3Tools_ programs** are the following:

_ **gistogis** _ (see [https://cjcoats.github.io/ioapi/GISTOGIS.html](https://cjcoats.github.io/ioapi/GISTOGIS.html)):  
convert among various formats for “raster” (GRIDDED) GIS-style files.  
See also GDAL program [https://gdal.org/en/stable/programs/gdal\_translate.html](https://gdal.org/en/stable/programs/gdal_translate.html)

_ **gistom3** _ (see [https://cjcoats.github.io/ioapi/GISTOM3.html](https://cjcoats.github.io/ioapi/GISTOM3.html)):  
convert various formats for “raster” (GRIDDED) GIS-style files to GRDDED3 I/O API files.

_ **m3togis** _ (see [https://cjcoats.github.io/ioapi/M3TOGIS.html](https://cjcoats.github.io/ioapi/M3TOGIS.html)):  
convert GRDDED3 I/O API files to various “raster” GIS-style formats.

_ **gisplot** _ (see [https://cjcoats.github.io/ioapi/GISPLOT.html](https://cjcoats.github.io/ioapi/GISPLOT.html)):  
create GIF, JPEG, or PNG tile-plots from various formats of GRIDDED GIS-style files. Supports all of the I/O API map projection types; see [https://cjcoats.github.io/ioapi/GRIDS.html#horiz](https://cjcoats.github.io/ioapi/GRIDS.html#horiz).

_ **m3plot** _ (see [https://cjcoats.github.io/ioapi/M3PLOT.html](https://cjcoats.github.io/ioapi/M3PLOT.html)):  
create GIF, JPEG, or PNG tile-plots with optional contour, gridded vector, scalar-observation, and vector-observation overlays, from GRIDDED I/O API files.  
It is designed to offer high performance production graphics for potentially very large (much larger than RAM; in one past example, 1.2 TB) data sets.  
Unlike _VERDI_ or _PAVE_, _m3plot_ always generates images with the correct aspect ratio, without the distortion of stretching in the horizontal or vertical, and supports all of the I/O API map projection types.
