Select to view content in your preferred language

Define Travel Mode in ModelBuilder

542
3
Jump to solution
09-12-2022 04:40 PM
John_Herrera
Occasional Contributor

I've created a closest facility analysis model using Model Builder in ArcGIS Pro v2.9.4. I'm using StreetMap Premium 2021 as the network dataset. Inspecting the Network Analyst geoprocessing tools, I noticed that I have not seen Travel Mode (specifically Restrictions settings) in the geoprocessing tools (i.e. no U-turns, Avoid Toll Roads, Avoid Ferries). These are the same Travel Mode settings that can be defined in the layer properties for closest facility in the table of contents pane. Can Travel Mode be defined in Model Builder?

0 Kudos
1 Solution

Accepted Solutions
MelindaMorang
Esri Regular Contributor

This tutorial might help: https://pro.arcgis.com/en/pro-app/latest/help/analysis/networks/create-a-model-for-route-analysis.ht...

It explains what it means to expose something as a model parameter, although it doesn't demonstrate the travel mode parameter specifically.

Here's the documentation explaining model parameters specifically: https://pro.arcgis.com/en/pro-app/latest/help/analysis/geoprocessing/modelbuilder/model-parameters.h... 

 

 

View solution in original post

3 Replies
MelindaMorang
Esri Regular Contributor

The Make Closest Facility Analysis Layer tool has a travel mode parameter, so you can choose one of the pre-defined travel modes on the network dataset.  However, the individual settings within the travel mode (restrictions, u-turn policy, etc.) cannot be individually set.  You can expose the travel mode parameter as a model parameter so the user can pick the travel mode from the model tool UI.  There are ways to create a custom travel mode using Python or a JSON string.  Or you can add travel modes to your Streetmap Premium dataset if there's a specific non-default configuration you want.

0 Kudos
John_Herrera
Occasional Contributor
Thank you for your reply! Do you know of documentation that can assist with, "...expose the travel mode parameter as a model parameter so the user can pick the travel mode from the model tool UI?"
0 Kudos
MelindaMorang
Esri Regular Contributor

This tutorial might help: https://pro.arcgis.com/en/pro-app/latest/help/analysis/networks/create-a-model-for-route-analysis.ht...

It explains what it means to expose something as a model parameter, although it doesn't demonstrate the travel mode parameter specifically.

Here's the documentation explaining model parameters specifically: https://pro.arcgis.com/en/pro-app/latest/help/analysis/geoprocessing/modelbuilder/model-parameters.h...