Spaces:
Runtime error
Runtime error
| import logging | |
| from lipnet import config | |
| from lipnet.model import LipReadingModel | |
| from lipnet.preprocessing import VideoPreprocessor | |
| from lipnet.ui import create_app | |
| logging.basicConfig( | |
| level=logging.INFO, | |
| format="%(asctime)s [%(levelname)s] %(name)s - %(message)s", | |
| ) | |
| logger = logging.getLogger(__name__) | |
| def main(): | |
| logger.info("Loading model and preprocessor...") | |
| model = LipReadingModel() | |
| preprocessor = VideoPreprocessor() | |
| demo = create_app(model=model, preprocessor=preprocessor) | |
| demo.launch( | |
| server_name="0.0.0.0", | |
| server_port=config.SERVER_PORT, | |
| share=config.SHARE_PUBLIC, | |
| ssr_mode=False, | |
| ) | |
| if __name__ == "__main__": | |
| main() | |