Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
videogen
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexlab
videogen
Commits
df41bc66
Commit
df41bc66
authored
Feb 28, 2026
by
Stefy Lanza (nextime / spora )
Browse files
Options
Browse Files
Download
Plain Diff
Merge experimental: Add --invert_colors flag for color inversion control
parents
13698a69
db0f50f6
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
6 deletions
+13
-6
SKILL.md
SKILL.md
+8
-1
videogen.py
videogen.py
+5
-5
No files found.
SKILL.md
View file @
df41bc66
...
@@ -535,7 +535,14 @@ Auto mode detects NSFW content automatically. For explicit requests:
...
@@ -535,7 +535,14 @@ Auto mode detects NSFW content automatically. For explicit requests:
python3 videogen
--model
<model>
--prompt
"<prompt>"
--no_filter
python3 videogen
--model
<model>
--prompt
"<prompt>"
--no_filter
```
```
### 5. Reproducibility
### 5. Color Inversion
Some models (particularly certain LoRA adapters) may produce inverted colors. Fix this with:
```
bash
python3 videogen
--model
wan2_2_i2v_general_nsfw_lora
--image
input.png
--prompt
"..."
--invert_colors
```
### 6. Reproducibility
Always capture and store the seed for reproducibility:
Always capture and store the seed for reproducibility:
```
bash
```
bash
...
...
videogen.py
View file @
df41bc66
...
@@ -10238,11 +10238,9 @@ def main(args):
...
@@ -10238,11 +10238,9 @@ def main(args):
# Convert from [-1, 1] to [0, 1]
# Convert from [-1, 1] to [0, 1]
frames
=
(
frames
+
1.0
)
/
2.0
frames
=
(
frames
+
1.0
)
/
2.0
# Check if colors appear inverted (mostly dark images mean inverted)
# Check if colors should be inverted (user-specified via --invert_colors)
# Inverted images have mean > 0.5 when they should be < 0.5
if
args
.
invert_colors
:
mean_val
=
np
.
mean
(
frames
)
print
(
f
" 🎨 Inverting colors as requested (--invert_colors)..."
)
if
mean_val
>
0.7
:
# Likely inverted
print
(
f
" ⚠️ Detected inverted colors (mean={mean_val:.2f}), correcting..."
)
frames
=
1.0
-
frames
frames
=
1.0
-
frames
# Now convert from [0, 1] to [0, 255]
# Now convert from [0, 1] to [0, 255]
...
@@ -10480,6 +10478,8 @@ List TTS voices:
...
@@ -10480,6 +10478,8 @@ List TTS voices:
help
=
"Directory for output files (overrides --output path)"
)
help
=
"Directory for output files (overrides --output path)"
)
parser
.
add_argument
(
"--seed"
,
type
=
int
,
default
=-
1
)
parser
.
add_argument
(
"--seed"
,
type
=
int
,
default
=-
1
)
parser
.
add_argument
(
"--no_filter"
,
action
=
"store_true"
)
parser
.
add_argument
(
"--no_filter"
,
action
=
"store_true"
)
parser
.
add_argument
(
"--invert_colors"
,
action
=
"store_true"
,
help
=
"Invert video colors after generation (fixes inverted output from some models)"
)
parser
.
add_argument
(
"--upscale"
,
action
=
"store_true"
)
parser
.
add_argument
(
"--upscale"
,
action
=
"store_true"
)
parser
.
add_argument
(
"--upscale_factor"
,
type
=
float
,
default
=
2.0
)
parser
.
add_argument
(
"--upscale_factor"
,
type
=
float
,
default
=
2.0
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment