Spaces:
Running on Zero
Running on Zero
Commit ·
e38d64b
1
Parent(s): 9619759
Import from Huggingface_hub
Browse filesFiles changed (2)
- app.py+3-2
- requirements.txt+2-1
7 unmodified lines8910111213141575 unmodified lines919293949596977 unmodified linessys.path.append('./latent-diffusion')from taming.models import vqganfrom ldm.util import instantiate_from_configtorch.hub.download_url_to_file('https://ommer-lab.com/files/latent-diffusion/nitro/txt2img-f8-large/model.ckpt','txt2img-f8-large.ckpt')#@title Import stuffimport argparse, os, sys, glob75 unmodified linesreturn True if x > threshold else Falseconfig = OmegaConf.load("latent-diffusion/configs/latent-diffusion/txt2img-1p4B-eval.yaml")model = load_model_from_config(config, f"txt2img-f8-large.ckpt")device = torch.device("cuda") if torch.cuda.is_available() else torch.device("cpu")model = model.to(device)7 unmodified lines891011121314151675 unmodified lines929394959697987 unmodified linessys.path.append('./latent-diffusion')from taming.models import vqganfrom ldm.util import instantiate_from_configfrom huggingface_hub import hf_hub_downloadmodel_path_e = hf_hub_download(repo_id="multimodalart/compvis-latent-diffusion-text2img-large", filename="txt2img-f8-large.ckpt")#@title Import stuffimport argparse, os, sys, glob75 unmodified linesreturn True if x > threshold else Falseconfig = OmegaConf.load("latent-diffusion/configs/latent-diffusion/txt2img-1p4B-eval.yaml")model = load_model_from_config(config,model_path_e)device = torch.device("cuda") if torch.cuda.is_available() else torch.device("cpu")model = model.to(device)
13 unmodified lines1415161713 unmodified linestqdmtorchvisionPillowautokeras13 unmodified lines141516171813 unmodified linestqdmtorchvisionPillowautokerashuggingface_hub
app.py+3-2
requirements.txt+2-1