Skip to content
This repository has been archived by the owner on Feb 18, 2020. It is now read-only.

External Code Interfaces

Daniel Patrick Foose edited this page Oct 20, 2016 · 2 revisions

Vespucci 1.1.x will integrate interprocess communication between Vespucci and Python and R packages distributed with Vespucci. More information will be available as this feature is implemented.

Getting a Matrix into the External Environment

Writing Python Extensions for Vespucci

Under the Hood

Vespucci keeps a list of all available matrices in shared memory. When the user calls the list function of the Python or R package, this list is presented as a list of lists, with each member containing the keys of the matrix. When the user calls the requestMatrix function, a message is passed to Vespucci, which then copies the requested matrix into shared memory. The Python or R package then copies the matrix as a numeric array into its local memory and deallocates the shared matrix. When the user calls addMatrix from the Python or R package, the matrix is copied into shared memory and a message is sent to Vespucci, which copies the matrix from shared memory into its local memory and deallocates the shared memory block. This is done using Qt D-Bus and QSharedMemory.