Skip to content

how to optimize reading long tuples from julia to python #575

@dpinol

Description

@dpinol

Is your feature request related to a problem? Please describe.
This code takes around 7s on a modern i9 the first time that it's executed. It's immediate the next times it's executed. It's also immediate to execute (zeros(20_000)...,) in julia.
I have python 3.12 and julia 1.10.5

import juliacall
v=juliacall.Main.seval("(zeros(20_000)...,)");

Describe the solution you'd like
Is there any way to speed up the initial compilation?

Describe alternatives you've considered
I tried to use this code to to speed up reading data from julia to python by going through a tuple. Looping a long julia vector from python is much slower than looping a tuple ( around 4 times slower to read a 100_000 floats vector vs reading a tuple)

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions