Skip to content

Commit

Permalink
Fix invoke-spandrel file (#406)
Browse files Browse the repository at this point in the history
  • Loading branch information
joeyballentine authored May 5, 2024
1 parent aff9094 commit f2d3332
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions invoke-spandrel.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ def print_metadata(file: str):

return_success(
{
"architecture": model.architecture,
"architecture": model.architecture.name,
"tags": model.tags,
"scale": model.scale,
"inputChannels": model.input_channels,
Expand All @@ -45,6 +45,8 @@ def print_metadata(file: str):
current_python = sys.executable
os.system(current_python + " -m pip install spandrel")
else:
return_error("PyTorch is not installed. Install PyTorch on your system's Python installation to automatically detect model metadata.")
return_error(
"PyTorch is not installed. Install PyTorch on your system's Python installation to automatically detect model metadata."
)

print_metadata(sys.argv[1])

0 comments on commit f2d3332

Please sign in to comment.