Creating a shovel test grid for Cultural Resource Management

5407
26
08-05-2017 09:39 AM
EricMai
Emerging Contributor

I can't find a good amount of information on creating a grid within a set boundary and using the intersection points as points for data.  I work in the archaeology field and we dig shovel tests on a 50 foot grid.  I am trying to figure out a way of creating a grid before entering the field, where each intersection point already has a distinct GPS point, and data can be entered via a database app in reference to each one of these points.  Can anyone help me through this process?

I understand the fishnet tool, but not sure how to use the intersections and create points for each, and additional attributes to be filled in later.  And how could I label each point based off of that grid system of x, y?  For example, transect 1, shovel test 1.  

0 Kudos
26 Replies
EricMai
Emerging Contributor

That may make things easier.  But wondering how the grid would be numbered then?  Or if there is a way to choose on which side of the baseline the grid is drawn?

0 Kudos
EricMai
Emerging Contributor

Hi Brian.

Yes, I'm unfamiliar with GitHub.  Can you explain how I would load these tools to arcmap?  I've added the toolbox but there is some kind of error when I run the tool.  

Executing: ShovelTest_Tool "C:\Users\ericv\Documents\ArcGIS\Web Maps\Mechanicsville, Virginia\Features.gdb\ShovelTestBaseline" "C:\Users\ericv\Documents\ArcGIS\Web Maps\Mechanicsville, Virginia\Features.gdb\ShovelTestArea" "C:\Users\ericv\Documents\ArcGIS\Web Maps\Mechanicsville, Virginia\Features.gdb" grid_poly grid_point 50 50
Start Time: Sun Aug 13 10:12:13 2017
Running script ShovelTest_Tool...
Parameter: baseline = C:\Users\ericv\Documents\ArcGIS\Web Maps\Mechanicsville, Virginia\Features.gdb\ShovelTestBaseline
Parameter: template = C:\Users\ericv\Documents\ArcGIS\Web Maps\Mechanicsville, Virginia\Features.gdb\ShovelTestArea
Parameter: output_workspace = C:\Users\ericv\Documents\ArcGIS\Web Maps\Mechanicsville, Virginia\Features.gdb
Parameter: output_polygon_features = grid_poly
Parameter: output_point_features = grid_point
Parameter: grid_cell_width = 50
Parameter: grid_cell_height = 50
baseline origin: -8609652,4521015 end: -8609420,4521206
Delete failed on "C:\Users\ericv\Documents\ArcGIS\Web Maps\Mechanicsville, Virginia\Features.gdb\grid_point". ERROR 000464: Cannot get exclusive schema lock.  Either being edited or in use by another application.
Failed to execute (Delete).
Delete failed on "C:\Users\ericv\Documents\ArcGIS\Web Maps\Mechanicsville, Virginia\Features.gdb\grid_poly". ERROR 000464: Cannot get exclusive schema lock.  Either being edited or in use by another application.
Failed to execute (Delete).
Grid size will be (4 x 7)
Traceback (most recent call last):
  File "C:\Users\ericv\Documents\ArcGIS\Web Maps\Mechanicsville, Virginia\shoveltest-master\shoveltesttool.py", line 127, in execute
    makegrid(baseline_fc, template_fc, workspace, output_poly, output_point, width, height)
  File "C:\Users\ericv\Documents\ArcGIS\Web Maps\Mechanicsville, Virginia\shoveltest-master\shoveltest.py", line 153, in makegrid
    cursor_pt.insertRow([p1, label])
RuntimeError: Cannot find field 'label'
Failed to execute (ShovelTest_Tool).
Failed at Sun Aug 13 10:12:13 2017 (Elapsed Time: 0.41 seconds)
0 Kudos
XanderBakker
Esri Esteemed Contributor

This is what can happen when the result from a previous run are still in the TOC of ArcMap. ArcMap will probably create an exclusive lock on those featureclasses and fail to delete them. So, remove

C:\Users\ericv\Documents\ArcGIS\Web Maps\Mechanicsville, Virginia\Features.gdb\grid_point

and

C:\Users\ericv\Documents\ArcGIS\Web Maps\Mechanicsville, Virginia\Features.gdb\grid_poly

...and try again.

Another question:

Do you have a folder called "Mechanicsville, Virginia" with a comma and a space"? If so, it is better to avoid using large names, spaces and special characters in folder names.

BrianWilson
Frequent Contributor

If you search this forum for "schema lock" you will find hundreds of messages.

In my experiences, as with many things in ArcMap and ArcCatalog, quitting and restarting is the most reliable (and time consuming) way to deal with schema locks. There does not seem to be any consistent pattern to it that I have ever seen.

I find that if I try to keep ArcMap open and to run the tools in ArcCatalog it's worst - I have to close ArcMap to clear the lock before I can work in ArcCatalog. If the feature class or sometimes just the geodatabase is open in ArcMap it can get locked. I would think that it would only create locks when I start editing but that's not always true.

I have the best luck when working exclusively in ArcMap but even that's often problematic.

0 Kudos
BrianWilson
Frequent Contributor

I will try to write up something on github for GIS people soon.

0 Kudos
BrianWilson
Frequent Contributor

I updated the README in the github project, and added sample MXD and GDB.

Also I added a few words on github but my intention is to write a blog post about using it, perhaps once ESRI fixes the codesharing.arcgis.com support for github.

0 Kudos
mkatuna
New Contributor

Hi Brian,

Found this thread many years after you wrote it, but I'd love to know the code/workflow for how made your "shovel test" grid. I work in an archaeological lab and we're trying to do a similar thing.

0 Kudos