Skip to main content

This is toolbox for boosting calculation speed using GPU

Project description

Boostrsa

This library is based on rsatoolbox(https://github.com/rsagroup/rsatoolbox).

The purpose of library is made to boost calcuation speed for searchlight RSA(Representational Similarity Analysis). However, It is still in development, so this library only includes tools for boosting crossnobis distance calculation for constructing RDM(Representational Dissimilartiy Matrix) on the whole brain.

How it works?

Basically, this library uses a Nvidia's GPU instead of CPU for parallel processing. In the searchlight analysis, the data targeted for constructing the RDM in volvxes a voxel and its neighboring voxels. That is well-suited for parallel processing since the calculations for each target are independent of one another. This library utilizes GPU-compatible libraries such as Numba and Cupy to facilitate this process.

Dependencies

To use this library, you need to have a Nvidia's GPU and CUDA. Additionally, this library heavily relies on Cupy and Numba. It is essential to install the appropriate versions of these libraries.

cupy

Cupy is designed to work with specific versions of CUDA. See cupy's guide and install appropriate version in correspond to your system (https://github.com/cupy/cupy).

Please check your cuda version to install cupy.

  • versions
    • cupy-cuda10x (for cuda 10)
    • cupy-cuda11x (for cuda 11)
    • cupy-cuda12x (for cuda 12)

If you installed the cuda10 in your computer, then install cupy-cuda10x. install cupy-cuda10x. ex) pip install cupy-cuda10x

numba

The numba library is a powerful tool that enbales python functions to be compiled to machine code at runtime using the LLVM. One of its key features is the ability to generate native code for different architectures, including CPUs and GPUs, which greatly accelerates the execution of data-heavy and computationally intense python code.

Please see installation guideline of numba (https://numba.pydata.org/numba-doc/latest/user/installing.html).

Pip installation).

  • pip install numba

rsatoolbox

The rsatoolbox is a Python library specifically designed for Representational Similarity Analysis (RSA).

Please see installation guideline of rsatoolbox (https://github.com/rsagroup/rsatoolbox)

  • pip install rsatoolbox

Installation

pip install boostrsa

Checked version

These are the latest checked environment.

  • OS
    • Linux, ubuntu - 21.10
  • numba
    • 0.57.0 ~ 0.59.1 is fine to use
  • cupy
    • cupy-cuda11x
    • cupy-cuda12x

Future works

  • Add calculation sources to get neighbors and centers (boost)
  • Add RSA sources (boost)
  • Support other calculation methods except crossnobis distance

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

boostrsa-0.0.1.dev9.tar.gz (18.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

boostrsa-0.0.1.dev9-py3-none-any.whl (20.2 kB view details)

Uploaded Python 3

File details

Details for the file boostrsa-0.0.1.dev9.tar.gz.

File metadata

  • Download URL: boostrsa-0.0.1.dev9.tar.gz
  • Upload date:
  • Size: 18.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for boostrsa-0.0.1.dev9.tar.gz
Algorithm Hash digest
SHA256 4939f021fd03ad8d328b156c54b254ff267cf5b90e621657872a93036cd271aa
MD5 8148a104e05dd480d8597ffa9381a3ff
BLAKE2b-256 3f17658ba705a1324b3e892bb063e344f1fbb01f381d967619cd4f41211b3971

See more details on using hashes here.

File details

Details for the file boostrsa-0.0.1.dev9-py3-none-any.whl.

File metadata

  • Download URL: boostrsa-0.0.1.dev9-py3-none-any.whl
  • Upload date:
  • Size: 20.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for boostrsa-0.0.1.dev9-py3-none-any.whl
Algorithm Hash digest
SHA256 b1fb5f18645ba17e28cebd224947c4e906b594cb06e3785d193a5fb06ec8d824
MD5 ffdabef58aa0c2ece6cd35ef471f54fa
BLAKE2b-256 9d3e47c50f9ceaa129c1937814fcf73d815ca66697b62e1f02abf0ab230c5c50

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page