ravens/tasks/defs_cloth.py
def reset(self, env, last_info=None):
        """Reset to start an episode.

        Call the superclass to generate as usual, and then remove the zone
        here. Requires care in `environment.py` to avoid iterating over
        invalid IDs, and we need the zone in the superclass for many reasons.

        If loading goal images, we cannot just override self.target_hull_bool
        because that means the cloth isn't sampled the same way as if the
        target was visible. We need to first decide on the pose, THEN sample
        the cloth. Easiset solution: load the sampled `zone_pose`, then pass
        that into the reset() call so that we don't re-sample `zone_pose`.
        Everything is reconsructed from there.
        """
        zone_pose = None
        if last_info is not None:
            zone_pose = last_info['sampled_zone_pose']
        super().reset(env, zone_pose=zone_pose)
        p.removeBody(self.zone_ID)
Reset to start an episode.

        Call the superclass to generate as usual, and then remove the zone
        here. Requires care in `environment.py` to avoid iterating over
        invalid IDs, and we need the zone in the superclass for many reasons.

        If loading goal images, we cannot just override self.target_hull_bool
        because that means the cloth isn't sampled the same way as if the
        target was visible. We need to first decide on the pose, THEN sample
        the cloth. Easiset solution: load the sampled `zone_pose`, then pass
        that into the reset() call so that we don't re-sample `zone_pose`.
        Everything is reconsructed from there.
        
Reset to start an episode.
Call the superclass to generate as usual, and then remove the zone
here. Requires care in `environment.py` to avoid iterating over
invalid IDs, and we need the zone in the superclass for many reasons.

If loading goal images, we cannot just override self.target_hull_bool
because that means the cloth isn't sampled the same way as if the
target was visible. We need to first decide on the pose, THEN sample
the cloth. Easiset solution: load the sampled `zone_pose`, then pass
that into the reset() call so that we don't re-sample `zone_pose`.
Everything is reconsructed from there.
Reset to start an episode . Call the superclass to generate as usual and then remove the zone here . Requires care in ` environment . py ` to avoid iterating over invalid IDs and we need the zone in the superclass for many reasons . If loading goal images we cannot just override self . target_hull_bool because that means the cloth isn ' t sampled the same way as if the target was visible . We need to first decide on the pose THEN sample the cloth . Easiset solution : load the sampled ` zone_pose ` then pass that into the reset () call so that we don ' t re - sample ` zone_pose ` . Everything is reconsructed from there .
def reset(self, env, last_info=None):
        zone_pose = None
        if last_info is not None:
            zone_pose = last_info['sampled_zone_pose']
        super().reset(env, zone_pose=zone_pose)
        p.removeBody(self.zone_ID)
def reset ( self , env , last_info = None ) : zone_pose = None if last_info is not None : zone_pose = last_info [ 'sampled_zone_pose' ] super ( ) . reset ( env , zone_pose = zone_pose ) p . removeBody ( self . zone_ID )
Reset to start an episode.
Reset to start an episode .
"""Reset to start an episode.

        Call the superclass to generate as usual, and then remove the zone
        here. Requires care in `environment.py` to avoid iterating over
        invalid IDs, and we need the zone in the superclass for many reasons.

        If loading goal images, we cannot just override self.target_hull_bool
        because that means the cloth isn't sampled the same way as if the
        target was visible. We need to first decide on the pose, THEN sample
        the cloth. Easiset solution: load the sampled `zone_pose`, then pass
        that into the reset() call so that we don't re-sample `zone_pose`.
        Everything is reconsructed from there.
        """
self
env
last_info