(
llm_args: LlmArgs,
workspace: Optional[str | tempfile.TemporaryDirectory] = None,
llm_build_stats: Optional['LlmBuildStats'] = None,
engine_dir: Optional[Path] = None,
)
| 860 | @print_traceback_on_error |
| 861 | @staticmethod |
| 862 | def _node_build_task( |
| 863 | llm_args: LlmArgs, |
| 864 | workspace: Optional[str | tempfile.TemporaryDirectory] = None, |
| 865 | llm_build_stats: Optional['LlmBuildStats'] = None, |
| 866 | engine_dir: Optional[Path] = None, |
| 867 | ): |
| 868 | if MPINodeState.is_initialized(): |
| 869 | raise RuntimeError("The MPI node is already initialized.") |
| 870 | |
| 871 | with ModelLoader(llm_args, |
| 872 | workspace=workspace, |
| 873 | llm_build_stats=llm_build_stats) as model_loader: |
| 874 | model_loader(engine_dir=engine_dir) |
| 875 | return model_loader.llm_build_stats.build_steps_info |
| 876 | |
| 877 | def save(self, engine_dir: Path): |
| 878 | # copy the engine directory to the target directory |
nothing calls this directly
no test coverage detected