diff --git a/net.py b/net.py index d9fb694..f40fb99 100644 --- a/net.py +++ b/net.py @@ -248,11 +248,7 @@ class DetailFeatureExtraction(nn.Module): super(DetailFeatureExtraction, self).__init__() INNmodules = [DetailNode() for _ in range(num_layers)] self.net = nn.Sequential(*INNmodules) - self.enhancement_module = nn.Sequential( - nn.Conv2d(32, 32, kernel_size=3, padding=1, bias=True), - nn.ReLU(inplace=True), - nn.Conv2d(32, 32, kernel_size=3, padding=1, bias=True), - ) + self.enhancement_module = WTConv2d(32, 32) def forward(self, x): # 1 64 128 128 z1, z2 = x[:, :x.shape[1] // 2], x[:, x.shape[1] // 2:x.shape[1]] # 1 32 128 128 diff --git a/train.py b/train.py index f5a6abd..b963b00 100644 --- a/train.py +++ b/train.py @@ -222,7 +222,7 @@ for epoch in range(num_epochs): time_left = datetime.timedelta(seconds=batches_left * (time.time() - prev_time)) epoch_time = time.time() - prev_time prev_time = time.time() - if step % 100 == 0: + if i % 100 == 0: sys.stdout.write( "\r[Epoch %d/%d] [Batch %d/%d] [loss: %f] ETA: %.10s" % (