Improved installation and inference from python function (rather than CLI)#156
Open
rb-synth wants to merge 10 commits intoLightricks:mainfrom
Open
Improved installation and inference from python function (rather than CLI)#156rb-synth wants to merge 10 commits intoLightricks:mainfrom
rb-synth wants to merge 10 commits intoLightricks:mainfrom
Conversation
ybitterman
requested changes
May 15, 2025
| @@ -154,6 +154,9 @@ dmypy.json | |||
| # Cython debug symbols | |||
Collaborator
There was a problem hiding this comment.
Thanks for contributing to the package!
General comment:
Please use commit messages that match the regex pattern: .: [A-Z].
| "einops", | ||
| "timm", | ||
| "imageio", | ||
| "timm" |
Collaborator
There was a problem hiding this comment.
Please squash commit bd56660 into the first commit of the PR
| frame_rate: int = 30 | ||
| device: Optional[str] = None | ||
| pipeline_config: str = "configs/ltxv-13b-0.9.7-dev.yaml" | ||
| pipeline_config: str = str(CONFIG_PATH / "ltxv-13b-0.9.7-dev.yaml") |
Collaborator
There was a problem hiding this comment.
The default should be ltxv-13b-0.9.7-distilled.yaml
| # create env | ||
| python -m venv env | ||
| source env/bin/activate | ||
| python -m pip install -e .\[inference-script\] |
Collaborator
There was a problem hiding this comment.
Please fix the Readme to point to the new location of inference.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
src, so thatpip install -e .can be used (by updatingpyproject.toml).from ltx_video.inference import infer.def infersignature the same defaults as argparse so that it can be used as a function from elsewhere.models_dirargument exposed (so can be set to None and use hf default)src/ltx_videoso that it will be included with pip install. Path defaults to relative toinference.py.Local install:
Or add as dependency to another package (in e.g.,
requirements.txt):And run with:
from ltx_video.inference import infer infer(prompt="something")