Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ModuleNotFoundError: natten is required for neighborhood attention #9

Open
Song367 opened this issue Oct 16, 2024 · 4 comments
Open

Comments

@Song367
Copy link

Song367 commented Oct 16, 2024

!!! Exception during processing !!! natten is required for neighborhood attention
Traceback (most recent call last):
File "E:\workplace\ComfyUI\execution.py", line 323, 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 "E:\workplace\ComfyUI\execution.py", line 198, 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 "E:\workplace\ComfyUI\execution.py", line 169, in _map_node_over_list
process_inputs(input_dict, i)
File "E:\workplace\ComfyUI\execution.py", line 158, in process_inputs
results.append(getattr(obj, func)(**inputs))
File "E:\workplace\ComfyUI\custom_nodes\ComfyUI-PMRF\nodes.py", line 190, in pmrf
return inference(images, scale, num_steps, seed, interpolation)
File "E:\workplace\ComfyUI\venvs\lib\site-packages\torch\utils_contextlib.py", line 116, in decorate_context
return func(*args, **kwargs)
File "E:\workplace\ComfyUI\custom_nodes\ComfyUI-PMRF\nodes.py", line 153, in inference
cropped_face, restored_faces, restored_img = enhance_face(
File "E:\workplace\ComfyUI\venvs\lib\site-packages\torch\utils_contextlib.py", line 116, in decorate_context
return func(*args, **kwargs)
File "E:\workplace\ComfyUI\custom_nodes\ComfyUI-PMRF\nodes.py", line 84, in enhance_face
output = generate_reconstructions(
File "E:\workplace\ComfyUI\custom_nodes\ComfyUI-PMRF\nodes.py", line 60, in generate_reconstructions
v_t_next = pmrf_model(x_t=x_t_next, t=t_one * num_t, y=y).to(x_t_next.dtype)
File "E:\workplace\ComfyUI\venvs\lib\site-packages\torch\nn\modules\module.py", line 1553, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
File "E:\workplace\ComfyUI\venvs\lib\site-packages\torch\nn\modules\module.py", line 1562, in _call_impl
return forward_call(*args, **kwargs)
File "E:\workplace\ComfyUI\custom_nodes\ComfyUI-PMRF\lightning_models\mmse_rectified_flow.py", line 135, in forward
return self.forward_flow(x_t, t, y)
File "E:\workplace\ComfyUI\custom_nodes\ComfyUI-PMRF\lightning_models\mmse_rectified_flow.py", line 131, in forward_flow
return self.model(x_t, t)
File "E:\workplace\ComfyUI\venvs\lib\site-packages\torch\nn\modules\module.py", line 1553, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
File "E:\workplace\ComfyUI\venvs\lib\site-packages\torch\nn\modules\module.py", line 1562, in _call_impl
return forward_call(*args, **kwargs)
File "E:\workplace\ComfyUI\custom_nodes\ComfyUI-PMRF\arch\hourglass\image_transformer_v2.py", line 749, in forward
x = down_level(x, pos, cond)
File "E:\workplace\ComfyUI\venvs\lib\site-packages\torch\nn\modules\module.py", line 1553, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
File "E:\workplace\ComfyUI\venvs\lib\site-packages\torch\nn\modules\module.py", line 1562, in _call_impl
return forward_call(*args, **kwargs)
File "E:\workplace\ComfyUI\custom_nodes\ComfyUI-PMRF\arch\hourglass\image_transformer_v2.py", line 542, in forward
x = layer(x, *args, **kwargs)
File "E:\workplace\ComfyUI\venvs\lib\site-packages\torch\nn\modules\module.py", line 1553, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
File "E:\workplace\ComfyUI\venvs\lib\site-packages\torch\nn\modules\module.py", line 1562, in _call_impl
return forward_call(*args, **kwargs)
File "E:\workplace\ComfyUI\custom_nodes\ComfyUI-PMRF\arch\hourglass\image_transformer_v2.py", line 511, in forward
x = checkpoint(self.self_attn, x, pos, cond)
File "E:\workplace\ComfyUI\custom_nodes\ComfyUI-PMRF\arch\hourglass\image_transformer_v2.py", line 50, in checkpoint
return function(*args, **kwargs)
File "E:\workplace\ComfyUI\venvs\lib\site-packages\torch\nn\modules\module.py", line 1553, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
File "E:\workplace\ComfyUI\venvs\lib\site-packages\torch\nn\modules\module.py", line 1562, in _call_impl
return forward_call(*args, **kwargs)
File "E:\workplace\ComfyUI\custom_nodes\ComfyUI-PMRF\arch\hourglass\image_transformer_v2.py", line 416, in forward
raise ModuleNotFoundError("natten is required for neighborhood attention")
ModuleNotFoundError: natten is required for neighborhood attention

Prompt executed in 2.68 seconds

@t3239658
Copy link

The same problem, I hope it can be solved.

@richadlee
Copy link

same

1 similar comment
@dAItime001
Copy link

same

@KoDelioDa
Copy link

我在我的conda python=3.11.9环境中,使用pip install natten构建了natten解决了这个问题,我是用的是Ubuntu 22.04 server

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants