mirror of
https://github.com/Stability-AI/generative-models.git
synced 2025-12-20 14:54:21 +01:00
Pre release changes for production (#59)
* clean requirements * rm taming deps * isort, black * mv lipips, license * clean vq, fix path * fix loss path, gitignore * tested requirements pt13 * fix numpy req for python3.8, add tests * fix name * fix dep scipy 3.8 pt2 * add black test formatter
This commit is contained in:
11
main.py
11
main.py
@@ -12,22 +12,18 @@ import pytorch_lightning as pl
|
||||
import torch
|
||||
import torchvision
|
||||
import wandb
|
||||
from PIL import Image
|
||||
from matplotlib import pyplot as plt
|
||||
from natsort import natsorted
|
||||
from omegaconf import OmegaConf
|
||||
from packaging import version
|
||||
from PIL import Image
|
||||
from pytorch_lightning import seed_everything
|
||||
from pytorch_lightning.callbacks import Callback
|
||||
from pytorch_lightning.loggers import WandbLogger
|
||||
from pytorch_lightning.trainer import Trainer
|
||||
from pytorch_lightning.utilities import rank_zero_only
|
||||
|
||||
from sgm.util import (
|
||||
exists,
|
||||
instantiate_from_config,
|
||||
isheatmap,
|
||||
)
|
||||
from sgm.util import exists, instantiate_from_config, isheatmap
|
||||
|
||||
MULTINODE_HACKS = True
|
||||
|
||||
@@ -910,11 +906,12 @@ if __name__ == "__main__":
|
||||
trainer.test(model, data)
|
||||
except RuntimeError as err:
|
||||
if MULTINODE_HACKS:
|
||||
import requests
|
||||
import datetime
|
||||
import os
|
||||
import socket
|
||||
|
||||
import requests
|
||||
|
||||
device = os.environ.get("CUDA_VISIBLE_DEVICES", "?")
|
||||
hostname = socket.gethostname()
|
||||
ts = datetime.datetime.utcnow().strftime("%Y-%m-%d %H:%M:%S")
|
||||
|
||||
Reference in New Issue
Block a user