Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This includes everything from #357 and the following changes to make the runs fast and make the code (hopefully) easier to maintain:
OnnxModelInfo class refactoring:
__slots__
to optimize memory usagemodel
,ort_inference_session
,ort_input_nodes
, andort_output_nodes
Performance improvements:
Type hinting and imports:
List
andfinal
to imports from typing moduleChanges to helper classes:
AzureDownloadableModel
,SiblingModel
, andTruncatedModel
to work with the refactoredOnnxModelInfo
self._model
instead ofself.model
in some casesMinor updates to other files:
get_sample_inputs_for_onnx_model
function to accept input nodes directlyCommand-line argument change:
-t
/--test-filter
argument to indicate it uses regex filteringThese changes appear to focus on improving performance, reducing redundant operations, and making the code more maintainable through better encapsulation and lazy loading of resources.