Spaces:
Sleeping
Sleeping
Commit
·
3cb25e1
1
Parent(s):
199c8cd
debug
Browse files- README.md +1 -1
- revq/losses/aeloss_disc.py +1 -1
- revq/models/vqgan.py +1 -1
- revq/trainer/pipeline.py +3 -3
- revq/utils/logger.py +2 -2
README.md
CHANGED
|
@@ -1,5 +1,5 @@
|
|
| 1 |
---
|
| 2 |
-
title:
|
| 3 |
emoji: 😻
|
| 4 |
colorFrom: indigo
|
| 5 |
colorTo: red
|
|
|
|
| 1 |
---
|
| 2 |
+
title: ReVQ
|
| 3 |
emoji: 😻
|
| 4 |
colorFrom: indigo
|
| 5 |
colorTo: red
|
revq/losses/aeloss_disc.py
CHANGED
|
@@ -15,7 +15,7 @@ import torch.nn as nn
|
|
| 15 |
import torch.nn.functional as F
|
| 16 |
import lpips
|
| 17 |
|
| 18 |
-
from
|
| 19 |
|
| 20 |
class DummyLoss(nn.Module):
|
| 21 |
def __init__(self):
|
|
|
|
| 15 |
import torch.nn.functional as F
|
| 16 |
import lpips
|
| 17 |
|
| 18 |
+
from revq.models.discriminator import NLayerDiscriminator, weights_init
|
| 19 |
|
| 20 |
class DummyLoss(nn.Module):
|
| 21 |
def __init__(self):
|
revq/models/vqgan.py
CHANGED
|
@@ -11,7 +11,7 @@ import torch
|
|
| 11 |
import torch.nn.functional as F
|
| 12 |
import torch.nn as nn
|
| 13 |
|
| 14 |
-
import
|
| 15 |
|
| 16 |
class Identity(nn.Module):
|
| 17 |
def forward(self, x):
|
|
|
|
| 11 |
import torch.nn.functional as F
|
| 12 |
import torch.nn as nn
|
| 13 |
|
| 14 |
+
import revq.utils.logger as L
|
| 15 |
|
| 16 |
class Identity(nn.Module):
|
| 17 |
def forward(self, x):
|
revq/trainer/pipeline.py
CHANGED
|
@@ -15,9 +15,9 @@ import torch
|
|
| 15 |
import torch.nn as nn
|
| 16 |
from torch.utils.data.dataloader import DataLoader
|
| 17 |
|
| 18 |
-
from
|
| 19 |
-
from
|
| 20 |
-
import
|
| 21 |
|
| 22 |
def setup_config(opt: argparse.Namespace):
|
| 23 |
L.log.info("\n\n### Setting up the configurations. ###")
|
|
|
|
| 15 |
import torch.nn as nn
|
| 16 |
from torch.utils.data.dataloader import DataLoader
|
| 17 |
|
| 18 |
+
from revq.utils.init import initiate_from_config_recursively
|
| 19 |
+
from revq.data.dataloader import maybe_get_subset
|
| 20 |
+
import revq.utils.logger as L
|
| 21 |
|
| 22 |
def setup_config(opt: argparse.Namespace):
|
| 23 |
L.log.info("\n\n### Setting up the configurations. ###")
|
revq/utils/logger.py
CHANGED
|
@@ -25,9 +25,9 @@ except:
|
|
| 25 |
|
| 26 |
"""
|
| 27 |
NOTE: The `log` instance is a global variable, which should be imported by other modules as:
|
| 28 |
-
`import
|
| 29 |
rather than
|
| 30 |
-
`from
|
| 31 |
"""
|
| 32 |
|
| 33 |
def setup_printer(file_log_dir: str, use_console: bool = True):
|
|
|
|
| 25 |
|
| 26 |
"""
|
| 27 |
NOTE: The `log` instance is a global variable, which should be imported by other modules as:
|
| 28 |
+
`import revq.utils.logger as logger`
|
| 29 |
rather than
|
| 30 |
+
`from revq.utils.logger import log`.
|
| 31 |
"""
|
| 32 |
|
| 33 |
def setup_printer(file_log_dir: str, use_console: bool = True):
|