The performance here is indeed dominated by array transformation. Typically, the time can be decomposed into three parts.
- JuliaCall interface function time cost (
julia_call
on the order of 10 microsends,julia_command
on the order of 100 microseconds). - data transfer time cost, which will be on the order of milliseconds for a large data set like this.
- julia function time cost.