-
Notifications
You must be signed in to change notification settings - Fork 45
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
xyPlot and ranges #102
Comments
I'm considering adding some kind of node based parsing to xyPlot string. |
You could do another node, or you could do what A1111 does and have special syntax that's recognized as a range iterator. You could use something like A1111 like "x-y[3]" for 3 steps spanning x to y, or "x-y(z)" for x, x+z, x+2z, x+3z... until x+nz exceeds y. Another option would be a built in function in the node, like rangesteps(x,y,n,TRUE,TRUE) where the TRUE TRUE is a boolean for including the first and 2nd endpoint. Also rangeinterval(x,y,z,TRUE,TRUE) with the same idea. I think it might be a bit easier to implement if you tweaked the syntax of the xpplot node, which is very customizable (good thing) but clunky to use in its current state (bad thing). Maybe this was easier to code, though. I don't know what's under the hood. |
working on a node that ouputs a plot_string with similar functionality to this, but want to flesh it out properly before pushing it |
Excellent! I think it will push you way ahead of other all-in-one packages. Oh, and your "buy me a coffee" link is broken on the main page of this repo. I found you manually anyway but now I'm stuck on the captcha for some reason, endlessly spinning on the verification... I'll try back in a little bit. |
Thanks for the heads up, I've updated the link. |
I've added an initial version of 'advPlot range' (b62fe51) which outputs a correctly formatted string. the 'node' and 'widget' widgets update their options dynamically in a similar way to the advPlot dropdown - the node needs to be connected to an adv xyPlot node, which is in turn connected to a KSampler to show the available options (for range the widgets have been filtered to show only number widgets) Let me know if it works how you think it should, or if there's anything you think should be added/changed. I haven't tested it super extensively so it may need some polishing still. |
Hey this is a pretty good implementation! My only suggestion would be to expand on its functionality to either be increment based (like it is now) or range based (which it can be with a little bit of math). Sort of like how the range(int) and range(float) nodes work from the EasyUse package. But your node does 98% of the work for the user, so if you left it as is, it would still eliminate the need for that huge mess of nodes I built to accomplish the same thing. Cheers! |
1f8239b not sure if the range based is exactly the same as in EasyUse, so if you think it needs to be tweaked some more, let me know :)
|
I absolutely love the idea that an xyPlot node can take any node value from anywhere and iterate across it. This cements ttn as my go to for basically everything in comfy now.
One small issue I have with the new xyPlot is how you can't easily iterate across a range by step size or number of steps with endpoints.
I made a custom node group that does this, but it's extremely clunky and adds nearly 30 nodes to the workflow (all just to process a range, then convert it into the new xyPlot programatic format).
I can post my nodes later if anyone is interested. Until then, is there an easy way to do this? Any plans to build in a range/step option?
Pic of my janky workflow:
The text was updated successfully, but these errors were encountered: