K00B404 commited on
Commit
3297549
1 Parent(s): 87e3efe

Upload README.md with huggingface_hub

Browse files
Files changed (1) hide show
  1. README.md +46 -3
README.md CHANGED
@@ -1,3 +1,46 @@
1
- ---
2
- license: wtfpl
3
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ tags:
3
+ - unet
4
+ - pix2pix
5
+ library_name: pytorch
6
+ ---
7
+
8
+ # Pix2Pix UNet Model
9
+
10
+ ## Model Description
11
+ Custom UNet model for Pix2Pix image translation.
12
+ - Image Size: 256
13
+ - Model Type: Small (256)
14
+
15
+ ## Usage
16
+
17
+ ```python
18
+ import torch
19
+ from small_256_model import UNet as small_UNet
20
+ from big_1024_model import UNet as big_UNet
21
+
22
+ # Load the model
23
+ checkpoint = torch.load('model_weights.pth')
24
+ model = big_UNet() if checkpoint['model_config']['big'] else small_UNet()
25
+ model.load_state_dict(checkpoint['model_state_dict'])
26
+ model.eval()
27
+ Model Architecture
28
+ UNet(
29
+ (encoder): Sequential(
30
+ (0): Conv2d(3, 64, kernel_size=(4, 4), stride=(2, 2), padding=(1, 1))
31
+ (1): ReLU(inplace=True)
32
+ (2): Conv2d(64, 128, kernel_size=(4, 4), stride=(2, 2), padding=(1, 1))
33
+ (3): ReLU(inplace=True)
34
+ (4): Conv2d(128, 256, kernel_size=(4, 4), stride=(2, 2), padding=(1, 1))
35
+ (5): ReLU(inplace=True)
36
+ )
37
+ (decoder): Sequential(
38
+ (0): ConvTranspose2d(256, 128, kernel_size=(4, 4), stride=(2, 2), padding=(1, 1))
39
+ (1): ReLU(inplace=True)
40
+ (2): ConvTranspose2d(128, 64, kernel_size=(4, 4), stride=(2, 2), padding=(1, 1))
41
+ (3): ReLU(inplace=True)
42
+ (4): ConvTranspose2d(64, 3, kernel_size=(4, 4), stride=(2, 2), padding=(1, 1))
43
+ (5): Tanh()
44
+ )
45
+ )
46
+