New answers tagged

1

No need to export to single bands, there are a couple of ways of adding individual bands directly from the original multiband dataset: double click on the raster dataset in the file dialog. click on the + symbol next to the raster name in the Catalog window in ArcMap (or ArcCatalog). If you can't see any + symbols in the Catalog window tree, click the ...


0

I modified the original code a little bit to avoid some confusion when defining the RasterCenter function, since the argument named raster used in def RasterCenter(raster) and the variable named raster used in raster = arcpy.Raster(raster) within the function can cause confusion and make things not working properly. I modified parsing the path when reading ...


0

In this case, anyway, I decided that I need to calculate all fields for each of the two feature classes individually, before they are merged. Then, when merging the two, I will use field mapping if necessary (although, if the fields have the same name, they will be merged into one field even without field mapping, as I've discovered).


0

If you're comfortable with Python, you can write a script against the REST API to update the service URL in the web map and include it at the end of your model. The basic workflow in this script would be to generate an authorization token, retrieve the current data for the web map, update the url, then POST the modified data back to the web map URI in ...


0

If you don't want to use a code block, you can go for 'False' if !String! is None else 'true'


1

Edit: I checked the help for the calculate Value tool. It says: "Variables created in ModelBuilder can be used by this tool, but variables desired for use in the expression parameter cannot be connected to the Calculate Value tool. To use them in the expression, enclose the variable name in percent signs (%). For example, if you want to divide a variable ...


0

Looks like you are missing a colon at the end of the if statement. See this page for more info: http://pro.arcgis.com/en/pro-app/tool-reference/modelbuilder-toolbox/calculate-value.htm


1

ESRI Documentation says to set the toolbox to read-only in Windows. (Link is to 10.3 documentation but I have to believe the same workflow applies for 10.2)


0

This problem often occurs here, what "helps" in most cases are these steps: Click on: Validate entire model Go to "Diagram Properties" -> "Symbology" and switch to Style 2. Click on "Accept" and "OK" - Sometimes repeat with switching to Style 1.


2

Let's take a look at it in Excel: | 1 | A | B | | 2 | ABCDEFGHIJKLMNOPQRSTUVWXYZ | =RIGHT(LEFT(A1,20),13) | Which will display HIJKLMNOPQRST In python then, we need to slice the first 20 characters, and from that the last 13. (Note the use of negative slicing, which is needed to start from the end of the ...


1

If you want to preserve the names of your rasters, consider saving your shapefile as a feature class in a geodatabase . See here for feature class field name limits.


0

Thanks. And after hours of more online reading, I found the answer. The destination point was outside of the spatial extent of the origin points. Once I adjusted that, it all ran fine. Here's a link to the post that contained the solution I used: https://geonet.esri.com/thread/77736#post315923


0

As commented by @KHibma: I can confirm, theres no option to modify this behavior. Thats how it works. In the new ArcGIS Pro app, the dialogues will behave a bit differently than this.


1

I've come across similar issues with mass automation generating thousands of files. An issue is that you are filling a folder with thousands of datasets which all have one feature, this would have an impact. I would consider either writing them to a file geodatabase or combine them in some manner. You could turn your model into a sub-model and pass out a ...


0

To do this I would use Summary Statistics to get the minimum value into a one row table, and then use the Get Field Value (Model Only tool) to read that row and field. A very similar technique is described in Examples of using Model Only tools in ModelBuilder.


2

Your model appears to be correct and you are using the %value% correctly, that is the ID of what your are calling your station number. The error message says you have no spatial reference, i.e. either your DEM or Polygon dataset are missing a defined coordinate system. So you need to make sure they have that set. Look into the Define Projection tool. It ...


2

I would use Long (derived). This will be automatically stored in your field as a short integer if the absolute value is small enough (< 32767), but this will be an issue when its larger, so make sure that your model handles the case when the user enters a value that will yield an "out of range" output.


0

I think you should focus on the first error message first. It appears that comes from the Intersect tool element which is trying to use a variable named Name. Your model does not contain a variable named Name.


1

Create buffer of any radius around your points and run this expression, using field calculator on field Shape, parser - Python: def makeRectangle(shp,H,W): hH=H/2;hW=W/2 pcX=shp.centroid.X pcY=shp.centroid.Y LL=arcpy.Point(pcX-hW,pcY-hH) UL=arcpy.Point(pcX-hW,pcY+hH) UR=arcpy.Point(pcX+hW,pcY+hH) LR=arcpy.Point(pcX+hW,pcY-hH) rectangle=arcpy....


1

I can think of a few things that might help you here. First of all, you can initially work with a file geodatabase instead of shapefiles, if that helps you to get around the 2GB limit. If your output needs to be shapefile then that may not help too much but perhaps it gets you to the next step in your workflow. Next if you are trying to delete land cover ...


2

This can be easily done in the same calculate tool so no need to add another tool. If you think about it what does a replace function return? A string! Which you can put through another function! Here is a silly example were ww would be your %Value% ww = "Wwww 23'rrr" ww.replace(" ","").replace("'","_") returns 'Wwww23_rrr'


1

You can judge the existence of the result dataset and only when the dataset does not exist for processing. You can use FileExistenceChecker and NoFeaturesTester, they can from the FME HUB for download. Will you want to undertake the processing of connected to NoFeatruesTester NOINPUT port will be able to achieve your goal.


3

Have a look at inline model variable substitution Something like Parcels_10m_Rail_%fc_name% is what you want. fc_name is the variable that stores the names of your restrictions feature classes. Parse Path can be used to retrieve feature class name.


0

I've solved the problem. The Get Value string variable refers to attributes which begin with '0'. I put some text before these attributes and edited the input file names and the model works perfectly now.



Top 50 recent answers are included