EntropyDrop commited on
Commit
eb0ee82
·
1 Parent(s): 9b237bf

sking_v9x

Browse files
This view is limited to 50 files because it contains too many changes.   See raw diff
Files changed (50) hide show
  1. README.md +1 -1
  2. build_target_img.py +1 -1
  3. build_target_imgs.py +35 -19
  4. control_imgs/.DS_Store +0 -0
  5. control_imgs/{12.png → lowpoly/12.png} +0 -0
  6. control_imgs/lowpoly/124203.png +3 -0
  7. control_imgs/lowpoly/198224.png +3 -0
  8. control_imgs/{408097.png → lowpoly/408097.png} +0 -0
  9. control_imgs/lowpoly/438299.png +3 -0
  10. control_imgs/{517485.png → lowpoly/517485.png} +0 -0
  11. control_imgs/{525273.png → lowpoly/525273.png} +0 -0
  12. control_imgs/{8880007.png → lowpoly/8880007.png} +0 -0
  13. control_imgs/{8880010.png → lowpoly/8880010.png} +0 -0
  14. control_imgs/lowpoly/8880011.png +3 -0
  15. control_imgs/{8880023.png → lowpoly/8880023.png} +0 -0
  16. control_imgs/{8880023f.png → lowpoly/8880023f.png} +0 -0
  17. control_imgs/lowpoly/8880102.png +3 -0
  18. control_imgs/{half_12.png → lowpoly/half_12.png} +0 -0
  19. control_imgs/lowpoly/half_124203.png +3 -0
  20. control_imgs/lowpoly/half_198224.png +3 -0
  21. control_imgs/{half_408097.png → lowpoly/half_408097.png} +0 -0
  22. control_imgs/lowpoly/half_438299.png +3 -0
  23. control_imgs/{half_517485.png → lowpoly/half_517485.png} +0 -0
  24. control_imgs/{half_525273.png → lowpoly/half_525273.png} +0 -0
  25. control_imgs/{half_8880007.png → lowpoly/half_8880007.png} +0 -0
  26. control_imgs/{half_8880010.png → lowpoly/half_8880010.png} +0 -0
  27. control_imgs/lowpoly/half_8880011.png +3 -0
  28. control_imgs/{half_8880023.png → lowpoly/half_8880023.png} +0 -0
  29. control_imgs/{half_8880023f.png → lowpoly/half_8880023f.png} +0 -0
  30. control_imgs/lowpoly/half_8880102.png +3 -0
  31. control_imgs/{0042.png → realistic/0042.png} +0 -0
  32. control_imgs/{17474.png → realistic/17474.png} +0 -0
  33. control_imgs/{1ed2b9af-0722-4869-8685-294610976cb5.png → realistic/1ed2b9af-0722-4869-8685-294610976cb5.png} +0 -0
  34. control_imgs/{222855.png → realistic/222855.png} +0 -0
  35. control_imgs/{49ed3dbc-2d35-491c-b995-be54c59ab423.png → realistic/49ed3dbc-2d35-491c-b995-be54c59ab423.png} +0 -0
  36. control_imgs/{519494.png → realistic/519494.png} +0 -0
  37. control_imgs/{538419.png → realistic/538419.png} +0 -0
  38. control_imgs/{553045.png → realistic/553045.png} +0 -0
  39. control_imgs/{560261.png → realistic/560261.png} +0 -0
  40. control_imgs/{6306fffe-5944-4659-adea-055d00af89b0.png → realistic/6306fffe-5944-4659-adea-055d00af89b0.png} +0 -0
  41. control_imgs/{64154.png → realistic/64154.png} +0 -0
  42. control_imgs/{64154f.png → realistic/64154f.png} +0 -0
  43. control_imgs/{645888.png → realistic/645888.png} +0 -0
  44. control_imgs/{661333b9-bf31-4c70-af83-293663497b98.png → realistic/661333b9-bf31-4c70-af83-293663497b98.png} +0 -0
  45. control_imgs/{667114.png → realistic/667114.png} +0 -0
  46. control_imgs/{716523.png → realistic/716523.png} +0 -0
  47. control_imgs/{7d3f1a9c-1945-4b5f-a686-2eb7aa6f8d89.png → realistic/7d3f1a9c-1945-4b5f-a686-2eb7aa6f8d89.png} +0 -0
  48. control_imgs/{8024eb55-ef05-4752-a1b8-4ad7351a8172.png → realistic/8024eb55-ef05-4752-a1b8-4ad7351a8172.png} +0 -0
  49. control_imgs/{8880001.png → realistic/8880001.png} +0 -0
  50. control_imgs/{8880002.png → realistic/8880002.png} +0 -0
