Skip to content

Commit f8e0278

Browse files
Added my 3 normal map models (#290)
1 parent ff459d5 commit f8e0278

File tree

3 files changed

+142
-0
lines changed

3 files changed

+142
-0
lines changed

data/models/4x-Normal-RG0-BC1.json

+48
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
{
2+
"name": "Normal RG0 BC1",
3+
"author": "rundevelopment",
4+
"license": "CC0-1.0",
5+
"tags": [
6+
"dds",
7+
"game-textures",
8+
"restoration"
9+
],
10+
"description": "A 4x upscaler for BC1-compressed normal maps with a zeroed-out B channel. The output normals will also have a constant-zero B channel. Use external software or image editing plugins to properly normalize the generated normals and generate the Z component (if necessary). E.g. chaiNNer can do this with Normalize Normal Map node. Do not rely on this network producing unit vectors. \n\n**Dataset transformation:** \\\nThe LR have been compressed with various BC1 compression settings (dithering, weighting) using Texconv version 2021.11.8.1. Since the contents of the B channel influence the R and G channels during compression, the LR were given a B channel that was either the Z component of the normal, a random constant color, or a random texture (usually the G channel of the associated albedo) before compression. The LR + B channel was then compressed and the resulting BC1-compressed DDS was converted back into a PNG and had its B channel zeroed out.\n\nMore information: https://github.com/RunDevelopment/ESRGAN-models/blob/main/normals/README.md",
11+
"date": "2022-04-02",
12+
"architecture": "esrgan",
13+
"size": [
14+
"64nf",
15+
"23nb"
16+
],
17+
"scale": 4,
18+
"inputChannels": 3,
19+
"outputChannels": 3,
20+
"resources": [
21+
{
22+
"platform": "pytorch",
23+
"type": "pth",
24+
"size": 66961958,
25+
"sha256": "769f5b9b51813b5c8f43ece9fb17da9e249e3d667a5be649ba9583cae5e8843f",
26+
"urls": [
27+
"https://github.com/RunDevelopment/ESRGAN-models/raw/main/normals/4x-Normal-RG0-BC1.pth"
28+
]
29+
}
30+
],
31+
"trainingIterations": 100000,
32+
"trainingEpochs": 89,
33+
"trainingBatchSize": 8,
34+
"trainingHRSize": 128,
35+
"trainingOTF": false,
36+
"dataset": "Custom. See description.",
37+
"datasetSize": 577,
38+
"pretrainedModelG": "4x-ESRGAN",
39+
"images": [
40+
{
41+
"type": "paired",
42+
"caption": "Face of an old man",
43+
"LR": "https://images2.imgbox.com/65/bf/AdbeC87A_o.png",
44+
"SR": "https://images2.imgbox.com/bd/ae/gU4oQXzh_o.jpg",
45+
"thumbnail": "https://thumbs2.imgbox.com/bd/ae/gU4oQXzh_t.jpg"
46+
}
47+
]
48+
}

data/models/4x-Normal-RG0-BC7.json

+48
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
{
2+
"name": "Normal RG0 BC7",
3+
"author": "rundevelopment",
4+
"license": "CC0-1.0",
5+
"tags": [
6+
"dds",
7+
"game-textures",
8+
"restoration"
9+
],
10+
"description": "A 4x upscaler for BC7-compressed normal maps with a zeroed-out B channel and no alpha. The input is required to have no alpha and constant-zero blue channel. BC7-compressed images with an alpha channel should be handled by the BC1 model instead. This is because BC7 achieves very different quality for images with and without an alpha channel. The output normals will also have a constant-zero B channel. The output normals will also have a constant-zero B channel. Use external software or image editing plugins to properly normalize the generated normals and generate the Z component (if necessary). E.g. chaiNNer can do this with Normalize Normal Map node. Do not rely on this network producing unit vectors. \n\n**Dataset transformation:** \\\nThe LR have been compressed using Texconv version 2021.11.8.1. Since the contents of the B channel influence the R and G channels during compression, the LR were given a B channel that was either the Z component of the normal, a random constant color, or a random texture (usually the G channel of the associated albedo) before compression. The LR + B channel was then compressed and the resulting BC7-compressed DDS was converted back into a PNG and had its B channel zeroed out.\n\nMore information: https://github.com/RunDevelopment/ESRGAN-models/blob/main/normals/README.md",
11+
"date": "2022-04-02",
12+
"architecture": "esrgan",
13+
"size": [
14+
"64nf",
15+
"23nb"
16+
],
17+
"scale": 4,
18+
"inputChannels": 3,
19+
"outputChannels": 3,
20+
"resources": [
21+
{
22+
"platform": "pytorch",
23+
"type": "pth",
24+
"size": 66961958,
25+
"sha256": "ce39c9e227b672eadd6e924a3b5ea19781207af2cf982b8c70257a64745263cd",
26+
"urls": [
27+
"https://github.com/RunDevelopment/ESRGAN-models/raw/main/normals/4x-Normal-RG0-BC7.pth"
28+
]
29+
}
30+
],
31+
"trainingIterations": 100000,
32+
"trainingEpochs": 89,
33+
"trainingBatchSize": 8,
34+
"trainingHRSize": 128,
35+
"trainingOTF": false,
36+
"dataset": "Custom. See description",
37+
"datasetSize": 577,
38+
"pretrainedModelG": "4x-ESRGAN",
39+
"images": [
40+
{
41+
"type": "paired",
42+
"caption": "Crystal Lizard from Dark Souls 3",
43+
"LR": "https://images2.imgbox.com/cc/e1/i20G62sv_o.png",
44+
"SR": "https://images2.imgbox.com/39/c1/IDCLFuJ6_o.jpg",
45+
"thumbnail": "https://thumbs2.imgbox.com/39/c1/IDCLFuJ6_t.jpg"
46+
}
47+
]
48+
}

data/models/4x-Normal-RG0.json

+46
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
{
2+
"name": "Normal RG0",
3+
"author": "rundevelopment",
4+
"license": "CC0-1.0",
5+
"tags": [
6+
"game-textures"
7+
],
8+
"description": "A 4x upscaler for uncompressed normal maps with a zeroed-out B channel. The input is required to have no alpha and constant-zero blue channel. The model can handle some light compression artifacts but has trouble with quantization artifacts. The output normals will also have a constant-zero B channel. Use external software or image editing plugins to properly normalize the generated normals and generate the Z component (if necessary). E.g. chaiNNer can do this with Normalize Normal Map node. Do not rely on this network producing unit vectors.\n\n\nMore information: https://github.com/RunDevelopment/ESRGAN-models/blob/main/normals/README.md",
9+
"date": "2022-04-02",
10+
"architecture": "esrgan",
11+
"size": [
12+
"64nf",
13+
"23nb"
14+
],
15+
"scale": 4,
16+
"inputChannels": 3,
17+
"outputChannels": 3,
18+
"resources": [
19+
{
20+
"platform": "pytorch",
21+
"type": "pth",
22+
"size": 66961958,
23+
"sha256": "a52f1ddf0be2d5199622e8a3b155655a6c5adf6043669214c72264bec32c0583",
24+
"urls": [
25+
"https://github.com/RunDevelopment/ESRGAN-models/raw/main/normals/4x-Normal-RG0.pth"
26+
]
27+
}
28+
],
29+
"trainingIterations": 100000,
30+
"trainingEpochs": 89,
31+
"trainingBatchSize": 8,
32+
"trainingHRSize": 128,
33+
"trainingOTF": false,
34+
"dataset": "Custom. See description",
35+
"datasetSize": 577,
36+
"pretrainedModelG": "4x-ESRGAN",
37+
"images": [
38+
{
39+
"type": "paired",
40+
"caption": "Dragonslayer Armour shield from Dark Souls 3",
41+
"LR": "https://images2.imgbox.com/0a/c5/h00712oc_o.png",
42+
"SR": "https://images2.imgbox.com/14/c8/H3XDEUYS_o.jpg",
43+
"thumbnail": "https://thumbs2.imgbox.com/14/c8/H3XDEUYS_t.jpg"
44+
}
45+
]
46+
}

0 commit comments

Comments
 (0)