Downloads · 30 days
0
public-data/Self-Distilled-StyleGAN
Self-Distilled-StyleGAN is a machine learning model from public-data. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
- https://arxiv.org/abs/2202.12211 - https://github.com/self-distilled-stylegan/self-distilled-internet-photos - weights - https://storage.googleapis.com/self-distilled-stylegan/dogs1024pytorch.pkl - https://storage.g…
Downloads · 30 days
0
Access
Public
Updated Jul 2, 2023
Repo size
3.9 GB
Likes
0
Public
Click a slice to open those files.
.pkl3.4 GB · 89%
From the Hugging Face model README
import pathlib
import pickle
sys.path.insert(0, '~/codes/clones/stylegan3')
paths = sorted(pathlib.Path('orig/').glob('*'))
out_dir = pathlib.Path('models')
out_dir.mkdir()
for path in paths:
with open(path, 'rb') as f:
ckpt = pickle.load(f)
for key in list(ckpt.keys()):
if key != 'G_ema':
del ckpt[key]
out_path = out_dir / path.name
with open(out_path, 'wb') as f:
pickle.dump(ckpt, f)