Viktor is an open source Kotlin / cross-platform JNI library aimed at idiomatic multidimensional array representation
and efficient vector calculations on CPU.
The source code is hosted on GitHub (https://github.com/JetBrains-Research/viktor).

Features

  • Versatile F64Array class represents an arbitrarily multidimensional double-precision floating-point number array.
    It was inspired by NumPy's ndarray.
  • Arithmetic, mathematical and statistical methods are provided for these arrays.
  • Easy subsetting and substitution of arrays made possible by views.
  • Built-in support for logarithmically-stored values.
  • Bulk computations are SIMD-optimized wherever possible.

System Requirements

viktor can run on any JVM, but to make use of JNI+SIMD optimizations you need the following:

  • JVM: 64-bit
  • OS: Windows, Linux or macOS
  • CPU instruction set: amd64 / x86_64 with either SSE2 or AVX extension

Installation

The easiest way to add viktor to your project is through Gradle:

repositories {
    jCenter()
}
dependencies {
    compile 'org.jetbrains.bio:viktor:1.0.1'
}

or Maven:

<dependency>
    <groupId>org.jetbrains.bio</groupId>
    <artifactId>viktor</artifactId>
    <version>1.0.1</version>
    <type>pom</type>
</dependency>

Download

You can download viktor JAR from Bintray.

Usage

Please refer to the documentation for details.
There is a tutorial to get you started.

Issues

Please report any issues (bugs, feature requests etc.) to GitHub issue tracker: https://github.com/JetBrains-Research/viktor/issues.

JNI+SIMD Optimization

viktor's array operations can be up to 57x more efficient than doing things in a loop, see our benchmarks.