{"record":{"id":"d3d2bba94a3dcac8","repo":"2noise/ChatTTS","slug":"total-number-of-hidden-layers-total-num-hidden-l","errorCode":null,"errorMessage":"Total number of hidden layers ({total_num_hidden_layers}) must be divisible by pipeline parallel size ({pipeline_parallel_size}).","messagePattern":"Total number of hidden layers \\((.+?)\\) must be divisible by pipeline parallel size \\((.+?)\\)\\.","errorType":"validation","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"ChatTTS/model/velocity/configs.py","lineNumber":219,"sourceCode":"        )\n\n    def verify_with_parallel_config(\n        self,\n        parallel_config: \"ParallelConfig\",\n    ) -> None:\n        total_num_attention_heads = self.hf_config.num_attention_heads\n        tensor_parallel_size = parallel_config.tensor_parallel_size\n        if total_num_attention_heads % tensor_parallel_size != 0:\n            raise ValueError(\n                f\"Total number of attention heads ({total_num_attention_heads})\"\n                \" must be divisible by tensor parallel size \"\n                f\"({tensor_parallel_size}).\"\n            )\n\n        total_num_hidden_layers = self.hf_config.num_hidden_layers\n        pipeline_parallel_size = parallel_config.pipeline_parallel_size\n        if total_num_hidden_layers % pipeline_parallel_size != 0:\n            raise ValueError(\n                f\"Total number of hidden layers ({total_num_hidden_layers}) \"\n                \"must be divisible by pipeline parallel size \"\n                f\"({pipeline_parallel_size}).\"\n            )\n\n    def get_sliding_window(self) -> Optional[int]:\n        return getattr(self.hf_config, \"sliding_window\", None)\n\n    def get_vocab_size(self) -> int:\n        return self.hf_config.vocab_size\n\n    def get_hidden_size(self) -> int:\n        return self.hf_config.hidden_size\n\n    def get_head_size(self) -> int:\n        # FIXME(woosuk): This may not be true for all models.\n        return self.hf_config.hidden_size // self.hf_config.num_attention_heads\n","sourceCodeStart":201,"sourceCodeEnd":237,"githubUrl":"https://github.com/2noise/ChatTTS/blob/77b89ee281cd479f5b1a787ada330dc975ca1f2a/ChatTTS/model/velocity/configs.py#L201-L237","documentation":"Error \"Total number of hidden layers ({total_num_hidden_layers}) must be divisible by pipeline parallel size ({pipeline_parallel_size}).\" thrown in 2noise/ChatTTS.","triggerScenarios":"Thrown at ChatTTS/model/velocity/configs.py:219 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"77b89ee281cd479f5b1a787ada330dc975ca1f2a","analyzedAt":"2026-08-26T17:48:24.233Z","schemaVersion":2},"datasetVersion":"2026-08-26T21:11:00.512Z"}