# Spatial Allocator Tool Seg fault with CODE: 820

**URL:** <https://forum.cmascenter.org/t/spatial-allocator-tool-seg-fault-with-code-820/655>\
**Category:** Spatial Allocator\
**Created:** [May 8, 2019, 3:16pm UTC](https://forum.cmascenter.org/t/spatial-allocator-tool-seg-fault-with-code-820/655 "2019-05-08T15:16:25Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![amcvey\_AER](https://avatars.discourse-cdn.com/v4/letter/a/7feea3/32.png) [@amcvey\_AER](https://forum.cmascenter.org/u/amcvey_AER)\
**Post date:** [May 8, 2019, 3:16pm UTC](https://forum.cmascenter.org/t/spatial-allocator-tool-seg-fault-with-code-820/655/1 "2019-05-08T15:16:25Z")

</div>

I’ve been using the spatial allocator tool v4.3.1. I’ve gotten all surrogates to work except for the US Ports Code: 820. I keep getting a segment fault. I’m running the tool on the cloud throwing as much as 72 GB of RAM at it. I’ve made sure the shapefile\_catalog and surrogate\_specification files are accurate with path/file/field names. I’ve run all the pre-requisite codes successfully (800, 807, and 350), but nothing seems to work. I’m using the Ports\_081412\_NEI2011\_NOx\_WRF.shp from an updated dataset. I’ve tried using the newer version (4.3.2) but got the same result.

---

<div class="post-metadata">

**Author:** ![dyang](https://avatars.discourse-cdn.com/v4/letter/d/dbc845/32.png) [@dyang](https://forum.cmascenter.org/u/dyang)\
**Post date:** [May 8, 2019, 4:04pm UTC](https://forum.cmascenter.org/t/spatial-allocator-tool-seg-fault-with-code-820/655/2 "2019-05-08T16:04:27Z")

</div>

Looks like you are running 2011 surrogates. Make sure that your data shapefile is correct. For 2011, the data shape file is cty\_pophu2k\_revised.  
#SRGDESC=820,Ports NEI2011 NOx

# 

#SURROGATE REGION = USA  
#SURROGATE CODE = 820  
#SURROGATE NAME = Ports NEI2011 NOx  
#DATA SHAPEFILE = cty\_pophu2k\_revised  
#DATA ATTRIBUTE = FIPSSTCO  
#WEIGHT SHAPEFILE = Ports\_081412\_NEI2011\_NOx\_WRF  
#WEIGHT ATTRIBUTE = ann\_value

For 2014 surrogates:  
#SRGDESC=820,Ports NEI2014 Activity

# 

#SURROGATE REGION = USA  
#SURROGATE CODE = 820  
#SURROGATE NAME = Ports NEI2014 Activity  
#DATA SHAPEFILE = NTAD\_2014\_County\_Pol  
#DATA ATTRIBUTE = CTFIPS  
#WEIGHT SHAPEFILE = Ports\_2014NEI  
#WEIGHT ATTRIBUTE = ACTIVITYKW  
#WEIGHT FUNCTION =  
#FILTER FUNCTION =

---

<div class="post-metadata">

**Author:** ![amcvey\_AER](https://avatars.discourse-cdn.com/v4/letter/a/7feea3/32.png) [@amcvey\_AER](https://forum.cmascenter.org/u/amcvey_AER)\
**Post date:** [May 9, 2019, 1:15pm UTC](https://forum.cmascenter.org/t/spatial-allocator-tool-seg-fault-with-code-820/655/3 "2019-05-09T13:15:47Z")

</div>

Yes, I’m using 2011 surrogates. I couldn’t find any updates files. Those parameters listed are what I have, and it’s not working.

---

<div class="post-metadata">

**Author:** ![amcvey\_AER](https://avatars.discourse-cdn.com/v4/letter/a/7feea3/32.png) [@amcvey\_AER](https://forum.cmascenter.org/u/amcvey_AER)\
**Post date:** [May 14, 2019, 6:07pm UTC](https://forum.cmascenter.org/t/spatial-allocator-tool-seg-fault-with-code-820/655/4 "2019-05-14T18:07:24Z")

</div>

Do you have any other suggestions as for why it’s not working? It seemed earlier version port files were points not polygons. Would this make a difference?

---

<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:** [May 15, 2019, 12:50pm UTC](https://forum.cmascenter.org/t/spatial-allocator-tool-seg-fault-with-code-820/655/5 "2019-05-15T12:50:22Z")

</div>

How much “scratch variable space” will it take with polygons? Could this be the issue:  
[https://www.cmascenter.org/ioapi/documentation/all\_versions/html/AVAIL.html#medium](https://www.cmascenter.org/ioapi/documentation/all_versions/html/AVAIL.html#medium)

---

<div class="post-metadata">

**Author:** ![amcvey\_AER](https://avatars.discourse-cdn.com/v4/letter/a/7feea3/32.png) [@amcvey\_AER](https://forum.cmascenter.org/u/amcvey_AER)\
**Post date:** [May 22, 2019, 1:32pm UTC](https://forum.cmascenter.org/t/spatial-allocator-tool-seg-fault-with-code-820/655/6 "2019-05-22T13:32:53Z")

</div>

Many other surrogates are polygons and much larger files that seem to work fine. I’ll try to increase scratch space just to make sure. Thank you.
