8000 Florence2 模型加载器 'NoneType' object has no attribute 'get' · Issue #161 · kijai/ComfyUI-Florence2 · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Florence2 模型加载器 'NoneType' object has no attribute 'get' #161
Open
@ok1248

Description

@ok1248

ComfyUI Error Report

Error Details

  • Node ID: 12
  • Node Type: Florence2ModelLoader
  • Exception Type: AttributeError
  • Exception Message: 'NoneType' object has no attribute 'get'

Stack Trace

  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 349, in execute
    output_data, output_ui, has_subgraph = get_output_data(obj, input_data_all, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
                                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 224, in get_output_data
    return_values = _map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 196, in _map_node_over_list
    process_inputs(input_dict, i)

  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 185, in process_inputs
    results.append(getattr(obj, func)(**inputs))
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "D:\ComfyUI-aki-v1.6\ComfyUI\custom_nodes\ComfyUI-Florence2\nodes.py", line 251, in loadmodel
    model = AutoModelForCausalLM.from_pretrained(model_path, attn_implementation=attention, torch_dtype=dtype,trust_remote_code=True).to(offload_device)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "D:\ComfyUI-aki-v1.6\python\Lib\site-packages\transformers\models\auto\auto_factory.py", line 559, in from_pretrained
    return model_class.from_pretrained(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  File "D:\ComfyUI-aki-v1.6\python\Lib\site-packages\transformers\modeling_utils.py", line 4013, in from_pretrained
    if metadata.get("format") == "pt":
       ^^^^^^^^^^^^

System Information

  • ComfyUI Version: 0.3.40
  • Arguments: D:\ComfyUI-aki-v1.6\ComfyUI\main.py --auto-launch --preview-method auto --disable-cuda-malloc --fast
  • OS: nt
  • Python Version: 3.11.9 (tags/v3.11.9:de54cf5, Apr 2 2024, 10:12:12) [MSC v.1938 64 bit (AMD64)]
  • Embedded Python: false
  • PyTorch Version: 2.5.1+cu124

Devices

  • Name: cuda:0 NVIDIA GeForce RTX 4060 Laptop GPU : cudaMallocAsync
    • Type: cuda
    • VRAM Total: 8585216000
    • VRAM Free: 7443841024
    • Torch VRAM Total: 0
    • Torch VRAM Free: 0

Logs

2025-06-05T20:15:02.924414 - FETCH ComfyRegistry Data: 45/882025-06-05T20:15:02.924414 - 
2025-06-05T20:15:03.425522 - Use Proxy:2025-06-05T20:15:03.425522 -  2025-06-05T20:15:03.425522 - http://127.0.0.1:78902025-06-05T20:15:03.425522 - 
2025-06-05T20:15:04.300259 - Use Proxy:2025-06-05T20:15:04.300259 -  2025-06-05T20:15:04.300259 - http://127.0.0.1:78902025-06-05T20:15:04.300259 - 
2025-06-05T20:15:05.253202 - Use Proxy:2025-06-05T20:15:05.253202 -  2025-06-05T20:15:05.253202 - http://127.0.0.1:78902025-06-05T20:15:05.253202 - 
2025-06-05T20:15:06.106797 - Use Proxy:2025-06-05T20:15:06.106797 -  2025-06-05T20:15:06.106797 - http://127.0.0.1:78902025-06-05T20:15:06.106797 - 
2025-06-05T20:15:07.006963 - Use Proxy:2025-06-05T20:15:07.006963 -  2025-06-05T20:15:07.006963 - http://127.0.0.1:78902025-06-05T20:15:07.006963 - 
2025-06-05T20:15:07.352844 - FETCH ComfyRegistry Data: 50/882025-06-05T20:15:07.353182 - 
2025-06-05T20:15:07.853791 - Use Proxy:2025-06-05T20:15:07.853791 -  2025-06-05T20:15:07.853791 - http://127.0.0.1:78902025-06-05T20:15:07.853791 - 
2025-06-05T20:15:08.786680 - Use Proxy:2025-06-05T20:15:08.786680 -  2025-06-05T20:15:08.786680 - http://127.0.0.1:78902025-06-05T20:15:08.786680 - 
2025-06-05T20:15:09.659337 - Use Proxy:2025-06-05T20:15:09.659337 -  2025-06-05T20:15:09.659337 - http://127.0.0.1:78902025-06-05T20:15:09.659337 - 
2025-06-05T20:15:10.572931 - Use Proxy:2025-06-05T20:15:10.572931 -  2025-06-05T20:15:10.572931 - http://127.0.0.1:78902025-06-05T20:15:10.572931 - 
2025-06-05T20:15:11.582927 - Use Proxy:2025-06-05T20:15:11.582927 -  2025-06-05T20:15:11.582927 - http://127.0.0.1:78902025-06-05T20:15:11.582927 - 
2025-06-05T20:15:11.961191 - FETCH ComfyRegistry Data: 55/882025-06-05T20:15:11.961191 - 
2025-06-05T20:15:12.462865 - Use Proxy:2025-06-05T20:15:12.462865 -  2025-06-05T20:15:12.462865 - http://127.0.0.1:78902025-06-05T20:15:12.462865 - 
2025-06-05T20:15:13.323249 - Use Proxy:2025-06-05T20:15:13.323249 -  2025-06-05T20:15:13.323249 - http://127.0.0.1:78902025-06-05T20:15:13.323249 - 
2025-06-05T20:15:14.187989 - Use Proxy:2025-06-05T20:15:14.187989 -  2025-06-05T20:15:14.187989 - http://127.0.0.1:78902025-06-05T20:15:14.187989 - 
2025-06-05T20:15:15.183984 - Use Proxy:2025-06-05T20:15:15.183984 -  2025-06-05T20:15:15.183984 - http://127.0.0.1:78902025-06-05T20:15:15.183984 - 
2025-06-05T20:15:16.183304 - Use Proxy:2025-06-05T20:15:16.183304 -  2025-06-05T20:15:16.183304 - http://127.0.0.1:78902025-06-05T20:15:16.183304 - 
2025-06-05T20:15:16.688453 - FETCH ComfyRegistry Data: 60/882025-06-05T20:15:16.689480 - 
2025-06-05T20:15:17.189625 - Use Proxy:2025-06-05T20:15:17.190160 -  2025-06-05T20:15:17.190160 - http://127.0.0.1:78902025-06-05T20:15:17.190160 - 
2025-06-05T20:15:18.067927 - Use Proxy:2025-06-05T20:15:18.067927 -  2025-06-05T20:15:18.067927 - http://127.0.0.1:78902025-06-05T20:15:18.067927 - 
2025-06-05T20:15:18.956939 - Use Proxy:2025-06-05T20:15:18.956939 -  2025-06-05T20:15:18.956939 - http://127.0.0.1:78902025-06-05T20:15:18.956939 - 
2025-06-05T20:15:19.974685 - Use Proxy:2025-06-05T20:15:19.975685 -  2025-06-05T20:15:19.975685 - http://127.0.0.1:78902025-06-05T20:15:19.975685 - 
2025-06-05T20:15:20.836672 - Use Proxy:2025-06-05T20:15:20.836672 -  2025-06-05T20:15:20.836672 - http://127.0.0.1:78902025-06-05T20:15:20.836672 - 
2025-06-05T20:15:21.201240 - FETCH ComfyRegistry Data: 65/882025-06-05T20:15:21.201240 - 
2025-06-05T20:15:21.702247 - Use Proxy:2025-06-05T20:15:21.702247 -  2025-06-05T20:15:21.702247 - http://127.0.0.1:78902025-06-05T20:15:21.702247 - 
2025-06-05T20:15:22.598467 - Use Proxy:2025-06-05T20:15:22.598467 -  2025-06-05T20:15:22.598467 - http://127.0.0.1:78902025-06-05T20:15:22.598467 - 
2025-06-05T20:15:23.450611 - Use Proxy:2025-06-05T20:15:23.450611 -  2025-06-05T20:15:23.451626 - http://127.0.0.1:78902025-06-05T20:15:23.451626 - 
2025-06-05T20:15:24.375447 - Use Proxy:2025-06-05T20:15:24.375447 -  2025-06-05T20:15:24.375447 - http://127.0.0.1:78902025-06-05T20:15:24.375447 - 
2025-06-05T20:15:25.258353 - Use Proxy:2025-06-05T20:15:25.258353 -  2025-06-05T20:15:25.258353 - http://127.0.0.1:78902025-06-05T20:15:25.258353 - 
2025-06-05T20:15:25.708347 - FETCH ComfyRegistry Data: 70/882025-06-05T20:15:25.708347 - 
2025-06-05T20:15:26.209237 - Use Proxy:2025-06-05T20:15:26.209237 -  2025-06-05T20:15:26.209237 - http://127.0.0.1:78902025-06-05T20:15:26.209237 - 
2025-06-05T20:15:27.081266 - Use Proxy:2025-06-05T20:15:27.081266 -  2025-06-05T20:15:27.081266 - http://127.0.0.1:78902025-06-05T20:15:27.081266 - 
2025-06-05T20:15:28.370891 - Use Proxy:2025-06-05T20:15:28.370891 -  2025-06-05T20:15:28.370891 - http://127.0.0.1:78902025-06-05T20:15:28.370891 - 
2025-06-05T20:15:29.251642 - Use Proxy:2025-06-05T20:15:29.251642 -  2025-06-05T20:15:29.251642 - http://127.0.0.1:78902025-06-05T20:15:29.251642 - 
2025-06-05T20:15:30.173606 - Use Proxy:2025-06-05T20:15:30.173606 -  2025-06-05T20:15:30.173606 - http://127.0.0.1:78902025-06-05T20:15:30.173606 - 
2025-06-05T20:15:30.640223 - FETCH ComfyRegistry Data: 75/882025-06-05T20:15:30.640223 - 
2025-06-05T20:15:31.141308 - Use Proxy:2025-06-05T20:15:31.141308 -  2025-06-05T20:15:31.141308 - http://127.0.0.1:78902025-06-05T20:15:31.141308 - 
2025-06-05T20:15:31.979726 - Use Proxy:2025-06-05T20:15:31.979726 -  2025-06-05T20:15:31.979726 - http://127.0.0.1:78902025-06-05T20:15:31.979726 - 
2025-06-05T20:15:33.054524 - Use Proxy:2025-06-05T20:15:33.054524 -  2025-06-05T20:15:33.054524 - http://127.0.0.1:78902025-06-05T20:15:33.054524 - 
2025-06-05T20:15:34.050014 - Use Proxy:2025-06-05T20:15:34.050014 -  2025-06-05T20:15:34.050014 - http://127.0.0.1:78902025-06-05T20:15:34.050014 - 
2025-06-05T20:15:34.976601 - Use Proxy:2025-06-05T20:15:34.976601 -  2025-06-05T20:15:34.976601 - http://127.0.0.1:78902025-06-05T20:15:34.976601 - 
2025-06-05T20:15:35.920451 - FETCH ComfyRegistry Data: 80/882025-06-05T20:15:35.920451 - 
2025-06-05T20:15:36.426938 - Use Proxy:2025-06-05T20:15:36.426938 -  2025-06-05T20:15:36.426938 - http://127.0.0.1:78902025-06-05T20:15:36.426938 - 
2025-06-05T20:15:37.265771 - Use Proxy:2025-06-05T20:15:37.265771 -  2025-06-05T20:15:37.265771 - http://127.0.0.1:78902025-06-05T20:15:37.265771 - 
2025-06-05T20:15:38.083330 - Use Proxy:2025-06-05T20:15:38.083330 
6DB6
-  2025-06-05T20:15:38.083330 - http://127.0.0.1:78902025-06-05T20:15:38.083330 - 
2025-06-05T20:15:38.922953 - Use Proxy:2025-06-05T20:15:38.922953 -  2025-06-05T20:15:38.922953 - http://127.0.0.1:78902025-06-05T20:15:38.922953 - 
2025-06-05T20:15:39.755924 - Use Proxy:2025-06-05T20:15:39.755924 -  2025-06-05T20:15:39.755924 - http://127.0.0.1:78902025-06-05T20:15:39.755924 - 
2025-06-05T20:15:40.166116 - FETCH ComfyRegistry Data: 85/882025-06-05T20:15:40.166116 - 
2025-06-05T20:15:40.670256 - Use Proxy:2025-06-05T20:15:40.670256 -  2025-06-05T20:15:40.670256 - http://127.0.0.1:78902025-06-05T20:15:40.670256 - 
2025-06-05T20:15:41.577562 - Use Proxy:2025-06-05T20:15:41.577562 -  2025-06-05T20:15:41.577562 - http://127.0.0.1:78902025-06-05T20:15:41.577562 - 
2025-06-05T20:15:42.586580 - Use Proxy:2025-06-05T20:15:42.586580 -  2025-06-05T20:15:42.586580 - http://127.0.0.1:78902025-06-05T20:15:42.586580 - 
2025-06-05T20:15:43.414228 - FETCH ComfyRegistry Data [DONE]2025-06-05T20:15:43.414228 - 
2025-06-05T20:15:43.731550 - [ComfyUI-Manager] default cache updated: https://api.comfy.org/nodes
2025-06-05T20:15:43.840164 - FETCH DATA from: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/custom-node-list.json2025-06-05T20:15:43.840164 - 2025-06-05T20:15:43.841168 - Use Proxy:2025-06-05T20:15:43.841168 -  2025-06-05T20:15:43.841168 - http://127.0.0.1:78902025-06-05T20:15:43.841168 - 
2025-06-05T20:15:44.356851 -  [DONE]2025-06-05T20:15:44.356851 - 
2025-06-05T20:15:44.474420 - [ComfyUI-Manager] All startup tasks have been completed.
2025-06-05T20:16:02.997493 - got prompt
2025-06-05T20:16:03.010790 - Loading model from D:\ComfyUI-aki-v1.6\ComfyUI\models\LLM\Florence-2-base2025-06-05T20:16:03.010790 - 
2025-06-05T20:16:03.010790 - Florence2 using sdpa for attention2025-06-05T20:16:03.010790 - 
2025-06-05T20:16:03.158080 - No flash_attn import to remove2025-06-05T20:16:03.158080 - 
2025-06-05T20:16:03.172068 - !!! Exception during processing !!! 'NoneType' object has no attribute 'get'
2025-06-05T20:16:03.172068 - Traceback (most recent call last):
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 349, in execute
    output_data, output_ui, has_subgraph = get_output_data(obj, input_data_all, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
                                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 224, in get_output_data
    return_values = _map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 196, in _map_node_over_list
    process_inputs(input_dict, i)
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 185, in process_inputs
    results.append(getattr(obj, func)(**inputs))
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\ComfyUI\custom_nodes\ComfyUI-Florence2\nodes.py", line 251, in loadmodel
    model = AutoModelForCausalLM.from_pretrained(model_path, attn_implementation=attention, torch_dtype=dtype,trust_remote_code=True).to(offload_device)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\python\Lib\site-packages\transformers\models\auto\auto_factory.py", line 559, in from_pretrained
    return model_class.from_pretrained(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\python\Lib\site-packages\transformers\modeling_utils.py", line 4013, in from_pretrained
    if metadata.get("format") == "pt":
       ^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'get'

2025-06-05T20:16:03.172068 - Prompt executed in 0.18 seconds
2025-06-05T20:19:16.291064 - got prompt
2025-06-05T20:19:16.300273 - Loading model from D:\ComfyUI-aki-v1.6\ComfyUI\models\LLM\Florence-2-base2025-06-05T20:19:16.300273 - 
2025-06-05T20:19:16.300273 - Florence2 using sdpa for attention2025-06-05T20:19:16.300273 - 
2025-06-05T20:19:16.338268 - No flash_attn import to remove2025-06-05T20:19:16.338268 - 
2025-06-05T20:19:16.379952 - !!! Exception during processing !!! 'NoneType' object has no attribute 'get'
2025-06-05T20:19:16.390227 - Traceback (most recent call last):
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 349, in execute
    output_data, output_ui, has_subgraph = get_output_data(obj, input_data_all, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
                                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 224, in get_output_data
    return_values = _map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 196, in _map_node_over_list
    process_inputs(input_dict, i)
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 185, in process_inputs
    results.append(getattr(obj, func)(**inputs))
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\ComfyUI\custom_nodes\ComfyUI-Florence2\nodes.py", line 251, in loadmodel
    model = AutoModelForCausalLM.from_pretrained(model_path, attn_implementation=attention, torch_dtype=dtype,trust_remote_code=True).to(offload_device)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\python\Lib\site-packages\transformers\models\auto\auto_factory.py", line 559, in from_pretrained
    return model_class.from_pretrained(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\python\Lib\site-packages\transformers\modeling_utils.py", line 4013, in from_pretrained
    if metadata.get("format") == "pt":
       ^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'get'

2025-06-05T20:19:16.394259 - Prompt executed in 0.10 seconds
2025-06-05T20:19:45.505312 - got prompt
2025-06-05T20:19:45.514408 - Loading model from D:\ComfyUI-aki-v1.6\ComfyUI\models\LLM\Florence-2-base2025-06-05T20:19:45.514408 - 
2025-06-05T20:19:45.514408 - Florence2 using sdpa for attention2025-06-05T20:19:45.514408 - 
2025-06-05T20:19:45.540458 - No flash_attn import to remove2025-06-05T20:19:45.540458 - 
2025-06-05T20:19:45.560199 - !!! Exception during processing !!! 'NoneType' object has no attribute 'get'
2025-06-05T20:19:45.563555 - Traceback (most recent call last):
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 349, in execute
    output_data, output_ui, has_subgraph = get_output_data(obj, input_data_all, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
                                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 224, in get_output_data
    return_values = _map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 196, in _map_node_over_list
    process_inputs(input_dict, i)
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 185, in process_inputs
    results.append(getattr(obj, func)(**inputs))
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\ComfyUI\custom_nodes\ComfyUI-Florence2\nodes.py", line 251, in loadmodel
    model = AutoModelForCausalLM.from_pretrained(model_path, attn_implementation=attention, torch_dtype=dtype,trust_remote_code=True).to(offload_device)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\python\Lib\site-packages\transformers\models\auto\auto_factory.py", line 559, in from_pretrained
    return model_class.from_pretrained(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\python\Lib\site-packages\transformers\modeling_utils.py", line 4013, in from_pretrained
    if metadata.get("format") == "pt":
       ^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'get'

2025-06-05T20:19:45.567290 - Prompt executed in 0.06 seconds
2025-06-05T20:23:57.830361 - Use Proxy:2025-06-05T20:23:57.831366 -  2025-06-05T20:23:57.831366 - http://127.0.0.1:78902025-06-05T20:23:57.831366 - 
2025-06-05T20:24:14.460168 - [ComfyUI-Manager] The ComfyRegistry cache update is still in progress, so an outdated cache is being used.2025-06-05T20:24:14.460168 - 
2025-06-05T20:24:14.620322 - FETCH DATA from: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/custom-node-list.json2025-06-05T20:24:14.620322 - 2025-06-05T20:24:14.620322 - Use Proxy:2025-06-05T20:24:14.620322 -  2025-06-05T20:24:14.620322 - http://127.0.0.1:78902025-06-05T20:24:14.620322 - 
2025-06-05T20:24:15.110128 -  [DONE]2025-06-05T20:24:15.110128 - 
2025-06-05T20:24:15.299965 - FETCH DATA from: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/github-stats.json2025-06-05T20:24:15.299965 - 2025-06-05T20:24:15.299965 - Use Proxy:2025-06-05T20:24:15.299965 -  2025-06-05T20:24:15.299965 - http://127.0.0.1:78902025-06-05T20:24:15.299965 - 
2025-06-05T20:24:15.740158 -  [DONE]2025-06-05T20:24:15.740158 - 
2025-06-05T20:24:15.781714 - FETCH DATA from: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/extras.json2025-06-05T20:24:15.782725 - 2025-06-05T20:24:15.782725 - Use Proxy:2025-06-05T20:24:15.783520 -  2025-06-05T20:24:15.783520 - http://127.0.0.1:78902025-06-05T20:24:15.783520 - 
2025-06-05T20:24:16.141273 -  [DONE]2025-06-05T20:24:16.141273 - 
2025-06-05T20:24:16.249948 - FETCH DATA from: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/extension-node-map.json2025-06-05T20:24:16.249948 - 2025-06-05T20:24:16.250266 - Use Proxy:2025-06-05T20:24:16.250266 -  2025-06-05T20:24:16.250266 - http://127.0.0.1:78902025-06-05T20:24:16.250266 - 
2025-06-05T20:24:16.750096 -  [DONE]2025-06-05T20:24:16.750096 - 
2025-06-05T20:25:04.846427 - got prompt
2025-06-05T20:25:04.854461 - Loading model from D:\ComfyUI-aki-v1.6\ComfyUI\models\LLM\Florence-2-base2025-06-05T20:25:04.854461 - 
2025-06-05T20:25:04.854461 - Florence2 using sdpa for attention2025-06-05T20:25:04.854461 - 
2025-06-05T20:25:04.875358 - No flash_attn import to remove2025-06-05T20:25:04.876359 - 
2025-06-05T20:25:04.892746 - !!! Exception during processing !!! 'NoneType' object has no attribute 'get'
2025-06-05T20:25:04.900428 - Traceback (most recent call last):
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 349, in execute
    output_data, output_ui, has_subgraph = get_output_data(obj, input_data_all, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
                                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 224, in get_output_data
    return_values = _map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 196, in _map_node_over_list
    process_inputs(input_dict, i)
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 185, in process_inputs
    results.append(getattr(obj, func)(**inputs))
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\ComfyUI\custom_nodes\ComfyUI-Florence2\nodes.py", line 251, in loadmodel
    model = AutoModelForCausalLM.from_pretrained(model_path, attn_implementation=attention, torch_dtype=dtype,trust_remote_code=True).to(offload_device)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\python\Lib\site-packages\transformers\models\auto\auto_factory.py", line 559, in from_pretrained
    return model_class.from_pretrained(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\python\Lib\site-packages\transformers\modeling_utils.py", line 4013, in from_pretrained
    if metadata.get("format") == "pt":
       ^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'get'

2025-06-05T20:25:04.900428 - Prompt executed in 0.05 seconds
2025-06-05T20:32:39.685794 - got prompt
2025-06-05T20:32:39.700253 - Loading model from D:\ComfyUI-aki-v1.6\ComfyUI\models\LLM\Florence-2-base2025-06-05T20:32:39.700253 - 
2025-06-05T20:32:39.700253 - Florence2 using sdpa for attention2025-06-05T20:32:39.700253 - 
2025-06-05T20:32:39.731596 - No flash_attn import to remove2025-06-05T20:32:39.731596 - 
2025-06-05T20:32:39.753005 - !!! Exception during processing !!! 'NoneType' object has no attribute 'get'
2025-06-05T20:32:39.753005 - Traceback (most recent call last):
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 349, in execute
    output_data, output_ui, has_subgraph = get_output_data(obj, input_data_all, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
                                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 224, in get_output_data
    return_values = _map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 196, in _map_node_over_list
    process_inputs(input_dict, i)
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 185, in process_inputs
    results.append(getattr(obj, func)(**inputs))
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\ComfyUI\custom_nodes\ComfyUI-Florence2\nodes.py", line 251, in loadmodel
    model = AutoModelForCausalLM.from_pretrained(model_path, attn_implementation=attention, torch_dtype=dtype,trust_remote_code=True).to(offload_device)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\python\Lib\site-packages\transformers\models\auto\auto_factory.py", line 559, in from_pretrained
    return model_class.from_pretrained(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\python\Lib\site-packages\transformers\modeling_utils.py", line 4013, in from_pretrained
    if metadata.get("format") == "pt":
       ^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'get'

2025-06-05T20:32:39.759939 - Prompt executed in 0.07 seconds
2025-06-05T20:33:07.930398 - got prompt
2025-06-05T20:33:07.940147 - Loading model from D:\ComfyUI-aki-v1.6\ComfyUI\models\LLM\Florence-2-base2025-06-05T20:33:07.940147 - 
2025-06-05T20:33:07.940147 - Florence2 using sdpa for attention2025-06-05T20:33:07.940147 - 
2025-06-05T20:33:07.960279 - No flash_attn import to remove2025-06-05T20:33:07.960279 - 
2025-06-05T20:33:07.980055 - !!! Exception during processing !!! 'NoneType' object has no attribute 'get'
2025-06-05T20:33:07.981596 - Traceback (most recent call last):
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 349, in execute
    output_data, output_ui, has_subgraph = get_output_data(obj, input_data_all, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
                                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 224, in get_output_data
    return_values = _map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 196, in _map_node_over_list
    process_inputs(input_dict, i)
  File "D:\ComfyUI-aki-v1.6\ComfyUI\execution.py", line 185, in process_inputs
    results.append(getattr(obj, func)(**inputs))
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\ComfyUI\custom_nodes\ComfyUI-Florence2\nodes.py", line 251, in loadmodel
    model = AutoModelForCausalLM.from_pretrained(model_path, attn_implementation=attention, torch_dtype=dtype,trust_remote_code=True).to(offload_device)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\python\Lib\site-packages\transformers\models\auto\auto_factory.py", line 559, in from_pretrained
    return model_class.from_pretrained(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\ComfyUI-aki-v1.6\python\Lib\site-packages\transformers\modeling_utils.py", line 4013, in from_pretrained
    if metadata.get("format") == "pt":
       ^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'get'

2025-06-05T20:33:07.981596 - Prompt executed in 0.05 seconds

Attached Workflow

Please make sure that workflow does not contain any sensitive information such as API keys or passwords.

{"id":"571750e8-a2fa-478c-812b-56cc04ab3157","revision":0,"last_node_id":17,"last_link_id":15,"nodes":[{"id":10,"type":"Florence2Run","pos":[2423.105712890625,1012.9110107421875],"size":[248.8236083984375,364],"flags":{},"order":2,"mode":0,"inputs":[{"label":"图像","localized_name":"image","name":"image","type":"IMAGE","link":10},{"label":"Florence2","localized_name":"florence2_model","name":"florence2_model","type":"FL2MODEL","link":11},{"localized_name":"文本","name":"text_input","type":"STRING","widget":{"name":"text_input"},"link":null},{"localized_name":"任务","name":"task","type":"COMBO","widget":{"name":"task"},"link":null},{"localized_name":"填充遮罩","name":"fill_mask","type":"BOOLEAN","widget":{"name":"fill_mask"},"link":null},{"localized_name":"保持模型加载","name":"keep_model_loaded","shape":7,"type":"BOOLEAN","widget":{"name":"keep_model_loaded"},"link":null},{"localized_name":"最大输出Token","name":"max_new_tokens","shape":7,"type":"INT","widget":{"name":"max_new_tokens"},"link":nu
5DA6
ll},{"localized_name":"num_beams","name":"num_beams","shape":7,"type":"INT","widget":{"name":"num_beams"},"link":null},{"localized_name":"采样","name":"do_sample","shape":7,"type":"BOOLEAN","widget":{"name":"do_sample"},"link":null},{"localized_name":"选中输出遮罩","name":"output_mask_select","shape":7,"type":"STRING","widget":{"name":"output_mask_select"},"link":null},{"localized_name":"随机种","name":"seed","shape":7,"type":"INT","widget":{"name":"seed"},"link":null}],"outputs":[{"label":"图像","localized_name":"image","name":"image","type":"IMAGE","links":null},{"label":"遮罩","localized_name":"mask","name":"mask","type":"MASK","links":null},{"label":"caption","localized_name":"caption","name":"caption","type":"STRING","links":[12]},{"label":"json数据","localized_name":"data","name":"data","type":"JSON","links":null}],"properties":{"cnr_id":"comfyui-florence2","ver":"18f62acf57b02f4e94282dcb74ee8f6dd7ca8878","Node name for S&R":"Florence2Run","widget_ue_connectable":{}},"widgets_values":["","more_detailed_caption",true,false,1024,3,true,"",1,"fixed",[false,true]]},{"id":13,"type":"ShowText|pysssss","pos":[2726.907958984375,1057.11083984375],"size":[246.4854278564453,217.31515502929688],"flags":{},"order":3,"mode":0,"inputs":[{"localized_name":"text","name":"text","type":"STRING","link":12}],"outputs":[{"label":"字符串","localized_name":"字符串","name":"STRING","shape":6,"type":"STRING","links":null}],"properties":{"cnr_id":"comfyui-custom-scripts","ver":"aac13aa7ce35b07d43633c3bbe654a38c00d74f5","Node name for S&R":"ShowText|pysssss","widget_ue_connectable":{}},"widgets_values":[]},{"id":11,"type":"LoadImage","pos":[1667.7828369140625,772.0504760742188],"size":[304.1326599121094,569.4470825195312],"flags":{},"order":0,"mode":0,"inputs":[{"localized_name":"图像","name":"image","type":"COMBO","widget":{"name":"image"},"link":null},{"localized_name":"选择文件上传","name":"upload","type":"IMAGEUPLOAD","widget":{"name":"upload"},"link":null}],"outputs":[{"label":"图像","localized_name":"图像","name":"IMAGE","type":"IMAGE","links":[10]},{"label":"遮罩","localized_name":"遮罩","name":"MASK","type":"MASK","links":null}],"properties":{"cnr_id":"comfy-core","ver":"0.3.34","Node name for S&R":"LoadImage","widget_ue_connectable":{}},"widgets_values":["1.jpg","image"]},{"id":12,"type":"Florence2ModelLoader","pos":[2041.8126220703125,1113.1915283203125],"size":[228.740234375,130],"flags":{},"order":1,"mode":0,"inputs":[{"label":"LoRA","localized_name":"lora","name":"lora","shape":7,"type":"PEFTLORA","link":null},{"localized_name":"模型","name":"model","type":"COMBO","widget":{"name":"model"},"link":null},{"localized_name":"精度","name":"precision","type":"COMBO","widget":{"name":"precision"},"link":null},{"localized_name":"注意力","name":"attention","type":"COMBO","widget":{"name":"attention"},"link":null},{"localized_name":"convert_to_safetensors","name":"convert_to_safetensors","shape":7,"type":"BOOLEAN","widget":{"name":"convert_to_safetensors"},"link":null}],"outputs":[{"label":"Florence2","localized_name":"florence2_model","name":"florence2_model","type":"FL2MODEL","links":[11]}],"properties":{"cnr_id":"comfyui-florence2","ver":"18f62acf57b02f4e94282dcb74ee8f6dd7ca8878","Node name for S&R":"Florence2ModelLoader","widget_ue_connectable":{}},"widgets_values":["Florence-2-base","fp16","sdpa",true]}],"links":[[10,11,0,10,0,"IMAGE"],[11,12,0,10,1,"FL2MODEL"],[12,10,2,13,0,"STRING"]],"groups":[],"config":{},"extra":{"ds":{"scale":0.6588450000000009,"offset":[-1337.0761804991507,-595.3933083411617]},"ue_links":[],"links_added_by_ue":[]},"version":0.4}

Additional Context

(Please add any additional context or steps to reproduce the error here)

2.json

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

      0