3

I have FGDB with points feature classes that I want to convert to lines using using a ready-made script called TrackBuilder. I am using model builder:

Model

When I populate the Track Builder script tool with the parameters everything looks fine. But when I validate the tool goes white

Validated model

WHY?

The beginning of the Track Builder script looks like this:

import arcpy, os, sys, traceback, datetime, math, re

## Input Paramaters
sInputFile = arcpy.GetParameterAsText(0)
sID_Field = arcpy.GetParameterAsText(1)
sDT_Field = arcpy.GetParameterAsText(2)
sOutWorkspace = arcpy.GetParameterAsText(3)
sOutName = arcpy.GetParameterAsText(4)
sLineMethod = arcpy.GetParameterAsText(5)
sMaxTimeMinutes = arcpy.GetParameterAsText(6)
sMaxDistMiles = arcpy.GetParameterAsText(7)
sIntervalHours = arcpy.GetParameterAsText(8)
sAddVoyageData = arcpy.GetParameterAsText(9)
voyageTable = arcpy.GetParameterAsText(10)
voyageMethod = arcpy.GetParameterAsText(11)
sAddVesselData = arcpy.GetParameterAsText(12)
vesselTable = arcpy.GetParameterAsText(13)

According to the TrackBuilder instructions the input point should be a feature class containing a date field and an unique number for each ship.

Everything looks correct here:

enter image description here

The whole TrackBuilder script can be found here

  • 1
    When a tool goes white during validation that is saying that one or more parameters are invalid. We can't tell from your screen shot. For example the iterator is passing out a FeatureClass but is your input requirement a FeatureLayer? You need to make your model, toolbox and code available to others if you want an answer to this question? – Hornbydd Sep 3 '15 at 19:54
  • You are right. Already edited! – Manuel Frias Sep 4 '15 at 7:25
  • What happens when you create a simpler model with just the TrackBuilder tool and its inputs (no iterator)? Will it validate and then run successfully? – PolyGeo Sep 16 '16 at 23:34
-1

This is alternative way to convert point to line using arcpy:

How to create lines from points pair coordinates with arcpy?

  • Thanks! TrackBuilder script can segment the line according to time and distance which is useful for our analysis and the reason why we are using it. – Manuel Frias Sep 4 '15 at 8:08

Not the answer you're looking for? Browse other questions tagged or ask your own question.