forked from openvinotoolkit/training_extensions
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update fuzzing (openvinotoolkit#3829)
* update-fuzzing-tests * extend available torch version
- Loading branch information
Showing
6 changed files
with
54 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
"-h" | ||
"-v" | ||
"install" | ||
"find" | ||
"train" | ||
|
@@ -6,3 +8,4 @@ | |
"export" | ||
"optimize" | ||
"explain" | ||
"benchmark" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
#!.tox/fuzzing/bin/python | ||
|
||
import sys | ||
from pathlib import Path | ||
|
||
from otx.cli import main as cli_main | ||
|
||
|
||
def main(): | ||
if len(sys.argv) != 2: | ||
print("usage: python eval_fuzzing_crash.py <fuzzing-crash-binary-file>") | ||
return | ||
|
||
ba = None | ||
if Path.exists(sys.argv[1]): | ||
with Path.open(sys.argv[1], "rb") as f: | ||
ba = bytearray(f.read()) | ||
|
||
arguments = "".join(ba.decode(errors="replace")) | ||
|
||
sys.argv = ["otx", f"{arguments!s}"] | ||
_ = cli_main() | ||
|
||
|
||
if __name__ == "__main__": | ||
main() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters