PyCharm Code Inspect fixes (#18392)
Signed-off-by: UltralyticsAssistant <web@ultralytics.com> Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com> Co-authored-by: UltralyticsAssistant <web@ultralytics.com>
This commit is contained in:
parent
d35860d4a1
commit
e5e91967d9
31 changed files with 72 additions and 72 deletions
|
|
@ -181,12 +181,8 @@ class Inference:
|
|||
if __name__ == "__main__":
|
||||
import sys # Import the sys module for accessing command-line arguments
|
||||
|
||||
model = None # Initialize the model variable as None
|
||||
|
||||
# Check if a model name is provided as a command-line argument
|
||||
args = len(sys.argv)
|
||||
if args > 1:
|
||||
model = args # Assign the first argument as the model name
|
||||
|
||||
model = args if args > 1 else None
|
||||
# Create an instance of the Inference class and run inference
|
||||
Inference(model=model).inference()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue