@times.setter
    def times(self, new_times):

        try:
            if new_times is not None and self.system is not None:
                msg = ('The system attribute has already been set, so the '
                       'times cannot be set. Set Scene.system = None to '
                       'allow a time array to be added.')
                raise ValueError(msg)
        except AttributeError:
            pass

        try:
            if new_times is not None and self.states_trajectories is not None:
                len_traj = self.states_trajectories.shape[0]
                if len(new_times) != len_traj:
                    msg = ('The times array length, {}, does not match the '
                           'length of the state trajectories array, {}.')
                    raise ValueError(msg.format(len(new_times), len_traj))
        except __HOLE__:
            pass

        if new_times is None:
            self._times = new_times
        else:
            self._times = np.array(new_times)
dataset/ETHPy150Open pydy/pydy/pydy/viz/scene.py/Scene.times