cavis/jumpy
Serhii Shepel 1233acf2ab
Fix formatting, remove obsolete files (#439)
* Update/remove obsolete files

* Fix nd4j-parameter-server-parent folder and module name

* Fix formatting for libnd4j pom

* Remove LICENSE file check for libnd4j build

* Temp revert removing encoding and version for nd4j-parameter-server-model, nd4j-parameter-server-node, nd4j-parameter-server-client
2020-05-29 11:01:02 +03:00
..
benchmarks Eclipse Migration Initial Commit 2019-06-06 15:21:15 +03:00
jumpy Eclipse Migration Initial Commit 2019-06-06 15:21:15 +03:00
tests Eclipse Migration Initial Commit 2019-06-06 15:21:15 +03:00
.gitignore Eclipse Migration Initial Commit 2019-06-06 15:21:15 +03:00
README.md Update links to eclipse repos (#252) 2019-09-10 19:09:46 +10:00
pom.xml Fix backend dependencies for tests (#189) 2019-08-29 12:54:48 +09:00
pytest.ini Eclipse Migration Initial Commit 2019-06-06 15:21:15 +03:00
release.sh Eclipse Migration Initial Commit 2019-06-06 15:21:15 +03:00
requirements.txt Eclipse Migration Initial Commit 2019-06-06 15:21:15 +03:00
setup.cfg Eclipse Migration Initial Commit 2019-06-06 15:21:15 +03:00
setup.py Eclipse Migration Initial Commit 2019-06-06 15:21:15 +03:00

README.md

Jumpy: Python interface for nd4j

Join the chat at https://gitter.im/deeplearning4j/deeplearning4j License PyPI version

Jumpy allows you to use ND4J from Python without any network communication. Many other Python libraries bridging Java have considerable overhead, jumpy uses pointers to directly access your numpy arrays. Under the hood, Jumpy uses pydl4j for dependency management and pyjnius to load Java classes.

Installation

Jumpy is on PyPI, simply install it with

pip install jumpy

or build it from source:

python setup.py install

Using Jumpy

Creating arrays

Just like numpy, you can initialize an array using .zeros() or .ones()

import jumpy as jp

x = jp.zeros((32, 16))
y = jp.ones((32, 16))

Converting numpy array to jumpy array

A numpy ndarray instance can be converted to a jumpy ndarray instance (and vice-versa) without copying the data

import jumpy as jp
import numpy as np

x_np = np.random.random((100, 50))
x_jp = jp.array(x_np)

Converting jumpy array to numpy array

Simply call the .numpy() method of jumpy.ndarray.ndarray

import jumpy as jp

x_jp = jp.zeros((100,50))
x_np = x_jp.numpy()

Operations

  • Basic operators like + - * / += -= *= /= are overloaded and broadcasting is supported.
  • Indexing, slicing and assignment behaviour has been made as close to numpy as possible.
  • Check jumpy/ops/ to see available ops.

Contribute

  • Check for open issues, or open a new issue to start a discussion around a feature idea or a bug.
  • We could use more ops! Have a look at available ops (jumpy/ops/), it's quite easy to add new ones.
  • Send a pull request and bug us on Gitter until it gets merged and published. :)