MCPcopy Create free account
hub / github.com/google-deepmind/dm_control / parse_schema

Function parse_schema

dm_control/mjcf/schema.py:73–84  ·  view source on GitHub ↗

Parses the schema XML. Args: schema_path: Path to the schema XML file. Returns: An `ElementSpec` for the root element in the schema.

(schema_path)

Source from the content-addressed store, hash-verified

71
72
73def parse_schema(schema_path):
74 """Parses the schema XML.
75
76 Args:
77 schema_path: Path to the schema XML file.
78
79 Returns:
80 An `ElementSpec` for the root element in the schema.
81 """
82 with resources.GetResourceAsFile(schema_path) as file_handle:
83 schema_xml = etree.parse(file_handle).getroot()
84 return _parse_element(schema_xml)
85
86
87def _parse_element(element_xml):

Callers 2

schema.pyFile · 0.85
override_schemaFunction · 0.85

Calls 1

_parse_elementFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…