Skip to content

Commit

Permalink
Refactor MochiVideoAPI initialization and update logging
Browse files Browse the repository at this point in the history
- Simplified the initialization of MochiSettings in the MochiVideoAPI class by removing specific parameters, allowing for default settings.
- Enhanced logging in combined_api.log to include multiple server start entries, improving traceability of server activity.

These changes aim to streamline the API initialization process and improve logging clarity for better monitoring of the video generation server.
  • Loading branch information
VikramxD committed Dec 23, 2024
1 parent 07754af commit 354cf81
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 6 deletions.
Binary file modified api/__pycache__/mochi_serve.cpython-310.pyc
Binary file not shown.
2 changes: 2 additions & 0 deletions api/logs/combined_api.log
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
2024-12-23 14:03:00.055 | INFO | __main__:main:220 - Starting Combined Video Generation Server
2024-12-23 14:58:34.285 | INFO | __main__:main:278 - Starting combined video generation server on port 8000
2024-12-23 15:06:16.741 | INFO | __main__:main:278 - Starting combined video generation server on port 8000
2024-12-23 15:07:54.567 | INFO | __main__:main:278 - Starting combined video generation server on port 8000
7 changes: 1 addition & 6 deletions api/mochi_serve.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,12 +134,7 @@ def setup(self, device: str) -> None:
Raises:
RuntimeError: On initialization failure
"""
self.settings = MochiSettings(
model_name="Mini-Mochi",
enable_vae_tiling=True,
enable_attention_slicing=True,
device=device
)
self.settings = MochiSettings()

logger.info("Initializing Mochi inference engine")
self.engine = MochiInference(self.settings)
Expand Down

0 comments on commit 354cf81

Please sign in to comment.