code: def read_records(file):
      
      records = []
      for record_data in read_recordio(file):
          record = Record()
          record.ParseFromString(record_data)
          records.append(record)
      return records
docs: Eagerly read a collection of amazon Record protobuf objects from file.