Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixing truss files for real esrgan #68

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

htrivedi99
Copy link
Contributor

No description provided.


headers = {"Authorization": f"Api-Key <BASETEN-API-KEY>"}
data = {"image": b64_img}
res = requests.post("https://app.baseten.co/model_versions/{model_version}/predict", headers=headers, json=data)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please use the new APi url

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good catch

Comment on lines 12 to 31
git_repo_url = "https://github.com/xinntao/Real-ESRGAN.git"
git_clone_command = ["git", "clone", git_repo_url]
commit_hash = "5ca1078535923d485892caee7d7804380bfc87fd"
original_working_directory = os.getcwd()

try:
subprocess.run(git_clone_command, check=True)
print("Git repository cloned successfully!")

os.chdir(os.path.join(original_working_directory, "Real-ESRGAN"))
checkout_command = ["git", "checkout", commit_hash]
subprocess.run(checkout_command, check=True)
subprocess.run([sys.executable, "setup.py", "develop"], check=True)

except Exception as e:
print(e)
raise Exception("Error cloning Real-ESRGAN repo :(")

sys.path.append(os.path.join(os.getcwd()))

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Better to drop all this and just add to the requirements


requirements:
- git+https://github.com/xinntao/Real-ESRGAN.git@fa4c8a0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants