AnotherMike

Member
Mar 26, 2020
142
116
What model and params/resolution did you use in the screenshot ?
Not 100% sure since I've long since then messed around more with the paramteers, but it was either Gonzales_v8_newCocktail or Gonzales-NSFW-PonyV1/V2-DMD they're both very fast Pony models, it would've been around 8-12 steps, cfg scale of around 1.3-1.5 and 0.3-0.35 noise.

Edit, no idea of the resolution, either 512x768 or 768x1152 for the resolution.

Edit2: and LCM as the sampler
 
  • Like
Reactions: ycbelane

4Hephaestus4

New Member
Aug 22, 2023
4
0
Here's a new dev build, with all the working Mods besides the AI image gen (VT & CT, RealPorn, moresomes, Zenpak, Kaden and Kina mods) PC/Linux.

Mega

The same problem is still present
```
I'm sorry, but an uncaught exception occurred.
While running game code:
File "renpy/common/000statements.rpy", line 671, in execute_call_screen
NameError: name 'softkey_not_visible' is not defined
-- Full Traceback ------------------------------------------------------------
Full traceback:
File "mods/LR2R/VT_Start.rpyc", line 473, in script
File "renpy/ast.py", line 1974, in execute
File "renpy/ast.py", line 1953, in call
File "renpy/statements.py", line 374, in call
File "renpy/common/000statements.rpy", line 671, in execute_call_screen
File "renpy/exports\statementexports.py", line 345, in call_screen
File "renpy/ui.py", line 301, in interact
File "renpy/display\core.py", line 2259, in interact
File "renpy/display\core.py", line 3082, in interact_core
File "renpy/display\core.py", line 1788, in event_wait
NameError: name 'softkey_not_visible' is not defined
```
 
Jun 28, 2017
8
3
Thank you so much for this! it worked amazingly, using img2img and a low noise value really does wonders for keeping things appearances consistent and the poses "sane" while still getting some nice improvements.

I figured I'd do my part and help out a bit as well by trying to remove the square background, which proved to be both easier and more annoying than I thought, mostly because the way I started doing it (using the rembg extension) just refused to work, but after I finally switched to another extension instead, it was incredibly simple so now I'm beating myself up over all the hours I wasted working on the wrong solution :)


View attachment 4895044

I've attached my modified sdcclient_ren.py file, but all I did was literally to add this line to the API-request:
'"script_args": [true, false, false, "#000000", false], "script_name": "abg remover", ' + \

There's no settings to turn it off or anything, so if anyone tries to use this, you have to make sure that the ABG extension is installed.

View attachment 4895045
Can you tell us what model you are using here?

The background remover script is not working. Upon further inspection, it is because the background on the generated image is 020202, 030303, 020203, basically any color CLOSE to 000000 except for 000000.

Because of the way AI works, this has to be because of the way it generate the new image. So, either you have a model that handles it well, or you have figured out how to run the ABG on the input image. Can you elaborate?
 

ycbelane

New Member
Jul 28, 2023
12
33
Sadly this version isn't without issues either, if the person is wearing black, they can sometimes become transparent. I've experimented with changing the saved image to have a purple background instead, seems less likely to get mixed up with the color of clothing, but that leaves people with a purple halo instead. Honestly not sure which version is better :)

for purple halo-version, it's easy enough to change from


Python:
       image = person.build_person_displayable(position, emotion, special_modifier, lighting)
       
       surface = renpy.render_to_surface(image).convert()
to
Python:
        image = person.build_person_displayable(position, emotion, special_modifier, lighting)
       
        newimage = Composite(position_size_dict.get(position),
            (0,0), Solid("#ff00ff"),
            (0,0),image)
   
        surface = renpy.render_to_surface(newimage).convert()
in the SDClient_ren.py file. Or you could just change #ff00ff to what ever color code you prefer, guess you could even use the persons designated color to give all of them a "personalized" halo similar to the original aura-thingy :) Then it'd be something like this instead:
Python:
        image = person.build_person_displayable(position, emotion, special_modifier, lighting)
       
        newimage = Composite(position_size_dict.get(position),
            (0,0), Solid(person.get_display_colour_code()),
            (0,0),image)
   
        surface = renpy.render_to_surface(newimage).convert()
