sketchucation logo sketchucation
    • Login
    ℹ️ Licensed Extensions | FredoBatch, ElevationProfile, FredoSketch, LayOps, MatSim and Pic2Shape will require license from Sept 1st More Info

    Frustrated with rubies

    Scheduled Pinned Locked Moved Developers' Forum
    47 Posts 18 Posters 4.2k Views 18 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Chris FullmerC Offline
      Chris Fullmer
      last edited by

      @thomthom said:

      But mind you, close the Outliner when you run plugins that does heavy operations. That thing really slows things down. You can often see it flicker like mad.

      Exactly! Also, in version 6, there was a version that was released that is NOTORIOUSLY slow with rubies due to the outliner. You might also close the layers window and the layers toolbar if you are doing stuff with layers. I see them flicker a lot too. That mighth help.

      Thom, I've noticed the same thing about exploding taking longer when you do it all in one shot. I was thinking to write a ruby that selects everyting to explode and then divides it into chunks to explode it. Maybe it would be faster than SU's built in method. I'm guessing it has something to do with the idea that a single command with 10,000 identical operations will take much longer than 1,000 commands of 100 identical operations. Just a thought.

      Chris

      Lately you've been tan, suspicious for the winter.
      All my Plugins I've written

      1 Reply Last reply Reply Quote 0
      • brodieB Offline
        brodie
        last edited by

        I'll take your advice on the outliner. I typically don't use the outliner anyway but I often have the layers pallete open. The flip side though is that sometimes the only "progress bar" you have is the blinking layer menu.

        -Brodie

        steelblue http://www.steelbluellc.com

        1 Reply Last reply Reply Quote 0
        • H Offline
          hebrides
          last edited by

          I'm not a big ruby fan. Some of the early basic scripts are great but I have found those that I have tried recently a little bloated, inconsistent in the way they load, and unpredictable. My modeling skills have improved greatly and so, as has been mentioned, many rubies take longer to set-up and clean-up then my normal manual workflow in many cases.

          I am also concerned with the large poly count some use to get simple things done. I used rubies everyday a year ago. I would say my use has dwindled to once a week.

          Some of my favorite rubies are more for play than anything else. They don't often get into the work-flow for customer work anymore.

          I appreciate the hard work of all who contribute rubies. I believe that it is probably a good idea to purchase your rubies though (from Smustard or equiv). Freebees sometimes come with more than you bargain for in headaches.

          1 Reply Last reply Reply Quote 0
          • thomthomT Offline
            thomthom
            last edited by

            @chris fullmer said:

            Thom, I've noticed the same thing about exploding taking longer when you do it all in one shot. I was thinking to write a ruby that selects everyting to explode and then divides it into chunks to explode it. Maybe it would be faster than SU's built in method. I'm guessing it has something to do with the idea that a single command with 10,000 identical operations will take much longer than 1,000 commands of 100 identical operations. Just a thought.

            I've also been contemplating on working on an alternative to the explode. I wanted to try to read the entities in a group/component one by one, then rebuild it in the group's parent and afterwards delete the group.

            Back to the topic, it would help so much if SU implemented a proper progress API which gave a UI which didn't lock up and had an cancel button. A neat bonus would be a pause button that would freeze the script's operation. Though, this is something the SU team would have to implement.
            Though, I have been theorising on this issue as well. I'm wondering if it would work to pop up a webdialog with a progress bar, or a spinning wheel, which would give indication of work. Of if the webdialog would freeze as well.

            Thomas Thomassen — SketchUp Monkey & Coding addict
            List of my plugins and link to the CookieWare fund

            1 Reply Last reply Reply Quote 0
            • Chris FullmerC Offline
              Chris Fullmer
              last edited by

              Todd mentioned a while ago that he was planning a massive overhaul for progressbar. I think he said it would include a cancel button, webdialog, and a progressbar that would not lock up. I don't know if he's working on it or not, but there is hope that it might happen.

              Chris

              Lately you've been tan, suspicious for the winter.
              All my Plugins I've written

              1 Reply Last reply Reply Quote 0
              • R Offline
                RickW
                last edited by

                Brodie,

                I understand your frustration with things going slowly. I've never personally experienced #1, and have only seen #4 when developing.

                I can tell you, though, that in regards to GroupByTexture, you'd wait at least as long for SU to explode all groups and components if you manually started the procedure as with a ruby script exploding them (though you do save time by not having to manually select and initiate the explode process - I've tested it).

                When exploding a large number of high-poly (relatively speaking) groups or components, SU will bog down, period. That's just the nature of the beast.

                The lack of feedback is marginally fixable (I can put in status messages), but your #3 item defeats that effort, and that's an internal SU issue that no ruby author can control.

                @thomthom said:

                Back to the topic, it would help so much if SU implemented a proper progress API which gave a UI which didn't lock up and had an cancel button. A neat bonus would be a pause button that would freeze the script's operation. Though, this is something the SU team would have to implement.
                Though, I have been theorising on this issue as well. I'm wondering if it would work to pop up a webdialog with a progress bar, or a spinning wheel, which would give indication of work. Of if the webdialog would freeze as well.

                I've requested (multiple times) a native Progress Bar for the API. It just hasn't been added.
                I've tried webDialog-based PB's and they don't work (at least I haven't gotten one to work, and that with direct Google input).

                RickW
                [www.smustard.com](http://www.smustard.com)

                1 Reply Last reply Reply Quote 0
                • thomthomT Offline
                  thomthom
                  last edited by

                  @rickw said:

                  When exploding a large number of high-poly (relatively speaking) groups or components, SU will bog down, period. That's just the nature of the beast.

                  This is the odd thing. If you manually go through and select each individual and explode the process will be faster.

                  As for native progressbar API, maybe we should be more vocal about this? Do you know what the team's stand on this is? Do they think it's a non-issue, or are they fully aware of it? I'm wondering if it'd help if we suggested it in the "Way of Coding" thread as well as sending direct feedback. I find this to be a pretty big show stopper and it'd make things much much easier to the users and coders.

                  Thomas Thomassen — SketchUp Monkey & Coding addict
                  List of my plugins and link to the CookieWare fund

                  1 Reply Last reply Reply Quote 0
                  • Chris FullmerC Offline
                    Chris Fullmer
                    last edited by

                    @unknownuser said:

                    I've requested (multiple times) a native Progress Bar for the API. It just hasn't been added.
                    I've tried webDialog-based PB's and they don't work (at least I haven't gotten one to work, and that with direct Google input).

                    Bummer! I had high hopes for a new progressbar.

                    Lately you've been tan, suspicious for the winter.
                    All my Plugins I've written

                    1 Reply Last reply Reply Quote 0
                    • jeff hammondJ Offline
                      jeff hammond
                      last edited by

                      @thomthom said:

                      @rickw said:

                      When exploding a large number of high-poly (relatively speaking) groups or components, SU will bog down, period. That's just the nature of the beast.

                      This is the odd thing. If you manually go through and select each individual and explode the process will be faster.

                      i've noticed that too and i just checked it out to confirm.. using a grid of spheres:

                      Edges 157872
                      Faces 82368
                      Component Instances 286
                      Guides 0
                      Guide Points 0
                      Groups 26

                      bomb.rb took 45 seconds to blow it up while doing it manually took 20 seconds (and by manually i mean - select all/explode which takes care of the groups and then repeating that to handle the components)

                      another thing.. on macs, you get the spinning beach ball during the process so you at least know something is happening..

                      dotdotdot

                      1 Reply Last reply Reply Quote 0
                      • thomthomT Offline
                        thomthom
                        last edited by

                        @unknownuser said:

                        bomb.rb took 45 seconds to blow it up while doing it manually took 20 seconds (and by manually i mean - select all/explode which takes care of the groups and then repeating that to handle the components)

                        Some times, if you have a large model, even selecting multiple items to explode bogs down. But selecting one item one by one completes the task faster than selecting all and exploding. And that's with the overhead of moving the cursor, click(select), rightclick(contextmenu), click(explode).

                        @unknownuser said:

                        another thing.. on macs, you get the spinning beach ball during the process so you at least know something is happening..

                        On XP you have the hourglass in addition to the white screen. On Vista and Windows7 with Aero enabled, the screen doesn't do while and you have just the hourglass. (spinning blue circlethingymajiggy) But in either case, you never know if the script or SU has gone down the drain...

                        Thomas Thomassen — SketchUp Monkey & Coding addict
                        List of my plugins and link to the CookieWare fund

                        1 Reply Last reply Reply Quote 0
                        • B Offline
                          BillW
                          last edited by

                          Just a note for developers.

                          I have started looking at wxSU for developing dialogs which ties into the native operating system dialog generation routines. I find Web dialogs a pain having to implement a mixture of ruby and javascript as well as the web page. wxSU is written in ruby so less levels of translation. Dialogs can be flexible with auto resizing of the content. Takes a bit of getting used to though.

                          Relating to the topic, there is a progress bar dialog in the examples folder "ProgressDialog.RB"

                          wxSU can be found at http://sourceforge.net/projects/wxsu/

                          1 Reply Last reply Reply Quote 0
                          • jeff hammondJ Offline
                            jeff hammond
                            last edited by

                            @thomthom said:

                            @unknownuser said:

                            bomb.rb took 45 seconds to blow it up while doing it manually took 20 seconds (and by manually i mean - select all/explode which takes care of the groups and then repeating that to handle the components)

                            Some times, if you have a large model, even selecting multiple items to explode bogs down. But selecting one item one by one completes the task faster than selecting all and exploding. And that's with the overhead of moving the cursor, click(select), rightclick(contextmenu), click(explode)

                            in this case (300+ individual groups/components), i think it would take much longer than either bomb.rb or select all/explode to explode everything one by one..

                            it does make me curious about what exactly bomb.rb is doing though because it took more than twice the amount of time to explode everything at once compared to doing the groups and components separately... i'm wondering if bomb would be faster if it was set up to do what i did manually.. apparently, if i have groups with components nestled inside, select all will not actually select the components.. only the groups.. exploding the groups first then the components next speeds up the process by 2x+..

                            regardless, i never have a real .skp with that many groups/components and bomb.rb is an instant process for the models i'm working on.. (well, it does have the confirm dialog that pops up and slows down the process & just like weld.rb, i wish the dialogues wouldn't show up)

                            dotdotdot

                            1 Reply Last reply Reply Quote 0
                            • jeff hammondJ Offline
                              jeff hammond
                              last edited by

                              oh.. and why does the progress bar work well with certain rubies and not others?
                              joint push/pull for instance has a great progress report.

                              dotdotdot

                              1 Reply Last reply Reply Quote 0
                              • thomthomT Offline
                                thomthom
                                last edited by

                                @unknownuser said:

                                in this case (300+ individual groups/components), i think it would take much longer than either bomb.rb or select all/explode to explode everything one by one..

                                It should. But it seems that it doesn't always happen. Some times SU simply choke.

                                Thomas Thomassen — SketchUp Monkey & Coding addict
                                List of my plugins and link to the CookieWare fund

                                1 Reply Last reply Reply Quote 0
                                • brodieB Offline
                                  brodie
                                  last edited by

                                  I'm glad to hear that at least the basis for many of my frustrations seems to be a known issue (lack of reliable feedback ie. integrated progress bar), at least among the community.

                                  I'd also be interested in finding out what the SU team's position/thoughts are on this.

                                  -Brodie

                                  steelblue http://www.steelbluellc.com

                                  1 Reply Last reply Reply Quote 0
                                  • thomthomT Offline
                                    thomthom
                                    last edited by

                                    Yup, some times you just have to go for a cup of tea or two.

                                    Thomas Thomassen — SketchUp Monkey & Coding addict
                                    List of my plugins and link to the CookieWare fund

                                    1 Reply Last reply Reply Quote 0
                                    • R Offline
                                      RickW
                                      last edited by

                                      @thomthom said:

                                      Yup, some times you just have to go for a cup of tea or two.

                                      Preferably chamomile, to soothe the nerves 😄

                                      RickW
                                      [www.smustard.com](http://www.smustard.com)

                                      1 Reply Last reply Reply Quote 0
                                      • T Offline
                                        todd burch
                                        last edited by

                                        My turn.

                                        progessbar.rb is pretty basic. I wrote it a few years ago to fill a gap of no progress bar at all. However, it was still insufficient in its first incarnation since when SU would freeze up due to intense processing of a Ruby script in a single, synchronous thread. Anytime the SU user interface would need repainting, too bad, because the Ruby script had the thread, and the user interface, unfortunately, does not get serviced. When SU hits this wall, the first thing to go is the SU menu bar, then the whole UI freezes, even the status bar where progressbar.rb makes it updates.

                                        I then changed progressbar.rb to add an estimated completion time. It's my opinion that this change transformed it into more than just a "cool animated bar", and into something that was actually pretty useful, since you now know that the script will take another 5 seconds, or 20 minutes, or whatever, and you can adjust your finger-tapping-on-the-desk to some other activity as needed.

                                        The next phase will be a dialog, similar to what Rick mentioned, that will provide a persistent external dialog that will allow you to cancel the script at any time. This will require programming changes to the invoking script, but it will be a big improvement in long running rubies that you choose to cancel.

                                        Todd

                                        1 Reply Last reply Reply Quote 0
                                        • K Offline
                                          kwistenbiebel
                                          last edited by

                                          Isn't the main issue here that the Sketchup core needs streamlining?
                                          I am not a coder, but to me, it feels like there is too much communication/checking going on while doing any operation.
                                          For instance, having the Outliner panel open kills workflow, not only when using rubies.
                                          Having the material browser or component browser open kills performance as well in many cases.

                                          A lot of the slowdowns seem to be related to 'getting the output on screen', creating a bottleneck as everything needs to be processed through the OpenGL mill .
                                          Operations one would expect to be powered by your CPU , suddenly seem to be overruled by (the lack of) GPU power (graphical card).

                                          A serious rewriting of the SU core, and perhaps implementing better ways for SU to deal with multiple processes at the same time (multicore adapted software) might produce a faster workflow.

                                          Other 3D modelers are modular based as well using plugins. They seem not to suffer of serious slowdowns though.

                                          1 Reply Last reply Reply Quote 0
                                          • J Offline
                                            Jackson
                                            last edited by

                                            Brodie,

                                            I couldn't agree more with your original point. As much as some of the simplest ruby scripts have become an absolutely essential part of my SU tool set (Todd Birch's "Renumber Scenes", Matthieu Noblet's "Remove C-G Materials", PurgeAll.rb, cleanup_model.rb among others) I recently loaded almost all of the (free) ruby scripts from the "Must Have Ruby Plugins - Visual Index" thread and some of them are either so complicated, or difficult to get to work or are buggy that I just want rid of them asap. "soapskinbubble.rb" is a prime example- at it's core it's ingenious and ought to be useful to every SU user, but it's bogged down with very short time limits of just a few weeks and a really awful UI which never fails to baffle me on the rare occassion that I feel the need to use it. I've learned how to get it to work twice in the past and just discovered to my shame I've forgotten again! I am in awe of anyone who has the skills, but most of all the generosity to create these scripts for free, but when you need a crash course in programming to get a ruby script to work no wonder users aren't donating!) Other ruby scripts add more and more items to the context menu with submenus and obscure names e.g. "FFD>Make Patch".

                                            As much as it's hard to be critical without naming names, I think in any case the real blame doesn't lie with individual ruby scripters- they are after all producing these amazing little tools for no reason other than to try to make other SU users day's a little easier. Google undoubtedly did a great thing when they built the ruby API into SU allowing end users the ability to customise SU, but I think once we all saw just how many excellent ruby scripts were actually being produced we thought this process would have some feedback built in. Sadly, so far this hasn't been the case. I struggle to think of even one ruby tool which was conceived and programmed by an "amateur" ruby scripter which has been implemented as a real (read: outwith the ruby API) SU tool. That is a very serious error on Google's part IMO, as, as far as end users can see they are no longer investing in the future of SU, but are simply allowing ruby scripters to drag it reluctantly and excrutiatingly slowly forwards while other software forges ahead.

                                            Jackson

                                            1 Reply Last reply Reply Quote 0
                                            • 1
                                            • 2
                                            • 3
                                            • 1 / 3
                                            • First post
                                              Last post
                                            Buy SketchPlus
                                            Buy SUbD
                                            Buy WrapR
                                            Buy eBook
                                            Buy Modelur
                                            Buy Vertex Tools
                                            Buy SketchCuisine
                                            Buy FormFonts

                                            Advertisement