Hi everyone; can Orca3D v3 leverage Rhino 8’s Python interface / is there a Python Orca3d module / library that can bypass command-line executions? Have to run a pretty computationally intensive loop and trying to find the points of compute buy-back. Haven’t found anything anywhere that indicates it’s possible though.
Hi Myles, Orca3D doesn’t have a Python module, but there are Grasshopper components for hydrostatics/stability, hull assistants, and resistance prediction (planing and displacement). Be sure that you are using the latest update to Version 3 (V3.1.5) which may be downloaded from our website.
Have you tried implementing the python script with the help of Rhino Script Syntax ?
Rhino script syntax has a Command function that reads
“Runs a Rhino command script. All Rhino commands can be used in command scripts. The command can be a built-in Rhino command or one provided by a 3rd party plug-in.”
Rhino - RhinoScriptSyntax
It may be able to run Orca commands if they can be called “headless” entirely on the command line, that is, without the pop up options that usually show.
Is that possible @bhays I am not at my computer to test it
Thanks, @altamiro.aj. Many, but not all, Orca3D commands are “scriptable.” That is, they can be run from the command line or in a script, without the normal dialogs. To test this, type the command that you’re interested in in the command line, preceded by a dash (-). For example, -OrcaProperties.
Hello, thanks for the replies!
@altamiro.aj, yes, I’ve been using a similar approach with Python, leveraging the command method like I did with VBA in the past.
I was hoping there might be a way to bypass the overhead of using the Rhino command line. The most relatable example I can think of is in Excel: creating and calculating arrays in VBA’s editor and then pasting results into the workbook is often much faster than interacting with Excel’s cells directly.
Similarly, I’ve been using RhinoGeometry to minimize the computational overhead of creating objects until the loop finishes running. However, now that Orca3D is part of the workflow, I couldn’t find a way to create objects without using rs.Command
. This means the hull is created in the document, adding unnecessary steps and overhead, which brought me here to confirm if a direct approach was possible.
@bhays, It seems like that functionality doesn’t exist currently. Is there any chance this might be considered for future updates?
What kind of hull you are working with?
Because there are a few python libraries that can do the basics of naval architecture, so if you could explain a little better your workflow and objective, we might find something to work with. (one library that comes to mind is OpenPlaning for savitsky equations for example)
That way, if you are doing iterations, you could work with the basics for most of the iterations going to Orca only on critical keypoints to make your process quicker and still taking advantage of Orca’s tools and capabilities. I am doing something between this lines for my Master’s degree
I was going to ask a similar question. Can you describe your workflow, and what role Orca3D is being used for? Orca3D may have some of the functionality already that you’re building in Python.