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

cannot access local variable 'pipe' where it is not associated with a value。 #9

Closed
AbleYu opened this issue Jul 4, 2024 · 10 comments

Comments

@AbleYu
Copy link

AbleYu commented Jul 4, 2024

HI.I followed the steps and completed everything, but after opening it in TD, when I press the pulse button, this error message keeps appearing. Any suggestions?
4013bbe847652ed01785f2805147cf3

@olegchomp
Copy link
Owner

Save project & restart TouchDesigner. If doesn't help, press ALT + T and post full log.

@AbleYu
Copy link
Author

AbleYu commented Jul 4, 2024

I have tried the method you mentioned countless times.

In TD textprot !

512 512
Model load has failed. Doesn't exist.
cannot import name 'packaging' from 'pkg_resources' (C:\Users/msi/AppData/Local/Programs/Python/Python311/Lib/site-packages\pkg_resources_init_.py)
Keyword arguments {'add_watermarker': False} are not expected by StableDiffusionPipeline and will be ignored.
Loading pipeline components...: 0%| | 0/5 [00:00<?, ?it/s]
Loading pipeline components...: 60%|###### | 3/5 [00:00<00:00, 14.57it/s]
Loading pipeline components...: 100%|##########| 5/5 [00:00<00:00, 15.71it/s]
Loading pipeline components...: 100%|##########| 5/5 [00:00<00:00, 15.49it/s]
You have disabled the safety checker for <class 'diffusers.pipelines.stable_diffusion.pipeline_stable_diffusion.StableDiffusionPipeline'> by passing safety_checker=None. Ensure that you abide to the conditions of the Stable Diffusion license and do not expose unfiltered results in services or applications open to the public. Both the diffusers team and Hugging Face strongly recommend to keep the safety filter enabled in all public facing circumstances, disabling it only for use-cases that involve analyzing network behavior or auditing its results. For more information, please have a look at huggingface/diffusers#254 .
python >>>

1a8961c56dbe3f3babcc608f7e77194

@olegchomp
Copy link
Owner

Ok, it's error about setuptools.
For now you can try with Portable version, it should work out of box.

@AbleYu
Copy link
Author

AbleYu commented Jul 4, 2024

Ok, it's error about setuptools. For now you can try with Portable version, it should work out of box.

Thank you for your quick response! Yes, I am currently using the portable version. I installed it directly at the beginning but it was unsuccessful. I have not yet deleted my first installed version. The hierarchical relationship is as shown in my picture. How do I correctly delete the first package that has been installed? Will there be any impact between them?

@olegchomp
Copy link
Owner

Delete TouchDiffusion folder. It's installed in virtual environment, so it's enough to completely remove folder. Download Portable and follow instruction.

@AbleYu
Copy link
Author

AbleYu commented Jul 5, 2024

Thank you for your patience, it's very unfortunate! I deleted all the folders and downloaded the portable package again. There was no error during the installation. Then I opened TD, saved it, and opened it again. Although there was a model selection, it still couldn't run. When I pressed pulse, it still couldn't run.

1720153540575

@olegchomp
Copy link
Owner

olegchomp commented Jul 5, 2024

You need to update TouchDiffusion.tox file. Download it again and add to project

@AbleYu
Copy link
Author

AbleYu commented Jul 6, 2024

I have tested it many times according to what you said, but it still cannot run. I think it may be because my computer environment is too messy? The error message is as follows:

TouchDesigner Build 2023.11510 compile on Thu Feb 8 06:41:58 2024
Python 3.11.1 (heads/3.11-Derivative-dirty:82b0389147, Jan 25 2023, 22:34:27) [MSC v.1929 64 bit (AMD64)]

Warning: 'TouchDiffusionPortable.venv/Lib/site-packages' is not a valid directory.
Added 'TouchDiffusionPortable\embedded_python/Lib/site-packages' to sys.path.
Added 'TouchDiffusionPortable\StreamDiffusion/src' to sys.path.
Added 'TouchDiffusionPortable' to sys.path.
DAT compile warnings: /project1/TouchDiffusion/TouchDiffusionExt
C:\Users\msi\Documents\TDProject\TouchDiffusionPortable\embedded_python/Lib/site-packages\diffusers\models\transformers\transformer_2d.py:34: FutureWarning: Transformer2DModelOutput is deprecated and will be removed in version 1.0.0. Importing Transformer2DModelOutput from diffusers.models.transformer_2d is deprecated and this will be removed in a future version. Please use from diffusers.models.modeling_outputs import Transformer2DModelOutput, instead.
deprecate("Transformer2DModelOutput", "1.0.0", deprecation_message)
512 512
Model load has failed. Doesn't exist.
cannot import name 'packaging' from 'pkg_resources' (C:\Users/msi/AppData/Local/Programs/Python/Python311/Lib/site-packages\pkg_resources_init_.py)
Keyword arguments {'add_watermarker': False} are not expected by StableDiffusionPipeline and will be ignored.
Loading pipeline components...: 0%| | 0/5 [00:00<?, ?it/s]
Loading pipeline components...: 40%|#### | 2/5 [00:00<00:00, 11.59it/s]
Loading pipeline components...: 80%|######## | 4/5 [00:00<00:00, 11.16it/s]
Loading pipeline components...: 100%|##########| 5/5 [00:00<00:00, 10.08it/s]
You have disabled the safety checker for <class 'diffusers.pipelines.stable_diffusion.pipeline_stable_diffusion.StableDiffusionPipeline'> by passing safety_checker=None. Ensure that you abide to the conditions of the Stable Diffusion license and do not expose unfiltered results in services or applications open to the public. Both the diffusers team and Hugging Face strongly recommend to keep the safety filter enabled in all public facing circumstances, disabling it only for use-cases that involve analyzing network behavior or auditing its results. For more information, please have a look at huggingface/diffusers#254 .

By the way, I tried using your TDComfyUI today with complete success! Thanks for your contribution!

@olegchomp
Copy link
Owner

olegchomp commented Jul 6, 2024

Do you have any other envs that required python 3.11? If not, delete it and try again. Also check in TD setting, there should be python site-package field, it must be empty. Also could message me in discord if still have issue.

@AbleYu
Copy link
Author

AbleYu commented Jul 6, 2024

Do you have any other envs that required python 3.11? If not, delete it and try again. Also check in TD setting, there should be python site-package field, it must be empty. Also could message me in discord if still have issue.

Awesome! Cheers! Thanks for your help! This worked for me! I deleted python3.10 and python3.11 from my computer and set TD->perferences->site-package to empty, but I don't know which one worked for me specifically, but it did work for me! My 3070ti laptop runs at about 14fps.

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

2 participants