But I guess, depending on what display color they have, you'd once again increase the risk of the background color melting into the color of their clothing, causing the background remover to get confused.

I really wish I could've gotten rembg to work since that seems to be a more flexible option for background-removal than the what I'm using now, but while rembg worked on it's own, combining it with ADetailer made it break (rembg would always be called first and remove the background and then adetailer would run after that and mess things up by removing the alpha channel and creating a new, wonky-looking, background instead).
Ok, I got it to work, but had some issue in SD Forge - turns out "Write infotext to metadata of the generated image" needs to be turned off in SD Forge settings, as it messes with the alpha channel of the output image. Also the "File format for images" has to be set to "png"

Have you looked into using Layer Diffusion ( ) to do the transparency ? Looks like it can do it in latent space, and quite powerful - not sure if there are any limitations in terms of models it can work with, etc.
 

AnotherMike

Member
Mar 26, 2020
142
116
Can you tell us what model you are using here?

The background remover script is not working. Upon further inspection, it is because the background on the generated image is 020202, 030303, 020203, basically any color CLOSE to 000000 except for 000000.

Because of the way AI works, this has to be because of the way it generate the new image. So, either you have a model that handles it well, or you have figured out how to run the ABG on the input image. Can you elaborate?
I've tried it with several different models and it's worked with all the ones I've tried, the background remover script doesn't remove any specific color, it can even remove the background if it's a "real" background image, it's been removing everything fine(ish) for everything I've tried. Are you using Automatic1111 or forge or something else?

I'm running this with an automatic1111 installation so can't really comment on other options but If you're using forge, it might be worth having a look a ycbelane's latest response:

Ok, I got it to work, but had some issue in SD Forge - turns out "Write infotext to metadata of the generated image" needs to be turned off in SD Forge settings, as it messes with the alpha channel of the output image. Also the "File format for images" has to be set to "png"

Have you looked into using Layer Diffusion ( ) to do the transparency ? Looks like it can do it in latent space, and quite powerful - not sure if there are any limitations in terms of models it can work with, etc.
i did see something about Layer Diffusion but all examples I found on it was only in forge, I didn't find anything for automatic1111. Since I already have ComfyUI and Automatic1111 installed I had hoped to find something that works with what I have installed and not have to install yet another way of running SD, I'm starting to run low on disk space :)
 

slobber

Member
May 19, 2019
199
208
is it possible to plug the github into ai and have it translate that into a descending log from most recent changes to least recent? :eek:
 

Deane9850

Active Member
Jan 4, 2018
592
605
The same problem is still present
```
I'm sorry, but an uncaught exception occurred.
While running game code:
File "renpy/common/000statements.rpy", line 671, in execute_call_screen
NameError: name 'softkey_not_visible' is not defined
-- Full Traceback ------------------------------------------------------------
Full traceback:
File "mods/LR2R/VT_Start.rpyc", line 473, in script
File "renpy/ast.py", line 1974, in execute
File "renpy/ast.py", line 1953, in call
File "renpy/statements.py", line 374, in call
File "renpy/common/000statements.rpy", line 671, in execute_call_screen
File "renpy/exports\statementexports.py", line 345, in call_screen
File "renpy/ui.py", line 301, in interact
File "renpy/display\core.py", line 2259, in interact
File "renpy/display\core.py", line 3082, in interact_core
File "renpy/display\core.py", line 1788, in event_wait
NameError: name 'softkey_not_visible' is not defined
```
This is joiplay issue, or whatever you use to run the game on ur mobile, not the game.
 
  • Like
Reactions: ibnarabi
Jun 28, 2017
8
3
I've tried it with several different models and it's worked with all the ones I've tried, the background remover script doesn't remove any specific color, it can even remove the background if it's a "real" background image, it's been removing everything fine(ish) for everything I've tried. Are you using Automatic1111 or forge or something else?

