localMapFiles.py - Map Background Shapefile Naming
File
Overrides
January 18, 2006
Organization
Overview
localMapFiles.py Format
Adding a New Map Background
Updating a map shapefile
Placement of the localMapFiles.py file
Updating Map Shapefiles
Overview
The localMapFiles.py file is used for overriding the defined shapefile
names in the MapFiles.py file. It is
the primary mechansism for reconfiguring the map backgrounds when
updated
shapefiles are installed. Explicit shapefile names should be
defined in the localMapFiles.py file and should be equated to a
mnemonic, e.g., CountyMapName, that is used in Maps.py and localMaps.py.
See the server
configuration overview for information on how to make changes that
are supported to the map backgrounds.
NOTE: Starting with software releases in
January 2006, GFESuite is installed with separate GFE CORE and Map
Shapefile components. For AWIPS releases, the map shapefile
component will not normally be provided. WFOs will be
responsible for downloading from NOAA1 their own set of shapefiles, and
defining them through localMapFiles.py. If the map
configuration is not correct during the installation time, then the
install will fail. Even though the GFE CORE and Map
Shapefile components will not both be delivered for AWIPS, the
etc/BASE/MapFiles.py will still point to the Map Shapefile set of
shapefiles. This makes it imperative for sites to have their own
localMapFiles.py to point to their inventory of maps.
localMaps.py Format
Example localMapFiles.py
configuration
file
Adding a New Map Background
A new map background can be added through localMaps.py,
but it is highly recommended that you use the localMapFiles.py method
to define
the shapefile name. This will allow you to update the shapefile
at
a later time and only have to change the localMapFiles.py file.
Here is an example of adding a shapefile for time zone. The
variable
name, by convention, should include the "MapName" as part of the
variable:
TimeZoneMapName = 'tz_13se02'
Updating a map Shapefile
Updating the definition of the map shapefile when a shapefile is
updated
is very simple, just repeat the definition that is contained in
MapFiles.py
and change the filename of the map. In this example, the zone
shapefile
is being updated to a September 13, 2002 version:
ZoneMapName = 'z_13sep02'
Placement of the localMapFiles.py file
The localMapFiles.py file should always be placed in the ***/etc/SITE
directory
as explained here.
Updating Map Shapefiles
The procedure to update map shapefiles is outlined below:
-
Download the new shapefiles from the AWIPS Map GIS catalog.
- If you are on AWIPS, then you should sftp to the NOAA1 server using the appropriate (NWS-supplied) username and password. Then "cd" to pub/maps
where the shapefiles are located. Then download the desired
shapefiles.
-
unzip them into a directory, or uncompress them as necessary. If
they have a *.Z extension, you can use the uncompress command. If
they have a *.gz extension, then you use the gzip -d
command.
When you are finished, verify that you have a *.shp, *.shx, and *.dbf
file.
-
gzip -9 each portion of the map (.shp, .shx, .dbf) using the
command
gzip -9 *.shp *.shx *.dbf
-
Place the updated shapefiles into the release/data/maps
directory,
where release is the software installation directory, nominally
/awips/GFESuite/primary for AWIPS installations (thus your map
shapefiles are put
into /awips/GFESuite/primary/data/maps).
-
Modify your localMapFiles.py file and redefine the reference name, such
as CountyMapName, to point to the new shapefile.
-
Restart the ifpServer.