def _LoadStopTimes(self):
    stop_time_class = self._gtfs_factory.StopTime

    for (row, row_num, cols) in self._ReadCSV('stop_times.txt',
        stop_time_class._FIELD_NAMES,
        stop_time_class._REQUIRED_FIELD_NAMES,
        stop_time_class._DEPRECATED_FIELD_NAMES):
      file_context = ('stop_times.txt', row_num, row, cols)
      self._problems.SetFileContext(*file_context)

      (trip_id, arrival_time, departure_time, stop_id, stop_sequence,
         stop_headsign, pickup_type, drop_off_type, shape_dist_traveled,
         timepoint) = row

      try:
        sequence = int(stop_sequence)
      except (__HOLE__, ValueError):
        self._problems.InvalidValue('stop_sequence', stop_sequence,
                                    'This should be a number.')
        continue
      if sequence < 0:
        self._problems.InvalidValue('stop_sequence', sequence,
                                    'Sequence numbers should be 0 or higher.')

      if stop_id not in self._schedule.stops:
        self._problems.InvalidValue('stop_id', stop_id,
                                    'This value wasn\'t defined in stops.txt')
        continue
      stop = self._schedule.stops[stop_id]
      if trip_id not in self._schedule.trips:
        self._problems.InvalidValue('trip_id', trip_id,
                                    'This value wasn\'t defined in trips.txt')
        continue
      trip = self._schedule.trips[trip_id]

      # If self._problems.Report returns then StopTime.__init__ will return
      # even if the StopTime object has an error. Thus this code may add a
      # StopTime that didn't validate to the database.
      # Trip.GetStopTimes then tries to make a StopTime from the invalid data
      # and calls the problem reporter for errors. An ugly solution is to
      # wrap problems and a better solution is to move all validation out of
      # __init__. For now make sure Trip.GetStopTimes gets a problem reporter
      # when called from Trip.Validate.
      stop_time = stop_time_class(self._problems, stop,
          arrival_time, departure_time, stop_headsign, pickup_type,
          drop_off_type, shape_dist_traveled, stop_sequence=sequence,
          timepoint=timepoint)
      trip._AddStopTimeObjectUnordered(stop_time, self._schedule)
      self._problems.ClearContext()

    # stop_times are validated in Trip.ValidateChildren, called by
    # Schedule.Validate
dataset/ETHPy150Open google/transitfeed/transitfeed/loader.py/Loader._LoadStopTimes