MCPcopy Create free account
hub / github.com/NVIDIA/TensorRT / __exit__

Method __exit__

tools/Polygraphy/tests/test_examples.py:188–195  ·  view source on GitHub ↗

Checks for and removes artifacts expected by this example

(self, exc_type, exc_value, traceback)

Source from the content-addressed store, hash-verified

186 return status
187
188 def __exit__(self, exc_type, exc_value, traceback):
189 """
190 Checks for and removes artifacts expected by this example
191 """
192 self._remove_artifacts()
193 assert (
194 self._get_file_list() == self.original_files
195 ), "Unexpected files were created. If this is the desired behavior, add the file paths to `artifact_names`"
196
197 def __str__(self):
198 return os.path.relpath(self.path, EXAMPLES_ROOT)

Callers

nothing calls this directly

Calls 2

_remove_artifactsMethod · 0.95
_get_file_listMethod · 0.95

Tested by

no test coverage detected