09-18-2023, 06:12 PM
(This post was last modified: 09-18-2023, 06:18 PM by Fionn_Merz.)
Hi All.
I have a question that I am looking for help with. I am working on a RoboDK simulation that uses the Python API. The task requires that I call setPose() or setJoints() on 10+ robots every 15ms or so.
This works fine in a simple test case. Using separate RDK sessions for each robot, setPose() and setJoints() both take about 1.35ms to return per call, according to cProfile.
But if I call solveIK() or solveFK() before or after setPose()/setJoints(), the set method now takes 10x longer to return (13ms per call).
This happens even if the solveFK() is interacting from a separate thread, to a separate Robot in RoboDK, through a separate API instance.
This is far too slow for my needs, and I just cannot figure out the root cause. It feels like congestion on a socket or similar, but I have no way of telling.
Has anyone encountered this before and found a good explanation, or better a fix?
I have attached the Python codes and rdk file if anyone is interested in taking a look.
Thanks All,
Fionn
Profiler Test.py (Size: 298 bytes / Downloads: 233)
Class_RobotTest.py (Size: 3.24 KB / Downloads: 249)
API Latency Test V1.rdk (Size: 276.02 KB / Downloads: 268)
I have a question that I am looking for help with. I am working on a RoboDK simulation that uses the Python API. The task requires that I call setPose() or setJoints() on 10+ robots every 15ms or so.
This works fine in a simple test case. Using separate RDK sessions for each robot, setPose() and setJoints() both take about 1.35ms to return per call, according to cProfile.
But if I call solveIK() or solveFK() before or after setPose()/setJoints(), the set method now takes 10x longer to return (13ms per call).
This happens even if the solveFK() is interacting from a separate thread, to a separate Robot in RoboDK, through a separate API instance.
This is far too slow for my needs, and I just cannot figure out the root cause. It feels like congestion on a socket or similar, but I have no way of telling.
Has anyone encountered this before and found a good explanation, or better a fix?
I have attached the Python codes and rdk file if anyone is interested in taking a look.
Thanks All,
Fionn


