Commit Graph

1303 Commits (dbbd61621c3bb341b01bc610cb3f3eaba697f73d)

Author SHA1 Message Date
Fariz Rahman bde0a4ec98
Python4j (#422)
* types

* pom fix

* basic exec + tests

* safe exec

* exec fixes + tests

* prim tests

* lists and dicts

* collections tests

* list test

* api

* exec and return all vars

* context manager + fixes

* leak fixes

* jobs tests

* gc basic working

* more gc fixed

* copyright headers

* try-catch-finally

* gc fixes

* validate var name (startswith _collapsed..)

* try block refac

* pythonexecutioner nits

* hashset->set

* call() gc fix

* gc fixes

* type check fix

* types fixes

* refacs

* rem numpyarray

* threadsafety check

* private->public

* threadsafe checks

* pythonGC test

* threading fixes + tests

* threading tests+

* threading test fixes

* make PythonException unchecked

* nits

* docstrings

* path fixes
2020-05-21 11:47:12 +10:00
Yurii Shyrma 0bc9785508
mkldnn concat call cases correction (#471)
* - disable mkldnn concat when number of input arrays > 3072

Signed-off-by: Yurii <iuriish@yahoo.com>

* - get rid of loop in calculating of input arrays number

Signed-off-by: Yurii <iuriish@yahoo.com>
2020-05-19 21:56:41 +03:00
Andrii T ec757f654d
Tensorflow import tests and fixes (#435)
* ignored ops checked

Signed-off-by: Andrii Tuzhykov <andrewtuzhykov@gmail.com>

* reconfigured AdjustContrast + commented primitive_gru

Signed-off-by: Andrii Tuzhykov <andrewtuzhykov@gmail.com>

* minor changes + exception ops commented

Signed-off-by: Andrii Tuzhykov <andrewtuzhykov@gmail.com>

* figured out non existent tf ops and random ops check

Signed-off-by: Andrii Tuzhykov <andrewtuzhykov@gmail.com>

* minor changes to tensorflowop and randomness cheks

Signed-off-by: Andrii Tuzhykov <andrewtuzhykov@gmail.com>

* deconv2d tensorfloname removed

* Fix Flatbuffers ser/de with character fields

Signed-off-by: Alex Black <blacka101@gmail.com>

* TFGraphTestAllSameDiff tests passed except NonMaxSuppression

Signed-off-by: Andrii Tuzhykov <andrewtuzhykov@gmail.com>

* minor changes

Signed-off-by: Andrii Tuzhykov <andrewtuzhykov@gmail.com>

* temporary ignored section added

Signed-off-by: Andrii Tuzhykov <andrewtuzhykov@gmail.com>

* ignores removed

Signed-off-by: Andrii Tuzhykov <andrewtuzhykov@gmail.com>

* org.nd4j.base.Preconditions -> org.nd4j.common.base.Preconditions

Signed-off-by: Andrii Tuzhykov <andrewtuzhykov@gmail.com>

* temsorflownames reverts and replace CopyHost

* ignored mod op tests due to known issue

Signed-off-by: Andrii Tuzhykov <andrewtuzhykov@gmail.com>

* rsestored mod after fixing in cpp level

Signed-off-by: Andrii Tuzhykov <andrewtuzhykov@gmail.com>

* ignored random_shuffle op test due to known issue

Signed-off-by: Andrii Tuzhykov <andrewtuzhykov@gmail.com>

* increased random_uniform mean/std comparator sensitivity

Signed-off-by: Andrii Tuzhykov <andrewtuzhykov@gmail.com>

* igmored random tests due to SameDiff RNG seed is not set.

Signed-off-by: Andrii Tuzhykov <andrewtuzhykov@gmail.com>

Co-authored-by: Alex Black <blacka101@gmail.com>
2020-05-20 00:18:52 +10:00
Paul Dubs 6e9c849e4a
Fix typo (#469) 2020-05-18 15:46:46 +10:00
Alex Black 4bdd5cb8ff
Add SameDiff file format ADR [WIP] (#467)
* Add SameDiff file format ADR

Signed-off-by: Alex Black <blacka101@gmail.com>

* Update 0001-SameDiff_File_Format.md

* Update

Signed-off-by: Alex Black <blacka101@gmail.com>
2020-05-16 22:44:31 +10:00
raver119 51ce6927fd
FP Mod (#468)
* mod

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* couple of tests for updated mod

Signed-off-by: raver119@gmail.com <raver119@gmail.com>
2020-05-16 10:44:58 +03:00
Alex Black deb87b04f7
Assorted fixes (#466)
* Timeouts and fixes

Signed-off-by: Alex Black <blacka101@gmail.com>

* Increase default timeout to 90s due to slow PPC CI machines

Signed-off-by: Alex Black <blacka101@gmail.com>

* Another timeout tweak

Signed-off-by: Alex Black <blacka101@gmail.com>

* Svhn

Signed-off-by: Alex Black <blacka101@gmail.com>
2020-05-15 15:34:08 +10:00
Yurii Shyrma 753ce28a92
Shyrma sqrtm (#429)
* - start working on implementation of sqrtm op

Signed-off-by: Yurii <iuriish@yahoo.com>

* - improving householder procedure

Signed-off-by: Yurii <iuriish@yahoo.com>

* - further polishing householder stuff

Signed-off-by: Yurii <iuriish@yahoo.com>

* - polishing hh pivoting qr procedure

Signed-off-by: Yurii <iuriish@yahoo.com>

* - polishing BiDiagonalUp procedure

Signed-off-by: Yurii <iuriish@yahoo.com>

* - polishing householder sequence class

Signed-off-by: Yurii <iuriish@yahoo.com>

* - polishing jacobi svd class

Signed-off-by: Yurii <iuriish@yahoo.com>

* - polishing svd stuff 1

Signed-off-by: Yurii <iuriish@yahoo.com>

* - polishing svd stuff 2

Signed-off-by: Yurii <iuriish@yahoo.com>

* - implementation and testing class which performs Hessenberg decomposition of square matrix

Signed-off-by: Yurii <iuriish@yahoo.com>

* - add static method to JacobiSVD class which makes the continuous Givens rotation generation algorithm

Signed-off-by: Yurii <iuriish@yahoo.com>

* - implementation and testing auxiliary methods of Schur decomp class

Signed-off-by: Yurii <iuriish@yahoo.com>

* some references here and there

Signed-off-by: raver119 <raver119@gmail.com>

* - trying figure out difference between eigen and our Schur alg

Signed-off-by: Yurii <iuriish@yahoo.com>

* - testing fixing bugs in Schur decomposition op

Signed-off-by: Yurii <iuriish@yahoo.com>

* - start to implement class which performs calculation of eigen values and vectors

Signed-off-by: Yurii <iuriish@yahoo.com>

* - add to EigenValsAndVecs method which calculates complex eigen vectors

Signed-off-by: Yurii <iuriish@yahoo.com>

* - testing and fixing bugs in EigenValsAndVecs class

Signed-off-by: Yurii <iuriish@yahoo.com>

* - implementation and testing triangularSolver class

Signed-off-by: Yurii <iuriish@yahoo.com>

* Added a 2D routine for triangular systems solve.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored triangularSolve2D routine and tests.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored another test for triangularSolve2D.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored test for triangularSolve for vector-bar case.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored triangularSolve2D routine and tests.

Signed-off-by: shugeo <sgazeos@gmail.com>

* - implementation of FullPivLU class

Signed-off-by: Yurii <iuriish@yahoo.com>

* - fix bugs in FullPivLU::solve method

Signed-off-by: Yurii <iuriish@yahoo.com>

* - correct permutation vector in FullPivLU::solve

Signed-off-by: Yurii <iuriish@yahoo.com>

* - correct include headers

Signed-off-by: Yurii <iuriish@yahoo.com>

* - implementation of Sqrtm class

Signed-off-by: Yurii <iuriish@yahoo.com>

* - testing and fixing bugs in Sqrtm class

Signed-off-by: Yurii <iuriish@yahoo.com>

* - include sqrtm classes to cuda folder, investigate in what places synchronization doesn't work

Signed-off-by: Yurii <iuriish@yahoo.com>

* Added implementation for cuda triangularSolve2D and also refactored triangularSolve2D for cpu.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Eliminated waste implementations.

Signed-off-by: shugeo <sgazeos@gmail.com>

* - make offset calculation faster in t<> methods

Signed-off-by: Yurii <iuriish@yahoo.com>

* - rename refference T& NDArray::t<> method

Signed-off-by: Yurii <iuriish@yahoo.com>

* - further work on cuda sqrtm

Signed-off-by: Yurii <iuriish@yahoo.com>

* - provide correct synchronization to device in Sqrtm class

Signed-off-by: Yurii <iuriish@yahoo.com>

* - add tests for sqrtm op

Signed-off-by: Yurii <iuriish@yahoo.com>

* - correct fails which appeared while testing on jenkins

Signed-off-by: Yurii <iuriish@yahoo.com>

* - trying to find out mistake in svd::deflation method

Signed-off-by: Yurii <iuriish@yahoo.com>

* Revert "- trying to find out mistake in svd::deflation method"

This reverts commit 19d37baddbc509028e4bc67bc932fe7449becdb6.

* Revert "- trying to find out mistake in svd::deflation method"

This reverts commit 19d37baddbc509028e4bc67bc932fe7449becdb6.

Signed-off-by: Yurii <iuriish@yahoo.com>

* - change call semantic of r<> and t<> methods

Signed-off-by: Yurii <iuriish@yahoo.com>

* - ged rid of ambiguity in * operator overloads for windows buikd

Signed-off-by: Yurii <iuriish@yahoo.com>

* - get rid of ambiguity in * operator overloads for windows build 2

Signed-off-by: Yurii <iuriish@yahoo.com>

* - get rid of ambiguity in * operator overloads for windows build 3

Signed-off-by: Yurii <iuriish@yahoo.com>

* - resolve conflicts with master

Signed-off-by: Yurii <iuriish@yahoo.com>

* cmakelists updated

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* - minor fix in merge cpu helper - make use of reference getter

Signed-off-by: Yurii <iuriish@yahoo.com>

Co-authored-by: raver119 <raver119@gmail.com>
Co-authored-by: shugeo <sgazeos@gmail.com>
2020-05-14 18:06:13 +03:00
raver119@gmail.com 2214175934 disable unwanted logging
Signed-off-by: raver119@gmail.com <raver119@gmail.com>
2020-05-14 13:54:52 +03:00
Abdelrauf 69d91e272a
- new implementations for Index Reductions (#421)
* - new implementations for Index Reductions
- small fix in the legacy reduction
- disabled index reduction bench tests inside Playground

Signed-off-by: Abdelrauf <rauf@konduit.ai>

* Allow LIBND4J_TYPES

Signed-off-by: Abdelrauf <rauf@konduit.ai>

* index reduction stuff split into bunch of units

* meh

* IMax switched to new impl

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* minor fix + test

* minor fix

* index range fix

Signed-off-by: Abdelrauf <rauf@konduit.ai>

* noop on empty outputs

* minor fix

* minor fix

Signed-off-by: Abdelrauf <rauf@konduit.ai>

* ArgMax replaces IMax

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* argmax/argmin/argamax/argamin shape functions updated

* ArgAmax/ArgAmin/ArgMin replaces IAMax/IAMin/IMin

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* argmax/argmin/argamax/argamin CUDA

* IMax replaced in dl4j

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* Codegen output

* imports fixed

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* fix compilation issue

Signed-off-by: Abdelrauf <rauf@konduit.ai>

* Auto-generate compilation units

Signed-off-by: Abdelrauf <rauf@konduit.ai>

* Should fix NDArray refactored function calls in indexReductions.cu

Signed-off-by: Abdelrauf <rauf@konduit.ai>

Co-authored-by: raver119@gmail.com <raver119@gmail.com>
Co-authored-by: Alexander Stoyakin <alexander.stoyakin@gmail.com>
2020-05-14 13:41:55 +03:00
Alex Black 62e9dc83e0
Merge pull request #8950 from eclipse/release/1.0.0-beta7
Release 1.0.0-beta7
2020-05-14 16:56:15 +10:00
Serhii Shepel da4256b8bb Update to version 1.0.0-SNAPSHOT
Signed-off-by: Serhii Shepel <9946053+sshepel@users.noreply.github.com>
2020-05-13 18:16:08 +03:00
Serhii Shepel 81be92a554 Update to version 1.0.0-beta7
Signed-off-by: Serhii Shepel <9946053+sshepel@users.noreply.github.com>
2020-05-13 18:13:51 +03:00
Alex Black 1a6ada0ce9
Merge pull request #8949 from KonduitAI/master
Pre-release fixes
2020-05-14 00:39:50 +10:00
Fariz Rahman 1c15d0f33e
casting fixes (#464) 2020-05-14 00:36:38 +10:00
raver119 60f103fb03
[WIP] Few more pre-release fixes (#461)
* error code check in CudaMemoryManager

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* clear

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* clear model before exiting

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* MultiLayerNetwork/ComputationGraph.close() [WIP] (#460)

* MultiLayerNetwork/ComputationGraph.close()

Signed-off-by: Alex Black <blacka101@gmail.com>

* Copyright header

Signed-off-by: Alex Black <blacka101@gmail.com>

* Fix

Signed-off-by: Alex Black <blacka101@gmail.com>

* - fix for handling release of nested DataBuffers
- couple of additional tests for released DataBuffers

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* PW test: increase number of epochs slightly

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

Co-authored-by: Alex Black <blacka101@gmail.com>
2020-05-13 16:00:54 +03:00
Alex Black 1ce65fced4
Fix missing comma (#463)
Signed-off-by: Alex Black <blacka101@gmail.com>
2020-05-13 21:05:39 +10:00
Andrii T 3714214b8c
temporary ignored section added (#462)
Signed-off-by: Andrii Tuzhykov <andrewtuzhykov@gmail.com>
2020-05-13 21:02:57 +10:00
Alex Black a4d74ec4d0
Fix wrong indexer for some DataBuffer constructors for UINT32 datatype (#458)
Signed-off-by: Alex Black <blacka101@gmail.com>
2020-05-13 19:47:51 +10:00
raver119 c396fcb960
More pre-release fixes (#456)
* - numPrefixBlocks fix for threshold_encoding
- temparrays pointers fixed

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* auto configuration of memory workspace for gradients sharing

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* limit sparse encoding message size

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* one more workspace test

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* one more CUDA-specific test

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* one more CUDA-specific workspace test

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* one more CUDA-specific workspace test

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* one more CUDA-specific workspace test

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* add separate host/device reset for circular workspace mode

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* new PW builder method for encoder memory amount

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* "inplace" execution for threshold encoding

Signed-off-by: raver119@gmail.com <raver119@gmail.com>
2020-05-13 08:12:07 +03:00
Alex Black f547f783d9
Keras import - remove debug lines (println/log) [WIP] (#459)
* Remove debug line from KerasConvolution2D

Signed-off-by: Alex Black <blacka101@gmail.com>

* Remove more debug lines

Signed-off-by: Alex Black <blacka101@gmail.com>
2020-05-13 14:50:23 +10:00
Alex Black 5e55e92002
Empty array casting fix (#457)
* Empty array casting fix

Signed-off-by: Alex Black <blacka101@gmail.com>

* Tests

Signed-off-by: Alex Black <blacka101@gmail.com>
2020-05-13 01:37:11 +10:00
Alex Black bfaa20e46c
Merge pull request #8935 from KonduitAI/master
Pre-release updates [WIP]
2020-05-12 14:56:08 +10:00
Alex Black bf017b458c Merge remote-tracking branch 'eclipse/master' 2020-05-12 14:53:58 +10:00
Alex Black 5e9ee8b958
ND4J no backend URL (#453)
Signed-off-by: Alex Black <blacka101@gmail.com>
2020-05-12 14:52:48 +10:00
raver119 7d6f628b88
stop using static library for tests (#450)
Signed-off-by: raver119 <raver119@gmail.com>
2020-05-12 07:48:29 +03:00
Yurii Shyrma 76f3553679
Shyrma merge max ind (#443)
* - provide correct possible output types in mergeMaxIndex op

Signed-off-by: Yurii <iuriish@yahoo.com>

* - cleaning up the unneeded backprop arg in reverse_bp op

Signed-off-by: Yurii <iuriish@yahoo.com>

* - improve clipByNorm both ff and bp

Signed-off-by: Yurii <iuriish@yahoo.com>

* - implementation and testing clipByAvgNorm_bp op

Signed-off-by: Yurii <iuriish@yahoo.com>

* - pass biases in any way in dnnl lstm op, they are zeros when user doesn't provide them to us

Signed-off-by: Yurii <iuriish@yahoo.com>

* - start working on mkldnn concat op

Signed-off-by: Yurii <iuriish@yahoo.com>

* - further work on mkldnn concat

Signed-off-by: Yurii <iuriish@yahoo.com>

* missing declaration fix

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* - polishing mkl ops

Signed-off-by: Yurii <iuriish@yahoo.com>

* - testing and fixing bugs in mkl concat op

Signed-off-by: Yurii <iuriish@yahoo.com>

* - fix linkage error for windows cuda build

Signed-off-by: Yurii <iuriish@yahoo.com>

* - further conflicts resolving with master

Signed-off-by: Yurii <iuriish@yahoo.com>

* - fix format tags in mkldnn matmul op

Signed-off-by: Yurii <iuriish@yahoo.com>

* - provide additional type cast in clip.cu

Signed-off-by: Yurii <iuriish@yahoo.com>

* - finally bug in mkldnn tanh_bp was caught

Co-authored-by: raver119@gmail.com <raver119@gmail.com>
2020-05-12 07:47:09 +03:00
Alex Black 872a511042
Update docs links to new website URLs [WIP] (#452)
* Update docs links to new website URLs

Signed-off-by: Alex Black <blacka101@gmail.com>

* One more link

Signed-off-by: Alex Black <blacka101@gmail.com>
2020-05-12 13:02:19 +10:00
Alex Black e2cd461578
Remove iOS from nd4j-native-platform until fixed (#451)
Signed-off-by: Alex Black <blacka101@gmail.com>
2020-05-12 12:31:52 +10:00
Alex Black ed5a2e56f9
Merge pull request #8931 from KonduitAI/master
bump up shared memory (#449) [WIP]
2020-05-11 23:58:36 +10:00
raver119 05c0f12c73
bump up shared memory (#449)
Signed-off-by: raver119@gmail.com <raver119@gmail.com>
2020-05-11 16:55:23 +03:00
Alex Black 9db86cec7a
Merge pull request #8930 from KonduitAI/master
Development updates
2020-05-11 22:57:02 +10:00
Alex Black 0d8b2d65cd Merge remote-tracking branch 'eclipse/master' 2020-05-11 22:53:22 +10:00
raver119 f0adb6f788
[WIP] minor fixes (#447)
* couple of tests disabled

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* few syncs removed, some logging added

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* some logging added

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* some logging added

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* fix min num_threads

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* fixed wrong release function for scalarPointer

Signed-off-by: raver119@gmail.com <raver119@gmail.com>
2020-05-11 15:41:43 +03:00
Alex Black b786418c5d
Fix an issue when creating DataBuffer/INDArray from ByteBuffer for multiple datatypes (#446)
* Fix missing dtypes when creating DataBuffer from ByteBuffer

Signed-off-by: Alex Black <blacka101@gmail.com>

* Revert LongIndexer -> ULongIndexer; fixes for UIntIndexer

Signed-off-by: Alex Black <blacka101@gmail.com>

* CUDA fix

Signed-off-by: Alex Black <blacka101@gmail.com>
2020-05-11 21:29:52 +10:00
Alex Black a76f957b72
Merge pull request #8872 from printomi/ui_multisession_arbiter
DL4J UI: Add multi-session support for Arbiter
2020-05-11 19:24:17 +10:00
Alex Black 91a2004d8f
Assorted fixes (#445)
* #8890 TestTransferStatsCollection timeout fix

Signed-off-by: Alex Black <blacka101@gmail.com>

* #8890 RegressionTest timeout fix

Signed-off-by: Alex Black <blacka101@gmail.com>

* Increase timeout for flaky test

Signed-off-by: Alex Black <blacka101@gmail.com>

* Remove test dependency

Signed-off-by: Alex Black <blacka101@gmail.com>

* BLAS iamax + loop -> argmax

Signed-off-by: Alex Black <blacka101@gmail.com>
2020-05-11 15:57:00 +10:00
Alex Black 57d16653c8 Merge remote-tracking branch 'eclipse/master' 2020-05-11 12:55:36 +10:00
Paul Dubs 2cdb2b3447
Remove GloVe (#437)
GloVe has been unmaintained and broken for a long time. The only people asking about it where those who were stumped by the broken example.

GloVe on its own has one intrinsic problem: a vocabulary of size N requires to build a matrix of NxN. This resulted in suboptimal performance for most people.

Overall, there are better performing approaches these days so it isn't worth the effort to fix this implementation.

Signed-off-by: Paul Dubs <paul.dubs@gmail.com>
2020-05-11 12:31:28 +10:00
Alex Black ea56ce7471 Import fix given recent refactoring
Signed-off-by: Alex Black <blacka101@gmail.com>
2020-05-11 12:25:31 +10:00
Alex Black 20f451e807 Merge remote-tracking branch 'eclipse/master' into ui_multisession_arbiter 2020-05-11 11:49:50 +10:00
Alex Black 58fe365c21
Merge pull request #8908 from hosuaby/feature/loadModelFromStream
FEATURE: change API of WordVectorSerializer. Add posibility to read m…
2020-05-11 11:45:48 +10:00
Alex Black 6844cfe126
Merge pull request #8929 from KonduitAI/master
Development updates
2020-05-09 20:00:02 +10:00
Alex Black e883256400 Merge remote-tracking branch 'eclipse/master' 2020-05-09 19:58:07 +10:00
raver119 10d6c3b024
do not relocate stuff on java side (#444)
Signed-off-by: raver119@gmail.com <raver119@gmail.com>
2020-05-09 12:56:45 +03:00
raver119 2849299bfb
Fix for https://github.com/eclipse/deeplearning4j/issues/8909 (#430)
Signed-off-by: raver119@gmail.com <raver119@gmail.com>
2020-05-09 08:09:26 +03:00
raver119 320924278d
Legacy API changes (#441)
* initial commit

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* another initial commit

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* another initial commit

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* one more initial commit

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* next step

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* next step

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* next step

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* next step

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* Refactored buffer() and shapeInfo() methods usage with NDArray class.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopt Graph class methods to use const shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopt choose op to use constant shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopt where op shape method to use constant shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopt lstsq op to use constant empty shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopt matrix_diag_part op shape routine to use constant shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopt determinant ops to use constant shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopt mean_pairwssqerr_loss ops to use constant shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopt ops shape methods.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopt shape methods for loss ops.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopt log_loss op shape method.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopt shape methods for ops.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopt dilation2d ops shape methods.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopted deconv2d ops shape methods.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopted dynamicRNN op shape method.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopted shape methods for ops.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopted shape methods for lstm layer ops.

Signed-off-by: shugeo <sgazeos@gmail.com>

* few updates

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* first cuda tweak

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* Adopt constant shapes for sconv2d ops.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopt constant shapes for gru ops.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopt constant shapes with shape methods for segment ops and so on.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopted constant shapes with unsorted_segment_* ops.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopted constant shapes with gamma op shape method.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopted shape methods of reduce_stddev ops.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopted shape methods for reduce_* ops.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopt shape method for squeeze op.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopt strided_slice shape method.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored concat op shape method to adopt constant shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopted shape method for mirror_pad op.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopted split op shape method.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopted tile ops shape methods.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Added const cast for mkldnn routines handles.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored logSoftMaxForVector_ routine to conform with proper data and shape pointer casts.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Cosmetic changes to proper usage of constant pointers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored a couple shape comparators for strides and addBias helpers to proper use data pointers with inplace option.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored depthToSpace helpers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored histogram helpers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored im2col helpers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored gather and gatherND helpers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed buffer usage on percentile helper.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed gather shape with helpers and range buffer usage.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed buffer usage with space to depth helpers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed buffer usage and constant shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed buffer usage with LUP decomposition>

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored onehot_ helper.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored pad and prefix to use constant shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactoed softmax helpers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed space to batch helpers to use buffers properly.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed stack and split helpers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed buffer usage with sparse to dense helpers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed buffer usage with mindistance_ helpers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed buffer usage with tile helper.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed constant shape usage.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed constant shape usage with legacy pairwise bool ops.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored a couple of methods to adopt constant shape usage.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed broadcasting with constant shape."

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed const usage with inplace reverse and constant shapes with legacy reduction.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored legacy ops with const shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored sort to adopt constant shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Corrected sort for constant shape usage.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed constant shape usage with special methods.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored Context to conform with constant shape usage.

Signed-off-by: shugeo <sgazeos@gmail.com>

* CUDA broadcasting headers

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* pairwise/indexreduce/random headers

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* Refactored native ops to adopt constant shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* legacy reduce3/scalar headers

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* Corrected pullRow signature and tests.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Corrected routines to proper use of constant shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored tests to use constant shapes properly.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored legacy ops tests to use constant shapes properly.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored buffer usage with NDArray tests.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed native ops tests.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed special concat routine.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed buffer usage with test.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed buffer usage with a test.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored TAD.h and tests.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored calcStrides* routines to use constant shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed miscelaneous errors with constant shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* NativeOps const changes

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* Corrected definitions for declared functions.

Signed-off-by: shugeo <sgazeos@gmail.com>

* NativeOps const changes

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* few more const changes

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* Fixed const shapes with shape routines.

Signed-off-by: shugeo <sgazeos@gmail.com>

* few more const changes

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* Fixed shape method for broadcastable case.

Signed-off-by: shugeo <sgazeos@gmail.com>

* few more const changes

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* xw_plus_b BP shape fn restored

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* Fixed signatures with broadcasting.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Repaired backprops shape methods for a set of operations.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored broadcast bool for cuda.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored methods for 3 args with const qualifier.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed a couple of kernel signatures for broadcasting.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed kernels signatures for const buffers and shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored pairwise methods to persistent buffers and shapes usage.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopt const to buffers and shapes with kernels.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopt const to buffers and shapes with scalar kernels.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored indexreduce kernels signatures to use const buffers and shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored pairwise kernels to adopt cons shapes and buffers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored pairwise bool kernels to adopt cons shapes and buffers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored random special ops to conform with const shapes and buffers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored native ops to conform with const shapes and buffers under cuda platform.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Cosmetical changes only.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed const shapes and buffers error.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Corrected start pos routine.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored methods to conform with const shapes and buffers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored helpers to use proper methods instead.

Signed-off-by: shugeo <sgazeos@gmail.com>

* bunch of changes

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* next bunch of changes

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* next bunch of changes

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* Fixed execScalar declaration.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed execScalar declaration.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Corrected const shape cases with sort and so on.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed const shapes for sort.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored kernel declarations to adopt const shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed kernels declarations to adopt const shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Corrected kernel declarations to adopt const shapes and buffers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed kernels declarations to adopt const shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed segment helpers kernels declarations and so on to adopt const shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed const shape usage with segment and solve helpers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed kernel declaration with adjustWeight helper.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed cuda implementations for constant shape helpers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopted const shape usage with kernels.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Adopted top_k kernels to use const shapes and buffers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Corrected kernels declarations to adopt const shapes with helpers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored NDArray definitions to adopt const shapes and buffers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed const shapes with image suppression helpers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Slight improvement with buffers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored buffer usage.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored buffer usage with tests.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed const shape usage with definitions.

Signed-off-by: shugeo <sgazeos@gmail.com>

* minor updates on cpu side

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* Refactored const shape usage with ConstantDescritor and native ops with cuda platform.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored tear and tile kernels to adopt with const shapes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* softmax_loop fix

Signed-off-by: raver119 <raver119@gmail.com>

* update missing signature

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* softmax again

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* few more missing consts

Signed-off-by: raver119 <raver119@gmail.com>

* new methods updated

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

Co-authored-by: shugeo <sgazeos@gmail.com>
2020-05-09 08:06:14 +03:00
raver119 0613485654
compression ops (#436)
* Added declarations for decode/encode_bitmap ops.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Added implementation for bitmap encoding/decoding ops.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Added helpers for encode/decode bitmap ops.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored encodingBitmap helper.

Signed-off-by: shugeo <sgazeos@gmail.com>

* threshold encode/decode skeleton

* helper skeleton

* minor import fix

* encoder shape fn & op impl

* thresholdEncode cpu impl

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* thresholdDecode cpu impl

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* Only cosmetical changes.

Signed-off-by: shugeo <sgazeos@gmail.com>

* placeholder

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* Added cuda implementation for bitmap decode helper.

Signed-off-by: shugeo <sgazeos@gmail.com>

* cuda thresholdEstimate

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* cuda thresholdDecode

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* next step

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* - nano cmakelist update (get rid of Clion section)
- fixed forgotten throw in AtomicTests

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* thesholdEncode cuda impl

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* Added tests for bitmap encoding/decoding ops.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed tests for encode/decode bitmaps.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Refactored decode/encode helpers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* Fixed crashes with bitmap decode/encode helpers.

Signed-off-by: shugeo <sgazeos@gmail.com>

* bitmap encode/decode CPU

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* bitmap encode/decode CUDA

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* C API removed for threshold/bitmap encode

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* EncodeBitmap/DecodeBitmap Java side

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* EncodeThreshold/DecodeThreshold Java side

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* EncodeThreshold/DecodeThreshold Java side

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* few more tests for threshold encoding

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* minor test tweak

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* two special tests

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* encodeBitmap CPU fix

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* parallel_long/parallel_double proper spans fix

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* encodeThreshold CUDA fix

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* nano fix

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* grid tweaks

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* RTX adaptation for thresholdEncode

Signed-off-by: raver119 <raver119@gmail.com>

* don't allow threshold encoding for length < 2

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* get rid of NDArrayCompressor in EncodingHandler

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* one more minor update of EncodingHandler

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* one more minor tweak of EncodingHandler

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* - matmul allows integer data types use
- EncodingHandler boundary default value
- few tests for integer matmul

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* minor fix of CUDA bitmap encode

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* boundary changed to integer everywhere

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* boundary changed to integer everywhere

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* re-enable CUDA deallocator

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* threshold encoder fix for systems without omp

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* - encode_threshold now requires non-negative boundary
- minor tweak in EncodingHandler

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* restore parallelism in decode_bitmap

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* fall back to omp for encode_bitmap cpu

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* single time casts

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

* - additional test for encode_threshold
- sync buffers to device before calling for shape function

Signed-off-by: raver119@gmail.com <raver119@gmail.com>

Co-authored-by: shugeo <sgazeos@gmail.com>
2020-05-08 20:59:39 +03:00
Tamás Fenyvesi 9f47c8aca8 narrow down UIServer.stop() to declare throwing InterruptedException; fix typo in test
Signed-off-by: Tamás Fenyvesi <tamas.fenyvesi@doknet.hu>
2020-05-08 13:08:01 +02:00
Tamás Fenyvesi cf24728f35 tests for auto-attach and manual attach; improve JavaDoc
Signed-off-by: Tamás Fenyvesi <tamas.fenyvesi@doknet.hu>
2020-05-08 13:08:00 +02:00