chrisgoringe / cg-use-everywhere

Apache License 2.0
460 stars 32 forks source link

Some inputs losing connection when reloading (pictures, workflow provided) #67

Closed aegis72 closed 9 months ago

aegis72 commented 9 months ago

image As an example, sometimes images lose their connection when loaded. If you just reconnect the node...

image It works again. Looks like it is losing its type or something?

Workflow: AegisFlow_Anywhere_conversion.json

Tiny utility node I hacked together out of WASquatch's Image Batch node to get an image node that could accept a UE link and pass it along to multiple nodes that need the same image input (the controlnet preprocessors, f/e). Hopefully, he'll add such a node and it can be replaced with something from WAS Suite, but for now I use this node a lot. aegisflow-image-pass.zip

chrisgoringe commented 9 months ago

I can't reproduce - any chance of narrowing down the circumstances at all?

aegis72 commented 9 months ago

Will certainly try. Let me work on it tonight.

aegis72 commented 9 months ago

I haven't been able to get it to happen since that night. but I do have a different (but similar) issue. Here's a couple minute video showing what is happening, as well as a node and two example workflows (the node is an extended version of CR's "image 4 switch" and is used to send a specific preprocessed image off to a controlnet stack, but here I've cut out all possible extra stuff to make the problem simpler to debug.

The workflow takes a loaded image, then passes it with UE to a bank of controlnet preprocessors. The image that is specified by the switch is then passed to the inputs of a 3-controlnet stack.

I had this working in a different workflow, but I realized that my goal of modularity wouldn't be achieved until I could make the template more simple to use/ scalable to N-instances. So I reworked the way I was doing it so that we feed in the target controlnet name once from a string node, and then the image output options are linked to the controlnet preprocessing chooser using UE. The user still has to make some title changes, but not many.

As in the longer video, when I have one, all works well: image

But if I add another stack, most of the connections are lost. All the target names are unique (as far as I see) and so I am unsure why it would be breaking/not linking up to the correct nodes. In the supplemental video, changing the title_regex target to a widget value versus usingthe common input didn't change anything.

Test workflow and "my" node 2 workflows and nodes.zip

https://github.com/chrisgoringe/cg-use-everywhere/assets/118572301/bc703f71-0256-4b47-a115-9e7d5579ae03

https://github.com/chrisgoringe/cg-use-everywhere/assets/118572301/aca79b55-b25f-4fc8-9863-ebf8e49c44aa

aegis72 commented 9 months ago

One more thing; if I delete a UE sender, and recreate it with a wildly different name, it rewires after I refresh the page. Here, "aaaa" is wiring up after the refresh, but "bbbb" isn't. image

Then, after a refresh: image

Note that the refresh doesn't fix anything that is using the string input (although as seen in the supplemental video, the correct name does seem to get passed to the node)

aegis72 commented 9 months ago

One last: if I delete the first "ctrlnet_1_ipmix" set of nodes, leaving just the "ctrlnet_2_ipmix" set left, and refresh the page, it does rewire. Is there just something really dumb I am doing with my regex? Is it that you can't use the string input the way I am trying to? That latter would be a shame, since it's needed to be able to make reusable components :(.

image

aegis72 commented 9 months ago

Signs point to the latter; here I changed the string for the title_regex input to "bigglesbam_ipmix" so I think that it isn't using that value as the title_regex after all, since the nodes are still UE-wired (and wouldn't be if this worked how I want it to)

image

Is this simply not possible to achieve? I really hope it's a bug and not a limitation of the framework itself or whatever.

chrisgoringe commented 9 months ago

Looks like the problem might be with converting the regex to an input. I'll look into that.

chrisgoringe commented 9 months ago

Yup - I can confirm that at present the UE? node doesn't work with the regex being an input. I'll need to look into that now...

aegis72 commented 9 months ago

Thank you!

aegis72 commented 9 months ago

Do you have a "buy a coffee" or similar?

chrisgoringe commented 9 months ago

OK - take a look at the latest update. There is limited support for converting the regex fields to inputs, but I think it should work with your case.

The limitation is that the input to the regex must come directly from a string source (basically a node which just produces a string literal). I've added a Simple String node that works with it.

Yes - https://www.buymeacoffee.com/chrisgoringe

aegis72 commented 9 months ago

Thanks! Will try in a sec....coffee sent!

aegis72 commented 9 months ago

SUCCESS. I can now proceed :)!

image Enjoy the coffee, and thank a ton and a half.

aegis72 commented 9 months ago

https://github.com/chrisgoringe/cg-use-everywhere/assets/118572301/32676d26-de48-456c-9b53-a3162c428d50

Here's loading some stuff via templates and having it wire up.

chrisgoringe commented 9 months ago

Hey @aegis72 , I just wondered if you were aware of the feature where you can limit where a UE node sends to the group(s) it is part of. That might be another way to do the sort of thing you needed this for.

aegis72 commented 9 months ago

Yes; in this case it wouldn't have solved it for reasons too long to explain since in waiting at a light ;)

On Thu, Dec 7, 2023, 4:44 PM chrisgoringe @.***> wrote:

Hey @aegis72 https://github.com/aegis72 , I just wondered if you were aware of the feature where you can limit where a UE node sends to the group(s) it is part of. That might be another way to do the sort of thing you needed this for.

— Reply to this email directly, view it on GitHub https://github.com/chrisgoringe/cg-use-everywhere/issues/67#issuecomment-1846222550, or unsubscribe https://github.com/notifications/unsubscribe-auth/A4IUKDNVM7VFCQATNCICYKLYIJBEBAVCNFSM6AAAAABAE7XGN6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNBWGIZDENJVGA . You are receiving this because you were mentioned.Message ID: @.***>

aegis72 commented 9 months ago

Now that I have more time, it would have fixed it if I didn’t care about modular reuse as much.

Imagine if I had a workflow with 4 samplers, and I wanted 3 to use the same control net and one to use a different one, but I also wanted to keep the wireless connection because part of the concept is things wire mostly automatically and can be moved around without chains of wires. Since I can’t use variables from UE nodes outside a group if I turned it on, I’d have to rename many nodes to new names which is worse than wiring, or use wires and connect everything up every time, which is also undesirable.

Because of your fix, I am able to have one “preprocess nodes” template, and all they have to do is change that one string field and match the title of the “preprocess chooser” field, and dozens of things wire themselves, but the processors are tucked away in a corner without distracting from the main workflow :)

On Thu, Dec 7, 2023 at 6:47 PM Don E. @.***> wrote:

Yes; in this case it wouldn't have solved it for reasons too long to explain since in waiting at a light ;)

On Thu, Dec 7, 2023, 4:44 PM chrisgoringe @.***> wrote:

Hey @aegis72 https://github.com/aegis72 , I just wondered if you were aware of the feature where you can limit where a UE node sends to the group(s) it is part of. That might be another way to do the sort of thing you needed this for.

— Reply to this email directly, view it on GitHub https://github.com/chrisgoringe/cg-use-everywhere/issues/67#issuecomment-1846222550, or unsubscribe https://github.com/notifications/unsubscribe-auth/A4IUKDNVM7VFCQATNCICYKLYIJBEBAVCNFSM6AAAAABAE7XGN6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNBWGIZDENJVGA . You are receiving this because you were mentioned.Message ID: @.***>