<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def getResetsIndices(networkDataFile):
 """Returns the indices at which the data sequences reset."""

    try:
      with open(networkDataFile) as f:
        reader = csv.reader(f)
        next(reader, None)
        next(reader, None)
        resetIdx = next(reader).index("R")

        resets = []
        for i, line in enumerate(reader):
          if int(line[resetIdx]) == 1:
            resets.append(i)
        return resets

    except IOError as e:
      print "Could not open the file {}.".format(networkDataFile)
      raise e