README.md CHANGED
@@ -28,7 +28,7 @@ Along with the dataset assets, it contains the complete automated pipeline for d
28
 
29
  * **🗂️ Dataset**: [Hugging Face Sking Dataset](https://huggingface.co/datasets/EntropyDrop/Sking)
30
  * **🧠 Trained Model**: [Hugging Face Sking Model](https://huggingface.co/EntropyDrop/Sking)
31
- * **📝 Technical Report**: [Technical Architecture](https://entropydrop.com/skin/open/article/skingen)
32
  * **🌐 Online Demo**: [EntropyDrop Web Portal](https://entropydrop.com)
33
 
34
  ---
 
28
 
29
  * **🗂️ Dataset**: [Hugging Face Sking Dataset](https://huggingface.co/datasets/EntropyDrop/Sking)
30
  * **🧠 Trained Model**: [Hugging Face Sking Model](https://huggingface.co/EntropyDrop/Sking)
31
+ * **📝 Technical Report**: [Technical Architecture](https://entropydrop.com/public/article/skingen)
32
  * **🌐 Online Demo**: [EntropyDrop Web Portal](https://entropydrop.com)
33
 
34
  ---
build_target_img.py CHANGED
@@ -209,7 +209,7 @@ def create_training_image(skin_image):
209
  'rot_arm_left': (0,0,0),
210
  'rot_leg_right': (0,0,0),
211
  'rot_leg_left': (0,0,0),
212
- },save_path=None, transparent_background=True, zoom=zoom, light=True)
213
 
214
  if img_np is not None:
215
  x = Image.fromarray(img_np)
 
209
  'rot_arm_left': (0,0,0),
210
  'rot_leg_right': (0,0,0),
211
  'rot_leg_left': (0,0,0),
212
+ },save_path=None, transparent_background=True, zoom=zoom, light=False)
213
 
214
  if img_np is not None:
215
  x = Image.fromarray(img_np)
build_target_imgs.py CHANGED
@@ -1,40 +1,56 @@
1
  import os
 
2
  import sys
3
  import subprocess
4
  from concurrent.futures import ThreadPoolExecutor
5
 
6
- output_dir = 'target_imgs_v73'
 
 
 
 
 
 
7
 
8
- def process_skin(skin_id):
9
- input_path = f'skins/{skin_id}.png'
10
- output_path = f'{output_dir}/{skin_id}.png'
11
  if not os.path.exists(output_path):
12
- print(f"Starting process for skin: {skin_id}...")
13
- # Run build_target_img.py as a separate subprocess using sys.executable
14
  result = subprocess.run(
15
- [sys.executable, 'build_target_img.py', input_path, output_path],
 
 
 
 
 
16
  capture_output=True,
17
  text=True
18
  )
 
19
  if result.returncode == 0:
20
  print(f"Successfully processed: {skin_id}")
21
  else:
22
  print(f"Error processing skin {skin_id}:")
23
  print(result.stderr or result.stdout)
24
-
25
  def main():
26
  os.makedirs(output_dir, exist_ok=True)
27
- iset = set()
28
- for i in os.listdir('skins'):
29
- if i.endswith('.png') and not i.startswith('.'):
30
- iset.add(i.split('.')[0])
31
-
32
- # Process skins in parallel using a pool of subprocesses
33
- # Using 4 workers for fast parallel rendering on Mac
34
- max_workers = 4
35
- print(f"Processing {len(iset)} skins using {max_workers} parallel workers...")
36
- with ThreadPoolExecutor(max_workers=max_workers) as executor:
37
- executor.map(process_skin, sorted(list(iset)))
38
 
 
 
 
 
 
 
 
 
 
39
  if __name__ == '__main__':
40
  main()
 
1
  import os
2
+ from functools import partial
3
  import sys
4
  import subprocess
5
  from concurrent.futures import ThreadPoolExecutor
6
 
7
+ output_dir = 'target_imgs_v91'
8
+
9
+ def process_skin(skin_id, skin_style):
10
+ input_path = f'skins/{skin_style}/{skin_id}.png'
11
+ output_path = f'{output_dir}/{skin_style}/{skin_id}.png'
12
+
13
+ os.makedirs(os.path.dirname(output_path), exist_ok=True)
14
 
 
 
 
15
  if not os.path.exists(output_path):
16
+ print(f"Starting process for skin: {skin_id}, style: {skin_style}...")
17
+
18
  result = subprocess.run(
19
+ [
20
+ sys.executable,
21
+ 'build_target_img.py',
22
+ input_path,
23
+ output_path,
24
+ ],
25
  capture_output=True,
26
  text=True
27
  )
28
+
29
  if result.returncode == 0:
30
  print(f"Successfully processed: {skin_id}")
31
  else:
32
  print(f"Error processing skin {skin_id}:")
33
  print(result.stderr or result.stdout)
 
34
  def main():
35
  os.makedirs(output_dir, exist_ok=True)
36
+ for skin_style in os.listdir('skins'):
37
+ if skin_style.startswith('.'):
38
+ continue
39
+ if skin_style != 'lowpoly':
40
+ continue
41
+ iset = set()
42
+ for i in os.listdir(f'skins/{skin_style}'):
43
+ if i.endswith('.png') and not i.startswith('.'):
44
+ iset.add(i.split('.')[0])
 
 
45
 
46
+ # Process skins in parallel using a pool of subprocesses
47
+ # Using 4 workers for fast parallel rendering on Mac
48
+ max_workers = 4
49
+ print(f"Processing {len(iset)} skins using {max_workers} parallel workers...")
50
+ with ThreadPoolExecutor(max_workers=max_workers) as executor:
51
+ executor.map(
52
+ partial(process_skin, skin_style=skin_style),
53
+ sorted(list(iset))
54
+ )
55
  if __name__ == '__main__':
56
  main()
control_imgs/.DS_Store CHANGED
Binary files a/control_imgs/.DS_Store and b/control_imgs/.DS_Store differ
 
control_imgs/{12.png → lowpoly/12.png} RENAMED
File without changes
control_imgs/lowpoly/124203.png ADDED

Git LFS Details

  • SHA256: ee43caac809cd66edac93cce69c107749005480bafe7fe58149fbb0ad06aac2f
  • Pointer size: 131 Bytes
  • Size of remote file: 851 kB
control_imgs/lowpoly/198224.png ADDED

Git LFS Details

  • SHA256: 9f3bc355e119f75c64d1c42c13dab3c6eaea0c25819628260acff81c9b23034a
  • Pointer size: 132 Bytes
  • Size of remote file: 1.38 MB
control_imgs/{408097.png → lowpoly/408097.png} RENAMED
File without changes
control_imgs/lowpoly/438299.png ADDED

Git LFS Details

  • SHA256: 2d381592d66dd3da31230896df92b608f40f6c4c31dbc44abe3a57043e36cbee
  • Pointer size: 131 Bytes
  • Size of remote file: 852 kB
control_imgs/{517485.png → lowpoly/517485.png} RENAMED
File without changes
control_imgs/{525273.png → lowpoly/525273.png} RENAMED
File without changes
control_imgs/{8880007.png → lowpoly/8880007.png} RENAMED
File without changes
control_imgs/{8880010.png → lowpoly/8880010.png} RENAMED
File without changes
control_imgs/lowpoly/8880011.png ADDED

Git LFS Details

  • SHA256: 62fa8f95420a881b47d657be3e0dda68b8e161a37444d27ac2e5b6e05227a25d
  • Pointer size: 132 Bytes
  • Size of remote file: 1.18 MB
control_imgs/{8880023.png → lowpoly/8880023.png} RENAMED
File without changes
control_imgs/{8880023f.png → lowpoly/8880023f.png} RENAMED
File without changes
control_imgs/lowpoly/8880102.png ADDED

Git LFS Details

  • SHA256: f61777183480fe96562b700dd36d8b71410abbede3bfe32d7b434be2f1e1fd57
  • Pointer size: 132 Bytes
  • Size of remote file: 1.96 MB
control_imgs/{half_12.png → lowpoly/half_12.png} RENAMED
File without changes
control_imgs/lowpoly/half_124203.png ADDED

Git LFS Details

  • SHA256: 509659450c0bb819d71e5a6fec30aa1f93081c4e831063970cbd043ff9a78ee8
  • Pointer size: 131 Bytes
  • Size of remote file: 488 kB
control_imgs/lowpoly/half_198224.png ADDED

Git LFS Details

  • SHA256: 10b35f4dd1038ad9f907ddf56544aac015443476ea1248eaa12f34a8b449f517
  • Pointer size: 131 Bytes
  • Size of remote file: 760 kB
control_imgs/{half_408097.png → lowpoly/half_408097.png} RENAMED
File without changes
control_imgs/lowpoly/half_438299.png ADDED

Git LFS Details

  • SHA256: aa3e178c7beb3ea4a01023f7e919bb0558005f65637b0c61e4999495b2643dff
  • Pointer size: 131 Bytes
  • Size of remote file: 412 kB
control_imgs/{half_517485.png → lowpoly/half_517485.png} RENAMED
File without changes
control_imgs/{half_525273.png → lowpoly/half_525273.png} RENAMED
File without changes
control_imgs/{half_8880007.png → lowpoly/half_8880007.png} RENAMED
File without changes
control_imgs/{half_8880010.png → lowpoly/half_8880010.png} RENAMED
File without changes
control_imgs/lowpoly/half_8880011.png ADDED

Git LFS Details

  • SHA256: ef3cc4a71e4f50b59449fd2e1107293ec4f790e7872e00e79975e2fbc47e7084
  • Pointer size: 131 Bytes
  • Size of remote file: 758 kB
control_imgs/{half_8880023.png → lowpoly/half_8880023.png} RENAMED
File without changes
control_imgs/{half_8880023f.png → lowpoly/half_8880023f.png} RENAMED
File without changes
control_imgs/lowpoly/half_8880102.png ADDED

Git LFS Details

  • SHA256: eac3c99a787888bb216c6100b980e217dbe95a5885a2211c023faa7f71ddfb0a
  • Pointer size: 131 Bytes
  • Size of remote file: 935 kB
control_imgs/{0042.png → realistic/0042.png} RENAMED
File without changes
control_imgs/{17474.png → realistic/17474.png} RENAMED
File without changes
control_imgs/{1ed2b9af-0722-4869-8685-294610976cb5.png → realistic/1ed2b9af-0722-4869-8685-294610976cb5.png} RENAMED
File without changes
control_imgs/{222855.png → realistic/222855.png} RENAMED
File without changes
control_imgs/{49ed3dbc-2d35-491c-b995-be54c59ab423.png → realistic/49ed3dbc-2d35-491c-b995-be54c59ab423.png} RENAMED
File without changes
control_imgs/{519494.png → realistic/519494.png} RENAMED
File without changes
control_imgs/{538419.png → realistic/538419.png} RENAMED
File without changes
control_imgs/{553045.png → realistic/553045.png} RENAMED
File without changes
control_imgs/{560261.png → realistic/560261.png} RENAMED
File without changes
control_imgs/{6306fffe-5944-4659-adea-055d00af89b0.png → realistic/6306fffe-5944-4659-adea-055d00af89b0.png} RENAMED
File without changes
control_imgs/{64154.png → realistic/64154.png} RENAMED
File without changes
control_imgs/{64154f.png → realistic/64154f.png} RENAMED
File without changes
control_imgs/{645888.png → realistic/645888.png} RENAMED
File without changes
control_imgs/{661333b9-bf31-4c70-af83-293663497b98.png → realistic/661333b9-bf31-4c70-af83-293663497b98.png} RENAMED
File without changes
control_imgs/{667114.png → realistic/667114.png} RENAMED
File without changes
control_imgs/{716523.png → realistic/716523.png} RENAMED
File without changes
control_imgs/{7d3f1a9c-1945-4b5f-a686-2eb7aa6f8d89.png → realistic/7d3f1a9c-1945-4b5f-a686-2eb7aa6f8d89.png} RENAMED
File without changes
control_imgs/{8024eb55-ef05-4752-a1b8-4ad7351a8172.png → realistic/8024eb55-ef05-4752-a1b8-4ad7351a8172.png} RENAMED
File without changes
control_imgs/{8880001.png → realistic/8880001.png} RENAMED
File without changes
control_imgs/{8880002.png → realistic/8880002.png} RENAMED
File without changes