def _compute_com_pos_vel(self, *com):
        com_key = ",".join(sorted(com))
        if com_key in self._cached_coms:
            return self._cached_coms[com_key]
        total_mass_quant = 0
        total_mass = 0
        for body_name in com:
            body = find_body(self.world, body_name)
            total_mass_quant += body.mass * np.array(
                list(body.worldCenter) + list(body.linearVelocity))
            total_mass += body.mass
        com_quant = total_mass_quant / total_mass
        self._cached_coms[com_key] = com_quant
        return com_quant
dataset/ETHPy150Open rllab/rllab/rllab/envs/box2d/box2d_env.py/Box2DEnv._compute_com_pos_vel/original