I'm running this with an automatic1111 installation so can't really comment on other options but If you're using forge, it might be worth having a look a ycbelane's latest response:



i did see something about Layer Diffusion but all examples I found on it was only in forge, I didn't find anything for automatic1111. Since I already have ComfyUI and Automatic1111 installed I had hoped to find something that works with what I have installed and not have to install yet another way of running SD, I'm starting to run low on disk space :)
It turns out this was all user error on my part. Disregard.
 
Last edited:

Pornocide

New Member
May 21, 2021
1
0
The same problem is still present
```
I'm sorry, but an uncaught exception occurred.
While running game code:
File "renpy/common/000statements.rpy", line 671, in execute_call_screen
NameError: name 'softkey_not_visible' is not defined
-- Full Traceback ------------------------------------------------------------
Full traceback:
File "mods/LR2R/VT_Start.rpyc", line 473, in script
File "renpy/ast.py", line 1974, in execute
File "renpy/ast.py", line 1953, in call
File "renpy/statements.py", line 374, in call
File "renpy/common/000statements.rpy", line 671, in execute_call_screen
File "renpy/exports\statementexports.py", line 345, in call_screen
File "renpy/ui.py", line 301, in interact
File "renpy/display\core.py", line 2259, in interact
File "renpy/display\core.py", line 3082, in interact_core
File "renpy/display\core.py", line 1788, in event_wait
NameError: name 'softkey_not_visible' is not defined
```
You'll need to downgrade your Renpy plugin to 8.3.2. Make sure to delete 8.3.3 plugin from your APPS and reinstall 8.3.2.
 

theman

New Member
Jul 12, 2017
3
0
odd the new download im getting
Code:
I'm sorry, but an uncaught exception occurred.

While running game code:
TypeError: __init__() takes from 3 to 4 positional arguments but 6 were given

-- Full Traceback ------------------------------------------------------------

Full traceback:
  File "game/people/Ashley/ashley_story_ren.py", line 28, in script
    init 5 python:
  File "F:\MEGA\LabRats2-Reformulate-2025.04-market\renpy\ast.py", line 834, in execute
    renpy.python.py_exec_bytecode(self.code.bytecode, self.hide, store=self.store)
  File "F:\MEGA\LabRats2-Reformulate-2025.04-market\renpy\python.py", line 1184, in py_exec_bytecode
    exec(bytecode, globals, locals)
  File "game/people/Ashley/ashley_story_ren.py", line 253, in <module>
    ashley_story_path_submission = Story_Path("Submission",
TypeError: __init__() takes from 3 to 4 positional arguments but 6 were given

Ren'Py 8.3.6.25022803
Lab Rats 2 - Down to Business 2025.07-betaVTMod4.0.31
 

Phoexist

Member
Mar 11, 2020
496
551
odd the new download im getting
Code:
I'm sorry, but an uncaught exception occurred.

While running game code:
TypeError: __init__() takes from 3 to 4 positional arguments but 6 were given

-- Full Traceback ------------------------------------------------------------

Full traceback:
  File "game/people/Ashley/ashley_story_ren.py", line 28, in script
    init 5 python:
  File "F:\MEGA\LabRats2-Reformulate-2025.04-market\renpy\ast.py", line 834, in execute
    renpy.python.py_exec_bytecode(self.code.bytecode, self.hide, store=self.store)
  File "F:\MEGA\LabRats2-Reformulate-2025.04-market\renpy\python.py", line 1184, in py_exec_bytecode
    exec(bytecode, globals, locals)
  File "game/people/Ashley/ashley_story_ren.py", line 253, in <module>
    ashley_story_path_submission = Story_Path("Submission",
TypeError: __init__() takes from 3 to 4 positional arguments but 6 were given

Ren'Py 8.3.6.25022803
Lab Rats 2 - Down to Business 2025.07-betaVTMod4.0.31
Did you use Unren to decompile the AIO version? Only time I've ever seen that kind of error. Unren doesn't work on this game. (At least all the versions of unren I have seen). Best to get the source code directly from git if thats what you want.
 
4.60 star(s) 73 Votes