Skip to content

Commit

Permalink
rectified accidentally inferring with resnet instead of generator
Browse files Browse the repository at this point in the history
  • Loading branch information
AndreiMoraru123 committed Jul 28, 2023
1 parent 625083d commit e21a490
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion resolve.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ def super_resolve(img: str, halve: bool = False):
sr_img_srresnet = tf.squeeze(sr_img_srresnet['output_0'])
sr_img_srresnet = transform.convert_image(sr_img_srresnet, source='[-1, 1]', target='pil')

sr_img_srgan = resnet_inference(lr_img)
sr_img_srgan = generator_inference(lr_img)
sr_img_srgan = tf.squeeze(sr_img_srgan['output_0'])
sr_img_srgan = transform.convert_image(sr_img_srgan, source='[-1, 1]', target='pil')

Expand Down
4 changes: 2 additions & 2 deletions train.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
large_kernel_size = 9 # kernel size of the first and last convolutions which transform the inputs and outputs
small_kernel_size = 3 # kernel size of the first and last convolutions which transform the inputs and outputs
n_channels = 64 # number of channels in-between, input and output channels for residual & subpixel conv blocks
n_blocks = 16 # number of residual blocks
n_blocks = 32 # number of residual blocks
srresnet_checkpoint = "SuperResolutionResNet_9999" # trained SRResNet checkpoint used for initialization

# Discriminator parameters
Expand Down Expand Up @@ -94,4 +94,4 @@ def main(architecture_type: str = "resnet"):


if __name__ == "__main__":
main(architecture_type="gan")
main(architecture_type="resnet")

0 comments on commit e21a490

Please sign in to comment.