|
POST
|
If you want to save the entire Closest Facility Layer as a layer file, use SaveToLayerFile as Dan suggests. If you just want to save the output Closest Facility routes sublayer to a feature class, you will have to retrieve the sublayer. An example of retrieving and saving sublayers can be found in the last code sample on this page: Make OD Cost Matrix Layer—Help | ArcGIS Desktop The example is for OD Cost Matrix, but the same principles hold for Closest Facility. Essentially you have to grab the sublayer object and use that in CopyFeatures.
... View more
11-22-2017
09:45 PM
|
1
|
1
|
1592
|
|
POST
|
You mention python, but your screenshot shows Model Builder. I'll try to answer this question for both. In Model Builder, you can use that Solve Succeeded turquoise-colored bubble as a precondition for the next step in your workflow, I think. If it's false, it should just skip whatever comes next. In python, you can use try/except: try: arcpy.na.Solve(blah...) print("Solve succeeded.") except: print("Solve failed. Error messages:") print(arcpyGetMessages(2))
... View more
10-12-2017
02:38 PM
|
0
|
1
|
2100
|
|
POST
|
I think Origin-Destination Cost Matrix would be a better tool for this job. For 1), you can limit the number of destinations to find for each origin to 1, so that for each origin, it will effectively find the closest facility. For 2), you can set a cutoff (similar to service area breaks), and the distance or travel time between origins and destinations will only be calculated if it is less the cutoff. The output Lines of the OD Cost Matrix will contain one entry per origin-destination pair that was calculated, so you can just count the number of destinations found for each origin using some simple statistics on the table.
... View more
10-05-2017
11:18 AM
|
1
|
0
|
1281
|
|
POST
|
The trim settings are not currently accessible from the UI in Pro. You have two options: To create the Service Area layer, use the Make Service Area Analysis Layer geoprocessing tool. You can adjust the trim settings in the Output Geometry section of the tool dialog. Once the layer is created, though, you can't use the UI to adjust the settings again. For an existing layer, you can use the python window and NA solver properties to adjust the trim settings: # Get the current ArcGIS Pro project:
doc = arcpy.mp.ArcGISProject('current')
# Get the current map (note, if you have more than one map,
# you might need to change the index from 0 to something else)
mapObj = doc.listMaps()[0]
# Get the Service Area layer object (might need to change the string
# 'Service Area' to match the SA layer's actual name)
layerObj = mapObj.listLayers('Service Area')[0]
# Get the Service Area solver properties object
props = arcpy.na.GetSolverProperties(layerObj)
# Whether or not to trim polygons
props.trimPolygons = "TRIM_POLYS"
# Trim distance
props.trimDistance = "50 meters"
... View more
09-27-2017
08:32 AM
|
1
|
0
|
1610
|
|
POST
|
I sent you a private message. Not sure if you saw it.
... View more
09-18-2017
10:31 AM
|
0
|
1
|
3742
|
|
POST
|
Possibly you can't both set a default in the model AND make it a model parameter.
... View more
09-18-2017
10:30 AM
|
0
|
1
|
1864
|
|
POST
|
You need to specify a feature class for the Input Locations parameter before the field mapping control will populate. The available field mappings depend on the fields available in the Input Locations, so it can't pre-populate with any specific values. As long as Input Locations remains a model parameter, you are free to choose a different input feature class than the one you used to build the model, but you must use a dummy feature class to construct the model with the field mapping as you desire it. Then, when you run the model, the input feature class must either have the same fields as your dummy feature class (to ensure that the field mapping works), or you must make the field mapping parameter a model parameter so you can change it at the time you run the model.
... View more
09-18-2017
10:11 AM
|
0
|
3
|
1864
|
|
POST
|
Would you be willing to share a project package with us so we can try to figure out what's causing the slowness? Please include your network dataset and the layer(s) you're solving.
... View more
09-15-2017
11:29 AM
|
0
|
3
|
3742
|
|
POST
|
We made some changes in Pro 2.0 that significantly speed up the Solve operation. Please let us know how the performance compares after you upgrade to 2.0.
... View more
09-15-2017
11:11 AM
|
0
|
5
|
3742
|
|
POST
|
Hello, Rob. No, I don't believe ArcGIS has anything like that. The downloadable BetterBusBuffers tool might be the closest thing: http://www.arcgis.com/home/item.html?id=42e57c5ff9a0497f831f4fced087b9b0 That tool requires you public transit data to be in GTFS Format.
... View more
08-29-2017
08:28 AM
|
0
|
0
|
1769
|
|
POST
|
Are you sure that both the streets and the bike paths have vertices at the locations where they cross? If not, they won't connect, even with Any Vertex connectivity. You can add vertices at the points of intersection using the Integrate tool with a 0 xy tolerance. Make a back-up copy of your data first, just in case, because the tool modifies the original data.
... View more
08-23-2017
08:38 AM
|
2
|
0
|
3736
|
|
POST
|
Let's back up. Can you describe in words what you're trying to do?
... View more
08-17-2017
03:15 PM
|
0
|
1
|
2303
|
|
POST
|
Try something like this. def NetworkParticipating(network_participating):
if Edge.AttributeValueByName(network_participating)== 0:
return -1
return 0
Value = NetworkParticipating('!network_participating!') The problem with your attempt was that you were passing '!network_participating!' to the function but then immediately reassigning the variable to something else.
... View more
08-17-2017
02:10 PM
|
1
|
3
|
2303
|
|
POST
|
You can do this in a python script. Take a look at the last code sample on this page: Make Service Area Layer—Help | ArcGIS Desktop You don't actually need to make a new Route layer for every time of day. You can use the solver properties object to update the time on your existing layer and solve again. You would just need to read in your list of times from the file and then loop through them in the script.
... View more
08-07-2017
04:22 PM
|
1
|
0
|
1058
|
|
POST
|
You can use Delete Features to delete all or a selection of locations, just as you would for a normal layer: Delete Features—Help | ArcGIS Desktop The trick is how to access the sublayer (like Stops or Point Barriers). In Model Builder, you can use the Select Data utility to grab the sublayer from the network analysis layer. In python, the syntax depends on whether you're using ArcMap or Pro, but it involves doing listLayers on the network analysis layer object. The last code sample on this page shows it being done (for ArcMap): Make Service Area Layer—Help | ArcGIS Desktop If you're going to add a completely different set of stops or barriers to your sublayers after deleting the existing locations, you actually don't need to do a delete step at all. When you run Add Locations, just chose the option to clear existing data rather than append.
... View more
05-23-2017
09:20 AM
|
2
|
1
|
2228
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 3 weeks ago | |
| 1 | a month ago | |
| 1 | a month ago | |
| 1 | 06-12-2026 01:53 PM | |
| 1 | 04-21-2026 08:39 AM |
| Online Status |
Offline
|
| Date Last Visited |
3 weeks ago
|