Very first attempt with ESRGAN

Started by Hobbes, Sat 05/06/2021 04:22:23

Previous topic - Next topic

Hobbes

So I've been wondering if ESRGAN would be a useful tool for some very specific use cases. For example, I'm drawing rooms for a game at 320 x 200. One of these is a map screen, which currently includes a lot of manual anti-aliasing and it's beginning to look pretty O-K, in my opinion. I would love to use portions of that map for an intro sequence (potentially) but I would need to blow it up to a bigger resolution. Hence, ESRGAN.

I first came across ESRGAN being used for LucasArts upscaling here. This was a great starting point because the person doing this work also offered their models for download. My understanding is very, very basic at this point, but these models (.pth files) include the mathematical computations used to upscale.

Next I went to the GameUpscale Reddit and clicked into a recommended Wiki. This helped me to install ESRGAN, Git Bash & I ended up going with nmkd CupScale.

So having installed ESRGAN, CupScale + using the blog's provided pathing models, I had a working upscale system in place (Windows at this point, using my AMD 5700XT graphics card and a swanky i7 10700K). So it takes about 12 seconds to upscale an image... obviously ESRGAN is a massive rabbit hole with many, many different options, pathing models, etc, etc. But as a first attempt... I think it's pretty decent!

[imgzoom]https://www.jaapmarsman.com/img/dusk_orig.png[/imgzoom]
The original 320 x 200 image. Obviously a very pixelated affair since that's the only way this one-man-show can have any hope of ever finishing anything. ;)



My first attempt at upscaling with ESRGAN is now here. I went for a screen without characters in it and basic, big shapes and tried the CartoonPainting400000 model. I'm not too displeased with this image.

I'm well aware this forum post is almost a tutorial in itself (which I might write into the Wiki at some point ;)) but at this stage... I'm just curious to get some feedback. Has anyone ever played with ESRGAN before? How does this blown-up image look to you? I can see some usage for promotion/marketing materials (Itch.Io background wallpapers for example) but it's also just fun and geeky to play with this. So if I get bored at some point I might throw some more images in.

Character sprites are a different story, they all come out looking very misshapen, so some touch-up would be required there afterwards. But it does save on having to draw at 720p resolution which I would just not be able to do with my current skill levels.

Any thoughts / feedback / criticism, please drop a note below!

lorenzo

Very interesting and the result is not too bad! I think that with some manual adjustment you could also hide the "upscaled" feeling of some parts of the image. Lovely palette, by the way!

Hobbes

Hi lorenzo, so great to hear from you! Loved the work you did on Breakfast on Trappist-1 btw!

I'm going to continue to play with this so I'll probably update this thread in a little while. The colour palette, I can't really take credit for that one... taken directly from this Thimbleweed Park screenshot, I have to confess! :)

Babar

I see it behind your avatar as well!
The upscale looks cool, but I feel that it would only ever really work for a very specific aesthetic style (in contrast to the pixel art it could be generated from, which could be fairly varied).
The ultimate Professional Amateur

Now, with his very own game: Alien Time Zone

Creamy

#4
As a little experiment, I ran a batch of screenshots (PNG images) from AGS games through Real ESRGAN.

I thought it'd be interesting to share the results:

Apprentice 2:
Spoiler
Original:
ESRGAN:
[close]

Arden's Vale:
Spoiler
Original:
ESRGAN:
[close]

Bury me in the Sand:
Spoiler
Original:
ESRGAN:
[close]

The Excavation of Hob's Barrow:
Spoiler
Original:
ESRGAN:
[close]

Infinity String:
Spoiler
Original :
ESRGAN:
 
[close]

I Want Out:
Spoiler
Original :
ESRGAN :
[close]

Oh du lieber Augustin:
Spoiler
Original :

ESRGAN :
 
[close]

Ossuarium:
Spoiler
Original :

ESRGAN:
[close]

The Potion Master:
Spoiler
Original :

ESRGAN :
[close]

Saturday Night is the Loneliest Night of the Week:
Spoiler
Original:
ESRGAN:
[close]

Tales
Spoiler
Original:
ESRGAN:
[close]

Urban Witch Story:
Spoiler
Original:
ESRGAN:
[close]

Witch Lullaby:
Spoiler
Original :
ESRGAN:
[close]

Some styles fare better than others. The results vary depending on if you feed it an image at the original resolution or if it's already upscaled.
If you take Saturday is the loneliest night of the week , that's what I got when I fed it an upscaled 1593x1002 picture instead of the 320x200 one:
Spoiler
[close]
 

newwaveburritos

Oh wow that's amazing!  In my case (Saturday Night for those who may not know) the game looks like a dream or something.  It doesn't really work exactly but the results are really interesting.  I mean, it doesn't *not* work it just takes it in a direction I never really intended which is also okay.

Creamy

Yeah, all the details from the 1st picture are lost but the interpretation of the gradients somehow works - which is not the case with the upscaled image.

Also, your character looks like a Playmobil now (laugh)
 

SMF spam blocked by CleanTalk