I noticed from my tests of Tunny0.12.0 version, the studies are stored either SQLITE3 or JournalFile . I read this from optuna webpage about that mySQL is recommended to parallel compute the optimization. I am wondering if there’s any parallel compute has already inside Tunny or Tunny will support mySQL to enhance the parallel compute-ability in the future development.
Tunny supports parallelization in JournalFile. MySQL is not currently supported.
You can perform parallel optimization by launching multiple instances of Rhino, referencing the same JournalFile from Tunny, and executing optimization with the same Grasshopper file. JournalFile means the fish.log file where Tunny writes the optimization results by default.
I would like to know more detail. When you said multiple instances of Rhino, you were referring to in the same gh file, copy paste multiple tunny components, and all referencing the same fish.log file. This way, the optimization will run parallelly? Does this sound correct to you?
Do you means that multiple tunny component in same gh document? If so, it is incorrect way.
Since the explanation was a little lacking, I created a video explanation.
First, perform optimization as usual.
If you want to parallelize it after that, you can start another Tunny and continue the study to perform optimization in a parallelized state.
You can check whether parallelization is working properly by looking at the plot on the Timeline. The Timeline can be viewed from Optuna-Dashboard.
In this case, optimization was performed in two parallel processes, so the Timeline shows two lines drawn at the same time, confirming that two evaluations are being performed at the same time (two parallel processes).
In the video, it looks like you run two Rhino and open the same gh file (or one is copied from other one) and just choose continue from the running study.
Thats looks great, can we somehow encapsulate part of grasshopper into hoops and run virtually unlimited “parallel” instances and be controlled by single tunny solver without need of running two or more rhinos?
Yes, We are considering how to implement this, but have not yet done so.
We believe that the easiest method of encapsulation would be to use RhinoCompute, as in Hops.
We are still considering the specific implementation, but believe that this has great potential.