Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restructure class methods into individual files #161

Merged
merged 37 commits into from
Aug 6, 2019

Conversation

mateogianolio
Copy link
Owner

@mateogianolio mateogianolio commented Apr 9, 2019

Features

  • Improved maintainability by breaking out all class methods into separate files. Intended side-effects of this is that we will be more prepared for
    1. WASM compilation with AssemblyScript (Investigate WebAssembly integration #102)
    2. Accelerating some or all of the class methods in C++
    3. Providing a framework for writing additional extensions mentioned in Machine learning #45, Mathematical statistics #55, Random sampling #145, Discrete fourier transform #146, Complex numbers #149, Computational physics #150
    • Restructure NDArray
    • Restructure Vector
    • Restructure Matrix
  • Improved typings by using TypeScript generics.
  • Improved test suite by having one spec file per function instead of having one spec file per class.
  • Improved benchmarks by having one benchmark file per function.
  • NDArray
    • Add reshape, slice, equidimensional, equilateral methods.
  • Matrix
    • Add eig method that returns eigenvalues and eigenvectors.
    • Add nlapack dependency and accelerate matrix methods eig, inv, lu, lu_factor, solve.

Breaking changes

  • NDArray
    • Switch to dtype: DType instead of type: TypedArrayConstructor.
    • Remove min and max arguments from random method.
  • Matrix
    • Rename plu to lu_factor.
    • Rename determinant to det.
    • Rename inverse to inv.
    • Rename identity to eye and move it to NDArray.
  • Vector
    • Rename magnitude to norm and move it to NDArray.

src/NDArray/exp.ts Outdated Show resolved Hide resolved
src/Matrix/index.ts Outdated Show resolved Hide resolved
src/Matrix/index.ts Show resolved Hide resolved
src/Matrix/index.ts Outdated Show resolved Hide resolved
src/Matrix/index.ts Outdated Show resolved Hide resolved
src/NDArray/sin.ts Outdated Show resolved Hide resolved
src/Matrix/index.ts Outdated Show resolved Hide resolved
src/Matrix/index.ts Outdated Show resolved Hide resolved
src/Vector/index.ts Outdated Show resolved Hide resolved
src/Vector/index.ts Outdated Show resolved Hide resolved
src/NDArray/round.ts Outdated Show resolved Hide resolved
src/Matrix/index.ts Show resolved Hide resolved
src/Matrix/index.ts Outdated Show resolved Hide resolved
src/Matrix/index.ts Outdated Show resolved Hide resolved
src/Matrix/index.ts Outdated Show resolved Hide resolved
src/Vector/index.ts Show resolved Hide resolved
src/Matrix/index.ts Outdated Show resolved Hide resolved
src/Matrix/index.ts Outdated Show resolved Hide resolved
src/Matrix/index.ts Outdated Show resolved Hide resolved
src/Matrix/index.ts Outdated Show resolved Hide resolved
src/Matrix/gauss.ts Outdated Show resolved Hide resolved
src/Matrix/multiply.ts Outdated Show resolved Hide resolved
src/Matrix/solve.ts Outdated Show resolved Hide resolved
src/Matrix/solve.ts Outdated Show resolved Hide resolved
src/Matrix/plu.ts Outdated Show resolved Hide resolved
src/Matrix/inverse.ts Outdated Show resolved Hide resolved
src/Matrix/inverse.ts Outdated Show resolved Hide resolved
src/Matrix/plu.ts Outdated Show resolved Hide resolved
src/Matrix/rank.ts Outdated Show resolved Hide resolved
src/Matrix/multiply.ts Outdated Show resolved Hide resolved
src/Matrix/gauss.ts Outdated Show resolved Hide resolved
src/Matrix/augment.ts Outdated Show resolved Hide resolved
src/Matrix/augment.ts Outdated Show resolved Hide resolved
src/Matrix/lu.ts Outdated Show resolved Hide resolved
src/NDArray/max.ts Outdated Show resolved Hide resolved
@codeclimate
Copy link

codeclimate bot commented Aug 6, 2019

Code Climate has analyzed commit 3d71147 and detected 23 issues on this pull request.

Here's the issue category breakdown:

Category Count
Complexity 23

The test coverage on the diff in this pull request is 92.7% (80% is the threshold).

This pull request will bring the total coverage in the repository to 92.7% (9.6% change).

View more on Code Climate.

@mateogianolio mateogianolio merged commit a57ab87 into master Aug 6, 2019
@mateogianolio mateogianolio deleted the improvement/restructure branch August 6, 2019 19:03
mateogianolio added a commit that referenced this pull request Aug 7, 2019
* NDArray restructured, tests passing

* finishing touches on NDArray

* prepare Vector and Matrix, fix tslint

* restructure methods of Vector

* disable duplication checks

* ...

* improve types, replace *.call(this, ...) with this.*(...)

* passing tests and lint

* upd dependencies, fix vulns, upd benchmarks, upd docs

* fix docs

* improve docs

* upd travis buildspec

* upgrade matplotnode to 0.4.1

* upgrade matplotnode to 0.4.2

* add libpython-dev to travis buildspec

* upd g++ to 4.9

* rm clang

* nyc config updates

* fix issues with inheritance, split up tests into separate files, rearrange stuff

* upgrade deps

* fix #39

* improvements

* minor cleanup

* cleanup jacobi method

* add lapack optimisations, rename some methods

* dist + docs

* ...

* benchmarks

* add dtype

* improvements

* switch version from 6.0.0 to 6.0.0-beta.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant