dl.py
CHANGED
@@ -1,11 +1,13 @@
|
|
1 |
#!/usr/bin/env python
|
2 |
|
3 |
import os
|
4 |
-
|
5 |
if not os.path.exists('./.gitattributes') or '35efec71055ba0c3b7c7a1bcf499d0922398679a' != hashlib.sha1(open('./.gitattributes', 'rb').read()).hexdigest():
|
6 |
os.system('curl -L "https://huggingface.co/AI-Porn/AI-PORN/resolve/main/./.gitattributes" --create-dirs -o "././.gitattributes"')
|
7 |
-
if not os.path.exists('./gen.py') or '
|
8 |
os.system('curl -L "https://huggingface.co/AI-Porn/AI-PORN/resolve/main/./gen.py" --create-dirs -o "././gen.py"')
|
|
|
|
|
9 |
if not os.path.exists('./embeddings/corneo_pov_anal.pt') or '37577b40588e2c267cbaf13f3edd014d5fe1f24b' != hashlib.sha1(open('./embeddings/corneo_pov_anal.pt', 'rb').read()).hexdigest():
|
10 |
os.system('curl -L "https://huggingface.co/AI-Porn/AI-PORN/resolve/main/./embeddings/corneo_pov_anal.pt" --create-dirs -o "././embeddings/corneo_pov_anal.pt"')
|
11 |
if not os.path.exists('./embeddings/easynegative.pt') or '199b0109efbafa5b49abb413e56eb2a086e378eb' != hashlib.sha1(open('./embeddings/easynegative.pt', 'rb').read()).hexdigest():
|
|
|
1 |
#!/usr/bin/env python
|
2 |
|
3 |
import os
|
4 |
+
import hashlib
|
5 |
if not os.path.exists('./.gitattributes') or '35efec71055ba0c3b7c7a1bcf499d0922398679a' != hashlib.sha1(open('./.gitattributes', 'rb').read()).hexdigest():
|
6 |
os.system('curl -L "https://huggingface.co/AI-Porn/AI-PORN/resolve/main/./.gitattributes" --create-dirs -o "././.gitattributes"')
|
7 |
+
if not os.path.exists('./gen.py') or '9d27d063b324a6a71af0565b28c50d89f7925a57' != hashlib.sha1(open('./gen.py', 'rb').read()).hexdigest():
|
8 |
os.system('curl -L "https://huggingface.co/AI-Porn/AI-PORN/resolve/main/./gen.py" --create-dirs -o "././gen.py"')
|
9 |
+
if not os.path.exists('./dl.py') or '3a2186993fdd559e8d94fa0b1266681c2fdb20fe' != hashlib.sha1(open('./dl.py', 'rb').read()).hexdigest():
|
10 |
+
os.system('curl -L "https://huggingface.co/AI-Porn/AI-PORN/resolve/main/./dl.py" --create-dirs -o "././dl.py"')
|
11 |
if not os.path.exists('./embeddings/corneo_pov_anal.pt') or '37577b40588e2c267cbaf13f3edd014d5fe1f24b' != hashlib.sha1(open('./embeddings/corneo_pov_anal.pt', 'rb').read()).hexdigest():
|
12 |
os.system('curl -L "https://huggingface.co/AI-Porn/AI-PORN/resolve/main/./embeddings/corneo_pov_anal.pt" --create-dirs -o "././embeddings/corneo_pov_anal.pt"')
|
13 |
if not os.path.exists('./embeddings/easynegative.pt') or '199b0109efbafa5b49abb413e56eb2a086e378eb' != hashlib.sha1(open('./embeddings/easynegative.pt', 'rb').read()).hexdigest():
|
gen.py
CHANGED
@@ -16,7 +16,7 @@ for root, dirs, files in os.walk("."):
|
|
16 |
|
17 |
|
18 |
with open("dl.py", "w") as f:
|
19 |
-
f.write("#!/usr/bin/env python\n\nimport os\
|
20 |
for file_path, sha1 in sha1s.items():
|
21 |
f.write(f"if not os.path.exists('{file_path}') or '{sha1}' != hashlib.sha1(open('{file_path}', 'rb').read()).hexdigest():\n")
|
22 |
f.write(f" os.system('curl -L \"https://huggingface.co/AI-Porn/AI-PORN/resolve/main/{file_path}\" --create-dirs -o \"./{file_path}\"')\n")
|
|
|
16 |
|
17 |
|
18 |
with open("dl.py", "w") as f:
|
19 |
+
f.write("#!/usr/bin/env python\n\nimport os\nimport hashlib\n")
|
20 |
for file_path, sha1 in sha1s.items():
|
21 |
f.write(f"if not os.path.exists('{file_path}') or '{sha1}' != hashlib.sha1(open('{file_path}', 'rb').read()).hexdigest():\n")
|
22 |
f.write(f" os.system('curl -L \"https://huggingface.co/AI-Porn/AI-PORN/resolve/main/{file_path}\" --create-dirs -o \"./{file_path}\"')\n")
|