Hello.
I think what you're asking is how you can make the geometry of the LineVariantElements look like your shapes.txt file so that the transit lines appear to follow their actual geographic paths instead of simple straight-line connections between stops. Is that correct?
If so, there is no need to do this. The Public Transit evaluator in the network dataset does not care about the geometry of the LineVariantElements. It looks up the travel times in the various Public Transit Data Model tables.
There are several reasons we don't use the geometry from shapes.txt for the network dataset:
- The shapes.txt file is optional, so we can't rely on it being there.
- Often the shapes derived from a shapes.txt file are messy or inaccurate (or missing).
- Good connectivity with stops is essential in a network dataset, and the data from shapes.txt does not have a straightforward relationship with stops.
You should not try to use your network dataset and its LineVariantElements feature class for visualization. It is designed specifically for analysis. But, I would be interested to understand your goal - what are you actually trying to do?
To answer your specific questions:
From your screenshot of the output of GTFS Shapes To Features, it looks like most routes have multiple shapes. For instance, route_id A_562 has four shape_ids: 10, 11, 12, 9.
The GTFS shape_id is not used in the LineVariants table. One reason is that shape_id can be a string, and we chose to use numeric values as IDs for our Public Transit Data Model. Also, although we provide tools to convert from GTFS to the Public Transit Data Model, you could instead use some non-GTFS source of transit data. Also, as I said before, the shapes.txt file is optional. So, you should not consider the ID field in LineVariants equivalent to the shape_id field in shapes.txt, but you are correct that LineVariants are conceptually equivalent to shapes. But...yeah, there is no good way to join the LineVariants table to the output of GTFS Shapes To Features.
If you tell me more about what you're trying to do, I might be able to give more useful advice.