def write_to_db(self, db): """Write all the seeing information to the survey database. Parameters ---------- db : :class:`.SocsDatabase` The instance of the survey database. """ indicies = numpy.arange(1, self.seeing_dates.size + 1) seeing_info = list(map(tuple, numpy.hstack((indicies, self.seeing_dates, self.seeing_values)).reshape(-1, 3, order='F').tolist())) seeing = [write_seeing(si, db.session_id) for si in seeing_info] db.write_table("seeing", seeing)