All Projects → aplbrain → npyjs

aplbrain / npyjs

Licence: Apache-2.0 License
Read numpy .npy files in JavaScript

Programming Languages

javascript
184084 projects - #8 most used programming language
python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to npyjs

Image-Classifier
Final Project of the Udacity AI Programming with Python Nanodegree
Stars: ✭ 63 (+125%)
Mutual labels:  numpy
gcpy
Python toolkit for GEOS-Chem.
Stars: ✭ 34 (+21.43%)
Mutual labels:  numpy
poisson-matting
Python implementation of Poisson matting method
Stars: ✭ 41 (+46.43%)
Mutual labels:  numpy
Scipy-Bordeaux-2017
Course taught at the University of Bordeaux in the academic year 2017 for PhD students.
Stars: ✭ 16 (-42.86%)
Mutual labels:  numpy
Cat-vs.-Dog-Classifier
Image Classifier with Flask and Keras CNN
Stars: ✭ 27 (-3.57%)
Mutual labels:  numpy
numpy-data-augmentation
Data Augmentation using NumPy
Stars: ✭ 50 (+78.57%)
Mutual labels:  numpy
Data-Scientist-In-Python
This repository contains notes and projects of Data scientist track from dataquest course work.
Stars: ✭ 23 (-17.86%)
Mutual labels:  numpy
robot
Functions and classes for gradient-based robot motion planning, written in Ivy.
Stars: ✭ 29 (+3.57%)
Mutual labels:  numpy
ml
经典机器学习算法的极简实现
Stars: ✭ 130 (+364.29%)
Mutual labels:  numpy
numpyeigen
Fast zero-overhead bindings between NumPy and Eigen
Stars: ✭ 75 (+167.86%)
Mutual labels:  numpy
Python-TensorFlow-WebApp
Emerging Technologies Project - 4th Year 2017
Stars: ✭ 16 (-42.86%)
Mutual labels:  numpy
Numscrypt
A port of a small but relevant part of Numpy to Transcrypt, simplified for the sake of speed
Stars: ✭ 53 (+89.29%)
Mutual labels:  numpy
hypothesis-gufunc
Extension to hypothesis for testing numpy general universal functions
Stars: ✭ 32 (+14.29%)
Mutual labels:  numpy
Exploratory Data Analysis Visualization Python
Data analysis and visualization with PyData ecosystem: Pandas, Matplotlib Numpy, and Seaborn
Stars: ✭ 78 (+178.57%)
Mutual labels:  numpy
Algorithmic-Trading
I have been deeply interested in algorithmic trading and systematic trading algorithms. This Repository contains the code of what I have learnt on the way. It starts form some basic simple statistics and will lead up to complex machine learning algorithms.
Stars: ✭ 47 (+67.86%)
Mutual labels:  numpy
Machine-Learning-in-Python-Workshop
My workshop on machine learning using python language to implement different algorithms
Stars: ✭ 89 (+217.86%)
Mutual labels:  numpy
wquantiles
weighted quantiles with Python
Stars: ✭ 28 (+0%)
Mutual labels:  numpy
NPY-for-Fortran
A FORTRAN module to write Numpy's *.npy and *.npz files
Stars: ✭ 30 (+7.14%)
Mutual labels:  numpy
Neo
Deep learning library in python from scratch
Stars: ✭ 36 (+28.57%)
Mutual labels:  numpy
gaia
Gaia is a geospatial analysis library jointly developed by Kitware and Epidemico.
Stars: ✭ 29 (+3.57%)
Mutual labels:  numpy

npy.js

Read .npy files directly in JS

GitHub Workflow Status

Installation

Include npy.js in your project directly, or:

yarn add npyjs
# npm i npyjs

Import

import npyjs from "npyjs";

Usage

  • Create a new npyjs object.
let n = new npyjs();
  • This object can now be used load .npy files. Arrays can be returned via a JavaScript callback, so usage looks like this:
n.load("my-array.npy", (array, shape) => {
    // `array` is a one-dimensional array of the raw data
    // `shape` is a one-dimensional array that holds a numpy-style shape.
    console.log(
        `You loaded an array with ${array.length} elements and ${shape.length} dimensions.`
    );
});
  • You can also use this library promise-style using either .then or async await:
n.load("test.npy").then((res) => {
    // res has { data, shape, dtype } members.
});
const npyArray = await n.load("test.npy");

Accessing multidimensional array elements

  • You can conveniently access multidimensional array elements using the 'ndarray' library:
import ndarray from "ndarray";
const npyArray = ndarray(data, shape);
npyArray.get(10, 15)

Unless otherwise specified, all code inside of this repository is covered under the license in LICENSE.

Please report bugs or contribute pull-requests on GitHub.


Made with at JHU APL

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].