MCPcopy Index your code
hub / github.com/google-deepmind/dm_control / from_xml_string

Method from_xml_string

dm_control/mujoco/engine.py:452–466  ·  view source on GitHub ↗

A named constructor from a string containing an MJCF XML file. Args: xml_string: XML string containing an MJCF model description. assets: Optional dict containing external assets referenced by the model (such as additional XML files, textures, meshes etc.), in the form of

(cls, xml_string, assets=None)

Source from the content-addressed store, hash-verified

450
451 @classmethod
452 def from_xml_string(cls, xml_string, assets=None):
453 """A named constructor from a string containing an MJCF XML file.
454
455 Args:
456 xml_string: XML string containing an MJCF model description.
457 assets: Optional dict containing external assets referenced by the model
458 (such as additional XML files, textures, meshes etc.), in the form of
459 `{filename: contents_string}` pairs. The keys should correspond to the
460 filenames specified in the model XML.
461
462 Returns:
463 A new `Physics` instance.
464 """
465 model = wrapper.MjModel.from_xml_string(xml_string, assets=assets)
466 return cls.from_model(model)
467
468 @classmethod
469 def from_byte_string(cls, byte_string):

Callers 15

swingupFunction · 0.45
swingup_sparseFunction · 0.45
uprightFunction · 0.45
swimFunction · 0.45
bring_ballFunction · 0.45
bring_pegFunction · 0.45
insert_ballFunction · 0.45
insert_pegFunction · 0.45
runFunction · 0.45
standFunction · 0.45
walkFunction · 0.45
runFunction · 0.45

Calls 1

from_modelMethod · 0.80