Skip to content

api_server issue #5

Description

@nogardvfx

Running the api_server on a Windows 11 machine. The apir_server loads fine. Was trying to do a text to image process and I noticed the "self.pipeline_t2i" part of the code is commented out. I uncommented it and reran the server and now it crashes with the following message. Tried to find out what to do, but I am not having much luck. Image to model works fine. Haven't tried generating a texture yet. Maybe I have overlooked something.

This is the line in the code that I uncommented:

    self.pipeline_t2i = HunyuanDiTPipeline(
        'Tencent-Hunyuan/HunyuanDiT-v1.1-Diffusers-Distilled',
        device=device

This is the error message:

2025-05-25 10:06:10 | INFO | hy3dgen.shapgen | Loading model from C:\Users\nogar.cache\huggingface\hub\models--tencent--Hunyuan3D-2mini\snapshots\d3318f050d91fe232038820bbbabeab95c0de14e\hunyuan3d-vae-v2-mini-turbo\model.fp16.safetensors
Loading pipeline components...: 0%| | 0/7 [00:00<?, ?it/s]
Loading pipeline components...: 29%|██████████████▊ | 2/7 [00:02<00:05, 1.00s/it]
Loading pipeline components...: 43%|██████████████████████▎ | 3/7 [00:02<00:02, 1.58it/s]
Loading pipeline components...: 43%|██████████████████████▎ | 3/7 [00:02<00:02, 1.41it/s]
2025-05-25 10:06:17 | ERROR | stderr |
2025-05-25 10:06:17 | ERROR | stderr | Traceback (most recent call last):
2025-05-25 10:06:17 | ERROR | stderr | File "E:\Maya_Hunyuan\Hunyuan3D-2\api_server.py", line 324, in
2025-05-25 10:06:17 | ERROR | stderr | worker = ModelWorker(model_path=args.model_path, device=args.device, enable_tex=args.enable_tex,
2025-05-25 10:06:17 | ERROR | stderr | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2025-05-25 10:06:17 | ERROR | stderr | File "E:\Maya_Hunyuan\Hunyuan3D-2\api_server.py", line 176, in init
2025-05-25 10:06:17 | ERROR | stderr | self.pipeline_t2i = HunyuanDiTPipeline(
2025-05-25 10:06:17 | ERROR | stderr | ^^^^^^^^^^^^^^^^^^^
2025-05-25 10:06:17 | ERROR | stderr | File "E:\Maya_Hunyuan\Hunyuan3D-2\hy3dgen\text2image.py", line 37, in init
2025-05-25 10:06:17 | ERROR | stderr | self.pipe = AutoPipelineForText2Image.from_pretrained(
2025-05-25 10:06:17 | ERROR | stderr | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2025-05-25 10:06:17 | ERROR | stderr | File "C:\Users\nogar\AppData\Local\Programs\Python\Python311\Lib\site-packages\huggingface_hub\utils_validators.py", line 114, in _inner_fn
2025-05-25 10:06:17 | ERROR | stderr | return fn(*args, **kwargs)
2025-05-25 10:06:17 | ERROR | stderr | ^^^^^^^^^^^^^^^^^^^
2025-05-25 10:06:17 | ERROR | stderr | File "C:\Users\nogar\AppData\Local\Programs\Python\Python311\Lib\site-packages\diffusers\pipelines\auto_pipeline.py", line 443, in from_pretrained
2025-05-25 10:06:17 | ERROR | stderr | return text_2_image_cls.from_pretrained(pretrained_model_or_path, **kwargs)
2025-05-25 10:06:17 | ERROR | stderr | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2025-05-25 10:06:17 | ERROR | stderr | File "C:\Users\nogar\AppData\Local\Programs\Python\Python311\Lib\site-packages\huggingface_hub\utils_validators.py", line 114, in _inner_fn
2025-05-25 10:06:17 | ERROR | stderr | return fn(*args, **kwargs)
2025-05-25 10:06:17 | ERROR | stderr | ^^^^^^^^^^^^^^^^^^^
2025-05-25 10:06:17 | ERROR | stderr | File "C:\Users\nogar\AppData\Local\Programs\Python\Python311\Lib\site-packages\diffusers\pipelines\pipeline_utils.py", line 961, in from_pretrained
2025-05-25 10:06:17 | ERROR | stderr | loaded_sub_model = load_sub_model(
2025-05-25 10:06:17 | ERROR | stderr | ^^^^^^^^^^^^^^^
2025-05-25 10:06:17 | ERROR | stderr | File "C:\Users\nogar\AppData\Local\Programs\Python\Python311\Lib\site-packages\diffusers\pipelines\pipeline_loading_utils.py", line 709, in load_sub_model
2025-05-25 10:06:17 | ERROR | stderr | raise ValueError(
2025-05-25 10:06:17 | ERROR | stderr | ValueError: The component <class 'transformers.models.t5.tokenization_t5._LazyModule.getattr..Placeholder'> of <class 'diffusers.pipelines.pag.pipeline_pag_hunyuandit.HunyuanDiTPAGPipeline'> cannot be loaded as it does not seem to have any of the loading methods defined in {'ModelMixin': ['save_pretrained', 'from_pretrained'], 'SchedulerMixin': ['save_pretrained', 'from_pretrained'], 'DiffusionPipeline': ['save_pretrained', 'from_pretrained'], 'OnnxRuntimeModel': ['save_pretrained', 'from_pretrained'], 'PreTrainedTokenizer': ['save_pretrained', 'from_pretrained'], 'PreTrainedTokenizerFast': ['save_pretrained', 'from_pretrained'], 'PreTrainedModel': ['save_pretrained', 'from_pretrained'], 'FeatureExtractionMixin': ['save_pretrained', 'from_pretrained'], 'ProcessorMixin': ['save_pretrained', 'from_pretrained'], 'ImageProcessingMixin': ['save_pretrained', 'from_pretrained'], 'ORTModule': ['save_pretrained', 'from_pretrained']}.

Thank you in advance.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions