229 parse all arguments in pytorch trace file #230
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.
What does this PR do?
The HTA currently filters a specific set of arguments defined by the ParserConfig class. This approach effectively minimizes memory footprint, which is crucial when dealing with fixed traces.
When working with new types of traces, such as MTIA traces, the current implementation requires modifying the ParserConfig class. This introduces an additional layer of effort and potential complexity.
Proposed Solution
We're adding a new boolean attribute,
parse_all_arguments
(defaultFalse
), to theParserConfig
class. When set toTrue
, the parser will parse all arguments in the trace file. Arguments defined inevents_args
will be parsed as specified, while undefined arguments will be parsed using a standard naming convention with inferred default values.The undefined arguments are parsed with the following method:
name: the converted name, which is the raw name from the trace file converted to lowercase and with spaces replaced by underscores.
Benefits
Before submitting