From 75e1fb9005445f894634eadd41d5562ed7e7e802 Mon Sep 17 00:00:00 2001 From: brian Date: Wed, 26 Oct 2022 12:59:25 +0200 Subject: [PATCH] Add jenkinsfile for pipeline build and dockerfile for build Signed-off-by: brian --- .gitignore | 16 +- {.github => .old/.github}/ISSUE_TEMPLATE.md | 0 .../.github}/PULL_REQUEST_TEMPLATE.md | 0 .../action.yml | 0 .../action.yml | 0 .../install-arm-cross-compile/action.yml | 0 .../actions/install-cmake-linux/action.yml | 0 .../actions/install-protobuf-linux/action.yml | 0 .../actions/msys2-base-setup/action.yml | 0 .../actions/publish-gh-packages/action.yml | 0 .../actions/update-deps-linux/action.yml | 0 .../workflows/build-android-x86_64.yml | 0 .../workflows/build-deploy-android-arm32.yml | 0 .../workflows/build-deploy-android-arm64.yml | 0 .../workflows/build-deploy-linux-arm32.yml | 0 .../workflows/build-deploy-linux-arm64.yml | 0 .../build-deploy-linux-cuda-11.0.yml | 0 .../build-deploy-linux-cuda-11.2.yml | 0 .../workflows/build-deploy-linux-x86_64.yml | 0 .../.github}/workflows/build-deploy-mac.yml | 0 .../build-deploy-windows-cuda-11.0.yml | 0 .../build-deploy-windows-cuda-11.2.yml | 0 .../workflows/build-deploy-windows.yml | 0 .../workflows/cpu-integration-tests.yaml | 0 .../workflows/cpu-sanity-check-tests.yaml | 0 .../workflows/run-cpu-tests-sanity-checks.yml | 0 .../workflows/run-gpu-tests-sanity-checks.yml | 0 .../workflows/test_multiple_arch.yaml | 0 .../ADRs}/0001-SameDiff_File_Format.md | 0 {ADRs => .old/ADRs}/0002-ONNX_Runtime.md | 0 {ADRs => .old/ADRs}/0003-Import_IR.md | 0 .../ADRs}/0003-NdArray_Strides_ArmCompute.md | 0 {ADRs => .old/ADRs}/0004-Mapping_IR.md | 0 {ADRs => .old/ADRs}/0005-Interpreter.md | 0 .../change-cuda-versions.sh | 0 .../change-scala-versions.sh | 0 {contrib => .old/contrib}/README.md | 0 .../adr/0001-kotlin_dsl_as_source_of_truth.md | 0 ...separate_object_graph_for_serialization.md | 0 ...ing_with_inconsistencies_in_java_naming.md | 0 ...o_initialization_for_inplace_operations.md | 0 ...0005-optional_parameters_and_signatures.md | 0 .../codegen/adr/0006-op_specific_enums.md | 0 .../codegen/adr/0007-configuration_objects.md | 0 .../codegen/adr/0008-inheritance.md | 0 .../codegen/adr/0009-aliasing.md | 0 .../codegen/adr/0010-ir-codegen.md | 0 .../main/java/org/nd4j/codegen/Namespace.java | 0 .../main/java/org/nd4j/codegen/cli/CLI.java | 0 .../nd4j/codegen/impl/cpp/CppGenerator.java | 0 .../nd4j/codegen/impl/java/DocsGenerator.java | 0 .../codegen/impl/java/JavaPoetGenerator.java | 0 .../impl/java/Nd4jNamespaceGenerator.java | 0 .../codegen/impl/python/PythonGenerator.java | 0 .../nd4j/codegen/ir/SerializationTest.java | 0 .../java/org/nd4j/codegen/util/GenUtil.java | 0 .../org/nd4j/codegen/util/JsonMapper.java | 0 .../org/nd4j/codegen/api/CodeComponent.kt | 0 .../kotlin/org/nd4j/codegen/api/DataType.kt | 0 .../kotlin/org/nd4j/codegen/api/Language.kt | 0 .../kotlin/org/nd4j/codegen/api/LossReduce.kt | 0 .../kotlin/org/nd4j/codegen/api/Namespace.kt | 0 .../org/nd4j/codegen/api/NamespaceOps.kt | 0 .../main/kotlin/org/nd4j/codegen/api/Op.kt | 0 .../kotlin/org/nd4j/codegen/api/Registry.kt | 0 .../kotlin/org/nd4j/codegen/api/Variables.kt | 0 .../org/nd4j/codegen/api/doc/DocScope.kt | 0 .../org/nd4j/codegen/api/doc/DocSection.kt | 0 .../org/nd4j/codegen/api/doc/DocTokens.kt | 0 .../api/generator/ConstraintCodeGenerator.kt | 0 .../nd4j/codegen/api/generator/Generator.kt | 0 .../codegen/api/generator/GeneratorConfig.kt | 0 .../kotlin/org/nd4j/codegen/dsl/OpBuilder.kt | 0 .../impl/java/JavaConstraintCodeGenerator.kt | 0 .../python/KotlinExamplePythonGenerator.kt | 0 .../org/nd4j/codegen/util/GenerateOps.kt | 0 .../util/extract/ExtractFromExisting.kt | 0 .../util/extract/FindUsedParameterTypes.kt | 0 .../ops/org/nd4j/codegen/mixins/Mixins.kt | 0 .../main/ops/org/nd4j/codegen/ops/Bitwise.kt | 0 .../src/main/ops/org/nd4j/codegen/ops/CNN.kt | 0 .../main/ops/org/nd4j/codegen/ops/Image.kt | 0 .../main/ops/org/nd4j/codegen/ops/Linalg.kt | 0 .../src/main/ops/org/nd4j/codegen/ops/Math.kt | 0 .../ops/org/nd4j/codegen/ops/NeuralNetwork.kt | 0 .../src/main/ops/org/nd4j/codegen/ops/RNN.kt | 0 .../main/ops/org/nd4j/codegen/ops/Random.kt | 0 .../ops/org/nd4j/codegen/ops/SDBaseOps.kt | 0 .../main/ops/org/nd4j/codegen/ops/SDLoss.kt | 0 .../codegen/src/main/resources/logback.xml | 0 .../src/main/resources/namespaces/math.json | 0 .../src/main/resources/nd4j-op-defs-2.proto | 0 .../src/main/resources/onnx-op-defs.pb | Bin .../codegen/src/main/resources/onnx.pbtxt | 0 .../main/resources/tensorflowOpMappings.csv | 0 .../nd4j/codegen/dsl/DocsGeneratorTest.java | 0 .../org/nd4j/codegen/dsl/TestGeneration.java | 0 .../kotlin/org/nd4j/codegen/dsl/ConfigTest.kt | 0 .../org/nd4j/codegen/dsl/ConstraintTest.kt | 0 .../codegen/dsl/NamespaceInvariantTest.kt | 0 .../org/nd4j/codegen/dsl/OpBuilderTest.kt | 0 .../org/nd4j/codegen/dsl/OpInvariantTest.kt | 0 .../org/nd4j/codegen/ops/ConstructionTest.kt | 0 .../codegen/src/test/resources/lenet.onnx | Bin .../src/test/resources/lenet_frozen.pb | Bin .../codegen-tools/libnd4j-gen/README.md | 0 .../codegen-tools/libnd4j-gen/op-ir.proto | 0 .../codegen-tools/libnd4j-gen/pom.xml | 0 .../descriptor/OpDeclarationDescriptor.java | 0 .../java/org/nd4j/descriptor/ParseOpFile.java | 0 .../proposal/ArgDescriptorProposal.java | 0 .../proposal/ArgDescriptorSource.java | 0 .../impl/ArgDescriptorParserUtils.java | 0 .../impl/JavaSourceArgDescriptorSource.java | 0 .../impl/Libnd4jArgDescriptorSource.java | 0 .../codegen-tools/onnx-def-gen/README.md | 0 .../codegen-tools/onnx-def-gen/lenet.onnx | Bin .../onnx-def-gen/onnx-op-defs.pb | Bin .../codegen-tools/onnx-def-gen/onnx.pbtxt | 0 .../onnx-def-gen/onnx_def_gen.py | 0 .../codegen-tools/onnx-def-gen/save_test.py | 0 .../onnx-def-gen/test_onnx_lenet.py | 0 .../onnx-def-gen/test_op_def_gen.py | 0 {contrib => .old/contrib}/formatter.xml | 0 .../deeplearning4j}/.codeclimate.yml | 0 .../deeplearning4j}/CONTRIBUTORS.md | 0 .../deeplearning4j}/GITTER_GUIDELINES.md | 0 .../deeplearning4j}/README.md | 0 .../buildmultiplescalaversions.sh | 0 .../deeplearning4j-dataimport-solrj/pom.xml | 0 .../io/stream/TupleStreamDataSetIterator.java | 0 .../TupleStreamDataSetIteratorTest.java | 0 .../test/resources/solr/collection1/README | 0 .../solr/configsets/mini/conf/schema.xml | 0 .../solr/configsets/mini/conf/solrconfig.xml | 0 .../deeplearning4j-graph/pom.xml | 0 .../deeplearning4j/graph/api/BaseGraph.java | 0 .../org/deeplearning4j/graph/api/Edge.java | 0 .../org/deeplearning4j/graph/api/IGraph.java | 0 .../graph/api/IVertexSequence.java | 0 .../graph/api/NoEdgeHandling.java | 0 .../org/deeplearning4j/graph/api/Vertex.java | 0 .../graph/data/EdgeLineProcessor.java | 0 .../graph/data/GraphLoader.java | 0 .../graph/data/VertexLoader.java | 0 .../data/impl/DelimitedEdgeLineProcessor.java | 0 .../data/impl/DelimitedVertexLoader.java | 0 .../data/impl/WeightedEdgeLineProcessor.java | 0 .../graph/exception/NoEdgesException.java | 0 .../graph/exception/ParseException.java | 0 .../org/deeplearning4j/graph/graph/Graph.java | 0 .../graph/graph/VertexSequence.java | 0 .../graph/iterator/GraphWalkIterator.java | 0 .../graph/iterator/RandomWalkIterator.java | 0 .../iterator/WeightedRandomWalkIterator.java | 0 .../parallel/GraphWalkIteratorProvider.java | 0 .../RandomWalkGraphIteratorProvider.java | 0 ...ightedRandomWalkGraphIteratorProvider.java | 0 .../graph/models/BinaryTree.java | 0 .../graph/models/GraphVectors.java | 0 .../graph/models/deepwalk/DeepWalk.java | 0 .../graph/models/deepwalk/GraphHuffman.java | 0 .../embeddings/GraphVectorLookupTable.java | 0 .../models/embeddings/GraphVectorsImpl.java | 0 .../embeddings/InMemoryGraphLookupTable.java | 0 .../models/loader/GraphVectorSerializer.java | 0 .../vertexfactory/IntegerVertexFactory.java | 0 .../vertexfactory/StringVertexFactory.java | 0 .../graph/vertexfactory/VertexFactory.java | 0 .../vertexfactory/VoidVertexFactory.java | 0 .../graph/AssertTestsExtendedBaseClass.java | 0 .../graph/data/TestGraphLoading.java | 0 .../graph/data/TestGraphLoadingWeighted.java | 0 .../deeplearning4j/graph/graph/TestGraph.java | 0 .../deepwalk/DeepWalkGradientCheck.java | 0 .../graph/models/deepwalk/TestDeepWalk.java | 0 .../models/deepwalk/TestGraphHuffman.java | 0 .../deeplearning4j-tsne/pom.xml | 0 .../deeplearning4j/plot/BarnesHutTsne.java | 0 .../java/org/deeplearning4j/plot/Tsne.java | 0 .../org/deeplearning4j/plot/Test6058.java | 0 .../org/deeplearning4j/plot/TsneTest.java | 0 .../deeplearning4j-manifold/pom.xml | 0 .../deeplearning4j-modelexport-solr/pom.xml | 0 .../solr/handler/ModelTupleStream.java | 0 .../solr/ltr/model/ScoringModel.java | 0 .../ModelTupleStreamIntegrationTest.java | 0 .../solr/handler/ModelTupleStreamTest.java | 0 .../solr/ltr/model/ScoringModelTest.java | 0 .../test/resources/solr/collection1/README | 0 .../mini-expressible/conf/schema.xml | 0 .../mini-expressible/conf/solrconfig.xml | 0 .../deeplearning4j-json-server/pom.xml | 0 .../deeplearning4j/remote/DL4jServlet.java | 0 .../remote/JsonModelServer.java | 0 .../remote/AssertTestsExtendBaseClass.java | 0 .../remote/BinaryModelServerTest.java | 0 .../remote/JsonModelServerTest.java | 0 .../deeplearning4j/remote/ServletTest.java | 0 .../deeplearning4j/remote/helpers/House.java | 0 .../helpers/HouseToPredictedPriceAdapter.java | 0 .../remote/helpers/ImageConversionUtils.java | 0 .../remote/helpers/PredictedPrice.java | 0 .../src/test/resources/logback.xml | 0 .../deeplearning4j-remote/pom.xml | 0 .../deeplearning4j-scaleout/pom.xml | 0 .../spark/dl4j-spark-nlp-java8/pom.xml | 0 .../SparkParagraphVectors.java | 0 .../DocumentSequenceConvertFunction.java | 0 .../functions/KeySequenceConvertFunction.java | 0 .../sequencevectors/SparkSequenceVectors.java | 0 .../export/ExportContainer.java | 0 .../export/SparkModelExporter.java | 0 .../export/impl/HdfsModelExporter.java | 0 .../export/impl/VocabCacheExporter.java | 0 .../functions/BaseTokenizerFunction.java | 0 .../functions/CountFunction.java | 0 .../functions/DistributedFunction.java | 0 .../ElementsFrequenciesAccumulator.java | 0 .../functions/ExportFunction.java | 0 .../functions/ExtraCountFunction.java | 0 .../ExtraElementsFrequenciesAccumulator.java | 0 .../ListSequenceConvertFunction.java | 0 .../functions/PartitionTrainingFunction.java | 0 .../functions/TokenizerFunction.java | 0 .../functions/TrainingFunction.java | 0 .../functions/VocabRddFunctionFlat.java | 0 .../SparkElementsLearningAlgorithm.java | 0 .../SparkSequenceLearningAlgorithm.java | 0 .../elements/BaseSparkLearningAlgorithm.java | 0 .../learning/elements/SparkCBOW.java | 0 .../learning/elements/SparkSkipGram.java | 0 .../BaseSparkSequenceLearningAlgorithm.java | 0 .../learning/sequence/SparkDBOW.java | 0 .../learning/sequence/SparkDM.java | 0 .../primitives/ExtraCounter.java | 0 .../spark/models/word2vec/SparkWord2Vec.java | 0 .../SparkSequenceVectorsTest.java | 0 .../export/ExportContainerTest.java | 0 .../models/word2vec/SparkWord2VecTest.java | 0 .../src/test/resources/log4j.properties | 0 .../src/test/resources/logback.xml | 0 .../spark/dl4j-spark-nlp/.gitignore | 0 .../spark/dl4j-spark-nlp/pom.xml | 0 .../word2vec/FirstIterationFunction.java | 0 .../word2vec/MapToPairFunction.java | 0 .../embeddings/word2vec/NegativeHolder.java | 0 .../word2vec/SecondIterationFunction.java | 0 .../embeddings/word2vec/SentenceBatch.java | 0 .../embeddings/word2vec/VocabHolder.java | 0 .../models/embeddings/word2vec/Word2Vec.java | 0 .../embeddings/word2vec/Word2VecChange.java | 0 .../embeddings/word2vec/Word2VecFuncCall.java | 0 .../embeddings/word2vec/Word2VecParam.java | 0 .../word2vec/Word2VecPerformer.java | 0 .../word2vec/Word2VecPerformerVoid.java | 0 .../embeddings/word2vec/Word2VecSetup.java | 0 .../word2vec/Word2VecVariables.java | 0 .../MaxPerPartitionAccumulator.java | 0 .../accumulators/WordFreqAccumulator.java | 0 .../spark/text/functions/CountCumSum.java | 0 .../FoldBetweenPartitionFunction.java | 0 .../FoldWithinPartitionFunction.java | 0 .../functions/GetSentenceCountFunction.java | 0 .../MapPerPartitionVoidFunction.java | 0 .../text/functions/ReduceSentenceCount.java | 0 .../spark/text/functions/TextPipeline.java | 0 .../text/functions/TokenizerFunction.java | 0 .../UpdateWordFreqAccumulatorFunction.java | 0 .../WordsListToVocabWordsFunction.java | 0 .../embeddings/word2vec/Word2VecTest.java | 0 .../spark/text/BaseSparkTest.java | 0 .../spark/text/TestFunction.java | 0 .../spark/text/TextPipelineTest.java | 0 .../src/test/resources/log4j.properties | 0 .../src/test/resources/logback.xml | 0 .../spark/dl4j-spark-parameterserver/pom.xml | 0 .../ParameterServerSubscriber.java | 0 .../ParameterServerTrainingHook.java | 0 .../SharedTrainingAccumulationFunction.java | 0 .../SharedTrainingAccumulationTuple.java | 0 .../SharedTrainingAggregateFunction.java | 0 .../DataSetDeserializationCallback.java | 0 .../MultiDataSetDeserializationCallback.java | 0 .../callbacks/PortableDataStreamCallback.java | 0 .../PortableDataStreamMDSCallback.java | 0 .../conf/SharedTrainingConfiguration.java | 0 .../functions/SharedFlatMapDataSet.java | 0 .../functions/SharedFlatMapMultiDataSet.java | 0 .../functions/SharedFlatMapPaths.java | 0 .../functions/SharedFlatMapPathsMDS.java | 0 .../iterators/MultiPdsIterator.java | 0 .../iterators/PdsIterator.java | 0 .../iterators/VirtualDataSetIterator.java | 0 .../iterators/VirtualIterator.java | 0 .../VirtualMultiDataSetIterator.java | 0 .../elephas/ElephasModelImport.java | 0 .../networking/v1/SilentTrainingDriver.java | 0 .../networking/v1/WiredEncodingHandler.java | 0 .../SilentIntroductoryConfirmation.java | 0 .../messages/SilentIntroductoryMessage.java | 0 .../v1/messages/SilentUpdatesMessage.java | 0 .../networking/v2/ModelParamsConsumer.java | 0 .../networking/v2/UpdaterParamsConsumer.java | 0 .../networking/v2/UpdatesConsumer.java | 0 .../networking/v2/WiredEncodingHandler.java | 0 .../pw/SharedTrainingWrapper.java | 0 .../python/ArrayDescriptor.java | 0 .../python/DataSetDescriptor.java | 0 .../spark/parameterserver/python/Utils.java | 0 .../training/SharedTrainingMaster.java | 0 .../training/SharedTrainingResult.java | 0 .../training/SharedTrainingWorker.java | 0 .../util/BlockingObserver.java | 0 .../util/CountingIterator.java | 0 .../spark/parameterserver/BaseSparkTest.java | 0 ...haredTrainingAccumulationFunctionTest.java | 0 .../SharedTrainingAggregateFunctionTest.java | 0 .../iterators/VirtualDataSetIteratorTest.java | 0 .../iterators/VirtualIteratorTest.java | 0 .../elephas/TestElephasImport.java | 0 .../train/GradientSharingTrainingTest.java | 0 .../src/test/resources/log4j.properties | 0 .../src/test/resources/logback.xml | 0 .../spark/dl4j-spark/nd4j-native.properties | 0 .../spark/dl4j-spark/pom.xml | 0 .../spark/api/RDDTrainingApproach.java | 0 .../deeplearning4j/spark/api/Repartition.java | 0 .../spark/api/RepartitionStrategy.java | 0 .../spark/api/Repartitioner.java | 0 .../spark/api/TrainingHook.java | 0 .../spark/api/TrainingMaster.java | 0 .../spark/api/TrainingResult.java | 0 .../spark/api/TrainingWorker.java | 0 .../spark/api/WorkerConfiguration.java | 0 .../api/stats/CommonSparkTrainingStats.java | 0 .../spark/api/stats/SparkTrainingStats.java | 0 .../api/stats/StatsCalculationHelper.java | 0 .../api/worker/ExecuteWorkerFlatMap.java | 0 .../ExecuteWorkerMultiDataSetFlatMap.java | 0 .../api/worker/ExecuteWorkerPDSFlatMap.java | 0 .../worker/ExecuteWorkerPDSMDSFlatMap.java | 0 .../api/worker/ExecuteWorkerPathFlatMap.java | 0 .../worker/ExecuteWorkerPathMDSFlatMap.java | 0 .../spark/api/worker/NetBroadcastTuple.java | 0 .../data/BatchAndExportDataSetsFunction.java | 0 .../BatchAndExportMultiDataSetsFunction.java | 0 .../spark/data/BatchDataSetsFunction.java | 0 .../spark/data/DataSetExportFunction.java | 0 .../spark/data/DataSetProvider.java | 0 .../data/MultiDataSetExportFunction.java | 0 .../spark/data/MultiDataSetProvider.java | 0 .../spark/data/PathToDataSetFunction.java | 0 .../data/PathToMultiDataSetFunction.java | 0 .../spark/data/SplitDataSetsFunction.java | 0 .../spark/data/loader/RemoteFileSource.java | 0 .../data/loader/RemoteFileSourceFactory.java | 0 ...litDataSetExamplesPairFlatMapFunction.java | 0 .../datavec/DataVecByteDataSetFunction.java | 0 .../spark/datavec/DataVecDataSetFunction.java | 0 .../DataVecSequenceDataSetFunction.java | 0 .../DataVecSequencePairDataSetFunction.java | 0 .../spark/datavec/RDDMiniBatches.java | 0 .../spark/datavec/RecordReaderFunction.java | 0 .../export/StringToDataSetExportFunction.java | 0 .../spark/datavec/iterator/DataVecRecord.java | 0 .../datavec/iterator/DataVecRecords.java | 0 .../spark/datavec/iterator/IteratorUtils.java | 0 .../datavec/iterator/RRMDSIFunction.java | 0 .../iterator/SparkSourceDummyReader.java | 0 .../iterator/SparkSourceDummySeqReader.java | 0 .../BaseSparkEarlyStoppingTrainer.java | 0 .../SparkDataSetLossCalculator.java | 0 .../SparkEarlyStoppingGraphTrainer.java | 0 .../SparkEarlyStoppingTrainer.java | 0 .../SparkLossCalculatorComputationGraph.java | 0 .../spark/impl/SparkListenable.java | 0 .../deeplearning4j/spark/impl/common/Add.java | 0 .../impl/common/CountPartitionsFunction.java | 0 .../impl/common/LoadDataSetFunction.java | 0 .../impl/common/SplitPartitionsFunction.java | 0 .../impl/common/SplitPartitionsFunction2.java | 0 .../reduce/IntDoubleReduceFunction.java | 0 .../reduce/LongDoubleReduceFunction.java | 0 .../repartition/BalancedPartitioner.java | 0 .../common/repartition/EqualPartitioner.java | 0 .../HashingBalancedPartitioner.java | 0 .../repartition/MapTupleToPairFlatMap.java | 0 ...eVaeReconstructionProbWithKeyFunction.java | 0 .../score/BaseVaeScoreWithKeyFunction.java | 0 .../impl/evaluation/EvaluationRunner.java | 0 .../impl/graph/SparkComputationGraph.java | 0 .../dataset/DataSetToMultiDataSetFn.java | 0 .../dataset/PairDataSetToMultiDataSetFn.java | 0 .../IEvaluateMDSFlatMapFunction.java | 0 .../IEvaluateMDSPathsFlatMapFunction.java | 0 .../impl/graph/scoring/ArrayPairToPair.java | 0 ...VaeReconstructionErrorWithKeyFunction.java | 0 ...GVaeReconstructionProbWithKeyFunction.java | 0 .../GraphFeedForwardWithKeyFunction.java | 0 .../impl/graph/scoring/PairToArrayPair.java | 0 .../graph/scoring/ScoreExamplesFunction.java | 0 .../scoring/ScoreExamplesWithKeyFunction.java | 0 .../ScoreFlatMapFunctionCGDataSet.java | 0 .../ScoreFlatMapFunctionCGMultiDataSet.java | 0 .../listeners/VanillaStatsStorageRouter.java | 0 .../VanillaStatsStorageRouterProvider.java | 0 .../impl/multilayer/SparkDl4jMultiLayer.java | 0 .../IEvaluateAggregateFunction.java | 0 .../evaluation/IEvaluateFlatMapFunction.java | 0 .../evaluation/IEvaluationReduceFunction.java | 0 .../scoring/FeedForwardWithKeyFunction.java | 0 .../scoring/ScoreExamplesFunction.java | 0 .../scoring/ScoreExamplesWithKeyFunction.java | 0 .../scoring/ScoreFlatMapFunction.java | 0 .../scoring/SingleToPairFunction.java | 0 ...VaeReconstructionErrorWithKeyFunction.java | 0 .../VaeReconstructionProbWithKeyFunction.java | 0 .../impl/paramavg/BaseTrainingMaster.java | 0 .../impl/paramavg/BaseTrainingResult.java | 0 .../impl/paramavg/BaseTrainingWorker.java | 0 .../ParameterAveragingTrainingMaster.java | 0 .../ParameterAveragingTrainingResult.java | 0 .../ParameterAveragingTrainingWorker.java | 0 .../ParameterAveragingAggregationTuple.java | 0 .../ParameterAveragingElementAddFunction.java | 0 ...ameterAveragingElementCombineFunction.java | 0 ...ParameterAveragingTrainingMasterStats.java | 0 ...ParameterAveragingTrainingWorkerStats.java | 0 .../impl/paramavg/util/ExportSupport.java | 0 .../repartitioner/DefaultRepartitioner.java | 0 .../repartitioner/EqualRepartitioner.java | 0 .../impl/repartitioner/NoOpRepartitioner.java | 0 .../spark/iterator/BaseDataSetIterator.java | 0 .../iterator/PathSparkDataSetIterator.java | 0 .../PathSparkMultiDataSetIterator.java | 0 .../PortableDataStreamDataSetIterator.java | 0 ...ortableDataStreamMultiDataSetIterator.java | 0 .../spark/iterator/SparkADSI.java | 0 .../spark/iterator/SparkAMDSI.java | 0 .../spark/ordering/DataSetOrdering.java | 0 .../spark/stats/BaseEventStats.java | 0 .../spark/stats/EventStats.java | 0 .../spark/stats/ExampleCountEventStats.java | 0 .../spark/stats/PartitionCountEventStats.java | 0 .../spark/stats/StatsUtils.java | 0 .../spark/time/NTPTimeSource.java | 0 .../spark/time/SystemClockTimeSource.java | 0 .../deeplearning4j/spark/time/TimeSource.java | 0 .../spark/time/TimeSourceProvider.java | 0 .../deeplearning4j/spark/util/MLLibUtil.java | 0 .../spark/util/SparkDataUtils.java | 0 .../deeplearning4j/spark/util/SparkUtils.java | 0 .../spark/util/data/SparkDataValidation.java | 0 .../spark/util/data/ValidationResult.java | 0 .../data/validation/ValidateDataSetFn.java | 0 .../validation/ValidateMultiDataSetFn.java | 0 .../validation/ValidationResultReduceFn.java | 0 .../util/serde/StorageLevelDeserializer.java | 0 .../util/serde/StorageLevelSerializer.java | 0 .../org/apache/spark/TaskContextHelper.scala | 0 .../spark/BaseSparkKryoTest.java | 0 .../deeplearning4j/spark/BaseSparkTest.java | 0 .../spark/TestEarlyStoppingSpark.java | 0 .../TestEarlyStoppingSparkCompGraph.java | 0 .../org/deeplearning4j/spark/TestKryo.java | 0 .../deeplearning4j/spark/common/AddTest.java | 0 .../spark/data/TestShuffleExamples.java | 0 .../spark/data/TestSparkDataUtils.java | 0 .../spark/datavec/MiniBatchTests.java | 0 .../datavec/TestDataVecDataSetFunctions.java | 0 .../spark/datavec/TestExport.java | 0 .../spark/datavec/TestPreProcessedData.java | 0 .../datavec/iterator/TestIteratorUtils.java | 0 .../spark/impl/TestKryoWarning.java | 0 .../repartition/BalancedPartitionerTest.java | 0 .../HashingBalancedPartitionerTest.java | 0 .../impl/customlayer/TestCustomLayer.java | 0 .../impl/customlayer/layer/CustomLayer.java | 0 .../customlayer/layer/CustomLayerImpl.java | 0 .../impl/graph/TestSparkComputationGraph.java | 0 .../spark/impl/misc/TestFrozenLayers.java | 0 .../impl/multilayer/TestMiscFunctions.java | 0 .../multilayer/TestSparkDl4jMultiLayer.java | 0 ...arameterAveragingSparkVsSingleMachine.java | 0 .../spark/impl/paramavg/TestJsonYaml.java | 0 ...TestSparkMultiLayerParameterAveraging.java | 0 .../impl/paramavg/util/ExportSupportTest.java | 0 .../stats/TestTrainingStatsCollection.java | 0 .../spark/time/TestTimeSource.java | 0 .../spark/ui/TestListeners.java | 0 .../spark/util/MLLIbUtilTest.java | 0 .../spark/util/TestRepartitioning.java | 0 .../spark/util/TestValidation.java | 0 .../src/test/resources/log4j.properties | 0 .../dl4j-spark/src/test/resources/logback.xml | 0 .../deeplearning4j-scaleout/spark/pom.xml | 0 .../deeplearning4j}/pom.xml | 0 {nd4j => .old/nd4j}/README.md | 0 {nd4j => .old/nd4j}/RaspberryPi.md | 0 .../nd4j}/buildmultiplescalaversions.sh | 0 .../nd4j}/nd4j-jdbc/nd4j-jdbc-api/pom.xml | 0 .../nd4j/jdbc/driverfinder/DriverFinder.java | 0 .../nd4j/jdbc/loader/api/JDBCNDArrayIO.java | 0 .../org/nd4j/jdbc/loader/impl/BaseLoader.java | 0 .../nd4j}/nd4j-jdbc/nd4j-jdbc-hsql/pom.xml | 0 .../java/org/nd4j/jdbc/hsql/HsqlLoader.java | 0 .../src/main/resources/nd4j.jdbc.properties | 0 .../org/nd4j/jdbc/hsql/HSqlLoaderTest.java | 0 .../nd4j}/nd4j-jdbc/nd4j-jdbc-mysql/pom.xml | 0 .../java/org/nd4j/jdbc/mysql/MysqlLoader.java | 0 .../src/main/resources/nd4j.jdbc.properties | 0 .../org/nd4j/jdbc/mysql/MysqlLoaderTest.java | 0 {nd4j => .old/nd4j}/nd4j-jdbc/pom.xml | 0 {nd4j => .old/nd4j}/nd4j-onnxruntime/pom.xml | 0 .../onnxruntime/runner/OnnxRuntimeRunner.java | 0 .../org/nd4j/onnxruntime/util/ONNXUtils.java | 0 .../runner/OnnxRuntimeRunnerTests.java | 0 .../src/test/resources/add.onnx | 0 {nd4j => .old/nd4j}/nd4j-remote/README.md | 0 .../nd4j-remote/nd4j-grpc-client/pom.xml | 0 .../remote/grpc/GraphInferenceGrpcClient.java | 0 .../grpc/grpc/GraphInferenceServerGrpc.java | 0 .../graph/GraphInferenceGrpcClientTest.java | 0 .../nd4j-remote/nd4j-json-client/pom.xml | 0 .../remote/clients/JsonRemoteInference.java | 0 .../clients/serde/BinaryDeserializer.java | 0 .../clients/serde/BinarySerializer.java | 0 .../clients/serde/JsonDeserializer.java | 0 .../remote/clients/serde/JsonSerializer.java | 0 .../clients/serde/impl/AbstractSerDe.java | 0 .../clients/serde/impl/BooleanSerde.java | 0 .../clients/serde/impl/DoubleArraySerde.java | 0 .../clients/serde/impl/DoubleSerde.java | 0 .../clients/serde/impl/FloatArraySerde.java | 0 .../remote/clients/serde/impl/FloatSerde.java | 0 .../clients/serde/impl/IntegerSerde.java | 0 .../clients/serde/impl/StringSerde.java | 0 .../nd4j-remote/nd4j-json-server/README.md | 0 .../nd4j-remote/nd4j-json-server/pom.xml | 0 .../nd4j/remote/SameDiffJsonModelServer.java | 0 .../remote/serving/ModelServingServlet.java | 0 .../nd4j/remote/serving/SameDiffServlet.java | 0 .../nd4j/remote/serving/ServingProcessor.java | 0 .../remote/SameDiffJsonModelServerTest.java | 0 .../org/nd4j/remote/SameDiffServletTest.java | 0 .../java/org/nd4j/remote/helpers/House.java | 0 .../helpers/HouseToPredictedPriceAdapter.java | 0 .../nd4j/remote/helpers/PredictedPrice.java | 0 .../nd4j/remote/serde/BasicSerdeTests.java | 0 .../src/test/resources/logback.xml | 0 {nd4j => .old/nd4j}/nd4j-remote/pom.xml | 0 .../nd4j}/nd4j-serde/nd4j-arrow/pom.xml | 0 .../main/java/org/nd4j/arrow/ArrowSerde.java | 0 .../java/org/nd4j/arrow/DataBufferStruct.java | 0 .../java/org/nd4j/arrow/ArrowSerdeTest.java | 0 .../nd4j}/nd4j-serde/nd4j-kryo/pom.xml | 0 .../java/org/nd4j/kryo/Nd4jRegistrator.java | 0 .../java/org/nd4j/kryo/Nd4jSerializer.java | 0 .../primitives/AtomicDoubleSerializer.java | 0 .../org/nd4j/TestNd4jKryoSerialization.java | 0 {nd4j => .old/nd4j}/nd4j-serde/pom.xml | 0 {nd4j => .old/nd4j}/nd4j-tvm/pom.xml | 0 .../java/org/nd4j/tvm/runner/TvmRunner.java | 0 .../main/java/org/nd4j/tvm/util/TVMUtils.java | 0 .../org/nd4j/tvm/runner/TvmRunnerTests.java | 0 {nd4j => .old/nd4j}/pom.xml | 0 {nd4j => .old/nd4j}/samediff-import/pom.xml | 0 .../samediff-import-api/pom.xml | 0 .../frameworkimport/FrameworkImporter.kt | 0 .../frameworkimport/IRProtobufExtensions.kt | 0 .../samediff/frameworkimport/ImportGraph.kt | 0 .../frameworkimport/ImportGraphFactory.kt | 0 .../frameworkimport/ImportGraphHolder.kt | 0 .../context/AbstractMappingContext.kt | 0 .../frameworkimport/context/MappingContext.kt | 0 .../frameworkimport/hooks/PostImportHook.kt | 0 .../frameworkimport/hooks/PreImportHook.kt | 0 .../hooks/annotations/HookResult.kt | 0 .../hooks/annotations/PostHookRule.kt | 0 .../hooks/annotations/PreHookRule.kt | 0 .../samediff/frameworkimport/ir/IRArgDef.kt | 0 .../frameworkimport/ir/IRAttribute.kt | 0 .../samediff/frameworkimport/ir/IRDataType.kt | 0 .../frameworkimport/ir/IRDataTypeValue.kt | 0 .../frameworkimport/ir/IRFunctions.kt | 0 .../samediff/frameworkimport/ir/IRGraph.kt | 0 .../samediff/frameworkimport/ir/IRNode.kt | 0 .../samediff/frameworkimport/ir/IROpDef.kt | 0 .../samediff/frameworkimport/ir/IRTensor.kt | 0 .../mapper/MapperExtensions.kt | 0 .../opdefs/OpDescriptorLoader.kt | 0 .../opdefs/OpDescriptorLoaderHolder.kt | 0 .../process/AbstractMappingProcess.kt | 0 .../process/AbstractMappingProcessLoader.kt | 0 .../frameworkimport/process/MappingProcess.kt | 0 .../process/MappingProcessLoader.kt | 0 .../reflect/ImportReflectionCache.kt | 0 .../registry/ObjectRegistryHolder.kt | 0 .../registry/OpMappingRegistry.kt | 0 .../frameworkimport/rule/MappingRule.kt | 0 .../rule/attribute/ArgDescriptorConstant.kt | 0 .../rule/attribute/AttributeMappingRule.kt | 0 .../AttributeNDArrayToScalarAttribute.kt | 0 .../attribute/AttributeNumberListNDArray.kt | 0 .../AttributeScalarNDArrayAttribute.kt | 0 .../rule/attribute/AttributeValueType.kt | 0 .../attribute/BaseAttributeExtractionRule.kt | 0 .../ConditionalFieldValueIntIndexArrayRule.kt | 0 ...onditionalFieldValueIntIndexNDArrayRule.kt | 0 .../rule/attribute/DataTypeToInt.kt | 0 .../rule/attribute/FlattenDims.kt | 0 .../rule/attribute/IRMappingFunctions.kt | 0 .../rule/attribute/InvertBooleanNumber.kt | 0 .../ListAttributeValueLookupToIndex.kt | 0 .../rule/attribute/ListNumberToListNumber.kt | 0 .../rule/attribute/ListNumberToNDArray.kt | 0 .../rule/attribute/MapStringToInt.kt | 0 .../NDArrayAttributeToNDArrayInput.kt | 0 .../attribute/NDArrayExtractScalarValue.kt | 0 .../NDArrayInputToNumericalAttribute.kt | 0 .../rule/attribute/NDArraySizeAtRule.kt | 0 .../attribute/NDArrayToIntAttributeValue.kt | 0 .../rule/attribute/NumberToBoolean.kt | 0 .../SizeThresholdIntArrayIntIndexRule.kt | 0 .../attribute/StringAttributeToNDArray.kt | 0 .../attribute/StringContainsAdapterRule.kt | 0 .../rule/attribute/StringEqualsAdapterRule.kt | 0 .../attribute/StringNotEqualsAdapterRule.kt | 0 .../rule/attribute/StringToInt.kt | 0 .../rule/attribute/ValueMapping.kt | 0 .../rule/tensor/BaseNDArrayMappingRule.kt | 0 .../rule/tensor/MultiInputIndexMappingRule.kt | 0 .../tensor/PassThroughMultiTensorMapping.kt | 0 .../rule/tensor/TensorMappingRule.kt | 0 .../runner/DefaultImportRunner.kt | 0 .../frameworkimport/runner/IRGraphRunner.kt | 0 .../frameworkimport/runner/ImportRunner.kt | 0 .../src/main/resources/nd4j-op-def.pbtxt | 0 .../samediff-import-onnx/onnx-processes.pbtxt | 0 .../samediff-import-onnx/ops-added-new.txt | 0 .../samediff-import-onnx/ops-imported-new.txt | 0 .../samediff-import-onnx/ops-removed-new.txt | 0 .../samediff-import-onnx/pom.xml | 0 .../samediff/frameworkimport/onnx/OnnxIR.kt | 0 .../frameworkimport/onnx/OnnxImportGraph.kt | 0 .../onnx/OnnxImportGraphHolder.kt | 0 .../onnx/OnnxProtobufExtensions.kt | 0 .../onnx/OnnxRuleDeclarations.kt | 0 .../onnx/context/OnnxMappingContext.kt | 0 .../onnx/definitions/OnnxOpDeclarations.kt | 0 .../onnx/importer/OnnxFrameworkImporter.kt | 0 .../frameworkimport/onnx/ir/OnnxIRArgDef.kt | 0 .../frameworkimport/onnx/ir/OnnxIRAttr.kt | 0 .../frameworkimport/onnx/ir/OnnxIRDataType.kt | 0 .../frameworkimport/onnx/ir/OnnxIRGraph.kt | 0 .../onnx/ir/OnnxIRGraphRunner.kt | 0 .../frameworkimport/onnx/ir/OnnxIRNode.kt | 0 .../frameworkimport/onnx/ir/OnnxIROp.kt | 0 .../frameworkimport/onnx/ir/OnnxIRTensor.kt | 0 .../onnx/opdefs/OnnxOpDescriptorLoader.kt | 0 .../onnx/process/OnnxMappingProcess.kt | 0 .../onnx/process/OnnxMappingProcessLoader.kt | 0 .../attribute/OnnxArgDescriptorConstant.kt | 0 .../OnnxAttributeNDArrayToScalarAttribute.kt | 0 .../OnnxAttributeNumberListNDArray.kt | 0 .../OnnxAttributeScalarNDArrayAttribute.kt | 0 ...xConditionalFieldValueIntIndexArrayRule.kt | 0 ...onditionalFieldValueIntIndexNDArrayRule.kt | 0 .../onnx/rule/attribute/OnnxDataTypeToInt.kt | 0 .../onnx/rule/attribute/OnnxFlattenDims.kt | 0 .../rule/attribute/OnnxInvertBooleanNumber.kt | 0 .../OnnxListAttributeValueLookupToIndex.kt | 0 .../attribute/OnnxListNumberToListNumber.kt | 0 .../rule/attribute/OnnxListNumberToNDArray.kt | 0 .../onnx/rule/attribute/OnnxMapStringToInt.kt | 0 .../OnnxNDArrayAttributeToNDArrayInput.kt | 0 .../OnnxNDArrayExtractScalarValue.kt | 0 .../OnnxNDArrayInputToNumericalAttribute.kt | 0 .../onnx/rule/attribute/OnnxNDArraySizeAt.kt | 0 .../OnnxNDArrayToIntAttributeValue.kt | 0 .../OnnxSizeThresholdIntArrayIntIndexRule.kt | 0 .../attribute/OnnxStringAttributeToNDArray.kt | 0 .../OnnxStringContainsAdapterRule.kt | 0 .../attribute/OnnxStringEqualsAdapterRule.kt | 0 .../OnnxStringNotEqualsAdapterRule.kt | 0 .../onnx/rule/attribute/OnnxStringToIndex.kt | 0 .../onnx/rule/attribute/OnnxValueMapping.kt | 0 .../onnx/rule/tensor/NDArrayMappingRule.kt | 0 .../tensor/OnnxMultiInputIndexMappingRule.kt | 0 .../OnnxPassThroughMultiInputTensorMapping.kt | 0 ...samediff.frameworkimport.ImportGraphHolder | 0 ....frameworkimport.opdefs.OpDescriptorLoader | 0 .../main/resources/onnx-mapping-ruleset.pbtxt | 0 .../src/main/resources/onnx-op-def.pbtxt | 0 .../src/main/resources/onnx-op-defs.pb | Bin .../frameworkimport/onnx/TestOnnxIR.kt | 0 .../importer/TestOnnxFrameworkImporter.kt | 0 .../onnx/loader/TestOnnxProcessLoader.kt | 0 .../onnx/modelzoo/TestPretrainedModels.kt | 0 .../processing/GroupConvPreProcessingRule.kt | 0 .../src/test/resources/lenet.onnx | Bin .../variables-added-new.txt | 0 ...c93c-4ac9-867f-580443a45bb3-container.json | 0 ...47a3-4de9-9fc7-6691ea41aee0-container.json | 0 ...33-461b-4d6f-b6a8-a210cef103ff-result.json | 0 ...2d-1de4-4e85-b844-d90d20eea9fb-result.json | 0 ...c7-64e1-4e2c-a56e-05d390b459d7-result.json | 0 ...4d-ef52-441c-976b-3ef06799a362-result.json | 0 ...56da-4b92-983d-7385c888c80b-container.json | 0 ...053b-4dc9-a686-2040bb4f7fd3-container.json | 0 ...f7-cd22-4de1-80a6-b9890ce473fc-result.json | 0 ...ed9c-40b7-853c-d9462d2a67c0-container.json | 0 ...43-7f5f-4f5b-81db-e942139be1a7-result.json | 0 ...5f0d-4fe6-80ba-0628e9f3057b-container.json | 0 ...a05a-4382-a2fc-0835d2da893a-container.json | 0 ...d2-4a46-47d3-9748-578e7aae7121-result.json | 0 ...1d-1e98-4c83-b1ec-0812d352141d-result.json | 0 ...e3-ed5c-482a-89cf-0b4f46026b31-result.json | 0 ...d9-1d25-419e-a196-4a42f20fd8aa-result.json | 0 ...7c-ec8d-4567-9f3a-3b9bcb3d21f8-result.json | 0 ...2344-4dcc-a3d9-d23b5acbfe81-container.json | 0 ...e3-b7a8-492b-b0ab-ae77f112e105-result.json | 0 ...b0e3-446f-9e05-4fd86f350b83-container.json | 0 ...8b63-499e-9dc4-0206d0c38b29-container.json | 0 ...1a38-4b55-bc80-185feab4c978-container.json | 0 ...05d2-4692-ad17-af4aa388cb31-container.json | 0 ...25-9c6a-40b1-b825-916525e2cb24-result.json | 0 ...a732-411c-a65e-00111c6b550e-container.json | 0 ...1cb5-4edd-873b-c923d04905ec-container.json | 0 ...9a41-44aa-9b00-2bb9633a53be-container.json | 0 ...c322-458b-82e9-efd5494d37fc-container.json | 0 ...37-5ce9-4970-aa3d-7eaec8c8091a-result.json | 0 ...aa78-4897-a810-297802cccdfc-container.json | 0 ...6cd2-4a8d-82c7-9f45d15e8a73-container.json | 0 ...69-8c1d-440c-a135-174d7b873d11-result.json | 0 ...16-0d58-450b-85bb-ec61080f012f-result.json | 0 .../nd4j-op-def.pbtxt | 0 .../ops-added-new.txt | 0 .../ops-added-old.txt | 0 .../ops-imported-new.txt | 0 .../ops-imported-old.txt | 0 .../ops-removed-new.txt | 0 .../ops-removed-old.txt | 0 .../samediff-import-tensorflow/pom.xml | 0 .../tensorflow/TensorflowImportGraph.kt | 0 .../tensorflow/TensorflowImportGraphHolder.kt | 0 .../TensorflowProtobufExtensions.kt | 0 .../tensorflow/TensorflowRuleDeclarations.kt | 0 .../context/TensorflowMappingContext.kt | 0 .../definitions/TensorflowOpDeclarations.kt | 0 .../importer/TensorflowFrameworkImporter.kt | 0 .../tensorflow/ir/TensorflowIR.kt | 0 .../tensorflow/ir/TensorflowIRArgDef.kt | 0 .../tensorflow/ir/TensorflowIRAttr.kt | 0 .../tensorflow/ir/TensorflowIRDataType.kt | 0 .../tensorflow/ir/TensorflowIRGraph.kt | 0 .../tensorflow/ir/TensorflowIRGraphRunner.kt | 0 .../tensorflow/ir/TensorflowIRNode.kt | 0 .../tensorflow/ir/TensorflowIROp.kt | 0 .../tensorflow/ir/TensorflowIRTensor.kt | 0 .../opdefs/TensorflowOpDescriptorLoader.kt | 0 .../process/TensorflowMappingProcess.kt | 0 .../process/TensorflowMappingProcessLoader.kt | 0 .../TensorflowArgDescriptorConstant.kt | 0 ...orflowAttributeNDArrayToScalarAttribute.kt | 0 .../TensorflowAttributeNumberListNDArray.kt | 0 ...nsorflowAttributeScalarNDArrayAttribute.kt | 0 ...wConditionalFieldValueIntIndexArrayRule.kt | 0 ...onditionalFieldValueIntIndexNDArrayRule.kt | 0 .../rule/attribute/TensorflowDataTypeToInt.kt | 0 .../rule/attribute/TensorflowFlattenDims.kt | 0 .../TensorflowInvertBooleanNumber.kt | 0 ...nsorflowListAttributeValueLookupToIndex.kt | 0 .../TensorflowListNumberToListNumber.kt | 0 .../TensorflowListNumberToNDArray.kt | 0 .../attribute/TensorflowMapStringToInt.kt | 0 ...ensorflowNDArrayAttributeToNDArrayInput.kt | 0 .../TensorflowNDArrayExtractScalarValue.kt | 0 ...sorflowNDArrayInputToNumericalAttribute.kt | 0 .../rule/attribute/TensorflowNDArraySizeAt.kt | 0 .../TensorflowNDArrayToIntAttributeValue.kt | 0 .../TensorflowNdArrayToStringIndex.kt | 0 .../TensorflowStringAttributeToNDArray.kt | 0 .../TensorflowStringContainsAdapterRule.kt | 0 .../TensorflowStringEqualsAdapterRule.kt | 0 .../TensorflowStringNotEqualsAdapterRule.kt | 0 .../attribute/TensorflowValueMappingRule.kt | 0 .../rule/tensor/NDArrayMappingRule.kt | 0 .../TensorflowMultiInputIndexMappingRule.kt | 0 ...TensorflowPassThroughMultiTensorMapping.kt | 0 ...samediff.frameworkimport.ImportGraphHolder | 0 ....frameworkimport.opdefs.OpDescriptorLoader | 0 .../tensorflow-mapping-ruleset.pbtxt | 0 .../main/resources/tensorflow-op-def.pbtxt | 0 .../tensorflow/TestTensorflowIR.kt | 0 .../tensorflow/TestTensorflowUtils.kt | 0 .../importer/TestTensorflowImporter.kt | 0 .../loader/TestTensorflowProcessLoader.kt | 0 .../src/test/resources/lenet_frozen.pb | Bin .../src/test/resources/logback.xml | 0 .../tensorflow-processes.pbtxt | 0 .../samediff-import-tensorflow/test.pbtxt | 0 .../variables-added-new.txt | 0 .../variables-added-old.txt | 0 perform-release.sh => .old/perform-release.sh | 0 .../pydatavec}/.eggs/README.txt | 0 .../EGG-INFO/LICENSE | 0 .../EGG-INFO/PKG-INFO | 0 .../EGG-INFO/RECORD | 0 .../EGG-INFO/WHEEL | 0 .../EGG-INFO/entry_points.txt | 0 .../EGG-INFO/requires.txt | 0 .../EGG-INFO/top_level.txt | 0 .../.eggs/pytest_runner-5.2-py3.8.egg/ptr.py | 0 .../pydatavec}/pydatavec.egg-info/PKG-INFO | 0 .../pydatavec}/pydatavec.egg-info/SOURCES.txt | 0 .../pydatavec.egg-info/dependency_links.txt | 0 .../pydatavec.egg-info/requires.txt | 0 .../pydatavec.egg-info/top_level.txt | 0 {rl4j => .old/rl4j}/README.md | 0 {rl4j => .old/rl4j}/docs/images/cartpole.gif | Bin {rl4j => .old/rl4j}/docs/images/doom.gif | Bin {rl4j => .old/rl4j}/docs/images/malmo.gif | Bin {rl4j => .old/rl4j}/pom.xml | 0 {rl4j => .old/rl4j}/rl4j-ale/pom.xml | 0 .../deeplearning4j/rl4j/mdp/ale/ALEMDP.java | 0 {rl4j => .old/rl4j}/rl4j-api/pom.xml | 0 .../org/deeplearning4j/gym/StepReply.java | 0 .../java/org/deeplearning4j/rl4j/mdp/MDP.java | 0 .../rl4j/space/ActionSpace.java | 0 .../rl4j/space/ArrayObservationSpace.java | 0 .../org/deeplearning4j/rl4j/space/Box.java | 0 .../rl4j/space/DiscreteSpace.java | 0 .../deeplearning4j/rl4j/space/Encodable.java | 0 .../rl4j/space/HighLowDiscrete.java | 0 .../rl4j/space/ObservationSpace.java | 0 .../rl4j}/rl4j-core/nd4j-native.properties | 0 {rl4j => .old/rl4j}/rl4j-core/pom.xml | 0 .../org/deeplearning4j/rl4j/agent/Agent.java | 0 .../rl4j/agent/AgentLearner.java | 0 .../org/deeplearning4j/rl4j/agent/IAgent.java | 0 .../rl4j/agent/IAgentLearner.java | 0 .../learning/algorithm/IUpdateAlgorithm.java | 0 .../actorcritic/ActorCriticHelper.java | 0 .../actorcritic/AdvantageActorCritic.java | 0 .../NonRecurrentActorCriticHelper.java | 0 .../RecurrentActorCriticHelper.java | 0 .../algorithm/dqn/BaseDQNAlgorithm.java | 0 .../dqn/BaseTransitionTDAlgorithm.java | 0 .../learning/algorithm/dqn/DoubleDQN.java | 0 .../learning/algorithm/dqn/StandardDQN.java | 0 .../nstepqlearning/NStepQLearning.java | 0 .../nstepqlearning/NStepQLearningHelper.java | 0 .../NonRecurrentNStepQLearningHelper.java | 0 .../RecurrentNStepQLearningHelper.java | 0 .../learning/behavior/ILearningBehavior.java | 0 .../learning/behavior/LearningBehavior.java | 0 .../rl4j/agent/learning/update/Features.java | 0 .../learning/update/FeaturesBuilder.java | 0 .../agent/learning/update/FeaturesLabels.java | 0 .../rl4j/agent/learning/update/Gradients.java | 0 .../agent/learning/update/IUpdateRule.java | 0 .../agent/learning/update/UpdateRule.java | 0 .../update/updater/INeuralNetUpdater.java | 0 .../NeuralNetUpdaterConfiguration.java | 0 .../async/AsyncGradientsNeuralNetUpdater.java | 0 .../async/AsyncLabelsNeuralNetUpdater.java | 0 .../AsyncSharedNetworksUpdateHandler.java | 0 .../async/BaseAsyncNeuralNetUpdater.java | 0 .../sync/BaseSyncNeuralNetUpdater.java | 0 .../sync/SyncGradientsNeuralNetUpdater.java | 0 .../sync/SyncLabelsNeuralNetUpdater.java | 0 .../rl4j/agent/listener/AgentListener.java | 0 .../agent/listener/AgentListenerList.java | 0 .../builder/AdvantageActorCriticBuilder.java | 0 .../rl4j/builder/AsyncNetworkHandler.java | 0 .../rl4j/builder/BaseAgentLearnerBuilder.java | 0 .../builder/BaseAsyncAgentLearnerBuilder.java | 0 .../builder/BaseDQNAgentLearnerBuilder.java | 0 .../rl4j/builder/DoubleDQNBuilder.java | 0 .../rl4j/builder/INetworksHandler.java | 0 .../rl4j/builder/NStepQLearningBuilder.java | 0 .../rl4j/builder/StandardDQNBuilder.java | 0 .../rl4j/builder/SyncNetworkHandler.java | 0 .../rl4j/environment/Environment.java | 0 .../rl4j/environment/IActionSchema.java | 0 .../rl4j/environment/IntegerActionSchema.java | 0 .../rl4j/environment/Schema.java | 0 .../rl4j/environment/StepResult.java | 0 .../rl4j/experience/ExperienceHandler.java | 0 .../ReplayMemoryExperienceHandler.java | 0 .../StateActionExperienceHandler.java | 0 .../rl4j/experience/StateActionReward.java | 0 .../experience/StateActionRewardState.java | 0 .../rl4j/helper/INDArrayHelper.java | 0 .../rl4j/learning/HistoryProcessor.java | 0 .../rl4j/learning/IEpochTrainer.java | 0 .../rl4j/learning/IHistoryProcessor.java | 0 .../rl4j/learning/ILearning.java | 0 .../rl4j/learning/Learning.java | 0 .../rl4j/learning/NeuralNetFetchable.java | 0 .../rl4j/learning/async/AsyncGlobal.java | 0 .../rl4j/learning/async/AsyncLearning.java | 0 .../rl4j/learning/async/AsyncThread.java | 0 .../learning/async/AsyncThreadDiscrete.java | 0 .../rl4j/learning/async/IAsyncGlobal.java | 0 .../rl4j/learning/async/IAsyncLearning.java | 0 .../rl4j/learning/async/UpdateAlgorithm.java | 0 .../async/a3c/discrete/A3CDiscrete.java | 0 .../async/a3c/discrete/A3CDiscreteConv.java | 0 .../async/a3c/discrete/A3CDiscreteDense.java | 0 .../async/a3c/discrete/A3CThreadDiscrete.java | 0 .../AdvantageActorCriticUpdateAlgorithm.java | 0 .../discrete/AsyncNStepQLearningDiscrete.java | 0 .../AsyncNStepQLearningDiscreteConv.java | 0 .../AsyncNStepQLearningDiscreteDense.java | 0 .../AsyncNStepQLearningThreadDiscrete.java | 0 .../discrete/QLearningUpdateAlgorithm.java | 0 .../A3CLearningConfiguration.java | 0 .../AsyncQLearningConfiguration.java | 0 .../IAsyncLearningConfiguration.java | 0 .../configuration/ILearningConfiguration.java | 0 .../configuration/LearningConfiguration.java | 0 .../configuration/QLearningConfiguration.java | 0 .../learning/listener/TrainingListener.java | 0 .../listener/TrainingListenerList.java | 0 .../rl4j/learning/sync/ExpReplay.java | 0 .../rl4j/learning/sync/IExpReplay.java | 0 .../rl4j/learning/sync/SyncLearning.java | 0 .../learning/sync/qlearning/QLearning.java | 0 .../qlearning/discrete/QLearningDiscrete.java | 0 .../discrete/QLearningDiscreteConv.java | 0 .../discrete/QLearningDiscreteDense.java | 0 .../rl4j/mdp/CartpoleEnvironment.java | 0 .../rl4j/mdp/CartpoleNative.java | 0 .../rl4j/mdp/DoAsISayOrDont.java | 0 .../rl4j/mdp/TMazeEnvironment.java | 0 .../rl4j/mdp/robotlake/RobotLake.java | 0 .../rl4j/mdp/robotlake/RobotLakeHelper.java | 0 .../rl4j/mdp/robotlake/RobotLakeMap.java | 0 .../rl4j/mdp/robotlake/RobotLakeState.java | 0 .../rl4j/mdp/toy/HardDeteministicToy.java | 0 .../rl4j/mdp/toy/HardToyState.java | 0 .../rl4j/mdp/toy/SimpleToy.java | 0 .../rl4j/mdp/toy/SimpleToyState.java | 0 .../rl4j/network/ActorCriticNetwork.java | 0 .../rl4j/network/BaseNetwork.java | 0 .../network/ChannelToNetworkInputMapper.java | 0 .../rl4j/network/CommonGradientNames.java | 0 .../rl4j/network/CommonLabelNames.java | 0 .../rl4j/network/CommonOutputNames.java | 0 .../rl4j/network/CompoundNetworkHandler.java | 0 .../rl4j/network/ComputationGraphHandler.java | 0 .../rl4j/network/INetworkHandler.java | 0 .../rl4j/network/IOutputNeuralNet.java | 0 .../rl4j/network/ITrainableNeuralNet.java | 0 .../network/MultiLayerNetworkHandler.java | 0 .../rl4j/network/NetworkHelper.java | 0 .../rl4j/network/NeuralNet.java | 0 .../rl4j/network/NeuralNetOutput.java | 0 .../deeplearning4j/rl4j/network/QNetwork.java | 0 .../rl4j/network/ac/ActorCriticCompGraph.java | 0 .../ac/ActorCriticFactoryCompGraph.java | 0 .../ActorCriticFactoryCompGraphStdConv.java | 0 .../ActorCriticFactoryCompGraphStdDense.java | 0 .../ac/ActorCriticFactorySeparate.java | 0 .../ActorCriticFactorySeparateStdDense.java | 0 .../rl4j/network/ac/ActorCriticLoss.java | 0 .../rl4j/network/ac/ActorCriticSeparate.java | 0 .../rl4j/network/ac/IActorCritic.java | 0 .../ActorCriticDenseNetworkConfiguration.java | 0 .../ActorCriticNetworkConfiguration.java | 0 .../DQNDenseNetworkConfiguration.java | 0 .../configuration/NetworkConfiguration.java | 0 .../deeplearning4j/rl4j/network/dqn/DQN.java | 0 .../rl4j/network/dqn/DQNFactory.java | 0 .../rl4j/network/dqn/DQNFactoryStdConv.java | 0 .../rl4j/network/dqn/DQNFactoryStdDense.java | 0 .../deeplearning4j/rl4j/network/dqn/IDQN.java | 0 .../rl4j/observation/IObservationSource.java | 0 .../rl4j/observation/Observation.java | 0 .../EncodableToINDArrayTransform.java | 0 .../transform/FilterOperation.java | 0 .../transform/ResettableOperation.java | 0 .../transform/TransformProcess.java | 0 .../filter/UniformSkippingFilter.java | 0 .../EncodableToImageWritableTransform.java | 0 .../ImageWritableToINDArrayTransform.java | 0 .../operation/ArrayToINDArrayTransform.java | 0 .../operation/HistoryMergeTransform.java | 0 .../SimpleNormalizationTransform.java | 0 .../historymerge/CircularFifoStore.java | 0 .../historymerge/HistoryMergeAssembler.java | 0 .../HistoryMergeElementStore.java | 0 .../historymerge/HistoryStackAssembler.java | 0 .../deeplearning4j/rl4j/policy/ACPolicy.java | 0 .../rl4j/policy/BoltzmannQ.java | 0 .../deeplearning4j/rl4j/policy/DQNPolicy.java | 0 .../deeplearning4j/rl4j/policy/EpsGreedy.java | 0 .../rl4j/policy/INeuralNetPolicy.java | 0 .../deeplearning4j/rl4j/policy/IPolicy.java | 0 .../deeplearning4j/rl4j/policy/Policy.java | 0 .../rl4j/trainer/AsyncTrainer.java | 0 .../deeplearning4j/rl4j/trainer/ITrainer.java | 0 .../rl4j/trainer/SyncTrainer.java | 0 .../deeplearning4j/rl4j/util/Constants.java | 0 .../deeplearning4j/rl4j/util/DataManager.java | 0 .../util/DataManagerTrainingListener.java | 0 .../rl4j/util/IDataManager.java | 0 .../rl4j/util/LegacyMDPWrapper.java | 0 .../rl4j/util/VideoRecorder.java | 0 .../rl4j/AgentLearnerCartpole.java | 0 .../org/deeplearning4j/rl4j/NStepRnn.java | 0 .../deeplearning4j/rl4j/RobotLakeExample.java | 0 .../org/deeplearning4j/rl4j/TMazeExample.java | 0 .../rl4j/agent/AgentLearnerTest.java | 0 .../deeplearning4j/rl4j/agent/AgentTest.java | 0 .../NonRecurrentActorCriticHelperTest.java | 0 .../NonRecurrentAdvantageActorCriticTest.java | 0 .../RecurrentActorCriticHelperTest.java | 0 .../RecurrentAdvantageActorCriticTest.java | 0 .../learning/algorithm/dqn/DoubleDQNTest.java | 0 .../algorithm/dqn/StandardDQNTest.java | 0 .../NonRecurrentNStepQLearningHelperTest.java | 0 .../NonRecurrentNStepQLearningTest.java | 0 .../RecurrentNStepQLearningHelperTest.java | 0 .../RecurrentNStepQLearningTest.java | 0 .../behavior/LearningBehaviorTest.java | 0 .../learning/update/FeaturesBuilderTest.java | 0 .../learning/update/FeaturesLabelsTest.java | 0 .../agent/learning/update/FeaturesTest.java | 0 .../agent/learning/update/GradientsTest.java | 0 .../agent/learning/update/UpdateRuleTest.java | 0 .../AsyncGradientsNeuralNetUpdaterTest.java | 0 .../AsyncLabelsNeuralNetUpdaterTest.java | 0 .../AsyncSharedNetworksUpdateHandlerTest.java | 0 .../SyncGradientsNeuralNetUpdaterTest.java | 0 .../sync/SyncLabelsNeuralNetUpdaterTest.java | 0 .../builder/BaseAgentLearnerBuilderTest.java | 0 .../ReplayMemoryExperienceHandlerTest.java | 0 .../StateActionExperienceHandlerTest.java | 0 .../rl4j/helper/INDArrayHelperTest.java | 0 .../rl4j/learning/HistoryProcessorTest.java | 0 .../learning/async/AsyncLearningTest.java | 0 .../async/AsyncThreadDiscreteTest.java | 0 .../rl4j/learning/async/AsyncThreadTest.java | 0 ...vantageActorCriticUpdateAlgorithmTest.java | 0 .../AsyncTrainingListenerListTest.java | 0 .../QLearningUpdateAlgorithmTest.java | 0 .../listener/TrainingListenerListTest.java | 0 .../rl4j/learning/sync/ExpReplayTest.java | 0 .../sync/StateActionRewardStateTest.java | 0 .../rl4j/learning/sync/SyncLearningTest.java | 0 .../qlearning/QLearningConfigurationTest.java | 0 .../discrete/QLearningDiscreteTest.java | 0 .../rl4j/learning/sync/support/MockDQN.java | 0 .../learning/sync/support/MockStatEntry.java | 0 .../rl4j/network/ActorCriticNetworkTest.java | 0 .../rl4j/network/BaseNetworkTest.java | 0 .../ChannelToNetworkInputMapperTest.java | 0 .../network/CompoundNetworkHandlerTest.java | 0 .../network/ComputationGraphHandlerTest.java | 0 .../network/MultiLayerNetworkHandlerTest.java | 0 .../rl4j/network/NetworkHelperTest.java | 0 .../rl4j/network/QNetworkTest.java | 0 .../rl4j/network/ac/ActorCriticTest.java | 0 .../rl4j/network/dqn/DQNTest.java | 0 .../transform/TransformProcessTest.java | 0 .../filter/UniformSkippingFilterTest.java | 0 .../ArrayToINDArrayTransformTest.java | 0 .../operation/HistoryMergeTransformTest.java | 0 .../SimpleNormalizationTransformTest.java | 0 .../historymerge/CircularFifoStoreTest.java | 0 .../HistoryStackAssemblerTest.java | 0 .../rl4j/policy/PolicyTest.java | 0 .../deeplearning4j/rl4j/support/MockDQN.java | 0 .../rl4j/support/MockDataManager.java | 0 .../rl4j/support/MockHistoryProcessor.java | 0 .../deeplearning4j/rl4j/support/MockMDP.java | 0 .../rl4j/support/MockNeuralNet.java | 0 .../rl4j/support/MockObservation.java | 0 .../rl4j/support/MockObservationSpace.java | 0 .../rl4j/support/MockPolicy.java | 0 .../rl4j/support/MockRandom.java | 0 .../rl4j/trainer/AsyncTrainerTest.java | 0 .../rl4j/trainer/SyncTrainerTest.java | 0 .../util/DataManagerTrainingListenerTest.java | 0 {rl4j => .old/rl4j}/rl4j-doom/pom.xml | 0 .../rl4j/mdp/vizdoom/Basic.java | 0 .../rl4j/mdp/vizdoom/DeadlyCorridor.java | 0 .../rl4j/mdp/vizdoom/PredictPosition.java | 0 .../rl4j/mdp/vizdoom/TakeCover.java | 0 .../rl4j/mdp/vizdoom/VizDoom.java | 0 .../src/main/java/vizdoom/AutomapMode.java | 0 .../src/main/java/vizdoom/Button.java | 0 .../src/main/java/vizdoom/DoomGame.java | 0 .../vizdoom/FileDoesNotExistException.java | 0 .../src/main/java/vizdoom/GameState.java | 0 .../src/main/java/vizdoom/GameVariable.java | 0 .../src/main/java/vizdoom/Label.java | 0 .../java/vizdoom/MessageQueueException.java | 0 .../rl4j-doom/src/main/java/vizdoom/Mode.java | 0 .../src/main/java/vizdoom/ScreenFormat.java | 0 .../main/java/vizdoom/ScreenResolution.java | 0 .../java/vizdoom/SharedMemoryException.java | 0 .../main/java/vizdoom/SignalException.java | 0 .../java/vizdoom/ViZDoomErrorException.java | 0 .../vizdoom/ViZDoomIsNotRunningException.java | 0 .../ViZDoomUnexpectedExitException.java | 0 {rl4j => .old/rl4j}/rl4j-gym/pom.xml | 0 .../rl4j/mdp/gym/ActionTransformer.java | 0 .../deeplearning4j/rl4j/mdp/gym/GymEnv.java | 0 .../rl4j/mdp/gym/GymEnvTest.java | 0 {rl4j => .old/rl4j}/rl4j-malmo/pom.xml | 0 .../malmo/MalmoActionSpace.java | 0 .../malmo/MalmoActionSpaceDiscrete.java | 0 .../org/deeplearning4j/malmo/MalmoBox.java | 0 .../malmo/MalmoConnectionError.java | 0 .../malmo/MalmoDescretePositionPolicy.java | 0 .../org/deeplearning4j/malmo/MalmoEnv.java | 0 .../malmo/MalmoObservationPolicy.java | 0 .../malmo/MalmoObservationSpace.java | 0 .../malmo/MalmoObservationSpaceGrid.java | 0 .../malmo/MalmoObservationSpacePixels.java | 0 .../malmo/MalmoObservationSpacePosition.java | 0 .../malmo/MalmoResetHandler.java | 0 .../tensorflow-processes.pbtxt | 0 arbiter/.travis.yml | 24 - arbiter/README.md | 45 - arbiter/arbiter-core/pom.xml | 97 -- arbiter/arbiter-core/src/assembly/bin.xml | 91 -- .../optimize/api/AbstractParameterSpace.java | 74 - .../arbiter/optimize/api/Candidate.java | 57 - .../optimize/api/CandidateGenerator.java | 68 - .../optimize/api/OptimizationResult.java | 60 - .../arbiter/optimize/api/ParameterSpace.java | 81 - .../arbiter/optimize/api/TaskCreator.java | 62 - .../optimize/api/TaskCreatorProvider.java | 43 - .../api/adapter/ParameterSpaceAdapter.java | 82 - .../optimize/api/data/DataProvider.java | 54 - .../data/DataSetIteratorFactoryProvider.java | 89 -- .../arbiter/optimize/api/data/DataSource.java | 57 - .../api/evaluation/ModelEvaluator.java | 40 - .../api/saving/InMemoryResultSaver.java | 63 - .../optimize/api/saving/ResultReference.java | 37 - .../optimize/api/saving/ResultSaver.java | 57 - .../optimize/api/score/ScoreFunction.java | 75 - .../termination/MaxCandidatesCondition.java | 50 - .../api/termination/MaxTimeCondition.java | 81 - .../api/termination/TerminationCondition.java | 45 - .../config/OptimizationConfiguration.java | 226 --- .../DegenerateIntegerDistribution.java | 96 -- .../distribution/DistributionUtils.java | 149 -- .../distribution/LogUniformDistribution.java | 155 -- .../generator/BaseCandidateGenerator.java | 91 -- .../GeneticSearchCandidateGenerator.java | 187 --- .../GridSearchCandidateGenerator.java | 232 --- .../generator/RandomSearchGenerator.java | 93 -- .../generator/genetic/Chromosome.java | 42 - .../generator/genetic/ChromosomeFactory.java | 51 - .../crossover/ArithmeticCrossover.java | 120 -- .../genetic/crossover/CrossoverOperator.java | 45 - .../genetic/crossover/CrossoverResult.java | 43 - .../genetic/crossover/KPointCrossover.java | 178 --- .../crossover/SinglePointCrossover.java | 123 -- .../TwoParentsCrossoverOperator.java | 46 - .../genetic/crossover/UniformCrossover.java | 136 -- .../parentselection/ParentSelection.java | 44 - .../RandomTwoParentSelection.java | 65 - .../parentselection/TwoParentSelection.java | 25 - .../utils/CrossoverPointsGenerator.java | 68 - .../genetic/culling/CullOperator.java | 41 - .../genetic/culling/LeastFitCullOperator.java | 50 - .../genetic/culling/RatioCullOperator.java | 70 - .../GeneticGenerationException.java | 23 - .../genetic/mutation/MutationOperator.java | 33 - .../mutation/RandomMutationOperator.java | 93 -- .../EmptyPopulationInitializer.java | 41 - .../population/PopulationInitializer.java | 36 - .../population/PopulationListener.java | 35 - .../genetic/population/PopulationModel.java | 182 --- .../selection/GeneticSelectionOperator.java | 197 --- .../genetic/selection/SelectionOperator.java | 44 - .../generator/util/SerializedSupplier.java | 46 - .../optimize/parameter/BooleanSpace.java | 76 - .../optimize/parameter/FixedValue.java | 90 -- .../continuous/ContinuousParameterSpace.java | 137 -- .../discrete/DiscreteParameterSpace.java | 113 -- .../integer/IntegerParameterSpace.java | 151 -- .../optimize/parameter/math/MathOp.java | 69 - .../arbiter/optimize/parameter/math/Op.java | 76 - .../optimize/parameter/math/PairMathOp.java | 79 - .../runner/BaseOptimizationRunner.java | 383 ----- .../optimize/runner/CandidateInfo.java | 41 - .../optimize/runner/CandidateStatus.java | 24 - .../optimize/runner/IOptimizationRunner.java | 67 - .../runner/LocalOptimizationRunner.java | 150 -- .../runner/listener/BaseStatusListener.java | 54 - .../runner/listener/StatusChangeType.java | 26 - .../runner/listener/StatusListener.java | 60 - .../listener/impl/LoggingStatusListener.java | 57 - .../serde/jackson/FixedValueDeserializer.java | 52 - .../serde/jackson/FixedValueSerializer.java | 52 - .../IntegerDistributionDeserializer.java | 59 - .../IntegerDistributionSerializer.java | 74 - .../optimize/serde/jackson/JsonMapper.java | 77 - .../jackson/RealDistributionDeserializer.java | 78 - .../jackson/RealDistributionSerializer.java | 107 -- .../optimize/serde/jackson/YamlMapper.java | 52 - .../arbiter/util/ClassPathResource.java | 233 --- .../arbiter/util/CollectionUtils.java | 49 - .../arbiter/util/LeafUtils.java | 73 - .../arbiter/util/ObjectUtils.java | 61 - .../optimize/AssertTestsExtendBaseClass.java | 49 - .../arbiter/optimize/BraninFunction.java | 156 -- .../arbiter/optimize/TestGeneticSearch.java | 118 -- .../arbiter/optimize/TestGridSearch.java | 104 -- .../arbiter/optimize/TestJson.java | 122 -- .../arbiter/optimize/TestRandomSearch.java | 61 - .../optimize/distribution/TestLogUniform.java | 70 - .../genetic/TestCrossoverOperator.java | 40 - .../genetic/TestMutationOperator.java | 34 - .../optimize/genetic/TestParentSelection.java | 52 - .../genetic/TestPopulationInitializer.java | 30 - .../optimize/genetic/TestRandomGenerator.java | 88 -- .../crossover/ArithmeticCrossoverTests.java | 68 - .../crossover/CrossoverOperatorTests.java | 43 - .../CrossoverPointsGeneratorTests.java | 45 - .../crossover/KPointCrossoverTests.java | 67 - .../crossover/ParentSelectionTests.java | 39 - .../RandomTwoParentSelectionTests.java | 47 - .../crossover/SinglePointCrossoverTests.java | 68 - .../TwoParentsCrossoverOperatorTests.java | 71 - .../crossover/UniformCrossoverTests.java | 68 - .../culling/LeastFitCullOperatorTests.java | 62 - .../culling/RatioCullOperatorTests.java | 78 - .../mutation/RandomMutationOperatorTests.java | 73 - .../population/PopulationModelTests.java | 195 --- .../GeneticSelectionOperatorTests.java | 255 ---- .../selection/SelectionOperatorTests.java | 60 - .../parameter/TestParameterSpaces.java | 103 -- .../src/test/resources/logback.xml | 51 - arbiter/arbiter-deeplearning4j/pom.xml | 78 - .../arbiter/BaseNetworkSpace.java | 615 -------- .../arbiter/ComputationGraphSpace.java | 316 ---- .../arbiter/DL4JConfiguration.java | 73 - .../arbiter/GraphConfiguration.java | 67 - .../arbiter/MultiLayerSpace.java | 320 ---- .../ActivationParameterSpaceAdapter.java | 58 - .../LossFunctionParameterSpaceAdapter.java | 60 - .../arbiter/conf/dropout/DropoutSpace.java | 63 - .../arbiter/conf/updater/AdaGradSpace.java | 66 - .../arbiter/conf/updater/AdaMaxSpace.java | 83 -- .../arbiter/conf/updater/AdamSpace.java | 83 -- .../conf/updater/BaseUpdaterSpace.java | 70 - .../arbiter/conf/updater/NadamSpace.java | 83 -- .../arbiter/conf/updater/NesterovsSpace.java | 100 -- .../arbiter/conf/updater/RmsPropSpace.java | 54 - .../arbiter/conf/updater/SgdSpace.java | 54 - .../schedule/ExponentialScheduleSpace.java | 92 -- .../schedule/InverseScheduleSpace.java | 106 -- .../updater/schedule/PolyScheduleSpace.java | 106 -- .../schedule/SigmoidScheduleSpace.java | 106 -- .../updater/schedule/StepScheduleSpace.java | 106 -- .../data/DataSetIteratorFactoryProvider.java | 85 -- .../arbiter/data/MnistDataProvider.java | 80 - .../arbiter/dropout/AlphaDropoutSpace.java | 67 - .../arbiter/dropout/DropoutSpace.java | 67 - .../arbiter/dropout/GaussianDropoutSpace.java | 68 - .../arbiter/dropout/GaussianNoiseSpace.java | 67 - .../multilayer/ClassificationEvaluator.java | 68 - .../multilayer/RegressionDataEvaluator.java | 62 - .../layers/AbstractLSTMLayerSpace.java | 108 -- .../arbiter/layers/ActivationLayerSpace.java | 94 -- .../arbiter/layers/AutoEncoderLayerSpace.java | 107 -- .../layers/BaseConvolutionLayerSpace.java | 162 -- .../arbiter/layers/BaseLayerSpace.java | 292 ---- .../arbiter/layers/BaseOutputLayerSpace.java | 87 -- .../layers/BasePretrainNetworkLayerSpace.java | 57 - .../layers/BatchNormalizationSpace.java | 214 --- .../arbiter/layers/Bidirectional.java | 67 - .../layers/CenterLossOutputLayerSpace.java | 87 -- .../arbiter/layers/ConvolutionLayerSpace.java | 172 --- .../layers/Deconvolution2DLayerSpace.java | 52 - .../arbiter/layers/DenseLayerSpace.java | 90 -- .../arbiter/layers/DropoutLayerSpace.java | 89 -- .../arbiter/layers/EmbeddingLayerSpace.java | 88 -- .../arbiter/layers/FeedForwardLayerSpace.java | 154 -- .../layers/GlobalPoolingLayerSpace.java | 135 -- .../GravesBidirectionalLSTMLayerSpace.java | 97 -- .../arbiter/layers/GravesLSTMLayerSpace.java | 76 - .../arbiter/layers/LSTMLayerSpace.java | 77 - .../arbiter/layers/LayerSpace.java | 138 -- .../LocalResponseNormalizationLayerSpace.java | 119 -- .../arbiter/layers/LossLayerSpace.java | 105 -- .../arbiter/layers/OCNNLayerSpace.java | 153 -- .../arbiter/layers/OutputLayerSpace.java | 71 - .../arbiter/layers/RnnOutputLayerSpace.java | 71 - .../SeparableConvolution2DLayerSpace.java | 101 -- .../arbiter/layers/SubsamplingLayerSpace.java | 208 --- .../VariationalAutoencoderLayerSpace.java | 182 --- .../arbiter/layers/fixed/FixedLayerSpace.java | 71 - .../DL4JArbiterStatusReportingListener.java | 49 - .../arbiter/saver/local/FileModelSaver.java | 147 -- .../local/LocalFileNetResultReference.java | 103 -- .../arbiter/scoring/RegressionValue.java | 32 - .../arbiter/scoring/ScoreFunctions.java | 66 - .../scoring/impl/BaseNetScoreFunction.java | 103 -- .../scoring/impl/EvaluationScoreFunction.java | 86 -- .../scoring/impl/ROCScoreFunction.java | 122 -- .../scoring/impl/RegressionScoreFunction.java | 92 -- .../impl/TestSetAccuracyScoreFunction.java | 72 - .../scoring/impl/TestSetF1ScoreFunction.java | 72 - .../impl/TestSetLossScoreFunction.java | 78 - .../impl/TestSetRegressionScoreFunction.java | 85 -- .../arbiter/scoring/util/ScoreUtil.java | 328 ---- .../task/ComputationGraphTaskCreator.java | 267 ---- .../task/MultiLayerNetworkTaskCreator.java | 265 ---- .../arbiter/task/TaskListener.java | 49 - .../arbiter/AssertTestsExtendBaseClass.java | 50 - .../org/deeplearning4j/arbiter/TestUtils.java | 243 --- .../TestComputationGraphSpace.java | 168 --- .../TestGraphLocalExecution.java | 373 ----- .../TestGraphLocalExecutionGenetic.java | 212 --- .../deeplearning4j/arbiter/json/TestJson.java | 268 ---- .../MNISTOptimizationTest.java | 166 --- .../MnistDataSetIteratorFactory.java | 42 - .../TestDL4JLocalExecution.java | 381 ----- .../arbiter/multilayernetwork/TestErrors.java | 158 -- .../multilayernetwork/TestLayerSpace.java | 314 ---- .../TestMultiLayerSpace.java | 819 ---------- .../multilayernetwork/TestScoreFunctions.java | 220 --- .../util/TestDataFactoryProviderMnist.java | 46 - .../arbiter/util/TestDataProviderMnist.java | 61 - .../src/test/resources/logback.xml | 51 - arbiter/arbiter-server/pom.xml | 63 - .../arbiter/server/ArbiterCliGenerator.java | 286 ---- .../arbiter/server/ArbiterCliRunner.java | 152 -- .../server/cli/NeuralNetTypeValidator.java | 41 - .../server/cli/ProblemTypeValidator.java | 41 - .../arbiter/server/ArbiterCLIRunnerTest.java | 121 -- .../server/AssertTestsExtendBaseClass.java | 50 - .../server/MnistDataSetIteratorFactory.java | 43 - .../server/TestDataFactoryProviderMnist.java | 44 - arbiter/arbiter-ui/pom.xml | 73 - .../arbiter/ui/UpdateStatus.java | 33 - .../arbiter/ui/data/BaseJavaPersistable.java | 159 -- .../ui/data/GlobalConfigPersistable.java | 119 -- .../arbiter/ui/data/ModelInfoPersistable.java | 163 -- .../ui/listener/ArbiterStatusListener.java | 238 --- .../arbiter/ui/misc/JsonMapper.java | 76 - .../arbiter/ui/misc/UIUtils.java | 112 -- .../arbiter/ui/module/ArbiterModule.java | 943 ------------ .../org.deeplearning4j.ui.api.UIModule | 17 - .../deeplearning4jUiAssets/dl4j-ui.js | 1319 ----------------- .../deeplearning4jUiAssets/dl4j-ui.js.map | 1 - .../main/resources/templates/ArbiterUI.html | 638 -------- .../optimize/AssertTestsExtendBaseClass.java | 50 - .../arbiter/optimize/TestBasic.java | 791 ---------- .../arbiter-ui/src/test/resources/logback.xml | 51 - arbiter/buildmultiplescalaversions.sh | 53 - arbiter/contrib/formatter.xml | 353 ----- arbiter/pom.xml | 182 --- cavis-datavec/cavis-datavec-api/build.gradle | 74 +- .../java/org/datavec/api/package-info.java | 6 + .../api/records/reader/RecordReader.java | 213 +-- .../records/reader/impl/FileRecordReader.java | 370 ++--- .../datavec/api/writable/WritableFactory.java | 162 +- .../datavec/api/writable/WritableType.java | 119 +- cavis-full/build.gradle | 11 + cavis-native/cavis-native-lib/build.gradle | 25 +- chooseBackend.gradle | 11 +- createTestBackends.gradle | 10 +- 1374 files changed, 501 insertions(+), 28638 deletions(-) rename {.github => .old/.github}/ISSUE_TEMPLATE.md (100%) rename {.github => .old/.github}/PULL_REQUEST_TEMPLATE.md (100%) rename {.github => .old/.github}/actions/download-dl4j-test-resources-linux/action.yml (100%) rename {.github => .old/.github}/actions/download-dl4j-test-resources-windows/action.yml (100%) rename {.github => .old/.github}/actions/install-arm-cross-compile/action.yml (100%) rename {.github => .old/.github}/actions/install-cmake-linux/action.yml (100%) rename {.github => .old/.github}/actions/install-protobuf-linux/action.yml (100%) rename {.github => .old/.github}/actions/msys2-base-setup/action.yml (100%) rename {.github => .old/.github}/actions/publish-gh-packages/action.yml (100%) rename {.github => .old/.github}/actions/update-deps-linux/action.yml (100%) rename {.github => .old/.github}/workflows/build-android-x86_64.yml (100%) rename {.github => .old/.github}/workflows/build-deploy-android-arm32.yml (100%) rename {.github => .old/.github}/workflows/build-deploy-android-arm64.yml (100%) rename {.github => .old/.github}/workflows/build-deploy-linux-arm32.yml (100%) rename {.github => .old/.github}/workflows/build-deploy-linux-arm64.yml (100%) rename {.github => .old/.github}/workflows/build-deploy-linux-cuda-11.0.yml (100%) rename {.github => .old/.github}/workflows/build-deploy-linux-cuda-11.2.yml (100%) rename {.github => .old/.github}/workflows/build-deploy-linux-x86_64.yml (100%) rename {.github => .old/.github}/workflows/build-deploy-mac.yml (100%) rename {.github => .old/.github}/workflows/build-deploy-windows-cuda-11.0.yml (100%) rename {.github => .old/.github}/workflows/build-deploy-windows-cuda-11.2.yml (100%) rename {.github => .old/.github}/workflows/build-deploy-windows.yml (100%) rename {.github => .old/.github}/workflows/cpu-integration-tests.yaml (100%) rename {.github => .old/.github}/workflows/cpu-sanity-check-tests.yaml (100%) rename {.github => .old/.github}/workflows/run-cpu-tests-sanity-checks.yml (100%) rename {.github => .old/.github}/workflows/run-gpu-tests-sanity-checks.yml (100%) rename {.github => .old/.github}/workflows/test_multiple_arch.yaml (100%) rename {ADRs => .old/ADRs}/0001-SameDiff_File_Format.md (100%) rename {ADRs => .old/ADRs}/0002-ONNX_Runtime.md (100%) rename {ADRs => .old/ADRs}/0003-Import_IR.md (100%) rename {ADRs => .old/ADRs}/0003-NdArray_Strides_ArmCompute.md (100%) rename {ADRs => .old/ADRs}/0004-Mapping_IR.md (100%) rename {ADRs => .old/ADRs}/0005-Interpreter.md (100%) rename change-cuda-versions.sh => .old/change-cuda-versions.sh (100%) rename change-scala-versions.sh => .old/change-scala-versions.sh (100%) rename {contrib => .old/contrib}/README.md (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/adr/0001-kotlin_dsl_as_source_of_truth.md (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/adr/0002-separate_object_graph_for_serialization.md (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/adr/0003-dealing_with_inconsistencies_in_java_naming.md (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/adr/0004-auto_initialization_for_inplace_operations.md (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/adr/0005-optional_parameters_and_signatures.md (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/adr/0006-op_specific_enums.md (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/adr/0007-configuration_objects.md (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/adr/0008-inheritance.md (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/adr/0009-aliasing.md (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/adr/0010-ir-codegen.md (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/java/org/nd4j/codegen/Namespace.java (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/java/org/nd4j/codegen/cli/CLI.java (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/cpp/CppGenerator.java (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/java/DocsGenerator.java (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/java/JavaPoetGenerator.java (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/java/Nd4jNamespaceGenerator.java (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/python/PythonGenerator.java (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/java/org/nd4j/codegen/ir/SerializationTest.java (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/java/org/nd4j/codegen/util/GenUtil.java (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/java/org/nd4j/codegen/util/JsonMapper.java (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/CodeComponent.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/DataType.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Language.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/LossReduce.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Namespace.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/NamespaceOps.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Op.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Registry.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Variables.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/doc/DocScope.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/doc/DocSection.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/doc/DocTokens.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/generator/ConstraintCodeGenerator.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/generator/Generator.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/generator/GeneratorConfig.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/dsl/OpBuilder.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/impl/java/JavaConstraintCodeGenerator.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/impl/python/KotlinExamplePythonGenerator.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/util/GenerateOps.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/util/extract/ExtractFromExisting.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/util/extract/FindUsedParameterTypes.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/mixins/Mixins.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Bitwise.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/CNN.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Image.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Linalg.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Math.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/NeuralNetwork.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/RNN.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Random.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/SDBaseOps.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/SDLoss.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/resources/logback.xml (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/resources/namespaces/math.json (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/resources/nd4j-op-defs-2.proto (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/resources/onnx-op-defs.pb (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/resources/onnx.pbtxt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/main/resources/tensorflowOpMappings.csv (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/test/java/org/nd4j/codegen/dsl/DocsGeneratorTest.java (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/test/java/org/nd4j/codegen/dsl/TestGeneration.java (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/ConfigTest.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/ConstraintTest.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/NamespaceInvariantTest.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/OpBuilderTest.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/OpInvariantTest.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/ops/ConstructionTest.kt (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/test/resources/lenet.onnx (100%) rename {contrib => .old/contrib}/codegen-tools/codegen/src/test/resources/lenet_frozen.pb (100%) rename {contrib => .old/contrib}/codegen-tools/libnd4j-gen/README.md (100%) rename {contrib => .old/contrib}/codegen-tools/libnd4j-gen/op-ir.proto (100%) rename {contrib => .old/contrib}/codegen-tools/libnd4j-gen/pom.xml (100%) rename {contrib => .old/contrib}/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/OpDeclarationDescriptor.java (100%) rename {contrib => .old/contrib}/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/ParseOpFile.java (100%) rename {contrib => .old/contrib}/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/ArgDescriptorProposal.java (100%) rename {contrib => .old/contrib}/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/ArgDescriptorSource.java (100%) rename {contrib => .old/contrib}/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/impl/ArgDescriptorParserUtils.java (100%) rename {contrib => .old/contrib}/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/impl/JavaSourceArgDescriptorSource.java (100%) rename {contrib => .old/contrib}/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/impl/Libnd4jArgDescriptorSource.java (100%) rename {contrib => .old/contrib}/codegen-tools/onnx-def-gen/README.md (100%) rename {contrib => .old/contrib}/codegen-tools/onnx-def-gen/lenet.onnx (100%) rename {contrib => .old/contrib}/codegen-tools/onnx-def-gen/onnx-op-defs.pb (100%) rename {contrib => .old/contrib}/codegen-tools/onnx-def-gen/onnx.pbtxt (100%) rename {contrib => .old/contrib}/codegen-tools/onnx-def-gen/onnx_def_gen.py (100%) rename {contrib => .old/contrib}/codegen-tools/onnx-def-gen/save_test.py (100%) rename {contrib => .old/contrib}/codegen-tools/onnx-def-gen/test_onnx_lenet.py (100%) rename {contrib => .old/contrib}/codegen-tools/onnx-def-gen/test_op_def_gen.py (100%) rename {contrib => .old/contrib}/formatter.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/.codeclimate.yml (100%) rename {deeplearning4j => .old/deeplearning4j}/CONTRIBUTORS.md (100%) rename {deeplearning4j => .old/deeplearning4j}/GITTER_GUIDELINES.md (100%) rename {deeplearning4j => .old/deeplearning4j}/README.md (100%) rename {deeplearning4j => .old/deeplearning4j}/buildmultiplescalaversions.sh (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-dataimport-solrj/pom.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-dataimport-solrj/src/main/java/org/deeplearning4j/nn/dataimport/solr/client/solrj/io/stream/TupleStreamDataSetIterator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-dataimport-solrj/src/test/java/org/deeplearning4j/nn/dataimport/solr/client/solrj/io/stream/TupleStreamDataSetIteratorTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-dataimport-solrj/src/test/resources/solr/collection1/README (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-dataimport-solrj/src/test/resources/solr/configsets/mini/conf/schema.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-dataimport-solrj/src/test/resources/solr/configsets/mini/conf/solrconfig.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/pom.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/BaseGraph.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/Edge.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/IGraph.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/IVertexSequence.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/NoEdgeHandling.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/Vertex.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/EdgeLineProcessor.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/GraphLoader.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/VertexLoader.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/impl/DelimitedEdgeLineProcessor.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/impl/DelimitedVertexLoader.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/impl/WeightedEdgeLineProcessor.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/exception/NoEdgesException.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/exception/ParseException.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/graph/Graph.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/graph/VertexSequence.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/GraphWalkIterator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/RandomWalkIterator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/WeightedRandomWalkIterator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/parallel/GraphWalkIteratorProvider.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/parallel/RandomWalkGraphIteratorProvider.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/parallel/WeightedRandomWalkGraphIteratorProvider.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/BinaryTree.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/GraphVectors.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/deepwalk/DeepWalk.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/deepwalk/GraphHuffman.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/embeddings/GraphVectorLookupTable.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/embeddings/GraphVectorsImpl.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/embeddings/InMemoryGraphLookupTable.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/loader/GraphVectorSerializer.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/IntegerVertexFactory.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/StringVertexFactory.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/VertexFactory.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/VoidVertexFactory.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/AssertTestsExtendedBaseClass.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/data/TestGraphLoading.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/data/TestGraphLoadingWeighted.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/graph/TestGraph.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/models/deepwalk/DeepWalkGradientCheck.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/models/deepwalk/TestDeepWalk.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/models/deepwalk/TestGraphHuffman.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-manifold/deeplearning4j-tsne/pom.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-manifold/deeplearning4j-tsne/src/main/java/org/deeplearning4j/plot/BarnesHutTsne.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-manifold/deeplearning4j-tsne/src/main/java/org/deeplearning4j/plot/Tsne.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-manifold/deeplearning4j-tsne/src/test/java/org/deeplearning4j/plot/Test6058.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-manifold/deeplearning4j-tsne/src/test/java/org/deeplearning4j/plot/TsneTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-manifold/pom.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-modelexport-solr/pom.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-modelexport-solr/src/main/java/org/deeplearning4j/nn/modelexport/solr/handler/ModelTupleStream.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-modelexport-solr/src/main/java/org/deeplearning4j/nn/modelexport/solr/ltr/model/ScoringModel.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-modelexport-solr/src/test/java/org/deeplearning4j/nn/modelexport/solr/handler/ModelTupleStreamIntegrationTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-modelexport-solr/src/test/java/org/deeplearning4j/nn/modelexport/solr/handler/ModelTupleStreamTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-modelexport-solr/src/test/java/org/deeplearning4j/nn/modelexport/solr/ltr/model/ScoringModelTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-modelexport-solr/src/test/resources/solr/collection1/README (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-modelexport-solr/src/test/resources/solr/configsets/mini-expressible/conf/schema.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-modelexport-solr/src/test/resources/solr/configsets/mini-expressible/conf/solrconfig.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-remote/deeplearning4j-json-server/pom.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-remote/deeplearning4j-json-server/src/main/java/org/deeplearning4j/remote/DL4jServlet.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-remote/deeplearning4j-json-server/src/main/java/org/deeplearning4j/remote/JsonModelServer.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/AssertTestsExtendBaseClass.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/BinaryModelServerTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/JsonModelServerTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/ServletTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/House.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/HouseToPredictedPriceAdapter.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/ImageConversionUtils.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/PredictedPrice.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-remote/deeplearning4j-json-server/src/test/resources/logback.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-remote/pom.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/pom.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/pom.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/paragraphvectors/SparkParagraphVectors.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/paragraphvectors/functions/DocumentSequenceConvertFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/paragraphvectors/functions/KeySequenceConvertFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/SparkSequenceVectors.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/ExportContainer.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/SparkModelExporter.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/impl/HdfsModelExporter.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/impl/VocabCacheExporter.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/BaseTokenizerFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/CountFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/DistributedFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ElementsFrequenciesAccumulator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ExportFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ExtraCountFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ExtraElementsFrequenciesAccumulator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ListSequenceConvertFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/PartitionTrainingFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/TokenizerFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/TrainingFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/VocabRddFunctionFlat.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/SparkElementsLearningAlgorithm.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/SparkSequenceLearningAlgorithm.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/elements/BaseSparkLearningAlgorithm.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/elements/SparkCBOW.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/elements/SparkSkipGram.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/sequence/BaseSparkSequenceLearningAlgorithm.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/sequence/SparkDBOW.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/sequence/SparkDM.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/primitives/ExtraCounter.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/word2vec/SparkWord2Vec.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/sequencevectors/SparkSequenceVectorsTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/sequencevectors/export/ExportContainerTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/word2vec/SparkWord2VecTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/resources/log4j.properties (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/resources/logback.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/.gitignore (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/pom.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/FirstIterationFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/MapToPairFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/NegativeHolder.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/SecondIterationFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/SentenceBatch.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/VocabHolder.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2Vec.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecChange.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecFuncCall.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecParam.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecPerformer.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecPerformerVoid.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecSetup.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecVariables.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/accumulators/MaxPerPartitionAccumulator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/accumulators/WordFreqAccumulator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/CountCumSum.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/FoldBetweenPartitionFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/FoldWithinPartitionFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/GetSentenceCountFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/MapPerPartitionVoidFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/ReduceSentenceCount.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/TextPipeline.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/TokenizerFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/UpdateWordFreqAccumulatorFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/WordsListToVocabWordsFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/BaseSparkTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/TestFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/TextPipelineTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/resources/log4j.properties (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/resources/logback.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/pom.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/ParameterServerSubscriber.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/ParameterServerTrainingHook.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationTuple.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAggregateFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/DataSetDeserializationCallback.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/MultiDataSetDeserializationCallback.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/PortableDataStreamCallback.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/PortableDataStreamMDSCallback.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/conf/SharedTrainingConfiguration.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapDataSet.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapMultiDataSet.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapPaths.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapPathsMDS.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/MultiPdsIterator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/PdsIterator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualDataSetIterator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualIterator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualMultiDataSetIterator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/modelimport/elephas/ElephasModelImport.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/SilentTrainingDriver.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/WiredEncodingHandler.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/messages/SilentIntroductoryConfirmation.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/messages/SilentIntroductoryMessage.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/messages/SilentUpdatesMessage.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/ModelParamsConsumer.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/UpdaterParamsConsumer.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/UpdatesConsumer.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/WiredEncodingHandler.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/pw/SharedTrainingWrapper.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/python/ArrayDescriptor.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/python/DataSetDescriptor.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/python/Utils.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/training/SharedTrainingMaster.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/training/SharedTrainingResult.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/training/SharedTrainingWorker.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/util/BlockingObserver.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/util/CountingIterator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/BaseSparkTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationFunctionTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAggregateFunctionTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualDataSetIteratorTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualIteratorTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/modelimport/elephas/TestElephasImport.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/train/GradientSharingTrainingTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/resources/log4j.properties (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/resources/logback.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/nd4j-native.properties (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/pom.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/RDDTrainingApproach.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/Repartition.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/RepartitionStrategy.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/Repartitioner.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingHook.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingMaster.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingResult.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingWorker.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/WorkerConfiguration.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/stats/CommonSparkTrainingStats.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/stats/SparkTrainingStats.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/stats/StatsCalculationHelper.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerFlatMap.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerMultiDataSetFlatMap.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPDSFlatMap.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPDSMDSFlatMap.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPathFlatMap.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPathMDSFlatMap.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/NetBroadcastTuple.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/BatchAndExportDataSetsFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/BatchAndExportMultiDataSetsFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/BatchDataSetsFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/DataSetExportFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/DataSetProvider.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/MultiDataSetExportFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/MultiDataSetProvider.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/PathToDataSetFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/PathToMultiDataSetFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/SplitDataSetsFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/loader/RemoteFileSource.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/loader/RemoteFileSourceFactory.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/shuffle/SplitDataSetExamplesPairFlatMapFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecByteDataSetFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecDataSetFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecSequenceDataSetFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecSequencePairDataSetFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/RDDMiniBatches.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/RecordReaderFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/export/StringToDataSetExportFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/DataVecRecord.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/DataVecRecords.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/IteratorUtils.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/RRMDSIFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/SparkSourceDummyReader.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/SparkSourceDummySeqReader.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/BaseSparkEarlyStoppingTrainer.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkDataSetLossCalculator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkEarlyStoppingGraphTrainer.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkEarlyStoppingTrainer.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkLossCalculatorComputationGraph.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/SparkListenable.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/Add.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/CountPartitionsFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/LoadDataSetFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/SplitPartitionsFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/SplitPartitionsFunction2.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/reduce/IntDoubleReduceFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/reduce/LongDoubleReduceFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/BalancedPartitioner.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/EqualPartitioner.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/HashingBalancedPartitioner.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/MapTupleToPairFlatMap.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/score/BaseVaeReconstructionProbWithKeyFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/score/BaseVaeScoreWithKeyFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/evaluation/EvaluationRunner.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/SparkComputationGraph.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/dataset/DataSetToMultiDataSetFn.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/dataset/PairDataSetToMultiDataSetFn.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/evaluation/IEvaluateMDSFlatMapFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/evaluation/IEvaluateMDSPathsFlatMapFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ArrayPairToPair.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/CGVaeReconstructionErrorWithKeyFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/CGVaeReconstructionProbWithKeyFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/GraphFeedForwardWithKeyFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/PairToArrayPair.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreExamplesFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreExamplesWithKeyFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreFlatMapFunctionCGDataSet.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreFlatMapFunctionCGMultiDataSet.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/listeners/VanillaStatsStorageRouter.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/listeners/VanillaStatsStorageRouterProvider.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/SparkDl4jMultiLayer.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/evaluation/IEvaluateAggregateFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/evaluation/IEvaluateFlatMapFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/evaluation/IEvaluationReduceFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/FeedForwardWithKeyFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/ScoreExamplesFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/ScoreExamplesWithKeyFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/ScoreFlatMapFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/SingleToPairFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/VaeReconstructionErrorWithKeyFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/VaeReconstructionProbWithKeyFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/BaseTrainingMaster.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/BaseTrainingResult.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/BaseTrainingWorker.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/ParameterAveragingTrainingMaster.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/ParameterAveragingTrainingResult.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/ParameterAveragingTrainingWorker.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/aggregator/ParameterAveragingAggregationTuple.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/aggregator/ParameterAveragingElementAddFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/aggregator/ParameterAveragingElementCombineFunction.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/stats/ParameterAveragingTrainingMasterStats.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/stats/ParameterAveragingTrainingWorkerStats.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/util/ExportSupport.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/repartitioner/DefaultRepartitioner.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/repartitioner/EqualRepartitioner.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/repartitioner/NoOpRepartitioner.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/BaseDataSetIterator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PathSparkDataSetIterator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PathSparkMultiDataSetIterator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PortableDataStreamDataSetIterator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PortableDataStreamMultiDataSetIterator.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/SparkADSI.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/SparkAMDSI.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/ordering/DataSetOrdering.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/BaseEventStats.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/EventStats.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/ExampleCountEventStats.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/PartitionCountEventStats.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/StatsUtils.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/NTPTimeSource.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/SystemClockTimeSource.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/TimeSource.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/TimeSourceProvider.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/MLLibUtil.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/SparkDataUtils.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/SparkUtils.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/SparkDataValidation.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/ValidationResult.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/validation/ValidateDataSetFn.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/validation/ValidateMultiDataSetFn.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/validation/ValidationResultReduceFn.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/serde/StorageLevelDeserializer.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/serde/StorageLevelSerializer.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/main/scala/org/apache/spark/TaskContextHelper.scala (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/BaseSparkKryoTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/BaseSparkTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestEarlyStoppingSpark.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestEarlyStoppingSparkCompGraph.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestKryo.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/common/AddTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/data/TestShuffleExamples.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/data/TestSparkDataUtils.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/MiniBatchTests.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestDataVecDataSetFunctions.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestExport.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestPreProcessedData.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/iterator/TestIteratorUtils.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/TestKryoWarning.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/common/repartition/BalancedPartitionerTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/common/repartition/HashingBalancedPartitionerTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/TestCustomLayer.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/layer/CustomLayer.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/layer/CustomLayerImpl.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/graph/TestSparkComputationGraph.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/misc/TestFrozenLayers.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/multilayer/TestMiscFunctions.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/multilayer/TestSparkDl4jMultiLayer.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestCompareParameterAveragingSparkVsSingleMachine.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestJsonYaml.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestSparkMultiLayerParameterAveraging.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/util/ExportSupportTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/stats/TestTrainingStatsCollection.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/time/TestTimeSource.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/ui/TestListeners.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/MLLIbUtilTest.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/TestRepartitioning.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/TestValidation.java (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/resources/log4j.properties (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/dl4j-spark/src/test/resources/logback.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/deeplearning4j-scaleout/spark/pom.xml (100%) rename {deeplearning4j => .old/deeplearning4j}/pom.xml (100%) rename {nd4j => .old/nd4j}/README.md (100%) rename {nd4j => .old/nd4j}/RaspberryPi.md (100%) rename {nd4j => .old/nd4j}/buildmultiplescalaversions.sh (100%) rename {nd4j => .old/nd4j}/nd4j-jdbc/nd4j-jdbc-api/pom.xml (100%) rename {nd4j => .old/nd4j}/nd4j-jdbc/nd4j-jdbc-api/src/main/java/org/nd4j/jdbc/driverfinder/DriverFinder.java (100%) rename {nd4j => .old/nd4j}/nd4j-jdbc/nd4j-jdbc-api/src/main/java/org/nd4j/jdbc/loader/api/JDBCNDArrayIO.java (100%) rename {nd4j => .old/nd4j}/nd4j-jdbc/nd4j-jdbc-api/src/main/java/org/nd4j/jdbc/loader/impl/BaseLoader.java (100%) rename {nd4j => .old/nd4j}/nd4j-jdbc/nd4j-jdbc-hsql/pom.xml (100%) rename {nd4j => .old/nd4j}/nd4j-jdbc/nd4j-jdbc-hsql/src/main/java/org/nd4j/jdbc/hsql/HsqlLoader.java (100%) rename {nd4j => .old/nd4j}/nd4j-jdbc/nd4j-jdbc-hsql/src/main/resources/nd4j.jdbc.properties (100%) rename {nd4j => .old/nd4j}/nd4j-jdbc/nd4j-jdbc-hsql/src/test/java/org/nd4j/jdbc/hsql/HSqlLoaderTest.java (100%) rename {nd4j => .old/nd4j}/nd4j-jdbc/nd4j-jdbc-mysql/pom.xml (100%) rename {nd4j => .old/nd4j}/nd4j-jdbc/nd4j-jdbc-mysql/src/main/java/org/nd4j/jdbc/mysql/MysqlLoader.java (100%) rename {nd4j => .old/nd4j}/nd4j-jdbc/nd4j-jdbc-mysql/src/main/resources/nd4j.jdbc.properties (100%) rename {nd4j => .old/nd4j}/nd4j-jdbc/nd4j-jdbc-mysql/src/test/java/org/nd4j/jdbc/mysql/MysqlLoaderTest.java (100%) rename {nd4j => .old/nd4j}/nd4j-jdbc/pom.xml (100%) rename {nd4j => .old/nd4j}/nd4j-onnxruntime/pom.xml (100%) rename {nd4j => .old/nd4j}/nd4j-onnxruntime/src/main/java/org/nd4j/onnxruntime/runner/OnnxRuntimeRunner.java (100%) rename {nd4j => .old/nd4j}/nd4j-onnxruntime/src/main/java/org/nd4j/onnxruntime/util/ONNXUtils.java (100%) rename {nd4j => .old/nd4j}/nd4j-onnxruntime/src/test/java/org/nd4j/onnxruntime/runner/OnnxRuntimeRunnerTests.java (100%) rename {nd4j => .old/nd4j}/nd4j-onnxruntime/src/test/resources/add.onnx (100%) rename {nd4j => .old/nd4j}/nd4j-remote/README.md (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-grpc-client/pom.xml (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-grpc-client/src/main/java/org/nd4j/remote/grpc/GraphInferenceGrpcClient.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-grpc-client/src/main/java/org/nd4j/remote/grpc/grpc/GraphInferenceServerGrpc.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-grpc-client/src/test/java/org/nd4j/graph/GraphInferenceGrpcClientTest.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-client/pom.xml (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/JsonRemoteInference.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/BinaryDeserializer.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/BinarySerializer.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/JsonDeserializer.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/JsonSerializer.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/AbstractSerDe.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/BooleanSerde.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/DoubleArraySerde.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/DoubleSerde.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/FloatArraySerde.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/FloatSerde.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/IntegerSerde.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/StringSerde.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-server/README.md (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-server/pom.xml (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/SameDiffJsonModelServer.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/serving/ModelServingServlet.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/serving/SameDiffServlet.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/serving/ServingProcessor.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/SameDiffJsonModelServerTest.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/SameDiffServletTest.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/helpers/House.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/helpers/HouseToPredictedPriceAdapter.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/helpers/PredictedPrice.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/serde/BasicSerdeTests.java (100%) rename {nd4j => .old/nd4j}/nd4j-remote/nd4j-json-server/src/test/resources/logback.xml (100%) rename {nd4j => .old/nd4j}/nd4j-remote/pom.xml (100%) rename {nd4j => .old/nd4j}/nd4j-serde/nd4j-arrow/pom.xml (100%) rename {nd4j => .old/nd4j}/nd4j-serde/nd4j-arrow/src/main/java/org/nd4j/arrow/ArrowSerde.java (100%) rename {nd4j => .old/nd4j}/nd4j-serde/nd4j-arrow/src/main/java/org/nd4j/arrow/DataBufferStruct.java (100%) rename {nd4j => .old/nd4j}/nd4j-serde/nd4j-arrow/src/test/java/org/nd4j/arrow/ArrowSerdeTest.java (100%) rename {nd4j => .old/nd4j}/nd4j-serde/nd4j-kryo/pom.xml (100%) rename {nd4j => .old/nd4j}/nd4j-serde/nd4j-kryo/src/main/java/org/nd4j/kryo/Nd4jRegistrator.java (100%) rename {nd4j => .old/nd4j}/nd4j-serde/nd4j-kryo/src/main/java/org/nd4j/kryo/Nd4jSerializer.java (100%) rename {nd4j => .old/nd4j}/nd4j-serde/nd4j-kryo/src/main/java/org/nd4j/kryo/primitives/AtomicDoubleSerializer.java (100%) rename {nd4j => .old/nd4j}/nd4j-serde/nd4j-kryo/src/test/java/org/nd4j/TestNd4jKryoSerialization.java (100%) rename {nd4j => .old/nd4j}/nd4j-serde/pom.xml (100%) rename {nd4j => .old/nd4j}/nd4j-tvm/pom.xml (100%) rename {nd4j => .old/nd4j}/nd4j-tvm/src/main/java/org/nd4j/tvm/runner/TvmRunner.java (100%) rename {nd4j => .old/nd4j}/nd4j-tvm/src/main/java/org/nd4j/tvm/util/TVMUtils.java (100%) rename {nd4j => .old/nd4j}/nd4j-tvm/src/test/java/org/nd4j/tvm/runner/TvmRunnerTests.java (100%) rename {nd4j => .old/nd4j}/pom.xml (100%) rename {nd4j => .old/nd4j}/samediff-import/pom.xml (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/pom.xml (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/FrameworkImporter.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/IRProtobufExtensions.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ImportGraph.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ImportGraphFactory.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ImportGraphHolder.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/context/AbstractMappingContext.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/context/MappingContext.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/PostImportHook.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/PreImportHook.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/annotations/HookResult.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/annotations/PostHookRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/annotations/PreHookRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRArgDef.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRAttribute.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRDataType.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRDataTypeValue.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRFunctions.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRGraph.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRNode.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IROpDef.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRTensor.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/mapper/MapperExtensions.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/opdefs/OpDescriptorLoader.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/opdefs/OpDescriptorLoaderHolder.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/AbstractMappingProcess.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/AbstractMappingProcessLoader.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/MappingProcess.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/MappingProcessLoader.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/reflect/ImportReflectionCache.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/registry/ObjectRegistryHolder.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/registry/OpMappingRegistry.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/MappingRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ArgDescriptorConstant.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeMappingRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeNDArrayToScalarAttribute.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeNumberListNDArray.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeScalarNDArrayAttribute.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeValueType.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/BaseAttributeExtractionRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ConditionalFieldValueIntIndexArrayRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ConditionalFieldValueIntIndexNDArrayRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/DataTypeToInt.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/FlattenDims.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/IRMappingFunctions.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/InvertBooleanNumber.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ListAttributeValueLookupToIndex.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ListNumberToListNumber.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ListNumberToNDArray.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/MapStringToInt.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayAttributeToNDArrayInput.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayExtractScalarValue.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayInputToNumericalAttribute.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArraySizeAtRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayToIntAttributeValue.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NumberToBoolean.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/SizeThresholdIntArrayIntIndexRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringAttributeToNDArray.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringContainsAdapterRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringEqualsAdapterRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringNotEqualsAdapterRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringToInt.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ValueMapping.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/BaseNDArrayMappingRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/MultiInputIndexMappingRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/PassThroughMultiTensorMapping.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/TensorMappingRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/runner/DefaultImportRunner.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/runner/IRGraphRunner.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/runner/ImportRunner.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-api/src/main/resources/nd4j-op-def.pbtxt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/onnx-processes.pbtxt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/ops-added-new.txt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/ops-imported-new.txt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/ops-removed-new.txt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/pom.xml (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxIR.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxImportGraph.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxImportGraphHolder.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxProtobufExtensions.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxRuleDeclarations.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/context/OnnxMappingContext.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/definitions/OnnxOpDeclarations.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/importer/OnnxFrameworkImporter.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRArgDef.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRAttr.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRDataType.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRGraph.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRGraphRunner.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRNode.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIROp.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRTensor.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/opdefs/OnnxOpDescriptorLoader.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/process/OnnxMappingProcess.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/process/OnnxMappingProcessLoader.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxArgDescriptorConstant.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxAttributeNDArrayToScalarAttribute.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxAttributeNumberListNDArray.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxAttributeScalarNDArrayAttribute.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxConditionalFieldValueIntIndexArrayRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxConditionalFieldValueIntIndexNDArrayRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxDataTypeToInt.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxFlattenDims.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxInvertBooleanNumber.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxListAttributeValueLookupToIndex.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxListNumberToListNumber.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxListNumberToNDArray.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxMapStringToInt.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayAttributeToNDArrayInput.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayExtractScalarValue.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayInputToNumericalAttribute.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArraySizeAt.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayToIntAttributeValue.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxSizeThresholdIntArrayIntIndexRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringAttributeToNDArray.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringContainsAdapterRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringEqualsAdapterRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringNotEqualsAdapterRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringToIndex.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxValueMapping.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/tensor/NDArrayMappingRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/tensor/OnnxMultiInputIndexMappingRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/tensor/OnnxPassThroughMultiInputTensorMapping.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.ImportGraphHolder (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.opdefs.OpDescriptorLoader (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/resources/onnx-mapping-ruleset.pbtxt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/resources/onnx-op-def.pbtxt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/main/resources/onnx-op-defs.pb (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/TestOnnxIR.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/importer/TestOnnxFrameworkImporter.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/loader/TestOnnxProcessLoader.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/modelzoo/TestPretrainedModels.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/processing/GroupConvPreProcessingRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/src/test/resources/lenet.onnx (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-onnx/variables-added-new.txt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/00c6b5c8-c93c-4ac9-867f-580443a45bb3-container.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/03195bad-47a3-4de9-9fc7-6691ea41aee0-container.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/04c57933-461b-4d6f-b6a8-a210cef103ff-result.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/0541722d-1de4-4e85-b844-d90d20eea9fb-result.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/154f67c7-64e1-4e2c-a56e-05d390b459d7-result.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/2026534d-ef52-441c-976b-3ef06799a362-result.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/22943ac9-56da-4b92-983d-7385c888c80b-container.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/281f7eda-053b-4dc9-a686-2040bb4f7fd3-container.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/2cfad6f7-cd22-4de1-80a6-b9890ce473fc-result.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/36bc053b-ed9c-40b7-853c-d9462d2a67c0-container.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/445afe43-7f5f-4f5b-81db-e942139be1a7-result.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/505e442f-5f0d-4fe6-80ba-0628e9f3057b-container.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/52bec90b-a05a-4382-a2fc-0835d2da893a-container.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/58aad3d2-4a46-47d3-9748-578e7aae7121-result.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/5b55351d-1e98-4c83-b1ec-0812d352141d-result.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/629659e3-ed5c-482a-89cf-0b4f46026b31-result.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/6b35dfd9-1d25-419e-a196-4a42f20fd8aa-result.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/6f446d7c-ec8d-4567-9f3a-3b9bcb3d21f8-result.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/75db525b-2344-4dcc-a3d9-d23b5acbfe81-container.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/767f4fe3-b7a8-492b-b0ab-ae77f112e105-result.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/7b58c709-b0e3-446f-9e05-4fd86f350b83-container.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/7ce20a5d-8b63-499e-9dc4-0206d0c38b29-container.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/8b28bcc6-1a38-4b55-bc80-185feab4c978-container.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/9d55689b-05d2-4692-ad17-af4aa388cb31-container.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/9f6c1a25-9c6a-40b1-b825-916525e2cb24-result.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/a2400879-a732-411c-a65e-00111c6b550e-container.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/a24baaa5-1cb5-4edd-873b-c923d04905ec-container.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/b3b58b3b-9a41-44aa-9b00-2bb9633a53be-container.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/c0f861a5-c322-458b-82e9-efd5494d37fc-container.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/ca8a7a37-5ce9-4970-aa3d-7eaec8c8091a-result.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/e25409f2-aa78-4897-a810-297802cccdfc-container.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/e82fe95c-6cd2-4a8d-82c7-9f45d15e8a73-container.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/eb70b069-8c1d-440c-a135-174d7b873d11-result.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/allure-results/ef515f16-0d58-450b-85bb-ec61080f012f-result.json (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/nd4j-op-def.pbtxt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/ops-added-new.txt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/ops-added-old.txt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/ops-imported-new.txt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/ops-imported-old.txt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/ops-removed-new.txt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/ops-removed-old.txt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/pom.xml (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowImportGraph.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowImportGraphHolder.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowProtobufExtensions.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowRuleDeclarations.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/context/TensorflowMappingContext.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/definitions/TensorflowOpDeclarations.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/importer/TensorflowFrameworkImporter.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIR.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRArgDef.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRAttr.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRDataType.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRGraph.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRGraphRunner.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRNode.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIROp.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRTensor.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/opdefs/TensorflowOpDescriptorLoader.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/process/TensorflowMappingProcess.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/process/TensorflowMappingProcessLoader.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowArgDescriptorConstant.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowAttributeNDArrayToScalarAttribute.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowAttributeNumberListNDArray.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowAttributeScalarNDArrayAttribute.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowConditionalFieldValueIntIndexArrayRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowConditionalFieldValueIntIndexNDArrayRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowDataTypeToInt.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowFlattenDims.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowInvertBooleanNumber.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowListAttributeValueLookupToIndex.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowListNumberToListNumber.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowListNumberToNDArray.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowMapStringToInt.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayAttributeToNDArrayInput.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayExtractScalarValue.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayInputToNumericalAttribute.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArraySizeAt.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayToIntAttributeValue.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNdArrayToStringIndex.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringAttributeToNDArray.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringContainsAdapterRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringEqualsAdapterRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringNotEqualsAdapterRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowValueMappingRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/tensor/NDArrayMappingRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/tensor/TensorflowMultiInputIndexMappingRule.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/tensor/TensorflowPassThroughMultiTensorMapping.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.ImportGraphHolder (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.opdefs.OpDescriptorLoader (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/resources/tensorflow-mapping-ruleset.pbtxt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/main/resources/tensorflow-op-def.pbtxt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TestTensorflowIR.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TestTensorflowUtils.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/importer/TestTensorflowImporter.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/loader/TestTensorflowProcessLoader.kt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/test/resources/lenet_frozen.pb (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/src/test/resources/logback.xml (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/tensorflow-processes.pbtxt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/test.pbtxt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/variables-added-new.txt (100%) rename {nd4j => .old/nd4j}/samediff-import/samediff-import-tensorflow/variables-added-old.txt (100%) rename perform-release.sh => .old/perform-release.sh (100%) rename {pydatavec => .old/pydatavec}/.eggs/README.txt (100%) rename {pydatavec => .old/pydatavec}/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/LICENSE (100%) rename {pydatavec => .old/pydatavec}/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/PKG-INFO (100%) rename {pydatavec => .old/pydatavec}/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/RECORD (100%) rename {pydatavec => .old/pydatavec}/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/WHEEL (100%) rename {pydatavec => .old/pydatavec}/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/entry_points.txt (100%) rename {pydatavec => .old/pydatavec}/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/requires.txt (100%) rename {pydatavec => .old/pydatavec}/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/top_level.txt (100%) rename {pydatavec => .old/pydatavec}/.eggs/pytest_runner-5.2-py3.8.egg/ptr.py (100%) rename {pydatavec => .old/pydatavec}/pydatavec.egg-info/PKG-INFO (100%) rename {pydatavec => .old/pydatavec}/pydatavec.egg-info/SOURCES.txt (100%) rename {pydatavec => .old/pydatavec}/pydatavec.egg-info/dependency_links.txt (100%) rename {pydatavec => .old/pydatavec}/pydatavec.egg-info/requires.txt (100%) rename {pydatavec => .old/pydatavec}/pydatavec.egg-info/top_level.txt (100%) rename {rl4j => .old/rl4j}/README.md (100%) rename {rl4j => .old/rl4j}/docs/images/cartpole.gif (100%) rename {rl4j => .old/rl4j}/docs/images/doom.gif (100%) rename {rl4j => .old/rl4j}/docs/images/malmo.gif (100%) rename {rl4j => .old/rl4j}/pom.xml (100%) rename {rl4j => .old/rl4j}/rl4j-ale/pom.xml (100%) rename {rl4j => .old/rl4j}/rl4j-ale/src/main/java/org/deeplearning4j/rl4j/mdp/ale/ALEMDP.java (100%) rename {rl4j => .old/rl4j}/rl4j-api/pom.xml (100%) rename {rl4j => .old/rl4j}/rl4j-api/src/main/java/org/deeplearning4j/gym/StepReply.java (100%) rename {rl4j => .old/rl4j}/rl4j-api/src/main/java/org/deeplearning4j/rl4j/mdp/MDP.java (100%) rename {rl4j => .old/rl4j}/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/ActionSpace.java (100%) rename {rl4j => .old/rl4j}/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/ArrayObservationSpace.java (100%) rename {rl4j => .old/rl4j}/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/Box.java (100%) rename {rl4j => .old/rl4j}/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/DiscreteSpace.java (100%) rename {rl4j => .old/rl4j}/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/Encodable.java (100%) rename {rl4j => .old/rl4j}/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/HighLowDiscrete.java (100%) rename {rl4j => .old/rl4j}/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/ObservationSpace.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/nd4j-native.properties (100%) rename {rl4j => .old/rl4j}/rl4j-core/pom.xml (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/Agent.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/AgentLearner.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/IAgent.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/IAgentLearner.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/IUpdateAlgorithm.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/ActorCriticHelper.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/AdvantageActorCritic.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentActorCriticHelper.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentActorCriticHelper.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/BaseDQNAlgorithm.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/BaseTransitionTDAlgorithm.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/DoubleDQN.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/StandardDQN.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NStepQLearning.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NStepQLearningHelper.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningHelper.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningHelper.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/behavior/ILearningBehavior.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/behavior/LearningBehavior.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/Features.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesBuilder.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesLabels.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/Gradients.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/IUpdateRule.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/UpdateRule.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/INeuralNetUpdater.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/NeuralNetUpdaterConfiguration.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncGradientsNeuralNetUpdater.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncLabelsNeuralNetUpdater.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncSharedNetworksUpdateHandler.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/BaseAsyncNeuralNetUpdater.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/BaseSyncNeuralNetUpdater.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncGradientsNeuralNetUpdater.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncLabelsNeuralNetUpdater.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/listener/AgentListener.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/listener/AgentListenerList.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/AdvantageActorCriticBuilder.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/AsyncNetworkHandler.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/BaseAgentLearnerBuilder.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/BaseAsyncAgentLearnerBuilder.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/BaseDQNAgentLearnerBuilder.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/DoubleDQNBuilder.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/INetworksHandler.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/NStepQLearningBuilder.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/StandardDQNBuilder.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/SyncNetworkHandler.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/Environment.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/IActionSchema.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/IntegerActionSchema.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/Schema.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/StepResult.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/ExperienceHandler.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/ReplayMemoryExperienceHandler.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/StateActionExperienceHandler.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/StateActionReward.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/StateActionRewardState.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/helper/INDArrayHelper.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/HistoryProcessor.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/IEpochTrainer.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/IHistoryProcessor.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/ILearning.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/Learning.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/NeuralNetFetchable.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncGlobal.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncLearning.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncThread.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncThreadDiscrete.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/IAsyncGlobal.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/IAsyncLearning.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/UpdateAlgorithm.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CDiscrete.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CDiscreteConv.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CDiscreteDense.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CThreadDiscrete.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/AdvantageActorCriticUpdateAlgorithm.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningDiscrete.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningDiscreteConv.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningDiscreteDense.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningThreadDiscrete.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/QLearningUpdateAlgorithm.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/A3CLearningConfiguration.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/AsyncQLearningConfiguration.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/IAsyncLearningConfiguration.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/ILearningConfiguration.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/LearningConfiguration.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/QLearningConfiguration.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/listener/TrainingListener.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/listener/TrainingListenerList.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/ExpReplay.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/IExpReplay.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/SyncLearning.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/QLearning.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscrete.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscreteConv.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscreteDense.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/CartpoleEnvironment.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/CartpoleNative.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/DoAsISayOrDont.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/TMazeEnvironment.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLake.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLakeHelper.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLakeMap.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLakeState.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/HardDeteministicToy.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/HardToyState.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/SimpleToy.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/SimpleToyState.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ActorCriticNetwork.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/BaseNetwork.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ChannelToNetworkInputMapper.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CommonGradientNames.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CommonLabelNames.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CommonOutputNames.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CompoundNetworkHandler.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ComputationGraphHandler.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/INetworkHandler.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/IOutputNeuralNet.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ITrainableNeuralNet.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/MultiLayerNetworkHandler.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/NetworkHelper.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/NeuralNet.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/NeuralNetOutput.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/QNetwork.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticCompGraph.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactoryCompGraph.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactoryCompGraphStdConv.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactoryCompGraphStdDense.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactorySeparate.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactorySeparateStdDense.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticLoss.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticSeparate.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/IActorCritic.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/ActorCriticDenseNetworkConfiguration.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/ActorCriticNetworkConfiguration.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/DQNDenseNetworkConfiguration.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/NetworkConfiguration.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQN.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQNFactory.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQNFactoryStdConv.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQNFactoryStdDense.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/IDQN.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/IObservationSource.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/Observation.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/EncodableToINDArrayTransform.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/FilterOperation.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/ResettableOperation.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/TransformProcess.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/filter/UniformSkippingFilter.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/legacy/EncodableToImageWritableTransform.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/legacy/ImageWritableToINDArrayTransform.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/ArrayToINDArrayTransform.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/HistoryMergeTransform.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/SimpleNormalizationTransform.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/CircularFifoStore.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryMergeAssembler.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryMergeElementStore.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryStackAssembler.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/ACPolicy.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/BoltzmannQ.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/DQNPolicy.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/EpsGreedy.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/INeuralNetPolicy.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/IPolicy.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/Policy.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/trainer/AsyncTrainer.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/trainer/ITrainer.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/trainer/SyncTrainer.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/Constants.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/DataManager.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/DataManagerTrainingListener.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/IDataManager.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/LegacyMDPWrapper.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/VideoRecorder.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/AgentLearnerCartpole.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/NStepRnn.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/RobotLakeExample.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/TMazeExample.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/AgentLearnerTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/AgentTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentActorCriticHelperTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentAdvantageActorCriticTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentActorCriticHelperTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentAdvantageActorCriticTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/DoubleDQNTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/StandardDQNTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningHelperTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningHelperTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/behavior/LearningBehaviorTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesBuilderTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesLabelsTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/GradientsTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/UpdateRuleTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncGradientsNeuralNetUpdaterTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncLabelsNeuralNetUpdaterTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncSharedNetworksUpdateHandlerTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncGradientsNeuralNetUpdaterTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncLabelsNeuralNetUpdaterTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/builder/BaseAgentLearnerBuilderTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/experience/ReplayMemoryExperienceHandlerTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/experience/StateActionExperienceHandlerTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/helper/INDArrayHelperTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/HistoryProcessorTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/AsyncLearningTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/AsyncThreadDiscreteTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/AsyncThreadTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/AdvantageActorCriticUpdateAlgorithmTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/listener/AsyncTrainingListenerListTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/QLearningUpdateAlgorithmTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/listener/TrainingListenerListTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/ExpReplayTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/StateActionRewardStateTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/SyncLearningTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/qlearning/QLearningConfigurationTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscreteTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/support/MockDQN.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/support/MockStatEntry.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ActorCriticNetworkTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/BaseNetworkTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ChannelToNetworkInputMapperTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/CompoundNetworkHandlerTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ComputationGraphHandlerTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/MultiLayerNetworkHandlerTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/NetworkHelperTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/QNetworkTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ac/ActorCriticTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/dqn/DQNTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/TransformProcessTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/filter/UniformSkippingFilterTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/ArrayToINDArrayTransformTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/HistoryMergeTransformTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/SimpleNormalizationTransformTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/CircularFifoStoreTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryStackAssemblerTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/policy/PolicyTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockDQN.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockDataManager.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockHistoryProcessor.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockMDP.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockNeuralNet.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockObservation.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockObservationSpace.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockPolicy.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockRandom.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/trainer/AsyncTrainerTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/trainer/SyncTrainerTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-core/src/test/java/org/deeplearning4j/rl4j/util/DataManagerTrainingListenerTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/pom.xml (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/Basic.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/DeadlyCorridor.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/PredictPosition.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/TakeCover.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/VizDoom.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/vizdoom/AutomapMode.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/vizdoom/Button.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/vizdoom/DoomGame.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/vizdoom/FileDoesNotExistException.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/vizdoom/GameState.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/vizdoom/GameVariable.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/vizdoom/Label.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/vizdoom/MessageQueueException.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/vizdoom/Mode.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/vizdoom/ScreenFormat.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/vizdoom/ScreenResolution.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/vizdoom/SharedMemoryException.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/vizdoom/SignalException.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/vizdoom/ViZDoomErrorException.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/vizdoom/ViZDoomIsNotRunningException.java (100%) rename {rl4j => .old/rl4j}/rl4j-doom/src/main/java/vizdoom/ViZDoomUnexpectedExitException.java (100%) rename {rl4j => .old/rl4j}/rl4j-gym/pom.xml (100%) rename {rl4j => .old/rl4j}/rl4j-gym/src/main/java/org/deeplearning4j/rl4j/mdp/gym/ActionTransformer.java (100%) rename {rl4j => .old/rl4j}/rl4j-gym/src/main/java/org/deeplearning4j/rl4j/mdp/gym/GymEnv.java (100%) rename {rl4j => .old/rl4j}/rl4j-gym/src/test/java/org/deeplearning4j/rl4j/mdp/gym/GymEnvTest.java (100%) rename {rl4j => .old/rl4j}/rl4j-malmo/pom.xml (100%) rename {rl4j => .old/rl4j}/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoActionSpace.java (100%) rename {rl4j => .old/rl4j}/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoActionSpaceDiscrete.java (100%) rename {rl4j => .old/rl4j}/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoBox.java (100%) rename {rl4j => .old/rl4j}/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoConnectionError.java (100%) rename {rl4j => .old/rl4j}/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoDescretePositionPolicy.java (100%) rename {rl4j => .old/rl4j}/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoEnv.java (100%) rename {rl4j => .old/rl4j}/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationPolicy.java (100%) rename {rl4j => .old/rl4j}/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpace.java (100%) rename {rl4j => .old/rl4j}/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpaceGrid.java (100%) rename {rl4j => .old/rl4j}/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpacePixels.java (100%) rename {rl4j => .old/rl4j}/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpacePosition.java (100%) rename {rl4j => .old/rl4j}/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoResetHandler.java (100%) rename tensorflow-processes.pbtxt => .old/tensorflow-processes.pbtxt (100%) delete mode 100644 arbiter/.travis.yml delete mode 100644 arbiter/README.md delete mode 100644 arbiter/arbiter-core/pom.xml delete mode 100644 arbiter/arbiter-core/src/assembly/bin.xml delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/AbstractParameterSpace.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/Candidate.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/CandidateGenerator.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/OptimizationResult.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/ParameterSpace.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/TaskCreator.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/TaskCreatorProvider.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/adapter/ParameterSpaceAdapter.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/data/DataProvider.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/data/DataSetIteratorFactoryProvider.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/data/DataSource.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/evaluation/ModelEvaluator.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/saving/InMemoryResultSaver.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/saving/ResultReference.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/saving/ResultSaver.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/score/ScoreFunction.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/termination/MaxCandidatesCondition.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/termination/MaxTimeCondition.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/termination/TerminationCondition.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/config/OptimizationConfiguration.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/distribution/DegenerateIntegerDistribution.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/distribution/DistributionUtils.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/distribution/LogUniformDistribution.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/BaseCandidateGenerator.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/GeneticSearchCandidateGenerator.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/GridSearchCandidateGenerator.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/RandomSearchGenerator.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/Chromosome.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/ChromosomeFactory.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/ArithmeticCrossover.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/CrossoverOperator.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/CrossoverResult.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/KPointCrossover.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/SinglePointCrossover.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/TwoParentsCrossoverOperator.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/UniformCrossover.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/parentselection/ParentSelection.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/parentselection/RandomTwoParentSelection.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/parentselection/TwoParentSelection.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/utils/CrossoverPointsGenerator.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/culling/CullOperator.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/culling/LeastFitCullOperator.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/culling/RatioCullOperator.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/exceptions/GeneticGenerationException.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/mutation/MutationOperator.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/mutation/RandomMutationOperator.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/population/EmptyPopulationInitializer.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/population/PopulationInitializer.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/population/PopulationListener.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/population/PopulationModel.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/selection/GeneticSelectionOperator.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/selection/SelectionOperator.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/util/SerializedSupplier.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/BooleanSpace.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/FixedValue.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/continuous/ContinuousParameterSpace.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/discrete/DiscreteParameterSpace.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/integer/IntegerParameterSpace.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/math/MathOp.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/math/Op.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/math/PairMathOp.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/BaseOptimizationRunner.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/CandidateInfo.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/CandidateStatus.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/IOptimizationRunner.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/LocalOptimizationRunner.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/listener/BaseStatusListener.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/listener/StatusChangeType.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/listener/StatusListener.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/listener/impl/LoggingStatusListener.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/FixedValueDeserializer.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/FixedValueSerializer.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/IntegerDistributionDeserializer.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/IntegerDistributionSerializer.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/JsonMapper.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/RealDistributionDeserializer.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/RealDistributionSerializer.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/YamlMapper.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/util/ClassPathResource.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/util/CollectionUtils.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/util/LeafUtils.java delete mode 100644 arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/util/ObjectUtils.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/AssertTestsExtendBaseClass.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/BraninFunction.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/TestGeneticSearch.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/TestGridSearch.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/TestJson.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/TestRandomSearch.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/distribution/TestLogUniform.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestCrossoverOperator.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestMutationOperator.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestParentSelection.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestPopulationInitializer.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestRandomGenerator.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/ArithmeticCrossoverTests.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/CrossoverOperatorTests.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/CrossoverPointsGeneratorTests.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/KPointCrossoverTests.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/ParentSelectionTests.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/RandomTwoParentSelectionTests.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/SinglePointCrossoverTests.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/TwoParentsCrossoverOperatorTests.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/UniformCrossoverTests.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/culling/LeastFitCullOperatorTests.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/culling/RatioCullOperatorTests.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/mutation/RandomMutationOperatorTests.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/population/PopulationModelTests.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/selection/GeneticSelectionOperatorTests.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/selection/SelectionOperatorTests.java delete mode 100644 arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/parameter/TestParameterSpaces.java delete mode 100644 arbiter/arbiter-core/src/test/resources/logback.xml delete mode 100644 arbiter/arbiter-deeplearning4j/pom.xml delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/BaseNetworkSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/ComputationGraphSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/DL4JConfiguration.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/GraphConfiguration.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/MultiLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/adapter/ActivationParameterSpaceAdapter.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/adapter/LossFunctionParameterSpaceAdapter.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/dropout/DropoutSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/AdaGradSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/AdaMaxSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/AdamSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/BaseUpdaterSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/NadamSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/NesterovsSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/RmsPropSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/SgdSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/ExponentialScheduleSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/InverseScheduleSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/PolyScheduleSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/SigmoidScheduleSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/StepScheduleSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/data/DataSetIteratorFactoryProvider.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/data/MnistDataProvider.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/dropout/AlphaDropoutSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/dropout/DropoutSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/dropout/GaussianDropoutSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/dropout/GaussianNoiseSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/evaluator/multilayer/ClassificationEvaluator.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/evaluator/multilayer/RegressionDataEvaluator.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/AbstractLSTMLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/ActivationLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/AutoEncoderLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BaseConvolutionLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BaseLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BaseOutputLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BasePretrainNetworkLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BatchNormalizationSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/Bidirectional.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/CenterLossOutputLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/ConvolutionLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/Deconvolution2DLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/DenseLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/DropoutLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/EmbeddingLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/FeedForwardLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/GlobalPoolingLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/GravesBidirectionalLSTMLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/GravesLSTMLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/LSTMLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/LayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/LocalResponseNormalizationLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/LossLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/OCNNLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/OutputLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/RnnOutputLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/SeparableConvolution2DLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/SubsamplingLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/VariationalAutoencoderLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/fixed/FixedLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/listener/DL4JArbiterStatusReportingListener.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/saver/local/FileModelSaver.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/saver/local/LocalFileNetResultReference.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/RegressionValue.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/ScoreFunctions.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/BaseNetScoreFunction.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/EvaluationScoreFunction.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/ROCScoreFunction.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/RegressionScoreFunction.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/TestSetAccuracyScoreFunction.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/TestSetF1ScoreFunction.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/TestSetLossScoreFunction.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/TestSetRegressionScoreFunction.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/util/ScoreUtil.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/task/ComputationGraphTaskCreator.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/task/MultiLayerNetworkTaskCreator.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/task/TaskListener.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/AssertTestsExtendBaseClass.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/TestUtils.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/computationgraph/TestComputationGraphSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/computationgraph/TestGraphLocalExecution.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/computationgraph/TestGraphLocalExecutionGenetic.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/json/TestJson.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/MNISTOptimizationTest.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/MnistDataSetIteratorFactory.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestDL4JLocalExecution.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestErrors.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestMultiLayerSpace.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestScoreFunctions.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/util/TestDataFactoryProviderMnist.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/util/TestDataProviderMnist.java delete mode 100644 arbiter/arbiter-deeplearning4j/src/test/resources/logback.xml delete mode 100644 arbiter/arbiter-server/pom.xml delete mode 100644 arbiter/arbiter-server/src/main/java/org/deeplearning4j/arbiter/server/ArbiterCliGenerator.java delete mode 100644 arbiter/arbiter-server/src/main/java/org/deeplearning4j/arbiter/server/ArbiterCliRunner.java delete mode 100644 arbiter/arbiter-server/src/main/java/org/deeplearning4j/arbiter/server/cli/NeuralNetTypeValidator.java delete mode 100644 arbiter/arbiter-server/src/main/java/org/deeplearning4j/arbiter/server/cli/ProblemTypeValidator.java delete mode 100644 arbiter/arbiter-server/src/test/java/org/deeplearning4j/arbiter/server/ArbiterCLIRunnerTest.java delete mode 100644 arbiter/arbiter-server/src/test/java/org/deeplearning4j/arbiter/server/AssertTestsExtendBaseClass.java delete mode 100644 arbiter/arbiter-server/src/test/java/org/deeplearning4j/arbiter/server/MnistDataSetIteratorFactory.java delete mode 100644 arbiter/arbiter-server/src/test/java/org/deeplearning4j/arbiter/server/TestDataFactoryProviderMnist.java delete mode 100644 arbiter/arbiter-ui/pom.xml delete mode 100644 arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/UpdateStatus.java delete mode 100644 arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/data/BaseJavaPersistable.java delete mode 100644 arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/data/GlobalConfigPersistable.java delete mode 100644 arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/data/ModelInfoPersistable.java delete mode 100644 arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/listener/ArbiterStatusListener.java delete mode 100644 arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/misc/JsonMapper.java delete mode 100644 arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/misc/UIUtils.java delete mode 100644 arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/module/ArbiterModule.java delete mode 100644 arbiter/arbiter-ui/src/main/resources/META-INF/services/org.deeplearning4j.ui.api.UIModule delete mode 100644 arbiter/arbiter-ui/src/main/resources/deeplearning4jUiAssets/dl4j-ui.js delete mode 100644 arbiter/arbiter-ui/src/main/resources/deeplearning4jUiAssets/dl4j-ui.js.map delete mode 100644 arbiter/arbiter-ui/src/main/resources/templates/ArbiterUI.html delete mode 100644 arbiter/arbiter-ui/src/test/java/org/deeplearning4j/arbiter/optimize/AssertTestsExtendBaseClass.java delete mode 100644 arbiter/arbiter-ui/src/test/java/org/deeplearning4j/arbiter/optimize/TestBasic.java delete mode 100644 arbiter/arbiter-ui/src/test/resources/logback.xml delete mode 100644 arbiter/buildmultiplescalaversions.sh delete mode 100644 arbiter/contrib/formatter.xml delete mode 100644 arbiter/pom.xml create mode 100644 cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/package-info.java diff --git a/.gitignore b/.gitignore index fbe938d6a..6c39e54b9 100644 --- a/.gitignore +++ b/.gitignore @@ -50,12 +50,12 @@ release.properties *.dylib .vs/ .vscode/ -nd4j/nd4j-backends/nd4j-api-parent/nd4j-api/src/main/resources/bin -nd4j/nd4j-backends/nd4j-backend-impls/nd4j-native/src/test/resources/writeNumpy.csv -nd4j/nd4j-backends/nd4j-tests/src/test/resources/tf_graphs/examples/**/data-all* -nd4j/nd4j-backends/nd4j-tests/src/test/resources/tf_graphs/examples/**/checkpoint -nd4j/nd4j-backends/nd4j-api-parent/nd4j-api/src/main/java/onnx/ -nd4j/nd4j-backends/nd4j-api-parent/nd4j-api/src/main/java/org/tensorflow/ +.old/nd4j/nd4j-backends/nd4j-api-parent/nd4j-api/src/main/resources/bin +.old/nd4j/nd4j-backends/nd4j-backend-impls/nd4j-native/src/test/resources/writeNumpy.csv +.old/nd4j/nd4j-backends/nd4j-tests/src/test/resources/tf_graphs/examples/**/data-all* +.old/nd4j/nd4j-backends/nd4j-tests/src/test/resources/tf_graphs/examples/**/checkpoint +.old/nd4j/nd4j-backends/nd4j-api-parent/nd4j-api/src/main/java/onnx/ +.old/nd4j/nd4j-backends/nd4j-api-parent/nd4j-api/src/main/java/org/tensorflow/ doc_sources/ doc_sources_* @@ -67,8 +67,8 @@ venv/ venv2/ # Ignore the nd4j files that are created by javacpp at build to stop merge conflicts -nd4j/nd4j-backends/nd4j-backend-impls/nd4j-native/src/main/java/org/nd4j/nativeblas/Nd4jCpu.java -nd4j/nd4j-backends/nd4j-backend-impls/nd4j-cuda/src/main/java/org/nd4j/nativeblas/Nd4jCuda.java +.old/nd4j/nd4j-backends/nd4j-backend-impls/nd4j-native/src/main/java/org/nd4j/nativeblas/Nd4jCpu.java +.old/nd4j/nd4j-backends/nd4j-backend-impls/nd4j-cuda/src/main/java/org/nd4j/nativeblas/Nd4jCuda.java # Ignore meld temp files *.orig diff --git a/.github/ISSUE_TEMPLATE.md b/.old/.github/ISSUE_TEMPLATE.md similarity index 100% rename from .github/ISSUE_TEMPLATE.md rename to .old/.github/ISSUE_TEMPLATE.md diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.old/.github/PULL_REQUEST_TEMPLATE.md similarity index 100% rename from .github/PULL_REQUEST_TEMPLATE.md rename to .old/.github/PULL_REQUEST_TEMPLATE.md diff --git a/.github/actions/download-dl4j-test-resources-linux/action.yml b/.old/.github/actions/download-dl4j-test-resources-linux/action.yml similarity index 100% rename from .github/actions/download-dl4j-test-resources-linux/action.yml rename to .old/.github/actions/download-dl4j-test-resources-linux/action.yml diff --git a/.github/actions/download-dl4j-test-resources-windows/action.yml b/.old/.github/actions/download-dl4j-test-resources-windows/action.yml similarity index 100% rename from .github/actions/download-dl4j-test-resources-windows/action.yml rename to .old/.github/actions/download-dl4j-test-resources-windows/action.yml diff --git a/.github/actions/install-arm-cross-compile/action.yml b/.old/.github/actions/install-arm-cross-compile/action.yml similarity index 100% rename from .github/actions/install-arm-cross-compile/action.yml rename to .old/.github/actions/install-arm-cross-compile/action.yml diff --git a/.github/actions/install-cmake-linux/action.yml b/.old/.github/actions/install-cmake-linux/action.yml similarity index 100% rename from .github/actions/install-cmake-linux/action.yml rename to .old/.github/actions/install-cmake-linux/action.yml diff --git a/.github/actions/install-protobuf-linux/action.yml b/.old/.github/actions/install-protobuf-linux/action.yml similarity index 100% rename from .github/actions/install-protobuf-linux/action.yml rename to .old/.github/actions/install-protobuf-linux/action.yml diff --git a/.github/actions/msys2-base-setup/action.yml b/.old/.github/actions/msys2-base-setup/action.yml similarity index 100% rename from .github/actions/msys2-base-setup/action.yml rename to .old/.github/actions/msys2-base-setup/action.yml diff --git a/.github/actions/publish-gh-packages/action.yml b/.old/.github/actions/publish-gh-packages/action.yml similarity index 100% rename from .github/actions/publish-gh-packages/action.yml rename to .old/.github/actions/publish-gh-packages/action.yml diff --git a/.github/actions/update-deps-linux/action.yml b/.old/.github/actions/update-deps-linux/action.yml similarity index 100% rename from .github/actions/update-deps-linux/action.yml rename to .old/.github/actions/update-deps-linux/action.yml diff --git a/.github/workflows/build-android-x86_64.yml b/.old/.github/workflows/build-android-x86_64.yml similarity index 100% rename from .github/workflows/build-android-x86_64.yml rename to .old/.github/workflows/build-android-x86_64.yml diff --git a/.github/workflows/build-deploy-android-arm32.yml b/.old/.github/workflows/build-deploy-android-arm32.yml similarity index 100% rename from .github/workflows/build-deploy-android-arm32.yml rename to .old/.github/workflows/build-deploy-android-arm32.yml diff --git a/.github/workflows/build-deploy-android-arm64.yml b/.old/.github/workflows/build-deploy-android-arm64.yml similarity index 100% rename from .github/workflows/build-deploy-android-arm64.yml rename to .old/.github/workflows/build-deploy-android-arm64.yml diff --git a/.github/workflows/build-deploy-linux-arm32.yml b/.old/.github/workflows/build-deploy-linux-arm32.yml similarity index 100% rename from .github/workflows/build-deploy-linux-arm32.yml rename to .old/.github/workflows/build-deploy-linux-arm32.yml diff --git a/.github/workflows/build-deploy-linux-arm64.yml b/.old/.github/workflows/build-deploy-linux-arm64.yml similarity index 100% rename from .github/workflows/build-deploy-linux-arm64.yml rename to .old/.github/workflows/build-deploy-linux-arm64.yml diff --git a/.github/workflows/build-deploy-linux-cuda-11.0.yml b/.old/.github/workflows/build-deploy-linux-cuda-11.0.yml similarity index 100% rename from .github/workflows/build-deploy-linux-cuda-11.0.yml rename to .old/.github/workflows/build-deploy-linux-cuda-11.0.yml diff --git a/.github/workflows/build-deploy-linux-cuda-11.2.yml b/.old/.github/workflows/build-deploy-linux-cuda-11.2.yml similarity index 100% rename from .github/workflows/build-deploy-linux-cuda-11.2.yml rename to .old/.github/workflows/build-deploy-linux-cuda-11.2.yml diff --git a/.github/workflows/build-deploy-linux-x86_64.yml b/.old/.github/workflows/build-deploy-linux-x86_64.yml similarity index 100% rename from .github/workflows/build-deploy-linux-x86_64.yml rename to .old/.github/workflows/build-deploy-linux-x86_64.yml diff --git a/.github/workflows/build-deploy-mac.yml b/.old/.github/workflows/build-deploy-mac.yml similarity index 100% rename from .github/workflows/build-deploy-mac.yml rename to .old/.github/workflows/build-deploy-mac.yml diff --git a/.github/workflows/build-deploy-windows-cuda-11.0.yml b/.old/.github/workflows/build-deploy-windows-cuda-11.0.yml similarity index 100% rename from .github/workflows/build-deploy-windows-cuda-11.0.yml rename to .old/.github/workflows/build-deploy-windows-cuda-11.0.yml diff --git a/.github/workflows/build-deploy-windows-cuda-11.2.yml b/.old/.github/workflows/build-deploy-windows-cuda-11.2.yml similarity index 100% rename from .github/workflows/build-deploy-windows-cuda-11.2.yml rename to .old/.github/workflows/build-deploy-windows-cuda-11.2.yml diff --git a/.github/workflows/build-deploy-windows.yml b/.old/.github/workflows/build-deploy-windows.yml similarity index 100% rename from .github/workflows/build-deploy-windows.yml rename to .old/.github/workflows/build-deploy-windows.yml diff --git a/.github/workflows/cpu-integration-tests.yaml b/.old/.github/workflows/cpu-integration-tests.yaml similarity index 100% rename from .github/workflows/cpu-integration-tests.yaml rename to .old/.github/workflows/cpu-integration-tests.yaml diff --git a/.github/workflows/cpu-sanity-check-tests.yaml b/.old/.github/workflows/cpu-sanity-check-tests.yaml similarity index 100% rename from .github/workflows/cpu-sanity-check-tests.yaml rename to .old/.github/workflows/cpu-sanity-check-tests.yaml diff --git a/.github/workflows/run-cpu-tests-sanity-checks.yml b/.old/.github/workflows/run-cpu-tests-sanity-checks.yml similarity index 100% rename from .github/workflows/run-cpu-tests-sanity-checks.yml rename to .old/.github/workflows/run-cpu-tests-sanity-checks.yml diff --git a/.github/workflows/run-gpu-tests-sanity-checks.yml b/.old/.github/workflows/run-gpu-tests-sanity-checks.yml similarity index 100% rename from .github/workflows/run-gpu-tests-sanity-checks.yml rename to .old/.github/workflows/run-gpu-tests-sanity-checks.yml diff --git a/.github/workflows/test_multiple_arch.yaml b/.old/.github/workflows/test_multiple_arch.yaml similarity index 100% rename from .github/workflows/test_multiple_arch.yaml rename to .old/.github/workflows/test_multiple_arch.yaml diff --git a/ADRs/0001-SameDiff_File_Format.md b/.old/ADRs/0001-SameDiff_File_Format.md similarity index 100% rename from ADRs/0001-SameDiff_File_Format.md rename to .old/ADRs/0001-SameDiff_File_Format.md diff --git a/ADRs/0002-ONNX_Runtime.md b/.old/ADRs/0002-ONNX_Runtime.md similarity index 100% rename from ADRs/0002-ONNX_Runtime.md rename to .old/ADRs/0002-ONNX_Runtime.md diff --git a/ADRs/0003-Import_IR.md b/.old/ADRs/0003-Import_IR.md similarity index 100% rename from ADRs/0003-Import_IR.md rename to .old/ADRs/0003-Import_IR.md diff --git a/ADRs/0003-NdArray_Strides_ArmCompute.md b/.old/ADRs/0003-NdArray_Strides_ArmCompute.md similarity index 100% rename from ADRs/0003-NdArray_Strides_ArmCompute.md rename to .old/ADRs/0003-NdArray_Strides_ArmCompute.md diff --git a/ADRs/0004-Mapping_IR.md b/.old/ADRs/0004-Mapping_IR.md similarity index 100% rename from ADRs/0004-Mapping_IR.md rename to .old/ADRs/0004-Mapping_IR.md diff --git a/ADRs/0005-Interpreter.md b/.old/ADRs/0005-Interpreter.md similarity index 100% rename from ADRs/0005-Interpreter.md rename to .old/ADRs/0005-Interpreter.md diff --git a/change-cuda-versions.sh b/.old/change-cuda-versions.sh similarity index 100% rename from change-cuda-versions.sh rename to .old/change-cuda-versions.sh diff --git a/change-scala-versions.sh b/.old/change-scala-versions.sh similarity index 100% rename from change-scala-versions.sh rename to .old/change-scala-versions.sh diff --git a/contrib/README.md b/.old/contrib/README.md similarity index 100% rename from contrib/README.md rename to .old/contrib/README.md diff --git a/contrib/codegen-tools/codegen/adr/0001-kotlin_dsl_as_source_of_truth.md b/.old/contrib/codegen-tools/codegen/adr/0001-kotlin_dsl_as_source_of_truth.md similarity index 100% rename from contrib/codegen-tools/codegen/adr/0001-kotlin_dsl_as_source_of_truth.md rename to .old/contrib/codegen-tools/codegen/adr/0001-kotlin_dsl_as_source_of_truth.md diff --git a/contrib/codegen-tools/codegen/adr/0002-separate_object_graph_for_serialization.md b/.old/contrib/codegen-tools/codegen/adr/0002-separate_object_graph_for_serialization.md similarity index 100% rename from contrib/codegen-tools/codegen/adr/0002-separate_object_graph_for_serialization.md rename to .old/contrib/codegen-tools/codegen/adr/0002-separate_object_graph_for_serialization.md diff --git a/contrib/codegen-tools/codegen/adr/0003-dealing_with_inconsistencies_in_java_naming.md b/.old/contrib/codegen-tools/codegen/adr/0003-dealing_with_inconsistencies_in_java_naming.md similarity index 100% rename from contrib/codegen-tools/codegen/adr/0003-dealing_with_inconsistencies_in_java_naming.md rename to .old/contrib/codegen-tools/codegen/adr/0003-dealing_with_inconsistencies_in_java_naming.md diff --git a/contrib/codegen-tools/codegen/adr/0004-auto_initialization_for_inplace_operations.md b/.old/contrib/codegen-tools/codegen/adr/0004-auto_initialization_for_inplace_operations.md similarity index 100% rename from contrib/codegen-tools/codegen/adr/0004-auto_initialization_for_inplace_operations.md rename to .old/contrib/codegen-tools/codegen/adr/0004-auto_initialization_for_inplace_operations.md diff --git a/contrib/codegen-tools/codegen/adr/0005-optional_parameters_and_signatures.md b/.old/contrib/codegen-tools/codegen/adr/0005-optional_parameters_and_signatures.md similarity index 100% rename from contrib/codegen-tools/codegen/adr/0005-optional_parameters_and_signatures.md rename to .old/contrib/codegen-tools/codegen/adr/0005-optional_parameters_and_signatures.md diff --git a/contrib/codegen-tools/codegen/adr/0006-op_specific_enums.md b/.old/contrib/codegen-tools/codegen/adr/0006-op_specific_enums.md similarity index 100% rename from contrib/codegen-tools/codegen/adr/0006-op_specific_enums.md rename to .old/contrib/codegen-tools/codegen/adr/0006-op_specific_enums.md diff --git a/contrib/codegen-tools/codegen/adr/0007-configuration_objects.md b/.old/contrib/codegen-tools/codegen/adr/0007-configuration_objects.md similarity index 100% rename from contrib/codegen-tools/codegen/adr/0007-configuration_objects.md rename to .old/contrib/codegen-tools/codegen/adr/0007-configuration_objects.md diff --git a/contrib/codegen-tools/codegen/adr/0008-inheritance.md b/.old/contrib/codegen-tools/codegen/adr/0008-inheritance.md similarity index 100% rename from contrib/codegen-tools/codegen/adr/0008-inheritance.md rename to .old/contrib/codegen-tools/codegen/adr/0008-inheritance.md diff --git a/contrib/codegen-tools/codegen/adr/0009-aliasing.md b/.old/contrib/codegen-tools/codegen/adr/0009-aliasing.md similarity index 100% rename from contrib/codegen-tools/codegen/adr/0009-aliasing.md rename to .old/contrib/codegen-tools/codegen/adr/0009-aliasing.md diff --git a/contrib/codegen-tools/codegen/adr/0010-ir-codegen.md b/.old/contrib/codegen-tools/codegen/adr/0010-ir-codegen.md similarity index 100% rename from contrib/codegen-tools/codegen/adr/0010-ir-codegen.md rename to .old/contrib/codegen-tools/codegen/adr/0010-ir-codegen.md diff --git a/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/Namespace.java b/.old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/Namespace.java similarity index 100% rename from contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/Namespace.java rename to .old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/Namespace.java diff --git a/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/cli/CLI.java b/.old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/cli/CLI.java similarity index 100% rename from contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/cli/CLI.java rename to .old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/cli/CLI.java diff --git a/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/cpp/CppGenerator.java b/.old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/cpp/CppGenerator.java similarity index 100% rename from contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/cpp/CppGenerator.java rename to .old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/cpp/CppGenerator.java diff --git a/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/java/DocsGenerator.java b/.old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/java/DocsGenerator.java similarity index 100% rename from contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/java/DocsGenerator.java rename to .old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/java/DocsGenerator.java diff --git a/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/java/JavaPoetGenerator.java b/.old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/java/JavaPoetGenerator.java similarity index 100% rename from contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/java/JavaPoetGenerator.java rename to .old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/java/JavaPoetGenerator.java diff --git a/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/java/Nd4jNamespaceGenerator.java b/.old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/java/Nd4jNamespaceGenerator.java similarity index 100% rename from contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/java/Nd4jNamespaceGenerator.java rename to .old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/java/Nd4jNamespaceGenerator.java diff --git a/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/python/PythonGenerator.java b/.old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/python/PythonGenerator.java similarity index 100% rename from contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/python/PythonGenerator.java rename to .old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/impl/python/PythonGenerator.java diff --git a/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/ir/SerializationTest.java b/.old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/ir/SerializationTest.java similarity index 100% rename from contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/ir/SerializationTest.java rename to .old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/ir/SerializationTest.java diff --git a/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/util/GenUtil.java b/.old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/util/GenUtil.java similarity index 100% rename from contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/util/GenUtil.java rename to .old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/util/GenUtil.java diff --git a/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/util/JsonMapper.java b/.old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/util/JsonMapper.java similarity index 100% rename from contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/util/JsonMapper.java rename to .old/contrib/codegen-tools/codegen/src/main/java/org/nd4j/codegen/util/JsonMapper.java diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/CodeComponent.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/CodeComponent.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/CodeComponent.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/CodeComponent.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/DataType.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/DataType.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/DataType.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/DataType.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Language.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Language.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Language.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Language.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/LossReduce.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/LossReduce.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/LossReduce.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/LossReduce.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Namespace.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Namespace.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Namespace.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Namespace.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/NamespaceOps.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/NamespaceOps.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/NamespaceOps.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/NamespaceOps.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Op.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Op.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Op.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Op.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Registry.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Registry.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Registry.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Registry.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Variables.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Variables.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Variables.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/Variables.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/doc/DocScope.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/doc/DocScope.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/doc/DocScope.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/doc/DocScope.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/doc/DocSection.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/doc/DocSection.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/doc/DocSection.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/doc/DocSection.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/doc/DocTokens.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/doc/DocTokens.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/doc/DocTokens.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/doc/DocTokens.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/generator/ConstraintCodeGenerator.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/generator/ConstraintCodeGenerator.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/generator/ConstraintCodeGenerator.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/generator/ConstraintCodeGenerator.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/generator/Generator.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/generator/Generator.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/generator/Generator.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/generator/Generator.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/generator/GeneratorConfig.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/generator/GeneratorConfig.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/generator/GeneratorConfig.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/api/generator/GeneratorConfig.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/dsl/OpBuilder.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/dsl/OpBuilder.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/dsl/OpBuilder.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/dsl/OpBuilder.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/impl/java/JavaConstraintCodeGenerator.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/impl/java/JavaConstraintCodeGenerator.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/impl/java/JavaConstraintCodeGenerator.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/impl/java/JavaConstraintCodeGenerator.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/impl/python/KotlinExamplePythonGenerator.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/impl/python/KotlinExamplePythonGenerator.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/impl/python/KotlinExamplePythonGenerator.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/impl/python/KotlinExamplePythonGenerator.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/util/GenerateOps.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/util/GenerateOps.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/util/GenerateOps.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/util/GenerateOps.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/util/extract/ExtractFromExisting.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/util/extract/ExtractFromExisting.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/util/extract/ExtractFromExisting.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/util/extract/ExtractFromExisting.kt diff --git a/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/util/extract/FindUsedParameterTypes.kt b/.old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/util/extract/FindUsedParameterTypes.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/util/extract/FindUsedParameterTypes.kt rename to .old/contrib/codegen-tools/codegen/src/main/kotlin/org/nd4j/codegen/util/extract/FindUsedParameterTypes.kt diff --git a/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/mixins/Mixins.kt b/.old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/mixins/Mixins.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/mixins/Mixins.kt rename to .old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/mixins/Mixins.kt diff --git a/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Bitwise.kt b/.old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Bitwise.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Bitwise.kt rename to .old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Bitwise.kt diff --git a/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/CNN.kt b/.old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/CNN.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/CNN.kt rename to .old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/CNN.kt diff --git a/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Image.kt b/.old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Image.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Image.kt rename to .old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Image.kt diff --git a/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Linalg.kt b/.old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Linalg.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Linalg.kt rename to .old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Linalg.kt diff --git a/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Math.kt b/.old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Math.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Math.kt rename to .old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Math.kt diff --git a/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/NeuralNetwork.kt b/.old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/NeuralNetwork.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/NeuralNetwork.kt rename to .old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/NeuralNetwork.kt diff --git a/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/RNN.kt b/.old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/RNN.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/RNN.kt rename to .old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/RNN.kt diff --git a/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Random.kt b/.old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Random.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Random.kt rename to .old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/Random.kt diff --git a/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/SDBaseOps.kt b/.old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/SDBaseOps.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/SDBaseOps.kt rename to .old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/SDBaseOps.kt diff --git a/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/SDLoss.kt b/.old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/SDLoss.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/SDLoss.kt rename to .old/contrib/codegen-tools/codegen/src/main/ops/org/nd4j/codegen/ops/SDLoss.kt diff --git a/contrib/codegen-tools/codegen/src/main/resources/logback.xml b/.old/contrib/codegen-tools/codegen/src/main/resources/logback.xml similarity index 100% rename from contrib/codegen-tools/codegen/src/main/resources/logback.xml rename to .old/contrib/codegen-tools/codegen/src/main/resources/logback.xml diff --git a/contrib/codegen-tools/codegen/src/main/resources/namespaces/math.json b/.old/contrib/codegen-tools/codegen/src/main/resources/namespaces/math.json similarity index 100% rename from contrib/codegen-tools/codegen/src/main/resources/namespaces/math.json rename to .old/contrib/codegen-tools/codegen/src/main/resources/namespaces/math.json diff --git a/contrib/codegen-tools/codegen/src/main/resources/nd4j-op-defs-2.proto b/.old/contrib/codegen-tools/codegen/src/main/resources/nd4j-op-defs-2.proto similarity index 100% rename from contrib/codegen-tools/codegen/src/main/resources/nd4j-op-defs-2.proto rename to .old/contrib/codegen-tools/codegen/src/main/resources/nd4j-op-defs-2.proto diff --git a/contrib/codegen-tools/codegen/src/main/resources/onnx-op-defs.pb b/.old/contrib/codegen-tools/codegen/src/main/resources/onnx-op-defs.pb similarity index 100% rename from contrib/codegen-tools/codegen/src/main/resources/onnx-op-defs.pb rename to .old/contrib/codegen-tools/codegen/src/main/resources/onnx-op-defs.pb diff --git a/contrib/codegen-tools/codegen/src/main/resources/onnx.pbtxt b/.old/contrib/codegen-tools/codegen/src/main/resources/onnx.pbtxt similarity index 100% rename from contrib/codegen-tools/codegen/src/main/resources/onnx.pbtxt rename to .old/contrib/codegen-tools/codegen/src/main/resources/onnx.pbtxt diff --git a/contrib/codegen-tools/codegen/src/main/resources/tensorflowOpMappings.csv b/.old/contrib/codegen-tools/codegen/src/main/resources/tensorflowOpMappings.csv similarity index 100% rename from contrib/codegen-tools/codegen/src/main/resources/tensorflowOpMappings.csv rename to .old/contrib/codegen-tools/codegen/src/main/resources/tensorflowOpMappings.csv diff --git a/contrib/codegen-tools/codegen/src/test/java/org/nd4j/codegen/dsl/DocsGeneratorTest.java b/.old/contrib/codegen-tools/codegen/src/test/java/org/nd4j/codegen/dsl/DocsGeneratorTest.java similarity index 100% rename from contrib/codegen-tools/codegen/src/test/java/org/nd4j/codegen/dsl/DocsGeneratorTest.java rename to .old/contrib/codegen-tools/codegen/src/test/java/org/nd4j/codegen/dsl/DocsGeneratorTest.java diff --git a/contrib/codegen-tools/codegen/src/test/java/org/nd4j/codegen/dsl/TestGeneration.java b/.old/contrib/codegen-tools/codegen/src/test/java/org/nd4j/codegen/dsl/TestGeneration.java similarity index 100% rename from contrib/codegen-tools/codegen/src/test/java/org/nd4j/codegen/dsl/TestGeneration.java rename to .old/contrib/codegen-tools/codegen/src/test/java/org/nd4j/codegen/dsl/TestGeneration.java diff --git a/contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/ConfigTest.kt b/.old/contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/ConfigTest.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/ConfigTest.kt rename to .old/contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/ConfigTest.kt diff --git a/contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/ConstraintTest.kt b/.old/contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/ConstraintTest.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/ConstraintTest.kt rename to .old/contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/ConstraintTest.kt diff --git a/contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/NamespaceInvariantTest.kt b/.old/contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/NamespaceInvariantTest.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/NamespaceInvariantTest.kt rename to .old/contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/NamespaceInvariantTest.kt diff --git a/contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/OpBuilderTest.kt b/.old/contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/OpBuilderTest.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/OpBuilderTest.kt rename to .old/contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/OpBuilderTest.kt diff --git a/contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/OpInvariantTest.kt b/.old/contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/OpInvariantTest.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/OpInvariantTest.kt rename to .old/contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/dsl/OpInvariantTest.kt diff --git a/contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/ops/ConstructionTest.kt b/.old/contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/ops/ConstructionTest.kt similarity index 100% rename from contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/ops/ConstructionTest.kt rename to .old/contrib/codegen-tools/codegen/src/test/kotlin/org/nd4j/codegen/ops/ConstructionTest.kt diff --git a/contrib/codegen-tools/codegen/src/test/resources/lenet.onnx b/.old/contrib/codegen-tools/codegen/src/test/resources/lenet.onnx similarity index 100% rename from contrib/codegen-tools/codegen/src/test/resources/lenet.onnx rename to .old/contrib/codegen-tools/codegen/src/test/resources/lenet.onnx diff --git a/contrib/codegen-tools/codegen/src/test/resources/lenet_frozen.pb b/.old/contrib/codegen-tools/codegen/src/test/resources/lenet_frozen.pb similarity index 100% rename from contrib/codegen-tools/codegen/src/test/resources/lenet_frozen.pb rename to .old/contrib/codegen-tools/codegen/src/test/resources/lenet_frozen.pb diff --git a/contrib/codegen-tools/libnd4j-gen/README.md b/.old/contrib/codegen-tools/libnd4j-gen/README.md similarity index 100% rename from contrib/codegen-tools/libnd4j-gen/README.md rename to .old/contrib/codegen-tools/libnd4j-gen/README.md diff --git a/contrib/codegen-tools/libnd4j-gen/op-ir.proto b/.old/contrib/codegen-tools/libnd4j-gen/op-ir.proto similarity index 100% rename from contrib/codegen-tools/libnd4j-gen/op-ir.proto rename to .old/contrib/codegen-tools/libnd4j-gen/op-ir.proto diff --git a/contrib/codegen-tools/libnd4j-gen/pom.xml b/.old/contrib/codegen-tools/libnd4j-gen/pom.xml similarity index 100% rename from contrib/codegen-tools/libnd4j-gen/pom.xml rename to .old/contrib/codegen-tools/libnd4j-gen/pom.xml diff --git a/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/OpDeclarationDescriptor.java b/.old/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/OpDeclarationDescriptor.java similarity index 100% rename from contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/OpDeclarationDescriptor.java rename to .old/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/OpDeclarationDescriptor.java diff --git a/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/ParseOpFile.java b/.old/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/ParseOpFile.java similarity index 100% rename from contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/ParseOpFile.java rename to .old/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/ParseOpFile.java diff --git a/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/ArgDescriptorProposal.java b/.old/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/ArgDescriptorProposal.java similarity index 100% rename from contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/ArgDescriptorProposal.java rename to .old/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/ArgDescriptorProposal.java diff --git a/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/ArgDescriptorSource.java b/.old/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/ArgDescriptorSource.java similarity index 100% rename from contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/ArgDescriptorSource.java rename to .old/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/ArgDescriptorSource.java diff --git a/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/impl/ArgDescriptorParserUtils.java b/.old/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/impl/ArgDescriptorParserUtils.java similarity index 100% rename from contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/impl/ArgDescriptorParserUtils.java rename to .old/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/impl/ArgDescriptorParserUtils.java diff --git a/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/impl/JavaSourceArgDescriptorSource.java b/.old/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/impl/JavaSourceArgDescriptorSource.java similarity index 100% rename from contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/impl/JavaSourceArgDescriptorSource.java rename to .old/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/impl/JavaSourceArgDescriptorSource.java diff --git a/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/impl/Libnd4jArgDescriptorSource.java b/.old/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/impl/Libnd4jArgDescriptorSource.java similarity index 100% rename from contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/impl/Libnd4jArgDescriptorSource.java rename to .old/contrib/codegen-tools/libnd4j-gen/src/main/java/org/nd4j/descriptor/proposal/impl/Libnd4jArgDescriptorSource.java diff --git a/contrib/codegen-tools/onnx-def-gen/README.md b/.old/contrib/codegen-tools/onnx-def-gen/README.md similarity index 100% rename from contrib/codegen-tools/onnx-def-gen/README.md rename to .old/contrib/codegen-tools/onnx-def-gen/README.md diff --git a/contrib/codegen-tools/onnx-def-gen/lenet.onnx b/.old/contrib/codegen-tools/onnx-def-gen/lenet.onnx similarity index 100% rename from contrib/codegen-tools/onnx-def-gen/lenet.onnx rename to .old/contrib/codegen-tools/onnx-def-gen/lenet.onnx diff --git a/contrib/codegen-tools/onnx-def-gen/onnx-op-defs.pb b/.old/contrib/codegen-tools/onnx-def-gen/onnx-op-defs.pb similarity index 100% rename from contrib/codegen-tools/onnx-def-gen/onnx-op-defs.pb rename to .old/contrib/codegen-tools/onnx-def-gen/onnx-op-defs.pb diff --git a/contrib/codegen-tools/onnx-def-gen/onnx.pbtxt b/.old/contrib/codegen-tools/onnx-def-gen/onnx.pbtxt similarity index 100% rename from contrib/codegen-tools/onnx-def-gen/onnx.pbtxt rename to .old/contrib/codegen-tools/onnx-def-gen/onnx.pbtxt diff --git a/contrib/codegen-tools/onnx-def-gen/onnx_def_gen.py b/.old/contrib/codegen-tools/onnx-def-gen/onnx_def_gen.py similarity index 100% rename from contrib/codegen-tools/onnx-def-gen/onnx_def_gen.py rename to .old/contrib/codegen-tools/onnx-def-gen/onnx_def_gen.py diff --git a/contrib/codegen-tools/onnx-def-gen/save_test.py b/.old/contrib/codegen-tools/onnx-def-gen/save_test.py similarity index 100% rename from contrib/codegen-tools/onnx-def-gen/save_test.py rename to .old/contrib/codegen-tools/onnx-def-gen/save_test.py diff --git a/contrib/codegen-tools/onnx-def-gen/test_onnx_lenet.py b/.old/contrib/codegen-tools/onnx-def-gen/test_onnx_lenet.py similarity index 100% rename from contrib/codegen-tools/onnx-def-gen/test_onnx_lenet.py rename to .old/contrib/codegen-tools/onnx-def-gen/test_onnx_lenet.py diff --git a/contrib/codegen-tools/onnx-def-gen/test_op_def_gen.py b/.old/contrib/codegen-tools/onnx-def-gen/test_op_def_gen.py similarity index 100% rename from contrib/codegen-tools/onnx-def-gen/test_op_def_gen.py rename to .old/contrib/codegen-tools/onnx-def-gen/test_op_def_gen.py diff --git a/contrib/formatter.xml b/.old/contrib/formatter.xml similarity index 100% rename from contrib/formatter.xml rename to .old/contrib/formatter.xml diff --git a/deeplearning4j/.codeclimate.yml b/.old/deeplearning4j/.codeclimate.yml similarity index 100% rename from deeplearning4j/.codeclimate.yml rename to .old/deeplearning4j/.codeclimate.yml diff --git a/deeplearning4j/CONTRIBUTORS.md b/.old/deeplearning4j/CONTRIBUTORS.md similarity index 100% rename from deeplearning4j/CONTRIBUTORS.md rename to .old/deeplearning4j/CONTRIBUTORS.md diff --git a/deeplearning4j/GITTER_GUIDELINES.md b/.old/deeplearning4j/GITTER_GUIDELINES.md similarity index 100% rename from deeplearning4j/GITTER_GUIDELINES.md rename to .old/deeplearning4j/GITTER_GUIDELINES.md diff --git a/deeplearning4j/README.md b/.old/deeplearning4j/README.md similarity index 100% rename from deeplearning4j/README.md rename to .old/deeplearning4j/README.md diff --git a/deeplearning4j/buildmultiplescalaversions.sh b/.old/deeplearning4j/buildmultiplescalaversions.sh similarity index 100% rename from deeplearning4j/buildmultiplescalaversions.sh rename to .old/deeplearning4j/buildmultiplescalaversions.sh diff --git a/deeplearning4j/deeplearning4j-dataimport-solrj/pom.xml b/.old/deeplearning4j/deeplearning4j-dataimport-solrj/pom.xml similarity index 100% rename from deeplearning4j/deeplearning4j-dataimport-solrj/pom.xml rename to .old/deeplearning4j/deeplearning4j-dataimport-solrj/pom.xml diff --git a/deeplearning4j/deeplearning4j-dataimport-solrj/src/main/java/org/deeplearning4j/nn/dataimport/solr/client/solrj/io/stream/TupleStreamDataSetIterator.java b/.old/deeplearning4j/deeplearning4j-dataimport-solrj/src/main/java/org/deeplearning4j/nn/dataimport/solr/client/solrj/io/stream/TupleStreamDataSetIterator.java similarity index 100% rename from deeplearning4j/deeplearning4j-dataimport-solrj/src/main/java/org/deeplearning4j/nn/dataimport/solr/client/solrj/io/stream/TupleStreamDataSetIterator.java rename to .old/deeplearning4j/deeplearning4j-dataimport-solrj/src/main/java/org/deeplearning4j/nn/dataimport/solr/client/solrj/io/stream/TupleStreamDataSetIterator.java diff --git a/deeplearning4j/deeplearning4j-dataimport-solrj/src/test/java/org/deeplearning4j/nn/dataimport/solr/client/solrj/io/stream/TupleStreamDataSetIteratorTest.java b/.old/deeplearning4j/deeplearning4j-dataimport-solrj/src/test/java/org/deeplearning4j/nn/dataimport/solr/client/solrj/io/stream/TupleStreamDataSetIteratorTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-dataimport-solrj/src/test/java/org/deeplearning4j/nn/dataimport/solr/client/solrj/io/stream/TupleStreamDataSetIteratorTest.java rename to .old/deeplearning4j/deeplearning4j-dataimport-solrj/src/test/java/org/deeplearning4j/nn/dataimport/solr/client/solrj/io/stream/TupleStreamDataSetIteratorTest.java diff --git a/deeplearning4j/deeplearning4j-dataimport-solrj/src/test/resources/solr/collection1/README b/.old/deeplearning4j/deeplearning4j-dataimport-solrj/src/test/resources/solr/collection1/README similarity index 100% rename from deeplearning4j/deeplearning4j-dataimport-solrj/src/test/resources/solr/collection1/README rename to .old/deeplearning4j/deeplearning4j-dataimport-solrj/src/test/resources/solr/collection1/README diff --git a/deeplearning4j/deeplearning4j-dataimport-solrj/src/test/resources/solr/configsets/mini/conf/schema.xml b/.old/deeplearning4j/deeplearning4j-dataimport-solrj/src/test/resources/solr/configsets/mini/conf/schema.xml similarity index 100% rename from deeplearning4j/deeplearning4j-dataimport-solrj/src/test/resources/solr/configsets/mini/conf/schema.xml rename to .old/deeplearning4j/deeplearning4j-dataimport-solrj/src/test/resources/solr/configsets/mini/conf/schema.xml diff --git a/deeplearning4j/deeplearning4j-dataimport-solrj/src/test/resources/solr/configsets/mini/conf/solrconfig.xml b/.old/deeplearning4j/deeplearning4j-dataimport-solrj/src/test/resources/solr/configsets/mini/conf/solrconfig.xml similarity index 100% rename from deeplearning4j/deeplearning4j-dataimport-solrj/src/test/resources/solr/configsets/mini/conf/solrconfig.xml rename to .old/deeplearning4j/deeplearning4j-dataimport-solrj/src/test/resources/solr/configsets/mini/conf/solrconfig.xml diff --git a/deeplearning4j/deeplearning4j-graph/pom.xml b/.old/deeplearning4j/deeplearning4j-graph/pom.xml similarity index 100% rename from deeplearning4j/deeplearning4j-graph/pom.xml rename to .old/deeplearning4j/deeplearning4j-graph/pom.xml diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/BaseGraph.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/BaseGraph.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/BaseGraph.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/BaseGraph.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/Edge.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/Edge.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/Edge.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/Edge.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/IGraph.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/IGraph.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/IGraph.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/IGraph.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/IVertexSequence.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/IVertexSequence.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/IVertexSequence.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/IVertexSequence.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/NoEdgeHandling.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/NoEdgeHandling.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/NoEdgeHandling.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/NoEdgeHandling.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/Vertex.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/Vertex.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/Vertex.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/api/Vertex.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/EdgeLineProcessor.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/EdgeLineProcessor.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/EdgeLineProcessor.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/EdgeLineProcessor.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/GraphLoader.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/GraphLoader.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/GraphLoader.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/GraphLoader.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/VertexLoader.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/VertexLoader.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/VertexLoader.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/VertexLoader.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/impl/DelimitedEdgeLineProcessor.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/impl/DelimitedEdgeLineProcessor.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/impl/DelimitedEdgeLineProcessor.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/impl/DelimitedEdgeLineProcessor.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/impl/DelimitedVertexLoader.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/impl/DelimitedVertexLoader.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/impl/DelimitedVertexLoader.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/impl/DelimitedVertexLoader.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/impl/WeightedEdgeLineProcessor.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/impl/WeightedEdgeLineProcessor.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/impl/WeightedEdgeLineProcessor.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/data/impl/WeightedEdgeLineProcessor.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/exception/NoEdgesException.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/exception/NoEdgesException.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/exception/NoEdgesException.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/exception/NoEdgesException.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/exception/ParseException.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/exception/ParseException.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/exception/ParseException.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/exception/ParseException.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/graph/Graph.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/graph/Graph.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/graph/Graph.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/graph/Graph.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/graph/VertexSequence.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/graph/VertexSequence.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/graph/VertexSequence.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/graph/VertexSequence.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/GraphWalkIterator.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/GraphWalkIterator.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/GraphWalkIterator.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/GraphWalkIterator.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/RandomWalkIterator.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/RandomWalkIterator.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/RandomWalkIterator.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/RandomWalkIterator.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/WeightedRandomWalkIterator.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/WeightedRandomWalkIterator.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/WeightedRandomWalkIterator.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/WeightedRandomWalkIterator.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/parallel/GraphWalkIteratorProvider.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/parallel/GraphWalkIteratorProvider.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/parallel/GraphWalkIteratorProvider.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/parallel/GraphWalkIteratorProvider.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/parallel/RandomWalkGraphIteratorProvider.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/parallel/RandomWalkGraphIteratorProvider.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/parallel/RandomWalkGraphIteratorProvider.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/parallel/RandomWalkGraphIteratorProvider.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/parallel/WeightedRandomWalkGraphIteratorProvider.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/parallel/WeightedRandomWalkGraphIteratorProvider.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/parallel/WeightedRandomWalkGraphIteratorProvider.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/iterator/parallel/WeightedRandomWalkGraphIteratorProvider.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/BinaryTree.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/BinaryTree.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/BinaryTree.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/BinaryTree.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/GraphVectors.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/GraphVectors.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/GraphVectors.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/GraphVectors.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/deepwalk/DeepWalk.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/deepwalk/DeepWalk.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/deepwalk/DeepWalk.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/deepwalk/DeepWalk.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/deepwalk/GraphHuffman.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/deepwalk/GraphHuffman.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/deepwalk/GraphHuffman.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/deepwalk/GraphHuffman.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/embeddings/GraphVectorLookupTable.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/embeddings/GraphVectorLookupTable.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/embeddings/GraphVectorLookupTable.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/embeddings/GraphVectorLookupTable.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/embeddings/GraphVectorsImpl.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/embeddings/GraphVectorsImpl.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/embeddings/GraphVectorsImpl.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/embeddings/GraphVectorsImpl.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/embeddings/InMemoryGraphLookupTable.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/embeddings/InMemoryGraphLookupTable.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/embeddings/InMemoryGraphLookupTable.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/embeddings/InMemoryGraphLookupTable.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/loader/GraphVectorSerializer.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/loader/GraphVectorSerializer.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/loader/GraphVectorSerializer.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/models/loader/GraphVectorSerializer.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/IntegerVertexFactory.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/IntegerVertexFactory.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/IntegerVertexFactory.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/IntegerVertexFactory.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/StringVertexFactory.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/StringVertexFactory.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/StringVertexFactory.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/StringVertexFactory.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/VertexFactory.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/VertexFactory.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/VertexFactory.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/VertexFactory.java diff --git a/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/VoidVertexFactory.java b/.old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/VoidVertexFactory.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/VoidVertexFactory.java rename to .old/deeplearning4j/deeplearning4j-graph/src/main/java/org/deeplearning4j/graph/vertexfactory/VoidVertexFactory.java diff --git a/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/AssertTestsExtendedBaseClass.java b/.old/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/AssertTestsExtendedBaseClass.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/AssertTestsExtendedBaseClass.java rename to .old/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/AssertTestsExtendedBaseClass.java diff --git a/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/data/TestGraphLoading.java b/.old/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/data/TestGraphLoading.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/data/TestGraphLoading.java rename to .old/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/data/TestGraphLoading.java diff --git a/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/data/TestGraphLoadingWeighted.java b/.old/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/data/TestGraphLoadingWeighted.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/data/TestGraphLoadingWeighted.java rename to .old/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/data/TestGraphLoadingWeighted.java diff --git a/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/graph/TestGraph.java b/.old/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/graph/TestGraph.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/graph/TestGraph.java rename to .old/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/graph/TestGraph.java diff --git a/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/models/deepwalk/DeepWalkGradientCheck.java b/.old/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/models/deepwalk/DeepWalkGradientCheck.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/models/deepwalk/DeepWalkGradientCheck.java rename to .old/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/models/deepwalk/DeepWalkGradientCheck.java diff --git a/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/models/deepwalk/TestDeepWalk.java b/.old/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/models/deepwalk/TestDeepWalk.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/models/deepwalk/TestDeepWalk.java rename to .old/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/models/deepwalk/TestDeepWalk.java diff --git a/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/models/deepwalk/TestGraphHuffman.java b/.old/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/models/deepwalk/TestGraphHuffman.java similarity index 100% rename from deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/models/deepwalk/TestGraphHuffman.java rename to .old/deeplearning4j/deeplearning4j-graph/src/test/java/org/deeplearning4j/graph/models/deepwalk/TestGraphHuffman.java diff --git a/deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/pom.xml b/.old/deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/pom.xml similarity index 100% rename from deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/pom.xml rename to .old/deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/pom.xml diff --git a/deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/src/main/java/org/deeplearning4j/plot/BarnesHutTsne.java b/.old/deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/src/main/java/org/deeplearning4j/plot/BarnesHutTsne.java similarity index 100% rename from deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/src/main/java/org/deeplearning4j/plot/BarnesHutTsne.java rename to .old/deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/src/main/java/org/deeplearning4j/plot/BarnesHutTsne.java diff --git a/deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/src/main/java/org/deeplearning4j/plot/Tsne.java b/.old/deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/src/main/java/org/deeplearning4j/plot/Tsne.java similarity index 100% rename from deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/src/main/java/org/deeplearning4j/plot/Tsne.java rename to .old/deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/src/main/java/org/deeplearning4j/plot/Tsne.java diff --git a/deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/src/test/java/org/deeplearning4j/plot/Test6058.java b/.old/deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/src/test/java/org/deeplearning4j/plot/Test6058.java similarity index 100% rename from deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/src/test/java/org/deeplearning4j/plot/Test6058.java rename to .old/deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/src/test/java/org/deeplearning4j/plot/Test6058.java diff --git a/deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/src/test/java/org/deeplearning4j/plot/TsneTest.java b/.old/deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/src/test/java/org/deeplearning4j/plot/TsneTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/src/test/java/org/deeplearning4j/plot/TsneTest.java rename to .old/deeplearning4j/deeplearning4j-manifold/deeplearning4j-tsne/src/test/java/org/deeplearning4j/plot/TsneTest.java diff --git a/deeplearning4j/deeplearning4j-manifold/pom.xml b/.old/deeplearning4j/deeplearning4j-manifold/pom.xml similarity index 100% rename from deeplearning4j/deeplearning4j-manifold/pom.xml rename to .old/deeplearning4j/deeplearning4j-manifold/pom.xml diff --git a/deeplearning4j/deeplearning4j-modelexport-solr/pom.xml b/.old/deeplearning4j/deeplearning4j-modelexport-solr/pom.xml similarity index 100% rename from deeplearning4j/deeplearning4j-modelexport-solr/pom.xml rename to .old/deeplearning4j/deeplearning4j-modelexport-solr/pom.xml diff --git a/deeplearning4j/deeplearning4j-modelexport-solr/src/main/java/org/deeplearning4j/nn/modelexport/solr/handler/ModelTupleStream.java b/.old/deeplearning4j/deeplearning4j-modelexport-solr/src/main/java/org/deeplearning4j/nn/modelexport/solr/handler/ModelTupleStream.java similarity index 100% rename from deeplearning4j/deeplearning4j-modelexport-solr/src/main/java/org/deeplearning4j/nn/modelexport/solr/handler/ModelTupleStream.java rename to .old/deeplearning4j/deeplearning4j-modelexport-solr/src/main/java/org/deeplearning4j/nn/modelexport/solr/handler/ModelTupleStream.java diff --git a/deeplearning4j/deeplearning4j-modelexport-solr/src/main/java/org/deeplearning4j/nn/modelexport/solr/ltr/model/ScoringModel.java b/.old/deeplearning4j/deeplearning4j-modelexport-solr/src/main/java/org/deeplearning4j/nn/modelexport/solr/ltr/model/ScoringModel.java similarity index 100% rename from deeplearning4j/deeplearning4j-modelexport-solr/src/main/java/org/deeplearning4j/nn/modelexport/solr/ltr/model/ScoringModel.java rename to .old/deeplearning4j/deeplearning4j-modelexport-solr/src/main/java/org/deeplearning4j/nn/modelexport/solr/ltr/model/ScoringModel.java diff --git a/deeplearning4j/deeplearning4j-modelexport-solr/src/test/java/org/deeplearning4j/nn/modelexport/solr/handler/ModelTupleStreamIntegrationTest.java b/.old/deeplearning4j/deeplearning4j-modelexport-solr/src/test/java/org/deeplearning4j/nn/modelexport/solr/handler/ModelTupleStreamIntegrationTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-modelexport-solr/src/test/java/org/deeplearning4j/nn/modelexport/solr/handler/ModelTupleStreamIntegrationTest.java rename to .old/deeplearning4j/deeplearning4j-modelexport-solr/src/test/java/org/deeplearning4j/nn/modelexport/solr/handler/ModelTupleStreamIntegrationTest.java diff --git a/deeplearning4j/deeplearning4j-modelexport-solr/src/test/java/org/deeplearning4j/nn/modelexport/solr/handler/ModelTupleStreamTest.java b/.old/deeplearning4j/deeplearning4j-modelexport-solr/src/test/java/org/deeplearning4j/nn/modelexport/solr/handler/ModelTupleStreamTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-modelexport-solr/src/test/java/org/deeplearning4j/nn/modelexport/solr/handler/ModelTupleStreamTest.java rename to .old/deeplearning4j/deeplearning4j-modelexport-solr/src/test/java/org/deeplearning4j/nn/modelexport/solr/handler/ModelTupleStreamTest.java diff --git a/deeplearning4j/deeplearning4j-modelexport-solr/src/test/java/org/deeplearning4j/nn/modelexport/solr/ltr/model/ScoringModelTest.java b/.old/deeplearning4j/deeplearning4j-modelexport-solr/src/test/java/org/deeplearning4j/nn/modelexport/solr/ltr/model/ScoringModelTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-modelexport-solr/src/test/java/org/deeplearning4j/nn/modelexport/solr/ltr/model/ScoringModelTest.java rename to .old/deeplearning4j/deeplearning4j-modelexport-solr/src/test/java/org/deeplearning4j/nn/modelexport/solr/ltr/model/ScoringModelTest.java diff --git a/deeplearning4j/deeplearning4j-modelexport-solr/src/test/resources/solr/collection1/README b/.old/deeplearning4j/deeplearning4j-modelexport-solr/src/test/resources/solr/collection1/README similarity index 100% rename from deeplearning4j/deeplearning4j-modelexport-solr/src/test/resources/solr/collection1/README rename to .old/deeplearning4j/deeplearning4j-modelexport-solr/src/test/resources/solr/collection1/README diff --git a/deeplearning4j/deeplearning4j-modelexport-solr/src/test/resources/solr/configsets/mini-expressible/conf/schema.xml b/.old/deeplearning4j/deeplearning4j-modelexport-solr/src/test/resources/solr/configsets/mini-expressible/conf/schema.xml similarity index 100% rename from deeplearning4j/deeplearning4j-modelexport-solr/src/test/resources/solr/configsets/mini-expressible/conf/schema.xml rename to .old/deeplearning4j/deeplearning4j-modelexport-solr/src/test/resources/solr/configsets/mini-expressible/conf/schema.xml diff --git a/deeplearning4j/deeplearning4j-modelexport-solr/src/test/resources/solr/configsets/mini-expressible/conf/solrconfig.xml b/.old/deeplearning4j/deeplearning4j-modelexport-solr/src/test/resources/solr/configsets/mini-expressible/conf/solrconfig.xml similarity index 100% rename from deeplearning4j/deeplearning4j-modelexport-solr/src/test/resources/solr/configsets/mini-expressible/conf/solrconfig.xml rename to .old/deeplearning4j/deeplearning4j-modelexport-solr/src/test/resources/solr/configsets/mini-expressible/conf/solrconfig.xml diff --git a/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/pom.xml b/.old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/pom.xml similarity index 100% rename from deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/pom.xml rename to .old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/pom.xml diff --git a/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/main/java/org/deeplearning4j/remote/DL4jServlet.java b/.old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/main/java/org/deeplearning4j/remote/DL4jServlet.java similarity index 100% rename from deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/main/java/org/deeplearning4j/remote/DL4jServlet.java rename to .old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/main/java/org/deeplearning4j/remote/DL4jServlet.java diff --git a/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/main/java/org/deeplearning4j/remote/JsonModelServer.java b/.old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/main/java/org/deeplearning4j/remote/JsonModelServer.java similarity index 100% rename from deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/main/java/org/deeplearning4j/remote/JsonModelServer.java rename to .old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/main/java/org/deeplearning4j/remote/JsonModelServer.java diff --git a/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/AssertTestsExtendBaseClass.java b/.old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/AssertTestsExtendBaseClass.java similarity index 100% rename from deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/AssertTestsExtendBaseClass.java rename to .old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/AssertTestsExtendBaseClass.java diff --git a/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/BinaryModelServerTest.java b/.old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/BinaryModelServerTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/BinaryModelServerTest.java rename to .old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/BinaryModelServerTest.java diff --git a/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/JsonModelServerTest.java b/.old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/JsonModelServerTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/JsonModelServerTest.java rename to .old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/JsonModelServerTest.java diff --git a/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/ServletTest.java b/.old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/ServletTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/ServletTest.java rename to .old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/ServletTest.java diff --git a/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/House.java b/.old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/House.java similarity index 100% rename from deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/House.java rename to .old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/House.java diff --git a/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/HouseToPredictedPriceAdapter.java b/.old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/HouseToPredictedPriceAdapter.java similarity index 100% rename from deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/HouseToPredictedPriceAdapter.java rename to .old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/HouseToPredictedPriceAdapter.java diff --git a/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/ImageConversionUtils.java b/.old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/ImageConversionUtils.java similarity index 100% rename from deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/ImageConversionUtils.java rename to .old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/ImageConversionUtils.java diff --git a/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/PredictedPrice.java b/.old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/PredictedPrice.java similarity index 100% rename from deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/PredictedPrice.java rename to .old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/java/org/deeplearning4j/remote/helpers/PredictedPrice.java diff --git a/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/resources/logback.xml b/.old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/resources/logback.xml similarity index 100% rename from deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/resources/logback.xml rename to .old/deeplearning4j/deeplearning4j-remote/deeplearning4j-json-server/src/test/resources/logback.xml diff --git a/deeplearning4j/deeplearning4j-remote/pom.xml b/.old/deeplearning4j/deeplearning4j-remote/pom.xml similarity index 100% rename from deeplearning4j/deeplearning4j-remote/pom.xml rename to .old/deeplearning4j/deeplearning4j-remote/pom.xml diff --git a/deeplearning4j/deeplearning4j-scaleout/pom.xml b/.old/deeplearning4j/deeplearning4j-scaleout/pom.xml similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/pom.xml rename to .old/deeplearning4j/deeplearning4j-scaleout/pom.xml diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/pom.xml b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/pom.xml similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/pom.xml rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/pom.xml diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/paragraphvectors/SparkParagraphVectors.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/paragraphvectors/SparkParagraphVectors.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/paragraphvectors/SparkParagraphVectors.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/paragraphvectors/SparkParagraphVectors.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/paragraphvectors/functions/DocumentSequenceConvertFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/paragraphvectors/functions/DocumentSequenceConvertFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/paragraphvectors/functions/DocumentSequenceConvertFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/paragraphvectors/functions/DocumentSequenceConvertFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/paragraphvectors/functions/KeySequenceConvertFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/paragraphvectors/functions/KeySequenceConvertFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/paragraphvectors/functions/KeySequenceConvertFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/paragraphvectors/functions/KeySequenceConvertFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/SparkSequenceVectors.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/SparkSequenceVectors.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/SparkSequenceVectors.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/SparkSequenceVectors.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/ExportContainer.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/ExportContainer.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/ExportContainer.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/ExportContainer.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/SparkModelExporter.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/SparkModelExporter.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/SparkModelExporter.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/SparkModelExporter.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/impl/HdfsModelExporter.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/impl/HdfsModelExporter.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/impl/HdfsModelExporter.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/impl/HdfsModelExporter.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/impl/VocabCacheExporter.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/impl/VocabCacheExporter.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/impl/VocabCacheExporter.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/export/impl/VocabCacheExporter.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/BaseTokenizerFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/BaseTokenizerFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/BaseTokenizerFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/BaseTokenizerFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/CountFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/CountFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/CountFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/CountFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/DistributedFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/DistributedFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/DistributedFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/DistributedFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ElementsFrequenciesAccumulator.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ElementsFrequenciesAccumulator.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ElementsFrequenciesAccumulator.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ElementsFrequenciesAccumulator.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ExportFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ExportFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ExportFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ExportFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ExtraCountFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ExtraCountFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ExtraCountFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ExtraCountFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ExtraElementsFrequenciesAccumulator.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ExtraElementsFrequenciesAccumulator.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ExtraElementsFrequenciesAccumulator.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ExtraElementsFrequenciesAccumulator.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ListSequenceConvertFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ListSequenceConvertFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ListSequenceConvertFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/ListSequenceConvertFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/PartitionTrainingFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/PartitionTrainingFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/PartitionTrainingFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/PartitionTrainingFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/TokenizerFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/TokenizerFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/TokenizerFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/TokenizerFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/TrainingFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/TrainingFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/TrainingFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/TrainingFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/VocabRddFunctionFlat.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/VocabRddFunctionFlat.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/VocabRddFunctionFlat.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/functions/VocabRddFunctionFlat.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/SparkElementsLearningAlgorithm.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/SparkElementsLearningAlgorithm.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/SparkElementsLearningAlgorithm.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/SparkElementsLearningAlgorithm.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/SparkSequenceLearningAlgorithm.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/SparkSequenceLearningAlgorithm.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/SparkSequenceLearningAlgorithm.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/SparkSequenceLearningAlgorithm.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/elements/BaseSparkLearningAlgorithm.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/elements/BaseSparkLearningAlgorithm.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/elements/BaseSparkLearningAlgorithm.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/elements/BaseSparkLearningAlgorithm.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/elements/SparkCBOW.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/elements/SparkCBOW.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/elements/SparkCBOW.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/elements/SparkCBOW.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/elements/SparkSkipGram.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/elements/SparkSkipGram.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/elements/SparkSkipGram.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/elements/SparkSkipGram.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/sequence/BaseSparkSequenceLearningAlgorithm.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/sequence/BaseSparkSequenceLearningAlgorithm.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/sequence/BaseSparkSequenceLearningAlgorithm.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/sequence/BaseSparkSequenceLearningAlgorithm.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/sequence/SparkDBOW.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/sequence/SparkDBOW.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/sequence/SparkDBOW.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/sequence/SparkDBOW.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/sequence/SparkDM.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/sequence/SparkDM.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/sequence/SparkDM.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/learning/sequence/SparkDM.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/primitives/ExtraCounter.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/primitives/ExtraCounter.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/primitives/ExtraCounter.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/sequencevectors/primitives/ExtraCounter.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/word2vec/SparkWord2Vec.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/word2vec/SparkWord2Vec.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/word2vec/SparkWord2Vec.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/main/java/org/deeplearning4j/spark/models/word2vec/SparkWord2Vec.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/sequencevectors/SparkSequenceVectorsTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/sequencevectors/SparkSequenceVectorsTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/sequencevectors/SparkSequenceVectorsTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/sequencevectors/SparkSequenceVectorsTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/sequencevectors/export/ExportContainerTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/sequencevectors/export/ExportContainerTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/sequencevectors/export/ExportContainerTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/sequencevectors/export/ExportContainerTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/word2vec/SparkWord2VecTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/word2vec/SparkWord2VecTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/word2vec/SparkWord2VecTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/word2vec/SparkWord2VecTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/resources/log4j.properties b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/resources/log4j.properties similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/resources/log4j.properties rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/resources/log4j.properties diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/resources/logback.xml b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/resources/logback.xml similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/resources/logback.xml rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/resources/logback.xml diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/.gitignore b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/.gitignore similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/.gitignore rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/.gitignore diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/pom.xml b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/pom.xml similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/pom.xml rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/pom.xml diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/FirstIterationFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/FirstIterationFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/FirstIterationFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/FirstIterationFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/MapToPairFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/MapToPairFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/MapToPairFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/MapToPairFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/NegativeHolder.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/NegativeHolder.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/NegativeHolder.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/NegativeHolder.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/SecondIterationFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/SecondIterationFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/SecondIterationFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/SecondIterationFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/SentenceBatch.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/SentenceBatch.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/SentenceBatch.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/SentenceBatch.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/VocabHolder.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/VocabHolder.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/VocabHolder.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/VocabHolder.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2Vec.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2Vec.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2Vec.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2Vec.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecChange.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecChange.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecChange.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecChange.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecFuncCall.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecFuncCall.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecFuncCall.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecFuncCall.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecParam.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecParam.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecParam.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecParam.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecPerformer.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecPerformer.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecPerformer.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecPerformer.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecPerformerVoid.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecPerformerVoid.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecPerformerVoid.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecPerformerVoid.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecSetup.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecSetup.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecSetup.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecSetup.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecVariables.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecVariables.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecVariables.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecVariables.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/accumulators/MaxPerPartitionAccumulator.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/accumulators/MaxPerPartitionAccumulator.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/accumulators/MaxPerPartitionAccumulator.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/accumulators/MaxPerPartitionAccumulator.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/accumulators/WordFreqAccumulator.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/accumulators/WordFreqAccumulator.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/accumulators/WordFreqAccumulator.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/accumulators/WordFreqAccumulator.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/CountCumSum.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/CountCumSum.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/CountCumSum.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/CountCumSum.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/FoldBetweenPartitionFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/FoldBetweenPartitionFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/FoldBetweenPartitionFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/FoldBetweenPartitionFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/FoldWithinPartitionFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/FoldWithinPartitionFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/FoldWithinPartitionFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/FoldWithinPartitionFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/GetSentenceCountFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/GetSentenceCountFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/GetSentenceCountFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/GetSentenceCountFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/MapPerPartitionVoidFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/MapPerPartitionVoidFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/MapPerPartitionVoidFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/MapPerPartitionVoidFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/ReduceSentenceCount.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/ReduceSentenceCount.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/ReduceSentenceCount.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/ReduceSentenceCount.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/TextPipeline.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/TextPipeline.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/TextPipeline.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/TextPipeline.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/TokenizerFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/TokenizerFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/TokenizerFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/TokenizerFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/UpdateWordFreqAccumulatorFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/UpdateWordFreqAccumulatorFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/UpdateWordFreqAccumulatorFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/UpdateWordFreqAccumulatorFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/WordsListToVocabWordsFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/WordsListToVocabWordsFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/WordsListToVocabWordsFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/main/java/org/deeplearning4j/spark/text/functions/WordsListToVocabWordsFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/BaseSparkTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/BaseSparkTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/BaseSparkTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/BaseSparkTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/TestFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/TestFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/TestFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/TestFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/TextPipelineTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/TextPipelineTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/TextPipelineTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/TextPipelineTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/resources/log4j.properties b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/resources/log4j.properties similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/resources/log4j.properties rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/resources/log4j.properties diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/resources/logback.xml b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/resources/logback.xml similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/resources/logback.xml rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/resources/logback.xml diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/pom.xml b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/pom.xml similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/pom.xml rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/pom.xml diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/ParameterServerSubscriber.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/ParameterServerSubscriber.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/ParameterServerSubscriber.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/ParameterServerSubscriber.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/ParameterServerTrainingHook.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/ParameterServerTrainingHook.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/ParameterServerTrainingHook.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/ParameterServerTrainingHook.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationTuple.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationTuple.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationTuple.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationTuple.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAggregateFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAggregateFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAggregateFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAggregateFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/DataSetDeserializationCallback.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/DataSetDeserializationCallback.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/DataSetDeserializationCallback.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/DataSetDeserializationCallback.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/MultiDataSetDeserializationCallback.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/MultiDataSetDeserializationCallback.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/MultiDataSetDeserializationCallback.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/MultiDataSetDeserializationCallback.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/PortableDataStreamCallback.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/PortableDataStreamCallback.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/PortableDataStreamCallback.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/PortableDataStreamCallback.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/PortableDataStreamMDSCallback.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/PortableDataStreamMDSCallback.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/PortableDataStreamMDSCallback.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/callbacks/PortableDataStreamMDSCallback.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/conf/SharedTrainingConfiguration.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/conf/SharedTrainingConfiguration.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/conf/SharedTrainingConfiguration.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/conf/SharedTrainingConfiguration.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapDataSet.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapDataSet.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapDataSet.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapDataSet.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapMultiDataSet.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapMultiDataSet.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapMultiDataSet.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapMultiDataSet.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapPaths.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapPaths.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapPaths.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapPaths.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapPathsMDS.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapPathsMDS.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapPathsMDS.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/functions/SharedFlatMapPathsMDS.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/MultiPdsIterator.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/MultiPdsIterator.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/MultiPdsIterator.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/MultiPdsIterator.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/PdsIterator.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/PdsIterator.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/PdsIterator.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/PdsIterator.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualDataSetIterator.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualDataSetIterator.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualDataSetIterator.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualDataSetIterator.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualIterator.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualIterator.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualIterator.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualIterator.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualMultiDataSetIterator.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualMultiDataSetIterator.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualMultiDataSetIterator.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualMultiDataSetIterator.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/modelimport/elephas/ElephasModelImport.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/modelimport/elephas/ElephasModelImport.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/modelimport/elephas/ElephasModelImport.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/modelimport/elephas/ElephasModelImport.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/SilentTrainingDriver.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/SilentTrainingDriver.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/SilentTrainingDriver.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/SilentTrainingDriver.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/WiredEncodingHandler.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/WiredEncodingHandler.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/WiredEncodingHandler.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/WiredEncodingHandler.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/messages/SilentIntroductoryConfirmation.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/messages/SilentIntroductoryConfirmation.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/messages/SilentIntroductoryConfirmation.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/messages/SilentIntroductoryConfirmation.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/messages/SilentIntroductoryMessage.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/messages/SilentIntroductoryMessage.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/messages/SilentIntroductoryMessage.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/messages/SilentIntroductoryMessage.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/messages/SilentUpdatesMessage.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/messages/SilentUpdatesMessage.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/messages/SilentUpdatesMessage.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v1/messages/SilentUpdatesMessage.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/ModelParamsConsumer.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/ModelParamsConsumer.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/ModelParamsConsumer.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/ModelParamsConsumer.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/UpdaterParamsConsumer.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/UpdaterParamsConsumer.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/UpdaterParamsConsumer.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/UpdaterParamsConsumer.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/UpdatesConsumer.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/UpdatesConsumer.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/UpdatesConsumer.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/UpdatesConsumer.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/WiredEncodingHandler.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/WiredEncodingHandler.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/WiredEncodingHandler.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/networking/v2/WiredEncodingHandler.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/pw/SharedTrainingWrapper.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/pw/SharedTrainingWrapper.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/pw/SharedTrainingWrapper.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/pw/SharedTrainingWrapper.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/python/ArrayDescriptor.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/python/ArrayDescriptor.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/python/ArrayDescriptor.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/python/ArrayDescriptor.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/python/DataSetDescriptor.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/python/DataSetDescriptor.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/python/DataSetDescriptor.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/python/DataSetDescriptor.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/python/Utils.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/python/Utils.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/python/Utils.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/python/Utils.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/training/SharedTrainingMaster.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/training/SharedTrainingMaster.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/training/SharedTrainingMaster.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/training/SharedTrainingMaster.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/training/SharedTrainingResult.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/training/SharedTrainingResult.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/training/SharedTrainingResult.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/training/SharedTrainingResult.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/training/SharedTrainingWorker.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/training/SharedTrainingWorker.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/training/SharedTrainingWorker.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/training/SharedTrainingWorker.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/util/BlockingObserver.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/util/BlockingObserver.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/util/BlockingObserver.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/util/BlockingObserver.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/util/CountingIterator.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/util/CountingIterator.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/util/CountingIterator.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/main/java/org/deeplearning4j/spark/parameterserver/util/CountingIterator.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/BaseSparkTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/BaseSparkTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/BaseSparkTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/BaseSparkTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationFunctionTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationFunctionTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationFunctionTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationFunctionTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAggregateFunctionTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAggregateFunctionTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAggregateFunctionTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAggregateFunctionTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualDataSetIteratorTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualDataSetIteratorTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualDataSetIteratorTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualDataSetIteratorTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualIteratorTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualIteratorTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualIteratorTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualIteratorTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/modelimport/elephas/TestElephasImport.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/modelimport/elephas/TestElephasImport.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/modelimport/elephas/TestElephasImport.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/modelimport/elephas/TestElephasImport.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/train/GradientSharingTrainingTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/train/GradientSharingTrainingTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/train/GradientSharingTrainingTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/train/GradientSharingTrainingTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/resources/log4j.properties b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/resources/log4j.properties similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/resources/log4j.properties rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/resources/log4j.properties diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/resources/logback.xml b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/resources/logback.xml similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/resources/logback.xml rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/resources/logback.xml diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/nd4j-native.properties b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/nd4j-native.properties similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/nd4j-native.properties rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/nd4j-native.properties diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/pom.xml b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/pom.xml similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/pom.xml rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/pom.xml diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/RDDTrainingApproach.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/RDDTrainingApproach.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/RDDTrainingApproach.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/RDDTrainingApproach.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/Repartition.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/Repartition.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/Repartition.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/Repartition.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/RepartitionStrategy.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/RepartitionStrategy.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/RepartitionStrategy.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/RepartitionStrategy.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/Repartitioner.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/Repartitioner.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/Repartitioner.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/Repartitioner.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingHook.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingHook.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingHook.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingHook.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingMaster.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingMaster.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingMaster.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingMaster.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingResult.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingResult.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingResult.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingResult.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingWorker.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingWorker.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingWorker.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/TrainingWorker.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/WorkerConfiguration.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/WorkerConfiguration.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/WorkerConfiguration.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/WorkerConfiguration.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/stats/CommonSparkTrainingStats.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/stats/CommonSparkTrainingStats.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/stats/CommonSparkTrainingStats.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/stats/CommonSparkTrainingStats.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/stats/SparkTrainingStats.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/stats/SparkTrainingStats.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/stats/SparkTrainingStats.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/stats/SparkTrainingStats.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/stats/StatsCalculationHelper.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/stats/StatsCalculationHelper.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/stats/StatsCalculationHelper.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/stats/StatsCalculationHelper.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerFlatMap.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerFlatMap.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerFlatMap.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerFlatMap.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerMultiDataSetFlatMap.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerMultiDataSetFlatMap.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerMultiDataSetFlatMap.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerMultiDataSetFlatMap.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPDSFlatMap.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPDSFlatMap.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPDSFlatMap.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPDSFlatMap.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPDSMDSFlatMap.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPDSMDSFlatMap.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPDSMDSFlatMap.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPDSMDSFlatMap.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPathFlatMap.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPathFlatMap.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPathFlatMap.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPathFlatMap.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPathMDSFlatMap.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPathMDSFlatMap.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPathMDSFlatMap.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/ExecuteWorkerPathMDSFlatMap.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/NetBroadcastTuple.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/NetBroadcastTuple.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/NetBroadcastTuple.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/api/worker/NetBroadcastTuple.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/BatchAndExportDataSetsFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/BatchAndExportDataSetsFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/BatchAndExportDataSetsFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/BatchAndExportDataSetsFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/BatchAndExportMultiDataSetsFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/BatchAndExportMultiDataSetsFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/BatchAndExportMultiDataSetsFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/BatchAndExportMultiDataSetsFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/BatchDataSetsFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/BatchDataSetsFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/BatchDataSetsFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/BatchDataSetsFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/DataSetExportFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/DataSetExportFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/DataSetExportFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/DataSetExportFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/DataSetProvider.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/DataSetProvider.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/DataSetProvider.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/DataSetProvider.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/MultiDataSetExportFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/MultiDataSetExportFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/MultiDataSetExportFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/MultiDataSetExportFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/MultiDataSetProvider.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/MultiDataSetProvider.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/MultiDataSetProvider.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/MultiDataSetProvider.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/PathToDataSetFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/PathToDataSetFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/PathToDataSetFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/PathToDataSetFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/PathToMultiDataSetFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/PathToMultiDataSetFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/PathToMultiDataSetFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/PathToMultiDataSetFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/SplitDataSetsFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/SplitDataSetsFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/SplitDataSetsFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/SplitDataSetsFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/loader/RemoteFileSource.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/loader/RemoteFileSource.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/loader/RemoteFileSource.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/loader/RemoteFileSource.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/loader/RemoteFileSourceFactory.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/loader/RemoteFileSourceFactory.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/loader/RemoteFileSourceFactory.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/loader/RemoteFileSourceFactory.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/shuffle/SplitDataSetExamplesPairFlatMapFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/shuffle/SplitDataSetExamplesPairFlatMapFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/shuffle/SplitDataSetExamplesPairFlatMapFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/data/shuffle/SplitDataSetExamplesPairFlatMapFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecByteDataSetFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecByteDataSetFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecByteDataSetFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecByteDataSetFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecDataSetFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecDataSetFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecDataSetFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecDataSetFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecSequenceDataSetFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecSequenceDataSetFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecSequenceDataSetFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecSequenceDataSetFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecSequencePairDataSetFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecSequencePairDataSetFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecSequencePairDataSetFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/DataVecSequencePairDataSetFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/RDDMiniBatches.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/RDDMiniBatches.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/RDDMiniBatches.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/RDDMiniBatches.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/RecordReaderFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/RecordReaderFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/RecordReaderFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/RecordReaderFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/export/StringToDataSetExportFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/export/StringToDataSetExportFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/export/StringToDataSetExportFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/export/StringToDataSetExportFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/DataVecRecord.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/DataVecRecord.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/DataVecRecord.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/DataVecRecord.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/DataVecRecords.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/DataVecRecords.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/DataVecRecords.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/DataVecRecords.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/IteratorUtils.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/IteratorUtils.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/IteratorUtils.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/IteratorUtils.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/RRMDSIFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/RRMDSIFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/RRMDSIFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/RRMDSIFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/SparkSourceDummyReader.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/SparkSourceDummyReader.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/SparkSourceDummyReader.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/SparkSourceDummyReader.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/SparkSourceDummySeqReader.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/SparkSourceDummySeqReader.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/SparkSourceDummySeqReader.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/datavec/iterator/SparkSourceDummySeqReader.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/BaseSparkEarlyStoppingTrainer.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/BaseSparkEarlyStoppingTrainer.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/BaseSparkEarlyStoppingTrainer.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/BaseSparkEarlyStoppingTrainer.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkDataSetLossCalculator.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkDataSetLossCalculator.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkDataSetLossCalculator.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkDataSetLossCalculator.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkEarlyStoppingGraphTrainer.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkEarlyStoppingGraphTrainer.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkEarlyStoppingGraphTrainer.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkEarlyStoppingGraphTrainer.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkEarlyStoppingTrainer.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkEarlyStoppingTrainer.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkEarlyStoppingTrainer.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkEarlyStoppingTrainer.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkLossCalculatorComputationGraph.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkLossCalculatorComputationGraph.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkLossCalculatorComputationGraph.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/earlystopping/SparkLossCalculatorComputationGraph.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/SparkListenable.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/SparkListenable.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/SparkListenable.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/SparkListenable.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/Add.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/Add.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/Add.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/Add.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/CountPartitionsFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/CountPartitionsFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/CountPartitionsFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/CountPartitionsFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/LoadDataSetFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/LoadDataSetFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/LoadDataSetFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/LoadDataSetFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/SplitPartitionsFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/SplitPartitionsFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/SplitPartitionsFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/SplitPartitionsFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/SplitPartitionsFunction2.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/SplitPartitionsFunction2.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/SplitPartitionsFunction2.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/SplitPartitionsFunction2.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/reduce/IntDoubleReduceFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/reduce/IntDoubleReduceFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/reduce/IntDoubleReduceFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/reduce/IntDoubleReduceFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/reduce/LongDoubleReduceFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/reduce/LongDoubleReduceFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/reduce/LongDoubleReduceFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/reduce/LongDoubleReduceFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/BalancedPartitioner.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/BalancedPartitioner.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/BalancedPartitioner.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/BalancedPartitioner.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/EqualPartitioner.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/EqualPartitioner.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/EqualPartitioner.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/EqualPartitioner.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/HashingBalancedPartitioner.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/HashingBalancedPartitioner.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/HashingBalancedPartitioner.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/HashingBalancedPartitioner.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/MapTupleToPairFlatMap.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/MapTupleToPairFlatMap.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/MapTupleToPairFlatMap.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/repartition/MapTupleToPairFlatMap.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/score/BaseVaeReconstructionProbWithKeyFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/score/BaseVaeReconstructionProbWithKeyFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/score/BaseVaeReconstructionProbWithKeyFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/score/BaseVaeReconstructionProbWithKeyFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/score/BaseVaeScoreWithKeyFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/score/BaseVaeScoreWithKeyFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/score/BaseVaeScoreWithKeyFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/common/score/BaseVaeScoreWithKeyFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/evaluation/EvaluationRunner.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/evaluation/EvaluationRunner.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/evaluation/EvaluationRunner.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/evaluation/EvaluationRunner.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/SparkComputationGraph.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/SparkComputationGraph.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/SparkComputationGraph.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/SparkComputationGraph.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/dataset/DataSetToMultiDataSetFn.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/dataset/DataSetToMultiDataSetFn.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/dataset/DataSetToMultiDataSetFn.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/dataset/DataSetToMultiDataSetFn.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/dataset/PairDataSetToMultiDataSetFn.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/dataset/PairDataSetToMultiDataSetFn.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/dataset/PairDataSetToMultiDataSetFn.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/dataset/PairDataSetToMultiDataSetFn.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/evaluation/IEvaluateMDSFlatMapFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/evaluation/IEvaluateMDSFlatMapFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/evaluation/IEvaluateMDSFlatMapFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/evaluation/IEvaluateMDSFlatMapFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/evaluation/IEvaluateMDSPathsFlatMapFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/evaluation/IEvaluateMDSPathsFlatMapFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/evaluation/IEvaluateMDSPathsFlatMapFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/evaluation/IEvaluateMDSPathsFlatMapFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ArrayPairToPair.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ArrayPairToPair.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ArrayPairToPair.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ArrayPairToPair.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/CGVaeReconstructionErrorWithKeyFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/CGVaeReconstructionErrorWithKeyFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/CGVaeReconstructionErrorWithKeyFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/CGVaeReconstructionErrorWithKeyFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/CGVaeReconstructionProbWithKeyFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/CGVaeReconstructionProbWithKeyFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/CGVaeReconstructionProbWithKeyFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/CGVaeReconstructionProbWithKeyFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/GraphFeedForwardWithKeyFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/GraphFeedForwardWithKeyFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/GraphFeedForwardWithKeyFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/GraphFeedForwardWithKeyFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/PairToArrayPair.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/PairToArrayPair.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/PairToArrayPair.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/PairToArrayPair.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreExamplesFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreExamplesFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreExamplesFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreExamplesFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreExamplesWithKeyFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreExamplesWithKeyFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreExamplesWithKeyFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreExamplesWithKeyFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreFlatMapFunctionCGDataSet.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreFlatMapFunctionCGDataSet.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreFlatMapFunctionCGDataSet.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreFlatMapFunctionCGDataSet.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreFlatMapFunctionCGMultiDataSet.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreFlatMapFunctionCGMultiDataSet.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreFlatMapFunctionCGMultiDataSet.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/graph/scoring/ScoreFlatMapFunctionCGMultiDataSet.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/listeners/VanillaStatsStorageRouter.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/listeners/VanillaStatsStorageRouter.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/listeners/VanillaStatsStorageRouter.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/listeners/VanillaStatsStorageRouter.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/listeners/VanillaStatsStorageRouterProvider.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/listeners/VanillaStatsStorageRouterProvider.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/listeners/VanillaStatsStorageRouterProvider.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/listeners/VanillaStatsStorageRouterProvider.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/SparkDl4jMultiLayer.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/SparkDl4jMultiLayer.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/SparkDl4jMultiLayer.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/SparkDl4jMultiLayer.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/evaluation/IEvaluateAggregateFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/evaluation/IEvaluateAggregateFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/evaluation/IEvaluateAggregateFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/evaluation/IEvaluateAggregateFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/evaluation/IEvaluateFlatMapFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/evaluation/IEvaluateFlatMapFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/evaluation/IEvaluateFlatMapFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/evaluation/IEvaluateFlatMapFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/evaluation/IEvaluationReduceFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/evaluation/IEvaluationReduceFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/evaluation/IEvaluationReduceFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/evaluation/IEvaluationReduceFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/FeedForwardWithKeyFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/FeedForwardWithKeyFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/FeedForwardWithKeyFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/FeedForwardWithKeyFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/ScoreExamplesFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/ScoreExamplesFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/ScoreExamplesFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/ScoreExamplesFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/ScoreExamplesWithKeyFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/ScoreExamplesWithKeyFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/ScoreExamplesWithKeyFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/ScoreExamplesWithKeyFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/ScoreFlatMapFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/ScoreFlatMapFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/ScoreFlatMapFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/ScoreFlatMapFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/SingleToPairFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/SingleToPairFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/SingleToPairFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/SingleToPairFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/VaeReconstructionErrorWithKeyFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/VaeReconstructionErrorWithKeyFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/VaeReconstructionErrorWithKeyFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/VaeReconstructionErrorWithKeyFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/VaeReconstructionProbWithKeyFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/VaeReconstructionProbWithKeyFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/VaeReconstructionProbWithKeyFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/multilayer/scoring/VaeReconstructionProbWithKeyFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/BaseTrainingMaster.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/BaseTrainingMaster.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/BaseTrainingMaster.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/BaseTrainingMaster.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/BaseTrainingResult.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/BaseTrainingResult.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/BaseTrainingResult.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/BaseTrainingResult.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/BaseTrainingWorker.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/BaseTrainingWorker.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/BaseTrainingWorker.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/BaseTrainingWorker.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/ParameterAveragingTrainingMaster.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/ParameterAveragingTrainingMaster.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/ParameterAveragingTrainingMaster.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/ParameterAveragingTrainingMaster.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/ParameterAveragingTrainingResult.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/ParameterAveragingTrainingResult.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/ParameterAveragingTrainingResult.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/ParameterAveragingTrainingResult.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/ParameterAveragingTrainingWorker.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/ParameterAveragingTrainingWorker.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/ParameterAveragingTrainingWorker.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/ParameterAveragingTrainingWorker.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/aggregator/ParameterAveragingAggregationTuple.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/aggregator/ParameterAveragingAggregationTuple.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/aggregator/ParameterAveragingAggregationTuple.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/aggregator/ParameterAveragingAggregationTuple.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/aggregator/ParameterAveragingElementAddFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/aggregator/ParameterAveragingElementAddFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/aggregator/ParameterAveragingElementAddFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/aggregator/ParameterAveragingElementAddFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/aggregator/ParameterAveragingElementCombineFunction.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/aggregator/ParameterAveragingElementCombineFunction.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/aggregator/ParameterAveragingElementCombineFunction.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/aggregator/ParameterAveragingElementCombineFunction.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/stats/ParameterAveragingTrainingMasterStats.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/stats/ParameterAveragingTrainingMasterStats.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/stats/ParameterAveragingTrainingMasterStats.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/stats/ParameterAveragingTrainingMasterStats.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/stats/ParameterAveragingTrainingWorkerStats.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/stats/ParameterAveragingTrainingWorkerStats.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/stats/ParameterAveragingTrainingWorkerStats.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/stats/ParameterAveragingTrainingWorkerStats.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/util/ExportSupport.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/util/ExportSupport.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/util/ExportSupport.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/paramavg/util/ExportSupport.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/repartitioner/DefaultRepartitioner.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/repartitioner/DefaultRepartitioner.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/repartitioner/DefaultRepartitioner.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/repartitioner/DefaultRepartitioner.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/repartitioner/EqualRepartitioner.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/repartitioner/EqualRepartitioner.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/repartitioner/EqualRepartitioner.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/repartitioner/EqualRepartitioner.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/repartitioner/NoOpRepartitioner.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/repartitioner/NoOpRepartitioner.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/repartitioner/NoOpRepartitioner.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/impl/repartitioner/NoOpRepartitioner.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/BaseDataSetIterator.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/BaseDataSetIterator.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/BaseDataSetIterator.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/BaseDataSetIterator.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PathSparkDataSetIterator.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PathSparkDataSetIterator.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PathSparkDataSetIterator.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PathSparkDataSetIterator.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PathSparkMultiDataSetIterator.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PathSparkMultiDataSetIterator.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PathSparkMultiDataSetIterator.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PathSparkMultiDataSetIterator.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PortableDataStreamDataSetIterator.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PortableDataStreamDataSetIterator.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PortableDataStreamDataSetIterator.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PortableDataStreamDataSetIterator.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PortableDataStreamMultiDataSetIterator.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PortableDataStreamMultiDataSetIterator.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PortableDataStreamMultiDataSetIterator.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/PortableDataStreamMultiDataSetIterator.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/SparkADSI.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/SparkADSI.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/SparkADSI.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/SparkADSI.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/SparkAMDSI.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/SparkAMDSI.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/SparkAMDSI.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/iterator/SparkAMDSI.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/ordering/DataSetOrdering.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/ordering/DataSetOrdering.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/ordering/DataSetOrdering.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/ordering/DataSetOrdering.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/BaseEventStats.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/BaseEventStats.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/BaseEventStats.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/BaseEventStats.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/EventStats.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/EventStats.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/EventStats.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/EventStats.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/ExampleCountEventStats.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/ExampleCountEventStats.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/ExampleCountEventStats.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/ExampleCountEventStats.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/PartitionCountEventStats.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/PartitionCountEventStats.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/PartitionCountEventStats.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/PartitionCountEventStats.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/StatsUtils.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/StatsUtils.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/StatsUtils.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/stats/StatsUtils.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/NTPTimeSource.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/NTPTimeSource.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/NTPTimeSource.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/NTPTimeSource.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/SystemClockTimeSource.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/SystemClockTimeSource.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/SystemClockTimeSource.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/SystemClockTimeSource.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/TimeSource.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/TimeSource.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/TimeSource.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/TimeSource.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/TimeSourceProvider.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/TimeSourceProvider.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/TimeSourceProvider.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/time/TimeSourceProvider.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/MLLibUtil.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/MLLibUtil.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/MLLibUtil.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/MLLibUtil.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/SparkDataUtils.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/SparkDataUtils.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/SparkDataUtils.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/SparkDataUtils.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/SparkUtils.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/SparkUtils.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/SparkUtils.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/SparkUtils.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/SparkDataValidation.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/SparkDataValidation.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/SparkDataValidation.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/SparkDataValidation.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/ValidationResult.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/ValidationResult.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/ValidationResult.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/ValidationResult.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/validation/ValidateDataSetFn.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/validation/ValidateDataSetFn.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/validation/ValidateDataSetFn.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/validation/ValidateDataSetFn.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/validation/ValidateMultiDataSetFn.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/validation/ValidateMultiDataSetFn.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/validation/ValidateMultiDataSetFn.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/validation/ValidateMultiDataSetFn.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/validation/ValidationResultReduceFn.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/validation/ValidationResultReduceFn.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/validation/ValidationResultReduceFn.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/data/validation/ValidationResultReduceFn.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/serde/StorageLevelDeserializer.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/serde/StorageLevelDeserializer.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/serde/StorageLevelDeserializer.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/serde/StorageLevelDeserializer.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/serde/StorageLevelSerializer.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/serde/StorageLevelSerializer.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/serde/StorageLevelSerializer.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/java/org/deeplearning4j/spark/util/serde/StorageLevelSerializer.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/scala/org/apache/spark/TaskContextHelper.scala b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/scala/org/apache/spark/TaskContextHelper.scala similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/scala/org/apache/spark/TaskContextHelper.scala rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/main/scala/org/apache/spark/TaskContextHelper.scala diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/BaseSparkKryoTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/BaseSparkKryoTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/BaseSparkKryoTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/BaseSparkKryoTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/BaseSparkTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/BaseSparkTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/BaseSparkTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/BaseSparkTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestEarlyStoppingSpark.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestEarlyStoppingSpark.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestEarlyStoppingSpark.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestEarlyStoppingSpark.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestEarlyStoppingSparkCompGraph.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestEarlyStoppingSparkCompGraph.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestEarlyStoppingSparkCompGraph.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestEarlyStoppingSparkCompGraph.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestKryo.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestKryo.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestKryo.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestKryo.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/common/AddTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/common/AddTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/common/AddTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/common/AddTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/data/TestShuffleExamples.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/data/TestShuffleExamples.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/data/TestShuffleExamples.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/data/TestShuffleExamples.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/data/TestSparkDataUtils.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/data/TestSparkDataUtils.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/data/TestSparkDataUtils.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/data/TestSparkDataUtils.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/MiniBatchTests.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/MiniBatchTests.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/MiniBatchTests.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/MiniBatchTests.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestDataVecDataSetFunctions.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestDataVecDataSetFunctions.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestDataVecDataSetFunctions.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestDataVecDataSetFunctions.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestExport.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestExport.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestExport.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestExport.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestPreProcessedData.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestPreProcessedData.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestPreProcessedData.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestPreProcessedData.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/iterator/TestIteratorUtils.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/iterator/TestIteratorUtils.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/iterator/TestIteratorUtils.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/iterator/TestIteratorUtils.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/TestKryoWarning.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/TestKryoWarning.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/TestKryoWarning.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/TestKryoWarning.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/common/repartition/BalancedPartitionerTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/common/repartition/BalancedPartitionerTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/common/repartition/BalancedPartitionerTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/common/repartition/BalancedPartitionerTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/common/repartition/HashingBalancedPartitionerTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/common/repartition/HashingBalancedPartitionerTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/common/repartition/HashingBalancedPartitionerTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/common/repartition/HashingBalancedPartitionerTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/TestCustomLayer.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/TestCustomLayer.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/TestCustomLayer.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/TestCustomLayer.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/layer/CustomLayer.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/layer/CustomLayer.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/layer/CustomLayer.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/layer/CustomLayer.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/layer/CustomLayerImpl.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/layer/CustomLayerImpl.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/layer/CustomLayerImpl.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/layer/CustomLayerImpl.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/graph/TestSparkComputationGraph.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/graph/TestSparkComputationGraph.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/graph/TestSparkComputationGraph.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/graph/TestSparkComputationGraph.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/misc/TestFrozenLayers.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/misc/TestFrozenLayers.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/misc/TestFrozenLayers.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/misc/TestFrozenLayers.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/multilayer/TestMiscFunctions.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/multilayer/TestMiscFunctions.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/multilayer/TestMiscFunctions.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/multilayer/TestMiscFunctions.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/multilayer/TestSparkDl4jMultiLayer.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/multilayer/TestSparkDl4jMultiLayer.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/multilayer/TestSparkDl4jMultiLayer.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/multilayer/TestSparkDl4jMultiLayer.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestCompareParameterAveragingSparkVsSingleMachine.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestCompareParameterAveragingSparkVsSingleMachine.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestCompareParameterAveragingSparkVsSingleMachine.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestCompareParameterAveragingSparkVsSingleMachine.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestJsonYaml.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestJsonYaml.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestJsonYaml.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestJsonYaml.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestSparkMultiLayerParameterAveraging.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestSparkMultiLayerParameterAveraging.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestSparkMultiLayerParameterAveraging.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestSparkMultiLayerParameterAveraging.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/util/ExportSupportTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/util/ExportSupportTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/util/ExportSupportTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/util/ExportSupportTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/stats/TestTrainingStatsCollection.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/stats/TestTrainingStatsCollection.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/stats/TestTrainingStatsCollection.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/stats/TestTrainingStatsCollection.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/time/TestTimeSource.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/time/TestTimeSource.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/time/TestTimeSource.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/time/TestTimeSource.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/ui/TestListeners.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/ui/TestListeners.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/ui/TestListeners.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/ui/TestListeners.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/MLLIbUtilTest.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/MLLIbUtilTest.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/MLLIbUtilTest.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/MLLIbUtilTest.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/TestRepartitioning.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/TestRepartitioning.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/TestRepartitioning.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/TestRepartitioning.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/TestValidation.java b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/TestValidation.java similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/TestValidation.java rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/TestValidation.java diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/resources/log4j.properties b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/resources/log4j.properties similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/resources/log4j.properties rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/resources/log4j.properties diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/resources/logback.xml b/.old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/resources/logback.xml similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/resources/logback.xml rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/resources/logback.xml diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/pom.xml b/.old/deeplearning4j/deeplearning4j-scaleout/spark/pom.xml similarity index 100% rename from deeplearning4j/deeplearning4j-scaleout/spark/pom.xml rename to .old/deeplearning4j/deeplearning4j-scaleout/spark/pom.xml diff --git a/deeplearning4j/pom.xml b/.old/deeplearning4j/pom.xml similarity index 100% rename from deeplearning4j/pom.xml rename to .old/deeplearning4j/pom.xml diff --git a/nd4j/README.md b/.old/nd4j/README.md similarity index 100% rename from nd4j/README.md rename to .old/nd4j/README.md diff --git a/nd4j/RaspberryPi.md b/.old/nd4j/RaspberryPi.md similarity index 100% rename from nd4j/RaspberryPi.md rename to .old/nd4j/RaspberryPi.md diff --git a/nd4j/buildmultiplescalaversions.sh b/.old/nd4j/buildmultiplescalaversions.sh similarity index 100% rename from nd4j/buildmultiplescalaversions.sh rename to .old/nd4j/buildmultiplescalaversions.sh diff --git a/nd4j/nd4j-jdbc/nd4j-jdbc-api/pom.xml b/.old/nd4j/nd4j-jdbc/nd4j-jdbc-api/pom.xml similarity index 100% rename from nd4j/nd4j-jdbc/nd4j-jdbc-api/pom.xml rename to .old/nd4j/nd4j-jdbc/nd4j-jdbc-api/pom.xml diff --git a/nd4j/nd4j-jdbc/nd4j-jdbc-api/src/main/java/org/nd4j/jdbc/driverfinder/DriverFinder.java b/.old/nd4j/nd4j-jdbc/nd4j-jdbc-api/src/main/java/org/nd4j/jdbc/driverfinder/DriverFinder.java similarity index 100% rename from nd4j/nd4j-jdbc/nd4j-jdbc-api/src/main/java/org/nd4j/jdbc/driverfinder/DriverFinder.java rename to .old/nd4j/nd4j-jdbc/nd4j-jdbc-api/src/main/java/org/nd4j/jdbc/driverfinder/DriverFinder.java diff --git a/nd4j/nd4j-jdbc/nd4j-jdbc-api/src/main/java/org/nd4j/jdbc/loader/api/JDBCNDArrayIO.java b/.old/nd4j/nd4j-jdbc/nd4j-jdbc-api/src/main/java/org/nd4j/jdbc/loader/api/JDBCNDArrayIO.java similarity index 100% rename from nd4j/nd4j-jdbc/nd4j-jdbc-api/src/main/java/org/nd4j/jdbc/loader/api/JDBCNDArrayIO.java rename to .old/nd4j/nd4j-jdbc/nd4j-jdbc-api/src/main/java/org/nd4j/jdbc/loader/api/JDBCNDArrayIO.java diff --git a/nd4j/nd4j-jdbc/nd4j-jdbc-api/src/main/java/org/nd4j/jdbc/loader/impl/BaseLoader.java b/.old/nd4j/nd4j-jdbc/nd4j-jdbc-api/src/main/java/org/nd4j/jdbc/loader/impl/BaseLoader.java similarity index 100% rename from nd4j/nd4j-jdbc/nd4j-jdbc-api/src/main/java/org/nd4j/jdbc/loader/impl/BaseLoader.java rename to .old/nd4j/nd4j-jdbc/nd4j-jdbc-api/src/main/java/org/nd4j/jdbc/loader/impl/BaseLoader.java diff --git a/nd4j/nd4j-jdbc/nd4j-jdbc-hsql/pom.xml b/.old/nd4j/nd4j-jdbc/nd4j-jdbc-hsql/pom.xml similarity index 100% rename from nd4j/nd4j-jdbc/nd4j-jdbc-hsql/pom.xml rename to .old/nd4j/nd4j-jdbc/nd4j-jdbc-hsql/pom.xml diff --git a/nd4j/nd4j-jdbc/nd4j-jdbc-hsql/src/main/java/org/nd4j/jdbc/hsql/HsqlLoader.java b/.old/nd4j/nd4j-jdbc/nd4j-jdbc-hsql/src/main/java/org/nd4j/jdbc/hsql/HsqlLoader.java similarity index 100% rename from nd4j/nd4j-jdbc/nd4j-jdbc-hsql/src/main/java/org/nd4j/jdbc/hsql/HsqlLoader.java rename to .old/nd4j/nd4j-jdbc/nd4j-jdbc-hsql/src/main/java/org/nd4j/jdbc/hsql/HsqlLoader.java diff --git a/nd4j/nd4j-jdbc/nd4j-jdbc-hsql/src/main/resources/nd4j.jdbc.properties b/.old/nd4j/nd4j-jdbc/nd4j-jdbc-hsql/src/main/resources/nd4j.jdbc.properties similarity index 100% rename from nd4j/nd4j-jdbc/nd4j-jdbc-hsql/src/main/resources/nd4j.jdbc.properties rename to .old/nd4j/nd4j-jdbc/nd4j-jdbc-hsql/src/main/resources/nd4j.jdbc.properties diff --git a/nd4j/nd4j-jdbc/nd4j-jdbc-hsql/src/test/java/org/nd4j/jdbc/hsql/HSqlLoaderTest.java b/.old/nd4j/nd4j-jdbc/nd4j-jdbc-hsql/src/test/java/org/nd4j/jdbc/hsql/HSqlLoaderTest.java similarity index 100% rename from nd4j/nd4j-jdbc/nd4j-jdbc-hsql/src/test/java/org/nd4j/jdbc/hsql/HSqlLoaderTest.java rename to .old/nd4j/nd4j-jdbc/nd4j-jdbc-hsql/src/test/java/org/nd4j/jdbc/hsql/HSqlLoaderTest.java diff --git a/nd4j/nd4j-jdbc/nd4j-jdbc-mysql/pom.xml b/.old/nd4j/nd4j-jdbc/nd4j-jdbc-mysql/pom.xml similarity index 100% rename from nd4j/nd4j-jdbc/nd4j-jdbc-mysql/pom.xml rename to .old/nd4j/nd4j-jdbc/nd4j-jdbc-mysql/pom.xml diff --git a/nd4j/nd4j-jdbc/nd4j-jdbc-mysql/src/main/java/org/nd4j/jdbc/mysql/MysqlLoader.java b/.old/nd4j/nd4j-jdbc/nd4j-jdbc-mysql/src/main/java/org/nd4j/jdbc/mysql/MysqlLoader.java similarity index 100% rename from nd4j/nd4j-jdbc/nd4j-jdbc-mysql/src/main/java/org/nd4j/jdbc/mysql/MysqlLoader.java rename to .old/nd4j/nd4j-jdbc/nd4j-jdbc-mysql/src/main/java/org/nd4j/jdbc/mysql/MysqlLoader.java diff --git a/nd4j/nd4j-jdbc/nd4j-jdbc-mysql/src/main/resources/nd4j.jdbc.properties b/.old/nd4j/nd4j-jdbc/nd4j-jdbc-mysql/src/main/resources/nd4j.jdbc.properties similarity index 100% rename from nd4j/nd4j-jdbc/nd4j-jdbc-mysql/src/main/resources/nd4j.jdbc.properties rename to .old/nd4j/nd4j-jdbc/nd4j-jdbc-mysql/src/main/resources/nd4j.jdbc.properties diff --git a/nd4j/nd4j-jdbc/nd4j-jdbc-mysql/src/test/java/org/nd4j/jdbc/mysql/MysqlLoaderTest.java b/.old/nd4j/nd4j-jdbc/nd4j-jdbc-mysql/src/test/java/org/nd4j/jdbc/mysql/MysqlLoaderTest.java similarity index 100% rename from nd4j/nd4j-jdbc/nd4j-jdbc-mysql/src/test/java/org/nd4j/jdbc/mysql/MysqlLoaderTest.java rename to .old/nd4j/nd4j-jdbc/nd4j-jdbc-mysql/src/test/java/org/nd4j/jdbc/mysql/MysqlLoaderTest.java diff --git a/nd4j/nd4j-jdbc/pom.xml b/.old/nd4j/nd4j-jdbc/pom.xml similarity index 100% rename from nd4j/nd4j-jdbc/pom.xml rename to .old/nd4j/nd4j-jdbc/pom.xml diff --git a/nd4j/nd4j-onnxruntime/pom.xml b/.old/nd4j/nd4j-onnxruntime/pom.xml similarity index 100% rename from nd4j/nd4j-onnxruntime/pom.xml rename to .old/nd4j/nd4j-onnxruntime/pom.xml diff --git a/nd4j/nd4j-onnxruntime/src/main/java/org/nd4j/onnxruntime/runner/OnnxRuntimeRunner.java b/.old/nd4j/nd4j-onnxruntime/src/main/java/org/nd4j/onnxruntime/runner/OnnxRuntimeRunner.java similarity index 100% rename from nd4j/nd4j-onnxruntime/src/main/java/org/nd4j/onnxruntime/runner/OnnxRuntimeRunner.java rename to .old/nd4j/nd4j-onnxruntime/src/main/java/org/nd4j/onnxruntime/runner/OnnxRuntimeRunner.java diff --git a/nd4j/nd4j-onnxruntime/src/main/java/org/nd4j/onnxruntime/util/ONNXUtils.java b/.old/nd4j/nd4j-onnxruntime/src/main/java/org/nd4j/onnxruntime/util/ONNXUtils.java similarity index 100% rename from nd4j/nd4j-onnxruntime/src/main/java/org/nd4j/onnxruntime/util/ONNXUtils.java rename to .old/nd4j/nd4j-onnxruntime/src/main/java/org/nd4j/onnxruntime/util/ONNXUtils.java diff --git a/nd4j/nd4j-onnxruntime/src/test/java/org/nd4j/onnxruntime/runner/OnnxRuntimeRunnerTests.java b/.old/nd4j/nd4j-onnxruntime/src/test/java/org/nd4j/onnxruntime/runner/OnnxRuntimeRunnerTests.java similarity index 100% rename from nd4j/nd4j-onnxruntime/src/test/java/org/nd4j/onnxruntime/runner/OnnxRuntimeRunnerTests.java rename to .old/nd4j/nd4j-onnxruntime/src/test/java/org/nd4j/onnxruntime/runner/OnnxRuntimeRunnerTests.java diff --git a/nd4j/nd4j-onnxruntime/src/test/resources/add.onnx b/.old/nd4j/nd4j-onnxruntime/src/test/resources/add.onnx similarity index 100% rename from nd4j/nd4j-onnxruntime/src/test/resources/add.onnx rename to .old/nd4j/nd4j-onnxruntime/src/test/resources/add.onnx diff --git a/nd4j/nd4j-remote/README.md b/.old/nd4j/nd4j-remote/README.md similarity index 100% rename from nd4j/nd4j-remote/README.md rename to .old/nd4j/nd4j-remote/README.md diff --git a/nd4j/nd4j-remote/nd4j-grpc-client/pom.xml b/.old/nd4j/nd4j-remote/nd4j-grpc-client/pom.xml similarity index 100% rename from nd4j/nd4j-remote/nd4j-grpc-client/pom.xml rename to .old/nd4j/nd4j-remote/nd4j-grpc-client/pom.xml diff --git a/nd4j/nd4j-remote/nd4j-grpc-client/src/main/java/org/nd4j/remote/grpc/GraphInferenceGrpcClient.java b/.old/nd4j/nd4j-remote/nd4j-grpc-client/src/main/java/org/nd4j/remote/grpc/GraphInferenceGrpcClient.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-grpc-client/src/main/java/org/nd4j/remote/grpc/GraphInferenceGrpcClient.java rename to .old/nd4j/nd4j-remote/nd4j-grpc-client/src/main/java/org/nd4j/remote/grpc/GraphInferenceGrpcClient.java diff --git a/nd4j/nd4j-remote/nd4j-grpc-client/src/main/java/org/nd4j/remote/grpc/grpc/GraphInferenceServerGrpc.java b/.old/nd4j/nd4j-remote/nd4j-grpc-client/src/main/java/org/nd4j/remote/grpc/grpc/GraphInferenceServerGrpc.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-grpc-client/src/main/java/org/nd4j/remote/grpc/grpc/GraphInferenceServerGrpc.java rename to .old/nd4j/nd4j-remote/nd4j-grpc-client/src/main/java/org/nd4j/remote/grpc/grpc/GraphInferenceServerGrpc.java diff --git a/nd4j/nd4j-remote/nd4j-grpc-client/src/test/java/org/nd4j/graph/GraphInferenceGrpcClientTest.java b/.old/nd4j/nd4j-remote/nd4j-grpc-client/src/test/java/org/nd4j/graph/GraphInferenceGrpcClientTest.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-grpc-client/src/test/java/org/nd4j/graph/GraphInferenceGrpcClientTest.java rename to .old/nd4j/nd4j-remote/nd4j-grpc-client/src/test/java/org/nd4j/graph/GraphInferenceGrpcClientTest.java diff --git a/nd4j/nd4j-remote/nd4j-json-client/pom.xml b/.old/nd4j/nd4j-remote/nd4j-json-client/pom.xml similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-client/pom.xml rename to .old/nd4j/nd4j-remote/nd4j-json-client/pom.xml diff --git a/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/JsonRemoteInference.java b/.old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/JsonRemoteInference.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/JsonRemoteInference.java rename to .old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/JsonRemoteInference.java diff --git a/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/BinaryDeserializer.java b/.old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/BinaryDeserializer.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/BinaryDeserializer.java rename to .old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/BinaryDeserializer.java diff --git a/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/BinarySerializer.java b/.old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/BinarySerializer.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/BinarySerializer.java rename to .old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/BinarySerializer.java diff --git a/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/JsonDeserializer.java b/.old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/JsonDeserializer.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/JsonDeserializer.java rename to .old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/JsonDeserializer.java diff --git a/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/JsonSerializer.java b/.old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/JsonSerializer.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/JsonSerializer.java rename to .old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/JsonSerializer.java diff --git a/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/AbstractSerDe.java b/.old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/AbstractSerDe.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/AbstractSerDe.java rename to .old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/AbstractSerDe.java diff --git a/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/BooleanSerde.java b/.old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/BooleanSerde.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/BooleanSerde.java rename to .old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/BooleanSerde.java diff --git a/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/DoubleArraySerde.java b/.old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/DoubleArraySerde.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/DoubleArraySerde.java rename to .old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/DoubleArraySerde.java diff --git a/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/DoubleSerde.java b/.old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/DoubleSerde.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/DoubleSerde.java rename to .old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/DoubleSerde.java diff --git a/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/FloatArraySerde.java b/.old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/FloatArraySerde.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/FloatArraySerde.java rename to .old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/FloatArraySerde.java diff --git a/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/FloatSerde.java b/.old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/FloatSerde.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/FloatSerde.java rename to .old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/FloatSerde.java diff --git a/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/IntegerSerde.java b/.old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/IntegerSerde.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/IntegerSerde.java rename to .old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/IntegerSerde.java diff --git a/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/StringSerde.java b/.old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/StringSerde.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/StringSerde.java rename to .old/nd4j/nd4j-remote/nd4j-json-client/src/main/java/org/nd4j/remote/clients/serde/impl/StringSerde.java diff --git a/nd4j/nd4j-remote/nd4j-json-server/README.md b/.old/nd4j/nd4j-remote/nd4j-json-server/README.md similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-server/README.md rename to .old/nd4j/nd4j-remote/nd4j-json-server/README.md diff --git a/nd4j/nd4j-remote/nd4j-json-server/pom.xml b/.old/nd4j/nd4j-remote/nd4j-json-server/pom.xml similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-server/pom.xml rename to .old/nd4j/nd4j-remote/nd4j-json-server/pom.xml diff --git a/nd4j/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/SameDiffJsonModelServer.java b/.old/nd4j/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/SameDiffJsonModelServer.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/SameDiffJsonModelServer.java rename to .old/nd4j/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/SameDiffJsonModelServer.java diff --git a/nd4j/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/serving/ModelServingServlet.java b/.old/nd4j/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/serving/ModelServingServlet.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/serving/ModelServingServlet.java rename to .old/nd4j/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/serving/ModelServingServlet.java diff --git a/nd4j/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/serving/SameDiffServlet.java b/.old/nd4j/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/serving/SameDiffServlet.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/serving/SameDiffServlet.java rename to .old/nd4j/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/serving/SameDiffServlet.java diff --git a/nd4j/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/serving/ServingProcessor.java b/.old/nd4j/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/serving/ServingProcessor.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/serving/ServingProcessor.java rename to .old/nd4j/nd4j-remote/nd4j-json-server/src/main/java/org/nd4j/remote/serving/ServingProcessor.java diff --git a/nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/SameDiffJsonModelServerTest.java b/.old/nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/SameDiffJsonModelServerTest.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/SameDiffJsonModelServerTest.java rename to .old/nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/SameDiffJsonModelServerTest.java diff --git a/nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/SameDiffServletTest.java b/.old/nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/SameDiffServletTest.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/SameDiffServletTest.java rename to .old/nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/SameDiffServletTest.java diff --git a/nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/helpers/House.java b/.old/nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/helpers/House.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/helpers/House.java rename to .old/nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/helpers/House.java diff --git a/nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/helpers/HouseToPredictedPriceAdapter.java b/.old/nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/helpers/HouseToPredictedPriceAdapter.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/helpers/HouseToPredictedPriceAdapter.java rename to .old/nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/helpers/HouseToPredictedPriceAdapter.java diff --git a/nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/helpers/PredictedPrice.java b/.old/nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/helpers/PredictedPrice.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/helpers/PredictedPrice.java rename to .old/nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/helpers/PredictedPrice.java diff --git a/nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/serde/BasicSerdeTests.java b/.old/nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/serde/BasicSerdeTests.java similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/serde/BasicSerdeTests.java rename to .old/nd4j/nd4j-remote/nd4j-json-server/src/test/java/org/nd4j/remote/serde/BasicSerdeTests.java diff --git a/nd4j/nd4j-remote/nd4j-json-server/src/test/resources/logback.xml b/.old/nd4j/nd4j-remote/nd4j-json-server/src/test/resources/logback.xml similarity index 100% rename from nd4j/nd4j-remote/nd4j-json-server/src/test/resources/logback.xml rename to .old/nd4j/nd4j-remote/nd4j-json-server/src/test/resources/logback.xml diff --git a/nd4j/nd4j-remote/pom.xml b/.old/nd4j/nd4j-remote/pom.xml similarity index 100% rename from nd4j/nd4j-remote/pom.xml rename to .old/nd4j/nd4j-remote/pom.xml diff --git a/nd4j/nd4j-serde/nd4j-arrow/pom.xml b/.old/nd4j/nd4j-serde/nd4j-arrow/pom.xml similarity index 100% rename from nd4j/nd4j-serde/nd4j-arrow/pom.xml rename to .old/nd4j/nd4j-serde/nd4j-arrow/pom.xml diff --git a/nd4j/nd4j-serde/nd4j-arrow/src/main/java/org/nd4j/arrow/ArrowSerde.java b/.old/nd4j/nd4j-serde/nd4j-arrow/src/main/java/org/nd4j/arrow/ArrowSerde.java similarity index 100% rename from nd4j/nd4j-serde/nd4j-arrow/src/main/java/org/nd4j/arrow/ArrowSerde.java rename to .old/nd4j/nd4j-serde/nd4j-arrow/src/main/java/org/nd4j/arrow/ArrowSerde.java diff --git a/nd4j/nd4j-serde/nd4j-arrow/src/main/java/org/nd4j/arrow/DataBufferStruct.java b/.old/nd4j/nd4j-serde/nd4j-arrow/src/main/java/org/nd4j/arrow/DataBufferStruct.java similarity index 100% rename from nd4j/nd4j-serde/nd4j-arrow/src/main/java/org/nd4j/arrow/DataBufferStruct.java rename to .old/nd4j/nd4j-serde/nd4j-arrow/src/main/java/org/nd4j/arrow/DataBufferStruct.java diff --git a/nd4j/nd4j-serde/nd4j-arrow/src/test/java/org/nd4j/arrow/ArrowSerdeTest.java b/.old/nd4j/nd4j-serde/nd4j-arrow/src/test/java/org/nd4j/arrow/ArrowSerdeTest.java similarity index 100% rename from nd4j/nd4j-serde/nd4j-arrow/src/test/java/org/nd4j/arrow/ArrowSerdeTest.java rename to .old/nd4j/nd4j-serde/nd4j-arrow/src/test/java/org/nd4j/arrow/ArrowSerdeTest.java diff --git a/nd4j/nd4j-serde/nd4j-kryo/pom.xml b/.old/nd4j/nd4j-serde/nd4j-kryo/pom.xml similarity index 100% rename from nd4j/nd4j-serde/nd4j-kryo/pom.xml rename to .old/nd4j/nd4j-serde/nd4j-kryo/pom.xml diff --git a/nd4j/nd4j-serde/nd4j-kryo/src/main/java/org/nd4j/kryo/Nd4jRegistrator.java b/.old/nd4j/nd4j-serde/nd4j-kryo/src/main/java/org/nd4j/kryo/Nd4jRegistrator.java similarity index 100% rename from nd4j/nd4j-serde/nd4j-kryo/src/main/java/org/nd4j/kryo/Nd4jRegistrator.java rename to .old/nd4j/nd4j-serde/nd4j-kryo/src/main/java/org/nd4j/kryo/Nd4jRegistrator.java diff --git a/nd4j/nd4j-serde/nd4j-kryo/src/main/java/org/nd4j/kryo/Nd4jSerializer.java b/.old/nd4j/nd4j-serde/nd4j-kryo/src/main/java/org/nd4j/kryo/Nd4jSerializer.java similarity index 100% rename from nd4j/nd4j-serde/nd4j-kryo/src/main/java/org/nd4j/kryo/Nd4jSerializer.java rename to .old/nd4j/nd4j-serde/nd4j-kryo/src/main/java/org/nd4j/kryo/Nd4jSerializer.java diff --git a/nd4j/nd4j-serde/nd4j-kryo/src/main/java/org/nd4j/kryo/primitives/AtomicDoubleSerializer.java b/.old/nd4j/nd4j-serde/nd4j-kryo/src/main/java/org/nd4j/kryo/primitives/AtomicDoubleSerializer.java similarity index 100% rename from nd4j/nd4j-serde/nd4j-kryo/src/main/java/org/nd4j/kryo/primitives/AtomicDoubleSerializer.java rename to .old/nd4j/nd4j-serde/nd4j-kryo/src/main/java/org/nd4j/kryo/primitives/AtomicDoubleSerializer.java diff --git a/nd4j/nd4j-serde/nd4j-kryo/src/test/java/org/nd4j/TestNd4jKryoSerialization.java b/.old/nd4j/nd4j-serde/nd4j-kryo/src/test/java/org/nd4j/TestNd4jKryoSerialization.java similarity index 100% rename from nd4j/nd4j-serde/nd4j-kryo/src/test/java/org/nd4j/TestNd4jKryoSerialization.java rename to .old/nd4j/nd4j-serde/nd4j-kryo/src/test/java/org/nd4j/TestNd4jKryoSerialization.java diff --git a/nd4j/nd4j-serde/pom.xml b/.old/nd4j/nd4j-serde/pom.xml similarity index 100% rename from nd4j/nd4j-serde/pom.xml rename to .old/nd4j/nd4j-serde/pom.xml diff --git a/nd4j/nd4j-tvm/pom.xml b/.old/nd4j/nd4j-tvm/pom.xml similarity index 100% rename from nd4j/nd4j-tvm/pom.xml rename to .old/nd4j/nd4j-tvm/pom.xml diff --git a/nd4j/nd4j-tvm/src/main/java/org/nd4j/tvm/runner/TvmRunner.java b/.old/nd4j/nd4j-tvm/src/main/java/org/nd4j/tvm/runner/TvmRunner.java similarity index 100% rename from nd4j/nd4j-tvm/src/main/java/org/nd4j/tvm/runner/TvmRunner.java rename to .old/nd4j/nd4j-tvm/src/main/java/org/nd4j/tvm/runner/TvmRunner.java diff --git a/nd4j/nd4j-tvm/src/main/java/org/nd4j/tvm/util/TVMUtils.java b/.old/nd4j/nd4j-tvm/src/main/java/org/nd4j/tvm/util/TVMUtils.java similarity index 100% rename from nd4j/nd4j-tvm/src/main/java/org/nd4j/tvm/util/TVMUtils.java rename to .old/nd4j/nd4j-tvm/src/main/java/org/nd4j/tvm/util/TVMUtils.java diff --git a/nd4j/nd4j-tvm/src/test/java/org/nd4j/tvm/runner/TvmRunnerTests.java b/.old/nd4j/nd4j-tvm/src/test/java/org/nd4j/tvm/runner/TvmRunnerTests.java similarity index 100% rename from nd4j/nd4j-tvm/src/test/java/org/nd4j/tvm/runner/TvmRunnerTests.java rename to .old/nd4j/nd4j-tvm/src/test/java/org/nd4j/tvm/runner/TvmRunnerTests.java diff --git a/nd4j/pom.xml b/.old/nd4j/pom.xml similarity index 100% rename from nd4j/pom.xml rename to .old/nd4j/pom.xml diff --git a/nd4j/samediff-import/pom.xml b/.old/nd4j/samediff-import/pom.xml similarity index 100% rename from nd4j/samediff-import/pom.xml rename to .old/nd4j/samediff-import/pom.xml diff --git a/nd4j/samediff-import/samediff-import-api/pom.xml b/.old/nd4j/samediff-import/samediff-import-api/pom.xml similarity index 100% rename from nd4j/samediff-import/samediff-import-api/pom.xml rename to .old/nd4j/samediff-import/samediff-import-api/pom.xml diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/FrameworkImporter.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/FrameworkImporter.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/FrameworkImporter.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/FrameworkImporter.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/IRProtobufExtensions.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/IRProtobufExtensions.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/IRProtobufExtensions.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/IRProtobufExtensions.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ImportGraph.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ImportGraph.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ImportGraph.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ImportGraph.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ImportGraphFactory.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ImportGraphFactory.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ImportGraphFactory.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ImportGraphFactory.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ImportGraphHolder.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ImportGraphHolder.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ImportGraphHolder.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ImportGraphHolder.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/context/AbstractMappingContext.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/context/AbstractMappingContext.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/context/AbstractMappingContext.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/context/AbstractMappingContext.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/context/MappingContext.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/context/MappingContext.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/context/MappingContext.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/context/MappingContext.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/PostImportHook.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/PostImportHook.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/PostImportHook.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/PostImportHook.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/PreImportHook.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/PreImportHook.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/PreImportHook.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/PreImportHook.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/annotations/HookResult.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/annotations/HookResult.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/annotations/HookResult.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/annotations/HookResult.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/annotations/PostHookRule.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/annotations/PostHookRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/annotations/PostHookRule.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/annotations/PostHookRule.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/annotations/PreHookRule.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/annotations/PreHookRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/annotations/PreHookRule.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/hooks/annotations/PreHookRule.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRArgDef.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRArgDef.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRArgDef.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRArgDef.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRAttribute.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRAttribute.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRAttribute.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRAttribute.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRDataType.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRDataType.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRDataType.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRDataType.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRDataTypeValue.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRDataTypeValue.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRDataTypeValue.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRDataTypeValue.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRFunctions.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRFunctions.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRFunctions.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRFunctions.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRGraph.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRGraph.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRGraph.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRGraph.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRNode.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRNode.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRNode.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRNode.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IROpDef.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IROpDef.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IROpDef.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IROpDef.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRTensor.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRTensor.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRTensor.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/ir/IRTensor.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/mapper/MapperExtensions.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/mapper/MapperExtensions.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/mapper/MapperExtensions.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/mapper/MapperExtensions.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/opdefs/OpDescriptorLoader.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/opdefs/OpDescriptorLoader.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/opdefs/OpDescriptorLoader.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/opdefs/OpDescriptorLoader.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/opdefs/OpDescriptorLoaderHolder.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/opdefs/OpDescriptorLoaderHolder.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/opdefs/OpDescriptorLoaderHolder.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/opdefs/OpDescriptorLoaderHolder.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/AbstractMappingProcess.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/AbstractMappingProcess.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/AbstractMappingProcess.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/AbstractMappingProcess.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/AbstractMappingProcessLoader.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/AbstractMappingProcessLoader.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/AbstractMappingProcessLoader.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/AbstractMappingProcessLoader.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/MappingProcess.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/MappingProcess.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/MappingProcess.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/MappingProcess.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/MappingProcessLoader.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/MappingProcessLoader.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/MappingProcessLoader.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/process/MappingProcessLoader.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/reflect/ImportReflectionCache.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/reflect/ImportReflectionCache.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/reflect/ImportReflectionCache.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/reflect/ImportReflectionCache.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/registry/ObjectRegistryHolder.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/registry/ObjectRegistryHolder.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/registry/ObjectRegistryHolder.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/registry/ObjectRegistryHolder.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/registry/OpMappingRegistry.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/registry/OpMappingRegistry.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/registry/OpMappingRegistry.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/registry/OpMappingRegistry.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/MappingRule.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/MappingRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/MappingRule.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/MappingRule.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ArgDescriptorConstant.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ArgDescriptorConstant.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ArgDescriptorConstant.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ArgDescriptorConstant.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeMappingRule.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeMappingRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeMappingRule.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeMappingRule.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeNDArrayToScalarAttribute.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeNDArrayToScalarAttribute.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeNDArrayToScalarAttribute.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeNDArrayToScalarAttribute.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeNumberListNDArray.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeNumberListNDArray.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeNumberListNDArray.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeNumberListNDArray.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeScalarNDArrayAttribute.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeScalarNDArrayAttribute.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeScalarNDArrayAttribute.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeScalarNDArrayAttribute.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeValueType.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeValueType.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeValueType.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/AttributeValueType.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/BaseAttributeExtractionRule.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/BaseAttributeExtractionRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/BaseAttributeExtractionRule.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/BaseAttributeExtractionRule.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ConditionalFieldValueIntIndexArrayRule.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ConditionalFieldValueIntIndexArrayRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ConditionalFieldValueIntIndexArrayRule.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ConditionalFieldValueIntIndexArrayRule.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ConditionalFieldValueIntIndexNDArrayRule.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ConditionalFieldValueIntIndexNDArrayRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ConditionalFieldValueIntIndexNDArrayRule.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ConditionalFieldValueIntIndexNDArrayRule.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/DataTypeToInt.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/DataTypeToInt.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/DataTypeToInt.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/DataTypeToInt.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/FlattenDims.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/FlattenDims.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/FlattenDims.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/FlattenDims.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/IRMappingFunctions.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/IRMappingFunctions.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/IRMappingFunctions.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/IRMappingFunctions.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/InvertBooleanNumber.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/InvertBooleanNumber.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/InvertBooleanNumber.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/InvertBooleanNumber.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ListAttributeValueLookupToIndex.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ListAttributeValueLookupToIndex.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ListAttributeValueLookupToIndex.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ListAttributeValueLookupToIndex.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ListNumberToListNumber.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ListNumberToListNumber.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ListNumberToListNumber.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ListNumberToListNumber.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ListNumberToNDArray.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ListNumberToNDArray.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ListNumberToNDArray.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ListNumberToNDArray.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/MapStringToInt.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/MapStringToInt.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/MapStringToInt.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/MapStringToInt.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayAttributeToNDArrayInput.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayAttributeToNDArrayInput.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayAttributeToNDArrayInput.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayAttributeToNDArrayInput.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayExtractScalarValue.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayExtractScalarValue.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayExtractScalarValue.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayExtractScalarValue.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayInputToNumericalAttribute.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayInputToNumericalAttribute.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayInputToNumericalAttribute.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayInputToNumericalAttribute.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArraySizeAtRule.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArraySizeAtRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArraySizeAtRule.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArraySizeAtRule.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayToIntAttributeValue.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayToIntAttributeValue.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayToIntAttributeValue.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NDArrayToIntAttributeValue.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NumberToBoolean.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NumberToBoolean.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NumberToBoolean.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/NumberToBoolean.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/SizeThresholdIntArrayIntIndexRule.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/SizeThresholdIntArrayIntIndexRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/SizeThresholdIntArrayIntIndexRule.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/SizeThresholdIntArrayIntIndexRule.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringAttributeToNDArray.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringAttributeToNDArray.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringAttributeToNDArray.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringAttributeToNDArray.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringContainsAdapterRule.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringContainsAdapterRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringContainsAdapterRule.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringContainsAdapterRule.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringEqualsAdapterRule.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringEqualsAdapterRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringEqualsAdapterRule.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringEqualsAdapterRule.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringNotEqualsAdapterRule.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringNotEqualsAdapterRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringNotEqualsAdapterRule.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringNotEqualsAdapterRule.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringToInt.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringToInt.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringToInt.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/StringToInt.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ValueMapping.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ValueMapping.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ValueMapping.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/attribute/ValueMapping.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/BaseNDArrayMappingRule.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/BaseNDArrayMappingRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/BaseNDArrayMappingRule.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/BaseNDArrayMappingRule.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/MultiInputIndexMappingRule.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/MultiInputIndexMappingRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/MultiInputIndexMappingRule.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/MultiInputIndexMappingRule.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/PassThroughMultiTensorMapping.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/PassThroughMultiTensorMapping.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/PassThroughMultiTensorMapping.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/PassThroughMultiTensorMapping.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/TensorMappingRule.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/TensorMappingRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/TensorMappingRule.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/rule/tensor/TensorMappingRule.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/runner/DefaultImportRunner.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/runner/DefaultImportRunner.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/runner/DefaultImportRunner.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/runner/DefaultImportRunner.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/runner/IRGraphRunner.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/runner/IRGraphRunner.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/runner/IRGraphRunner.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/runner/IRGraphRunner.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/runner/ImportRunner.kt b/.old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/runner/ImportRunner.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/runner/ImportRunner.kt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/kotlin/org/nd4j/samediff/frameworkimport/runner/ImportRunner.kt diff --git a/nd4j/samediff-import/samediff-import-api/src/main/resources/nd4j-op-def.pbtxt b/.old/nd4j/samediff-import/samediff-import-api/src/main/resources/nd4j-op-def.pbtxt similarity index 100% rename from nd4j/samediff-import/samediff-import-api/src/main/resources/nd4j-op-def.pbtxt rename to .old/nd4j/samediff-import/samediff-import-api/src/main/resources/nd4j-op-def.pbtxt diff --git a/nd4j/samediff-import/samediff-import-onnx/onnx-processes.pbtxt b/.old/nd4j/samediff-import/samediff-import-onnx/onnx-processes.pbtxt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/onnx-processes.pbtxt rename to .old/nd4j/samediff-import/samediff-import-onnx/onnx-processes.pbtxt diff --git a/nd4j/samediff-import/samediff-import-onnx/ops-added-new.txt b/.old/nd4j/samediff-import/samediff-import-onnx/ops-added-new.txt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/ops-added-new.txt rename to .old/nd4j/samediff-import/samediff-import-onnx/ops-added-new.txt diff --git a/nd4j/samediff-import/samediff-import-onnx/ops-imported-new.txt b/.old/nd4j/samediff-import/samediff-import-onnx/ops-imported-new.txt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/ops-imported-new.txt rename to .old/nd4j/samediff-import/samediff-import-onnx/ops-imported-new.txt diff --git a/nd4j/samediff-import/samediff-import-onnx/ops-removed-new.txt b/.old/nd4j/samediff-import/samediff-import-onnx/ops-removed-new.txt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/ops-removed-new.txt rename to .old/nd4j/samediff-import/samediff-import-onnx/ops-removed-new.txt diff --git a/nd4j/samediff-import/samediff-import-onnx/pom.xml b/.old/nd4j/samediff-import/samediff-import-onnx/pom.xml similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/pom.xml rename to .old/nd4j/samediff-import/samediff-import-onnx/pom.xml diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxIR.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxIR.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxIR.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxIR.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxImportGraph.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxImportGraph.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxImportGraph.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxImportGraph.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxImportGraphHolder.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxImportGraphHolder.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxImportGraphHolder.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxImportGraphHolder.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxProtobufExtensions.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxProtobufExtensions.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxProtobufExtensions.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxProtobufExtensions.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxRuleDeclarations.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxRuleDeclarations.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxRuleDeclarations.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/OnnxRuleDeclarations.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/context/OnnxMappingContext.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/context/OnnxMappingContext.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/context/OnnxMappingContext.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/context/OnnxMappingContext.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/definitions/OnnxOpDeclarations.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/definitions/OnnxOpDeclarations.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/definitions/OnnxOpDeclarations.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/definitions/OnnxOpDeclarations.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/importer/OnnxFrameworkImporter.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/importer/OnnxFrameworkImporter.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/importer/OnnxFrameworkImporter.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/importer/OnnxFrameworkImporter.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRArgDef.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRArgDef.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRArgDef.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRArgDef.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRAttr.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRAttr.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRAttr.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRAttr.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRDataType.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRDataType.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRDataType.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRDataType.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRGraph.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRGraph.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRGraph.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRGraph.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRGraphRunner.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRGraphRunner.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRGraphRunner.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRGraphRunner.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRNode.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRNode.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRNode.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRNode.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIROp.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIROp.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIROp.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIROp.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRTensor.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRTensor.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRTensor.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/ir/OnnxIRTensor.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/opdefs/OnnxOpDescriptorLoader.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/opdefs/OnnxOpDescriptorLoader.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/opdefs/OnnxOpDescriptorLoader.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/opdefs/OnnxOpDescriptorLoader.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/process/OnnxMappingProcess.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/process/OnnxMappingProcess.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/process/OnnxMappingProcess.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/process/OnnxMappingProcess.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/process/OnnxMappingProcessLoader.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/process/OnnxMappingProcessLoader.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/process/OnnxMappingProcessLoader.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/process/OnnxMappingProcessLoader.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxArgDescriptorConstant.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxArgDescriptorConstant.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxArgDescriptorConstant.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxArgDescriptorConstant.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxAttributeNDArrayToScalarAttribute.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxAttributeNDArrayToScalarAttribute.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxAttributeNDArrayToScalarAttribute.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxAttributeNDArrayToScalarAttribute.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxAttributeNumberListNDArray.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxAttributeNumberListNDArray.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxAttributeNumberListNDArray.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxAttributeNumberListNDArray.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxAttributeScalarNDArrayAttribute.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxAttributeScalarNDArrayAttribute.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxAttributeScalarNDArrayAttribute.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxAttributeScalarNDArrayAttribute.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxConditionalFieldValueIntIndexArrayRule.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxConditionalFieldValueIntIndexArrayRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxConditionalFieldValueIntIndexArrayRule.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxConditionalFieldValueIntIndexArrayRule.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxConditionalFieldValueIntIndexNDArrayRule.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxConditionalFieldValueIntIndexNDArrayRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxConditionalFieldValueIntIndexNDArrayRule.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxConditionalFieldValueIntIndexNDArrayRule.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxDataTypeToInt.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxDataTypeToInt.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxDataTypeToInt.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxDataTypeToInt.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxFlattenDims.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxFlattenDims.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxFlattenDims.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxFlattenDims.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxInvertBooleanNumber.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxInvertBooleanNumber.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxInvertBooleanNumber.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxInvertBooleanNumber.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxListAttributeValueLookupToIndex.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxListAttributeValueLookupToIndex.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxListAttributeValueLookupToIndex.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxListAttributeValueLookupToIndex.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxListNumberToListNumber.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxListNumberToListNumber.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxListNumberToListNumber.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxListNumberToListNumber.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxListNumberToNDArray.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxListNumberToNDArray.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxListNumberToNDArray.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxListNumberToNDArray.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxMapStringToInt.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxMapStringToInt.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxMapStringToInt.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxMapStringToInt.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayAttributeToNDArrayInput.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayAttributeToNDArrayInput.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayAttributeToNDArrayInput.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayAttributeToNDArrayInput.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayExtractScalarValue.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayExtractScalarValue.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayExtractScalarValue.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayExtractScalarValue.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayInputToNumericalAttribute.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayInputToNumericalAttribute.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayInputToNumericalAttribute.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayInputToNumericalAttribute.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArraySizeAt.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArraySizeAt.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArraySizeAt.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArraySizeAt.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayToIntAttributeValue.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayToIntAttributeValue.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayToIntAttributeValue.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxNDArrayToIntAttributeValue.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxSizeThresholdIntArrayIntIndexRule.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxSizeThresholdIntArrayIntIndexRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxSizeThresholdIntArrayIntIndexRule.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxSizeThresholdIntArrayIntIndexRule.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringAttributeToNDArray.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringAttributeToNDArray.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringAttributeToNDArray.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringAttributeToNDArray.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringContainsAdapterRule.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringContainsAdapterRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringContainsAdapterRule.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringContainsAdapterRule.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringEqualsAdapterRule.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringEqualsAdapterRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringEqualsAdapterRule.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringEqualsAdapterRule.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringNotEqualsAdapterRule.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringNotEqualsAdapterRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringNotEqualsAdapterRule.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringNotEqualsAdapterRule.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringToIndex.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringToIndex.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringToIndex.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxStringToIndex.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxValueMapping.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxValueMapping.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxValueMapping.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/attribute/OnnxValueMapping.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/tensor/NDArrayMappingRule.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/tensor/NDArrayMappingRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/tensor/NDArrayMappingRule.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/tensor/NDArrayMappingRule.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/tensor/OnnxMultiInputIndexMappingRule.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/tensor/OnnxMultiInputIndexMappingRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/tensor/OnnxMultiInputIndexMappingRule.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/tensor/OnnxMultiInputIndexMappingRule.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/tensor/OnnxPassThroughMultiInputTensorMapping.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/tensor/OnnxPassThroughMultiInputTensorMapping.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/tensor/OnnxPassThroughMultiInputTensorMapping.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/kotlin/org/nd4j/samediff/frameworkimport/onnx/rule/tensor/OnnxPassThroughMultiInputTensorMapping.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.ImportGraphHolder b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.ImportGraphHolder similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.ImportGraphHolder rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.ImportGraphHolder diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.opdefs.OpDescriptorLoader b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.opdefs.OpDescriptorLoader similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.opdefs.OpDescriptorLoader rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.opdefs.OpDescriptorLoader diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/resources/onnx-mapping-ruleset.pbtxt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/resources/onnx-mapping-ruleset.pbtxt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/resources/onnx-mapping-ruleset.pbtxt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/resources/onnx-mapping-ruleset.pbtxt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/resources/onnx-op-def.pbtxt b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/resources/onnx-op-def.pbtxt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/resources/onnx-op-def.pbtxt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/resources/onnx-op-def.pbtxt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/main/resources/onnx-op-defs.pb b/.old/nd4j/samediff-import/samediff-import-onnx/src/main/resources/onnx-op-defs.pb similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/main/resources/onnx-op-defs.pb rename to .old/nd4j/samediff-import/samediff-import-onnx/src/main/resources/onnx-op-defs.pb diff --git a/nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/TestOnnxIR.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/TestOnnxIR.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/TestOnnxIR.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/TestOnnxIR.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/importer/TestOnnxFrameworkImporter.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/importer/TestOnnxFrameworkImporter.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/importer/TestOnnxFrameworkImporter.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/importer/TestOnnxFrameworkImporter.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/loader/TestOnnxProcessLoader.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/loader/TestOnnxProcessLoader.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/loader/TestOnnxProcessLoader.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/loader/TestOnnxProcessLoader.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/modelzoo/TestPretrainedModels.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/modelzoo/TestPretrainedModels.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/modelzoo/TestPretrainedModels.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/modelzoo/TestPretrainedModels.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/processing/GroupConvPreProcessingRule.kt b/.old/nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/processing/GroupConvPreProcessingRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/processing/GroupConvPreProcessingRule.kt rename to .old/nd4j/samediff-import/samediff-import-onnx/src/test/kotlin/org/nd4j/samediff/frameworkimport/onnx/processing/GroupConvPreProcessingRule.kt diff --git a/nd4j/samediff-import/samediff-import-onnx/src/test/resources/lenet.onnx b/.old/nd4j/samediff-import/samediff-import-onnx/src/test/resources/lenet.onnx similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/src/test/resources/lenet.onnx rename to .old/nd4j/samediff-import/samediff-import-onnx/src/test/resources/lenet.onnx diff --git a/nd4j/samediff-import/samediff-import-onnx/variables-added-new.txt b/.old/nd4j/samediff-import/samediff-import-onnx/variables-added-new.txt similarity index 100% rename from nd4j/samediff-import/samediff-import-onnx/variables-added-new.txt rename to .old/nd4j/samediff-import/samediff-import-onnx/variables-added-new.txt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/00c6b5c8-c93c-4ac9-867f-580443a45bb3-container.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/00c6b5c8-c93c-4ac9-867f-580443a45bb3-container.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/00c6b5c8-c93c-4ac9-867f-580443a45bb3-container.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/00c6b5c8-c93c-4ac9-867f-580443a45bb3-container.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/03195bad-47a3-4de9-9fc7-6691ea41aee0-container.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/03195bad-47a3-4de9-9fc7-6691ea41aee0-container.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/03195bad-47a3-4de9-9fc7-6691ea41aee0-container.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/03195bad-47a3-4de9-9fc7-6691ea41aee0-container.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/04c57933-461b-4d6f-b6a8-a210cef103ff-result.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/04c57933-461b-4d6f-b6a8-a210cef103ff-result.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/04c57933-461b-4d6f-b6a8-a210cef103ff-result.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/04c57933-461b-4d6f-b6a8-a210cef103ff-result.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/0541722d-1de4-4e85-b844-d90d20eea9fb-result.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/0541722d-1de4-4e85-b844-d90d20eea9fb-result.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/0541722d-1de4-4e85-b844-d90d20eea9fb-result.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/0541722d-1de4-4e85-b844-d90d20eea9fb-result.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/154f67c7-64e1-4e2c-a56e-05d390b459d7-result.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/154f67c7-64e1-4e2c-a56e-05d390b459d7-result.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/154f67c7-64e1-4e2c-a56e-05d390b459d7-result.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/154f67c7-64e1-4e2c-a56e-05d390b459d7-result.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/2026534d-ef52-441c-976b-3ef06799a362-result.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/2026534d-ef52-441c-976b-3ef06799a362-result.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/2026534d-ef52-441c-976b-3ef06799a362-result.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/2026534d-ef52-441c-976b-3ef06799a362-result.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/22943ac9-56da-4b92-983d-7385c888c80b-container.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/22943ac9-56da-4b92-983d-7385c888c80b-container.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/22943ac9-56da-4b92-983d-7385c888c80b-container.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/22943ac9-56da-4b92-983d-7385c888c80b-container.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/281f7eda-053b-4dc9-a686-2040bb4f7fd3-container.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/281f7eda-053b-4dc9-a686-2040bb4f7fd3-container.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/281f7eda-053b-4dc9-a686-2040bb4f7fd3-container.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/281f7eda-053b-4dc9-a686-2040bb4f7fd3-container.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/2cfad6f7-cd22-4de1-80a6-b9890ce473fc-result.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/2cfad6f7-cd22-4de1-80a6-b9890ce473fc-result.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/2cfad6f7-cd22-4de1-80a6-b9890ce473fc-result.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/2cfad6f7-cd22-4de1-80a6-b9890ce473fc-result.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/36bc053b-ed9c-40b7-853c-d9462d2a67c0-container.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/36bc053b-ed9c-40b7-853c-d9462d2a67c0-container.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/36bc053b-ed9c-40b7-853c-d9462d2a67c0-container.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/36bc053b-ed9c-40b7-853c-d9462d2a67c0-container.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/445afe43-7f5f-4f5b-81db-e942139be1a7-result.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/445afe43-7f5f-4f5b-81db-e942139be1a7-result.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/445afe43-7f5f-4f5b-81db-e942139be1a7-result.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/445afe43-7f5f-4f5b-81db-e942139be1a7-result.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/505e442f-5f0d-4fe6-80ba-0628e9f3057b-container.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/505e442f-5f0d-4fe6-80ba-0628e9f3057b-container.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/505e442f-5f0d-4fe6-80ba-0628e9f3057b-container.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/505e442f-5f0d-4fe6-80ba-0628e9f3057b-container.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/52bec90b-a05a-4382-a2fc-0835d2da893a-container.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/52bec90b-a05a-4382-a2fc-0835d2da893a-container.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/52bec90b-a05a-4382-a2fc-0835d2da893a-container.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/52bec90b-a05a-4382-a2fc-0835d2da893a-container.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/58aad3d2-4a46-47d3-9748-578e7aae7121-result.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/58aad3d2-4a46-47d3-9748-578e7aae7121-result.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/58aad3d2-4a46-47d3-9748-578e7aae7121-result.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/58aad3d2-4a46-47d3-9748-578e7aae7121-result.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/5b55351d-1e98-4c83-b1ec-0812d352141d-result.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/5b55351d-1e98-4c83-b1ec-0812d352141d-result.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/5b55351d-1e98-4c83-b1ec-0812d352141d-result.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/5b55351d-1e98-4c83-b1ec-0812d352141d-result.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/629659e3-ed5c-482a-89cf-0b4f46026b31-result.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/629659e3-ed5c-482a-89cf-0b4f46026b31-result.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/629659e3-ed5c-482a-89cf-0b4f46026b31-result.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/629659e3-ed5c-482a-89cf-0b4f46026b31-result.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/6b35dfd9-1d25-419e-a196-4a42f20fd8aa-result.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/6b35dfd9-1d25-419e-a196-4a42f20fd8aa-result.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/6b35dfd9-1d25-419e-a196-4a42f20fd8aa-result.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/6b35dfd9-1d25-419e-a196-4a42f20fd8aa-result.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/6f446d7c-ec8d-4567-9f3a-3b9bcb3d21f8-result.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/6f446d7c-ec8d-4567-9f3a-3b9bcb3d21f8-result.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/6f446d7c-ec8d-4567-9f3a-3b9bcb3d21f8-result.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/6f446d7c-ec8d-4567-9f3a-3b9bcb3d21f8-result.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/75db525b-2344-4dcc-a3d9-d23b5acbfe81-container.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/75db525b-2344-4dcc-a3d9-d23b5acbfe81-container.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/75db525b-2344-4dcc-a3d9-d23b5acbfe81-container.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/75db525b-2344-4dcc-a3d9-d23b5acbfe81-container.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/767f4fe3-b7a8-492b-b0ab-ae77f112e105-result.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/767f4fe3-b7a8-492b-b0ab-ae77f112e105-result.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/767f4fe3-b7a8-492b-b0ab-ae77f112e105-result.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/767f4fe3-b7a8-492b-b0ab-ae77f112e105-result.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/7b58c709-b0e3-446f-9e05-4fd86f350b83-container.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/7b58c709-b0e3-446f-9e05-4fd86f350b83-container.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/7b58c709-b0e3-446f-9e05-4fd86f350b83-container.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/7b58c709-b0e3-446f-9e05-4fd86f350b83-container.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/7ce20a5d-8b63-499e-9dc4-0206d0c38b29-container.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/7ce20a5d-8b63-499e-9dc4-0206d0c38b29-container.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/7ce20a5d-8b63-499e-9dc4-0206d0c38b29-container.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/7ce20a5d-8b63-499e-9dc4-0206d0c38b29-container.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/8b28bcc6-1a38-4b55-bc80-185feab4c978-container.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/8b28bcc6-1a38-4b55-bc80-185feab4c978-container.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/8b28bcc6-1a38-4b55-bc80-185feab4c978-container.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/8b28bcc6-1a38-4b55-bc80-185feab4c978-container.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/9d55689b-05d2-4692-ad17-af4aa388cb31-container.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/9d55689b-05d2-4692-ad17-af4aa388cb31-container.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/9d55689b-05d2-4692-ad17-af4aa388cb31-container.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/9d55689b-05d2-4692-ad17-af4aa388cb31-container.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/9f6c1a25-9c6a-40b1-b825-916525e2cb24-result.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/9f6c1a25-9c6a-40b1-b825-916525e2cb24-result.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/9f6c1a25-9c6a-40b1-b825-916525e2cb24-result.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/9f6c1a25-9c6a-40b1-b825-916525e2cb24-result.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/a2400879-a732-411c-a65e-00111c6b550e-container.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/a2400879-a732-411c-a65e-00111c6b550e-container.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/a2400879-a732-411c-a65e-00111c6b550e-container.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/a2400879-a732-411c-a65e-00111c6b550e-container.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/a24baaa5-1cb5-4edd-873b-c923d04905ec-container.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/a24baaa5-1cb5-4edd-873b-c923d04905ec-container.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/a24baaa5-1cb5-4edd-873b-c923d04905ec-container.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/a24baaa5-1cb5-4edd-873b-c923d04905ec-container.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/b3b58b3b-9a41-44aa-9b00-2bb9633a53be-container.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/b3b58b3b-9a41-44aa-9b00-2bb9633a53be-container.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/b3b58b3b-9a41-44aa-9b00-2bb9633a53be-container.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/b3b58b3b-9a41-44aa-9b00-2bb9633a53be-container.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/c0f861a5-c322-458b-82e9-efd5494d37fc-container.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/c0f861a5-c322-458b-82e9-efd5494d37fc-container.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/c0f861a5-c322-458b-82e9-efd5494d37fc-container.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/c0f861a5-c322-458b-82e9-efd5494d37fc-container.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/ca8a7a37-5ce9-4970-aa3d-7eaec8c8091a-result.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/ca8a7a37-5ce9-4970-aa3d-7eaec8c8091a-result.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/ca8a7a37-5ce9-4970-aa3d-7eaec8c8091a-result.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/ca8a7a37-5ce9-4970-aa3d-7eaec8c8091a-result.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/e25409f2-aa78-4897-a810-297802cccdfc-container.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/e25409f2-aa78-4897-a810-297802cccdfc-container.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/e25409f2-aa78-4897-a810-297802cccdfc-container.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/e25409f2-aa78-4897-a810-297802cccdfc-container.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/e82fe95c-6cd2-4a8d-82c7-9f45d15e8a73-container.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/e82fe95c-6cd2-4a8d-82c7-9f45d15e8a73-container.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/e82fe95c-6cd2-4a8d-82c7-9f45d15e8a73-container.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/e82fe95c-6cd2-4a8d-82c7-9f45d15e8a73-container.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/eb70b069-8c1d-440c-a135-174d7b873d11-result.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/eb70b069-8c1d-440c-a135-174d7b873d11-result.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/eb70b069-8c1d-440c-a135-174d7b873d11-result.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/eb70b069-8c1d-440c-a135-174d7b873d11-result.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/allure-results/ef515f16-0d58-450b-85bb-ec61080f012f-result.json b/.old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/ef515f16-0d58-450b-85bb-ec61080f012f-result.json similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/allure-results/ef515f16-0d58-450b-85bb-ec61080f012f-result.json rename to .old/nd4j/samediff-import/samediff-import-tensorflow/allure-results/ef515f16-0d58-450b-85bb-ec61080f012f-result.json diff --git a/nd4j/samediff-import/samediff-import-tensorflow/nd4j-op-def.pbtxt b/.old/nd4j/samediff-import/samediff-import-tensorflow/nd4j-op-def.pbtxt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/nd4j-op-def.pbtxt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/nd4j-op-def.pbtxt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/ops-added-new.txt b/.old/nd4j/samediff-import/samediff-import-tensorflow/ops-added-new.txt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/ops-added-new.txt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/ops-added-new.txt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/ops-added-old.txt b/.old/nd4j/samediff-import/samediff-import-tensorflow/ops-added-old.txt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/ops-added-old.txt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/ops-added-old.txt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/ops-imported-new.txt b/.old/nd4j/samediff-import/samediff-import-tensorflow/ops-imported-new.txt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/ops-imported-new.txt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/ops-imported-new.txt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/ops-imported-old.txt b/.old/nd4j/samediff-import/samediff-import-tensorflow/ops-imported-old.txt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/ops-imported-old.txt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/ops-imported-old.txt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/ops-removed-new.txt b/.old/nd4j/samediff-import/samediff-import-tensorflow/ops-removed-new.txt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/ops-removed-new.txt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/ops-removed-new.txt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/ops-removed-old.txt b/.old/nd4j/samediff-import/samediff-import-tensorflow/ops-removed-old.txt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/ops-removed-old.txt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/ops-removed-old.txt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/pom.xml b/.old/nd4j/samediff-import/samediff-import-tensorflow/pom.xml similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/pom.xml rename to .old/nd4j/samediff-import/samediff-import-tensorflow/pom.xml diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowImportGraph.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowImportGraph.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowImportGraph.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowImportGraph.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowImportGraphHolder.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowImportGraphHolder.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowImportGraphHolder.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowImportGraphHolder.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowProtobufExtensions.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowProtobufExtensions.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowProtobufExtensions.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowProtobufExtensions.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowRuleDeclarations.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowRuleDeclarations.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowRuleDeclarations.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TensorflowRuleDeclarations.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/context/TensorflowMappingContext.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/context/TensorflowMappingContext.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/context/TensorflowMappingContext.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/context/TensorflowMappingContext.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/definitions/TensorflowOpDeclarations.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/definitions/TensorflowOpDeclarations.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/definitions/TensorflowOpDeclarations.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/definitions/TensorflowOpDeclarations.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/importer/TensorflowFrameworkImporter.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/importer/TensorflowFrameworkImporter.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/importer/TensorflowFrameworkImporter.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/importer/TensorflowFrameworkImporter.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIR.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIR.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIR.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIR.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRArgDef.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRArgDef.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRArgDef.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRArgDef.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRAttr.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRAttr.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRAttr.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRAttr.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRDataType.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRDataType.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRDataType.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRDataType.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRGraph.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRGraph.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRGraph.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRGraph.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRGraphRunner.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRGraphRunner.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRGraphRunner.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRGraphRunner.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRNode.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRNode.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRNode.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRNode.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIROp.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIROp.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIROp.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIROp.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRTensor.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRTensor.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRTensor.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/ir/TensorflowIRTensor.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/opdefs/TensorflowOpDescriptorLoader.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/opdefs/TensorflowOpDescriptorLoader.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/opdefs/TensorflowOpDescriptorLoader.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/opdefs/TensorflowOpDescriptorLoader.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/process/TensorflowMappingProcess.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/process/TensorflowMappingProcess.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/process/TensorflowMappingProcess.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/process/TensorflowMappingProcess.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/process/TensorflowMappingProcessLoader.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/process/TensorflowMappingProcessLoader.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/process/TensorflowMappingProcessLoader.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/process/TensorflowMappingProcessLoader.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowArgDescriptorConstant.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowArgDescriptorConstant.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowArgDescriptorConstant.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowArgDescriptorConstant.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowAttributeNDArrayToScalarAttribute.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowAttributeNDArrayToScalarAttribute.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowAttributeNDArrayToScalarAttribute.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowAttributeNDArrayToScalarAttribute.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowAttributeNumberListNDArray.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowAttributeNumberListNDArray.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowAttributeNumberListNDArray.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowAttributeNumberListNDArray.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowAttributeScalarNDArrayAttribute.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowAttributeScalarNDArrayAttribute.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowAttributeScalarNDArrayAttribute.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowAttributeScalarNDArrayAttribute.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowConditionalFieldValueIntIndexArrayRule.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowConditionalFieldValueIntIndexArrayRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowConditionalFieldValueIntIndexArrayRule.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowConditionalFieldValueIntIndexArrayRule.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowConditionalFieldValueIntIndexNDArrayRule.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowConditionalFieldValueIntIndexNDArrayRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowConditionalFieldValueIntIndexNDArrayRule.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowConditionalFieldValueIntIndexNDArrayRule.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowDataTypeToInt.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowDataTypeToInt.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowDataTypeToInt.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowDataTypeToInt.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowFlattenDims.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowFlattenDims.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowFlattenDims.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowFlattenDims.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowInvertBooleanNumber.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowInvertBooleanNumber.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowInvertBooleanNumber.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowInvertBooleanNumber.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowListAttributeValueLookupToIndex.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowListAttributeValueLookupToIndex.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowListAttributeValueLookupToIndex.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowListAttributeValueLookupToIndex.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowListNumberToListNumber.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowListNumberToListNumber.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowListNumberToListNumber.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowListNumberToListNumber.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowListNumberToNDArray.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowListNumberToNDArray.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowListNumberToNDArray.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowListNumberToNDArray.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowMapStringToInt.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowMapStringToInt.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowMapStringToInt.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowMapStringToInt.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayAttributeToNDArrayInput.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayAttributeToNDArrayInput.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayAttributeToNDArrayInput.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayAttributeToNDArrayInput.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayExtractScalarValue.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayExtractScalarValue.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayExtractScalarValue.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayExtractScalarValue.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayInputToNumericalAttribute.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayInputToNumericalAttribute.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayInputToNumericalAttribute.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayInputToNumericalAttribute.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArraySizeAt.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArraySizeAt.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArraySizeAt.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArraySizeAt.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayToIntAttributeValue.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayToIntAttributeValue.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayToIntAttributeValue.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNDArrayToIntAttributeValue.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNdArrayToStringIndex.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNdArrayToStringIndex.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNdArrayToStringIndex.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowNdArrayToStringIndex.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringAttributeToNDArray.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringAttributeToNDArray.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringAttributeToNDArray.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringAttributeToNDArray.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringContainsAdapterRule.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringContainsAdapterRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringContainsAdapterRule.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringContainsAdapterRule.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringEqualsAdapterRule.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringEqualsAdapterRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringEqualsAdapterRule.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringEqualsAdapterRule.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringNotEqualsAdapterRule.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringNotEqualsAdapterRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringNotEqualsAdapterRule.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowStringNotEqualsAdapterRule.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowValueMappingRule.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowValueMappingRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowValueMappingRule.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/attribute/TensorflowValueMappingRule.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/tensor/NDArrayMappingRule.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/tensor/NDArrayMappingRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/tensor/NDArrayMappingRule.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/tensor/NDArrayMappingRule.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/tensor/TensorflowMultiInputIndexMappingRule.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/tensor/TensorflowMultiInputIndexMappingRule.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/tensor/TensorflowMultiInputIndexMappingRule.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/tensor/TensorflowMultiInputIndexMappingRule.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/tensor/TensorflowPassThroughMultiTensorMapping.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/tensor/TensorflowPassThroughMultiTensorMapping.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/tensor/TensorflowPassThroughMultiTensorMapping.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/rule/tensor/TensorflowPassThroughMultiTensorMapping.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.ImportGraphHolder b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.ImportGraphHolder similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.ImportGraphHolder rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.ImportGraphHolder diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.opdefs.OpDescriptorLoader b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.opdefs.OpDescriptorLoader similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.opdefs.OpDescriptorLoader rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/resources/META-INF/services/org.nd4j.samediff.frameworkimport.opdefs.OpDescriptorLoader diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/resources/tensorflow-mapping-ruleset.pbtxt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/resources/tensorflow-mapping-ruleset.pbtxt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/resources/tensorflow-mapping-ruleset.pbtxt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/resources/tensorflow-mapping-ruleset.pbtxt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/main/resources/tensorflow-op-def.pbtxt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/main/resources/tensorflow-op-def.pbtxt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/main/resources/tensorflow-op-def.pbtxt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/main/resources/tensorflow-op-def.pbtxt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TestTensorflowIR.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TestTensorflowIR.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TestTensorflowIR.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TestTensorflowIR.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TestTensorflowUtils.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TestTensorflowUtils.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TestTensorflowUtils.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/TestTensorflowUtils.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/importer/TestTensorflowImporter.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/importer/TestTensorflowImporter.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/importer/TestTensorflowImporter.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/importer/TestTensorflowImporter.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/loader/TestTensorflowProcessLoader.kt b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/loader/TestTensorflowProcessLoader.kt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/loader/TestTensorflowProcessLoader.kt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/test/kotlin/org/nd4j/samediff/frameworkimport/tensorflow/loader/TestTensorflowProcessLoader.kt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/test/resources/lenet_frozen.pb b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/test/resources/lenet_frozen.pb similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/test/resources/lenet_frozen.pb rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/test/resources/lenet_frozen.pb diff --git a/nd4j/samediff-import/samediff-import-tensorflow/src/test/resources/logback.xml b/.old/nd4j/samediff-import/samediff-import-tensorflow/src/test/resources/logback.xml similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/src/test/resources/logback.xml rename to .old/nd4j/samediff-import/samediff-import-tensorflow/src/test/resources/logback.xml diff --git a/nd4j/samediff-import/samediff-import-tensorflow/tensorflow-processes.pbtxt b/.old/nd4j/samediff-import/samediff-import-tensorflow/tensorflow-processes.pbtxt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/tensorflow-processes.pbtxt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/tensorflow-processes.pbtxt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/test.pbtxt b/.old/nd4j/samediff-import/samediff-import-tensorflow/test.pbtxt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/test.pbtxt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/test.pbtxt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/variables-added-new.txt b/.old/nd4j/samediff-import/samediff-import-tensorflow/variables-added-new.txt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/variables-added-new.txt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/variables-added-new.txt diff --git a/nd4j/samediff-import/samediff-import-tensorflow/variables-added-old.txt b/.old/nd4j/samediff-import/samediff-import-tensorflow/variables-added-old.txt similarity index 100% rename from nd4j/samediff-import/samediff-import-tensorflow/variables-added-old.txt rename to .old/nd4j/samediff-import/samediff-import-tensorflow/variables-added-old.txt diff --git a/perform-release.sh b/.old/perform-release.sh similarity index 100% rename from perform-release.sh rename to .old/perform-release.sh diff --git a/pydatavec/.eggs/README.txt b/.old/pydatavec/.eggs/README.txt similarity index 100% rename from pydatavec/.eggs/README.txt rename to .old/pydatavec/.eggs/README.txt diff --git a/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/LICENSE b/.old/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/LICENSE similarity index 100% rename from pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/LICENSE rename to .old/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/LICENSE diff --git a/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/PKG-INFO b/.old/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/PKG-INFO similarity index 100% rename from pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/PKG-INFO rename to .old/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/PKG-INFO diff --git a/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/RECORD b/.old/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/RECORD similarity index 100% rename from pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/RECORD rename to .old/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/RECORD diff --git a/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/WHEEL b/.old/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/WHEEL similarity index 100% rename from pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/WHEEL rename to .old/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/WHEEL diff --git a/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/entry_points.txt b/.old/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/entry_points.txt similarity index 100% rename from pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/entry_points.txt rename to .old/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/entry_points.txt diff --git a/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/requires.txt b/.old/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/requires.txt similarity index 100% rename from pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/requires.txt rename to .old/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/requires.txt diff --git a/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/top_level.txt b/.old/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/top_level.txt similarity index 100% rename from pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/top_level.txt rename to .old/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/EGG-INFO/top_level.txt diff --git a/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/ptr.py b/.old/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/ptr.py similarity index 100% rename from pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/ptr.py rename to .old/pydatavec/.eggs/pytest_runner-5.2-py3.8.egg/ptr.py diff --git a/pydatavec/pydatavec.egg-info/PKG-INFO b/.old/pydatavec/pydatavec.egg-info/PKG-INFO similarity index 100% rename from pydatavec/pydatavec.egg-info/PKG-INFO rename to .old/pydatavec/pydatavec.egg-info/PKG-INFO diff --git a/pydatavec/pydatavec.egg-info/SOURCES.txt b/.old/pydatavec/pydatavec.egg-info/SOURCES.txt similarity index 100% rename from pydatavec/pydatavec.egg-info/SOURCES.txt rename to .old/pydatavec/pydatavec.egg-info/SOURCES.txt diff --git a/pydatavec/pydatavec.egg-info/dependency_links.txt b/.old/pydatavec/pydatavec.egg-info/dependency_links.txt similarity index 100% rename from pydatavec/pydatavec.egg-info/dependency_links.txt rename to .old/pydatavec/pydatavec.egg-info/dependency_links.txt diff --git a/pydatavec/pydatavec.egg-info/requires.txt b/.old/pydatavec/pydatavec.egg-info/requires.txt similarity index 100% rename from pydatavec/pydatavec.egg-info/requires.txt rename to .old/pydatavec/pydatavec.egg-info/requires.txt diff --git a/pydatavec/pydatavec.egg-info/top_level.txt b/.old/pydatavec/pydatavec.egg-info/top_level.txt similarity index 100% rename from pydatavec/pydatavec.egg-info/top_level.txt rename to .old/pydatavec/pydatavec.egg-info/top_level.txt diff --git a/rl4j/README.md b/.old/rl4j/README.md similarity index 100% rename from rl4j/README.md rename to .old/rl4j/README.md diff --git a/rl4j/docs/images/cartpole.gif b/.old/rl4j/docs/images/cartpole.gif similarity index 100% rename from rl4j/docs/images/cartpole.gif rename to .old/rl4j/docs/images/cartpole.gif diff --git a/rl4j/docs/images/doom.gif b/.old/rl4j/docs/images/doom.gif similarity index 100% rename from rl4j/docs/images/doom.gif rename to .old/rl4j/docs/images/doom.gif diff --git a/rl4j/docs/images/malmo.gif b/.old/rl4j/docs/images/malmo.gif similarity index 100% rename from rl4j/docs/images/malmo.gif rename to .old/rl4j/docs/images/malmo.gif diff --git a/rl4j/pom.xml b/.old/rl4j/pom.xml similarity index 100% rename from rl4j/pom.xml rename to .old/rl4j/pom.xml diff --git a/rl4j/rl4j-ale/pom.xml b/.old/rl4j/rl4j-ale/pom.xml similarity index 100% rename from rl4j/rl4j-ale/pom.xml rename to .old/rl4j/rl4j-ale/pom.xml diff --git a/rl4j/rl4j-ale/src/main/java/org/deeplearning4j/rl4j/mdp/ale/ALEMDP.java b/.old/rl4j/rl4j-ale/src/main/java/org/deeplearning4j/rl4j/mdp/ale/ALEMDP.java similarity index 100% rename from rl4j/rl4j-ale/src/main/java/org/deeplearning4j/rl4j/mdp/ale/ALEMDP.java rename to .old/rl4j/rl4j-ale/src/main/java/org/deeplearning4j/rl4j/mdp/ale/ALEMDP.java diff --git a/rl4j/rl4j-api/pom.xml b/.old/rl4j/rl4j-api/pom.xml similarity index 100% rename from rl4j/rl4j-api/pom.xml rename to .old/rl4j/rl4j-api/pom.xml diff --git a/rl4j/rl4j-api/src/main/java/org/deeplearning4j/gym/StepReply.java b/.old/rl4j/rl4j-api/src/main/java/org/deeplearning4j/gym/StepReply.java similarity index 100% rename from rl4j/rl4j-api/src/main/java/org/deeplearning4j/gym/StepReply.java rename to .old/rl4j/rl4j-api/src/main/java/org/deeplearning4j/gym/StepReply.java diff --git a/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/mdp/MDP.java b/.old/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/mdp/MDP.java similarity index 100% rename from rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/mdp/MDP.java rename to .old/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/mdp/MDP.java diff --git a/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/ActionSpace.java b/.old/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/ActionSpace.java similarity index 100% rename from rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/ActionSpace.java rename to .old/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/ActionSpace.java diff --git a/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/ArrayObservationSpace.java b/.old/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/ArrayObservationSpace.java similarity index 100% rename from rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/ArrayObservationSpace.java rename to .old/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/ArrayObservationSpace.java diff --git a/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/Box.java b/.old/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/Box.java similarity index 100% rename from rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/Box.java rename to .old/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/Box.java diff --git a/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/DiscreteSpace.java b/.old/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/DiscreteSpace.java similarity index 100% rename from rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/DiscreteSpace.java rename to .old/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/DiscreteSpace.java diff --git a/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/Encodable.java b/.old/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/Encodable.java similarity index 100% rename from rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/Encodable.java rename to .old/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/Encodable.java diff --git a/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/HighLowDiscrete.java b/.old/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/HighLowDiscrete.java similarity index 100% rename from rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/HighLowDiscrete.java rename to .old/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/HighLowDiscrete.java diff --git a/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/ObservationSpace.java b/.old/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/ObservationSpace.java similarity index 100% rename from rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/ObservationSpace.java rename to .old/rl4j/rl4j-api/src/main/java/org/deeplearning4j/rl4j/space/ObservationSpace.java diff --git a/rl4j/rl4j-core/nd4j-native.properties b/.old/rl4j/rl4j-core/nd4j-native.properties similarity index 100% rename from rl4j/rl4j-core/nd4j-native.properties rename to .old/rl4j/rl4j-core/nd4j-native.properties diff --git a/rl4j/rl4j-core/pom.xml b/.old/rl4j/rl4j-core/pom.xml similarity index 100% rename from rl4j/rl4j-core/pom.xml rename to .old/rl4j/rl4j-core/pom.xml diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/Agent.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/Agent.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/Agent.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/Agent.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/AgentLearner.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/AgentLearner.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/AgentLearner.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/AgentLearner.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/IAgent.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/IAgent.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/IAgent.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/IAgent.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/IAgentLearner.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/IAgentLearner.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/IAgentLearner.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/IAgentLearner.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/IUpdateAlgorithm.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/IUpdateAlgorithm.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/IUpdateAlgorithm.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/IUpdateAlgorithm.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/ActorCriticHelper.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/ActorCriticHelper.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/ActorCriticHelper.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/ActorCriticHelper.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/AdvantageActorCritic.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/AdvantageActorCritic.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/AdvantageActorCritic.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/AdvantageActorCritic.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentActorCriticHelper.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentActorCriticHelper.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentActorCriticHelper.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentActorCriticHelper.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentActorCriticHelper.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentActorCriticHelper.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentActorCriticHelper.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentActorCriticHelper.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/BaseDQNAlgorithm.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/BaseDQNAlgorithm.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/BaseDQNAlgorithm.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/BaseDQNAlgorithm.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/BaseTransitionTDAlgorithm.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/BaseTransitionTDAlgorithm.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/BaseTransitionTDAlgorithm.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/BaseTransitionTDAlgorithm.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/DoubleDQN.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/DoubleDQN.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/DoubleDQN.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/DoubleDQN.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/StandardDQN.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/StandardDQN.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/StandardDQN.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/StandardDQN.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NStepQLearning.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NStepQLearning.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NStepQLearning.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NStepQLearning.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NStepQLearningHelper.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NStepQLearningHelper.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NStepQLearningHelper.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NStepQLearningHelper.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningHelper.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningHelper.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningHelper.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningHelper.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningHelper.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningHelper.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningHelper.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningHelper.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/behavior/ILearningBehavior.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/behavior/ILearningBehavior.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/behavior/ILearningBehavior.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/behavior/ILearningBehavior.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/behavior/LearningBehavior.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/behavior/LearningBehavior.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/behavior/LearningBehavior.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/behavior/LearningBehavior.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/Features.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/Features.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/Features.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/Features.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesBuilder.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesBuilder.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesBuilder.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesBuilder.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesLabels.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesLabels.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesLabels.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesLabels.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/Gradients.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/Gradients.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/Gradients.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/Gradients.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/IUpdateRule.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/IUpdateRule.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/IUpdateRule.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/IUpdateRule.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/UpdateRule.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/UpdateRule.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/UpdateRule.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/UpdateRule.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/INeuralNetUpdater.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/INeuralNetUpdater.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/INeuralNetUpdater.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/INeuralNetUpdater.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/NeuralNetUpdaterConfiguration.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/NeuralNetUpdaterConfiguration.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/NeuralNetUpdaterConfiguration.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/NeuralNetUpdaterConfiguration.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncGradientsNeuralNetUpdater.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncGradientsNeuralNetUpdater.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncGradientsNeuralNetUpdater.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncGradientsNeuralNetUpdater.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncLabelsNeuralNetUpdater.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncLabelsNeuralNetUpdater.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncLabelsNeuralNetUpdater.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncLabelsNeuralNetUpdater.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncSharedNetworksUpdateHandler.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncSharedNetworksUpdateHandler.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncSharedNetworksUpdateHandler.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncSharedNetworksUpdateHandler.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/BaseAsyncNeuralNetUpdater.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/BaseAsyncNeuralNetUpdater.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/BaseAsyncNeuralNetUpdater.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/BaseAsyncNeuralNetUpdater.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/BaseSyncNeuralNetUpdater.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/BaseSyncNeuralNetUpdater.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/BaseSyncNeuralNetUpdater.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/BaseSyncNeuralNetUpdater.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncGradientsNeuralNetUpdater.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncGradientsNeuralNetUpdater.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncGradientsNeuralNetUpdater.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncGradientsNeuralNetUpdater.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncLabelsNeuralNetUpdater.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncLabelsNeuralNetUpdater.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncLabelsNeuralNetUpdater.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncLabelsNeuralNetUpdater.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/listener/AgentListener.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/listener/AgentListener.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/listener/AgentListener.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/listener/AgentListener.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/listener/AgentListenerList.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/listener/AgentListenerList.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/listener/AgentListenerList.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/agent/listener/AgentListenerList.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/AdvantageActorCriticBuilder.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/AdvantageActorCriticBuilder.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/AdvantageActorCriticBuilder.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/AdvantageActorCriticBuilder.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/AsyncNetworkHandler.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/AsyncNetworkHandler.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/AsyncNetworkHandler.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/AsyncNetworkHandler.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/BaseAgentLearnerBuilder.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/BaseAgentLearnerBuilder.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/BaseAgentLearnerBuilder.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/BaseAgentLearnerBuilder.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/BaseAsyncAgentLearnerBuilder.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/BaseAsyncAgentLearnerBuilder.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/BaseAsyncAgentLearnerBuilder.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/BaseAsyncAgentLearnerBuilder.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/BaseDQNAgentLearnerBuilder.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/BaseDQNAgentLearnerBuilder.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/BaseDQNAgentLearnerBuilder.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/BaseDQNAgentLearnerBuilder.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/DoubleDQNBuilder.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/DoubleDQNBuilder.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/DoubleDQNBuilder.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/DoubleDQNBuilder.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/INetworksHandler.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/INetworksHandler.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/INetworksHandler.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/INetworksHandler.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/NStepQLearningBuilder.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/NStepQLearningBuilder.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/NStepQLearningBuilder.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/NStepQLearningBuilder.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/StandardDQNBuilder.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/StandardDQNBuilder.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/StandardDQNBuilder.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/StandardDQNBuilder.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/SyncNetworkHandler.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/SyncNetworkHandler.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/SyncNetworkHandler.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/builder/SyncNetworkHandler.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/Environment.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/Environment.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/Environment.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/Environment.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/IActionSchema.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/IActionSchema.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/IActionSchema.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/IActionSchema.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/IntegerActionSchema.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/IntegerActionSchema.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/IntegerActionSchema.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/IntegerActionSchema.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/Schema.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/Schema.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/Schema.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/Schema.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/StepResult.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/StepResult.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/StepResult.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/environment/StepResult.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/ExperienceHandler.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/ExperienceHandler.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/ExperienceHandler.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/ExperienceHandler.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/ReplayMemoryExperienceHandler.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/ReplayMemoryExperienceHandler.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/ReplayMemoryExperienceHandler.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/ReplayMemoryExperienceHandler.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/StateActionExperienceHandler.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/StateActionExperienceHandler.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/StateActionExperienceHandler.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/StateActionExperienceHandler.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/StateActionReward.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/StateActionReward.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/StateActionReward.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/StateActionReward.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/StateActionRewardState.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/StateActionRewardState.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/StateActionRewardState.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/experience/StateActionRewardState.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/helper/INDArrayHelper.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/helper/INDArrayHelper.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/helper/INDArrayHelper.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/helper/INDArrayHelper.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/HistoryProcessor.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/HistoryProcessor.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/HistoryProcessor.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/HistoryProcessor.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/IEpochTrainer.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/IEpochTrainer.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/IEpochTrainer.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/IEpochTrainer.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/IHistoryProcessor.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/IHistoryProcessor.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/IHistoryProcessor.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/IHistoryProcessor.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/ILearning.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/ILearning.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/ILearning.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/ILearning.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/Learning.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/Learning.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/Learning.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/Learning.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/NeuralNetFetchable.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/NeuralNetFetchable.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/NeuralNetFetchable.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/NeuralNetFetchable.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncGlobal.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncGlobal.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncGlobal.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncGlobal.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncLearning.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncLearning.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncLearning.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncLearning.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncThread.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncThread.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncThread.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncThread.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncThreadDiscrete.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncThreadDiscrete.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncThreadDiscrete.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/AsyncThreadDiscrete.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/IAsyncGlobal.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/IAsyncGlobal.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/IAsyncGlobal.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/IAsyncGlobal.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/IAsyncLearning.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/IAsyncLearning.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/IAsyncLearning.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/IAsyncLearning.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/UpdateAlgorithm.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/UpdateAlgorithm.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/UpdateAlgorithm.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/UpdateAlgorithm.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CDiscrete.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CDiscrete.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CDiscrete.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CDiscrete.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CDiscreteConv.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CDiscreteConv.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CDiscreteConv.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CDiscreteConv.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CDiscreteDense.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CDiscreteDense.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CDiscreteDense.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CDiscreteDense.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CThreadDiscrete.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CThreadDiscrete.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CThreadDiscrete.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/A3CThreadDiscrete.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/AdvantageActorCriticUpdateAlgorithm.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/AdvantageActorCriticUpdateAlgorithm.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/AdvantageActorCriticUpdateAlgorithm.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/AdvantageActorCriticUpdateAlgorithm.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningDiscrete.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningDiscrete.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningDiscrete.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningDiscrete.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningDiscreteConv.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningDiscreteConv.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningDiscreteConv.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningDiscreteConv.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningDiscreteDense.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningDiscreteDense.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningDiscreteDense.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningDiscreteDense.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningThreadDiscrete.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningThreadDiscrete.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningThreadDiscrete.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/AsyncNStepQLearningThreadDiscrete.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/QLearningUpdateAlgorithm.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/QLearningUpdateAlgorithm.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/QLearningUpdateAlgorithm.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/QLearningUpdateAlgorithm.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/A3CLearningConfiguration.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/A3CLearningConfiguration.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/A3CLearningConfiguration.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/A3CLearningConfiguration.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/AsyncQLearningConfiguration.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/AsyncQLearningConfiguration.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/AsyncQLearningConfiguration.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/AsyncQLearningConfiguration.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/IAsyncLearningConfiguration.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/IAsyncLearningConfiguration.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/IAsyncLearningConfiguration.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/IAsyncLearningConfiguration.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/ILearningConfiguration.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/ILearningConfiguration.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/ILearningConfiguration.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/ILearningConfiguration.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/LearningConfiguration.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/LearningConfiguration.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/LearningConfiguration.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/LearningConfiguration.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/QLearningConfiguration.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/QLearningConfiguration.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/QLearningConfiguration.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/configuration/QLearningConfiguration.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/listener/TrainingListener.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/listener/TrainingListener.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/listener/TrainingListener.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/listener/TrainingListener.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/listener/TrainingListenerList.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/listener/TrainingListenerList.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/listener/TrainingListenerList.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/listener/TrainingListenerList.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/ExpReplay.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/ExpReplay.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/ExpReplay.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/ExpReplay.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/IExpReplay.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/IExpReplay.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/IExpReplay.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/IExpReplay.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/SyncLearning.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/SyncLearning.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/SyncLearning.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/SyncLearning.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/QLearning.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/QLearning.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/QLearning.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/QLearning.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscrete.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscrete.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscrete.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscrete.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscreteConv.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscreteConv.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscreteConv.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscreteConv.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscreteDense.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscreteDense.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscreteDense.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscreteDense.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/CartpoleEnvironment.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/CartpoleEnvironment.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/CartpoleEnvironment.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/CartpoleEnvironment.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/CartpoleNative.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/CartpoleNative.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/CartpoleNative.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/CartpoleNative.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/DoAsISayOrDont.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/DoAsISayOrDont.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/DoAsISayOrDont.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/DoAsISayOrDont.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/TMazeEnvironment.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/TMazeEnvironment.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/TMazeEnvironment.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/TMazeEnvironment.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLake.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLake.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLake.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLake.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLakeHelper.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLakeHelper.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLakeHelper.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLakeHelper.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLakeMap.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLakeMap.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLakeMap.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLakeMap.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLakeState.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLakeState.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLakeState.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/robotlake/RobotLakeState.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/HardDeteministicToy.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/HardDeteministicToy.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/HardDeteministicToy.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/HardDeteministicToy.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/HardToyState.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/HardToyState.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/HardToyState.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/HardToyState.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/SimpleToy.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/SimpleToy.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/SimpleToy.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/SimpleToy.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/SimpleToyState.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/SimpleToyState.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/SimpleToyState.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/mdp/toy/SimpleToyState.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ActorCriticNetwork.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ActorCriticNetwork.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ActorCriticNetwork.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ActorCriticNetwork.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/BaseNetwork.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/BaseNetwork.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/BaseNetwork.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/BaseNetwork.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ChannelToNetworkInputMapper.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ChannelToNetworkInputMapper.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ChannelToNetworkInputMapper.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ChannelToNetworkInputMapper.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CommonGradientNames.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CommonGradientNames.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CommonGradientNames.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CommonGradientNames.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CommonLabelNames.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CommonLabelNames.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CommonLabelNames.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CommonLabelNames.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CommonOutputNames.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CommonOutputNames.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CommonOutputNames.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CommonOutputNames.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CompoundNetworkHandler.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CompoundNetworkHandler.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CompoundNetworkHandler.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/CompoundNetworkHandler.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ComputationGraphHandler.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ComputationGraphHandler.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ComputationGraphHandler.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ComputationGraphHandler.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/INetworkHandler.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/INetworkHandler.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/INetworkHandler.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/INetworkHandler.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/IOutputNeuralNet.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/IOutputNeuralNet.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/IOutputNeuralNet.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/IOutputNeuralNet.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ITrainableNeuralNet.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ITrainableNeuralNet.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ITrainableNeuralNet.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ITrainableNeuralNet.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/MultiLayerNetworkHandler.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/MultiLayerNetworkHandler.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/MultiLayerNetworkHandler.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/MultiLayerNetworkHandler.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/NetworkHelper.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/NetworkHelper.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/NetworkHelper.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/NetworkHelper.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/NeuralNet.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/NeuralNet.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/NeuralNet.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/NeuralNet.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/NeuralNetOutput.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/NeuralNetOutput.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/NeuralNetOutput.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/NeuralNetOutput.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/QNetwork.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/QNetwork.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/QNetwork.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/QNetwork.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticCompGraph.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticCompGraph.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticCompGraph.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticCompGraph.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactoryCompGraph.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactoryCompGraph.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactoryCompGraph.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactoryCompGraph.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactoryCompGraphStdConv.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactoryCompGraphStdConv.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactoryCompGraphStdConv.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactoryCompGraphStdConv.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactoryCompGraphStdDense.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactoryCompGraphStdDense.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactoryCompGraphStdDense.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactoryCompGraphStdDense.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactorySeparate.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactorySeparate.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactorySeparate.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactorySeparate.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactorySeparateStdDense.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactorySeparateStdDense.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactorySeparateStdDense.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticFactorySeparateStdDense.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticLoss.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticLoss.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticLoss.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticLoss.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticSeparate.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticSeparate.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticSeparate.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/ActorCriticSeparate.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/IActorCritic.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/IActorCritic.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/IActorCritic.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/ac/IActorCritic.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/ActorCriticDenseNetworkConfiguration.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/ActorCriticDenseNetworkConfiguration.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/ActorCriticDenseNetworkConfiguration.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/ActorCriticDenseNetworkConfiguration.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/ActorCriticNetworkConfiguration.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/ActorCriticNetworkConfiguration.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/ActorCriticNetworkConfiguration.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/ActorCriticNetworkConfiguration.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/DQNDenseNetworkConfiguration.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/DQNDenseNetworkConfiguration.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/DQNDenseNetworkConfiguration.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/DQNDenseNetworkConfiguration.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/NetworkConfiguration.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/NetworkConfiguration.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/NetworkConfiguration.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/configuration/NetworkConfiguration.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQN.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQN.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQN.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQN.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQNFactory.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQNFactory.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQNFactory.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQNFactory.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQNFactoryStdConv.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQNFactoryStdConv.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQNFactoryStdConv.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQNFactoryStdConv.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQNFactoryStdDense.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQNFactoryStdDense.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQNFactoryStdDense.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/DQNFactoryStdDense.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/IDQN.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/IDQN.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/IDQN.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/network/dqn/IDQN.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/IObservationSource.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/IObservationSource.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/IObservationSource.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/IObservationSource.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/Observation.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/Observation.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/Observation.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/Observation.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/EncodableToINDArrayTransform.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/EncodableToINDArrayTransform.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/EncodableToINDArrayTransform.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/EncodableToINDArrayTransform.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/FilterOperation.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/FilterOperation.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/FilterOperation.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/FilterOperation.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/ResettableOperation.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/ResettableOperation.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/ResettableOperation.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/ResettableOperation.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/TransformProcess.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/TransformProcess.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/TransformProcess.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/TransformProcess.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/filter/UniformSkippingFilter.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/filter/UniformSkippingFilter.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/filter/UniformSkippingFilter.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/filter/UniformSkippingFilter.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/legacy/EncodableToImageWritableTransform.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/legacy/EncodableToImageWritableTransform.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/legacy/EncodableToImageWritableTransform.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/legacy/EncodableToImageWritableTransform.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/legacy/ImageWritableToINDArrayTransform.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/legacy/ImageWritableToINDArrayTransform.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/legacy/ImageWritableToINDArrayTransform.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/legacy/ImageWritableToINDArrayTransform.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/ArrayToINDArrayTransform.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/ArrayToINDArrayTransform.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/ArrayToINDArrayTransform.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/ArrayToINDArrayTransform.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/HistoryMergeTransform.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/HistoryMergeTransform.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/HistoryMergeTransform.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/HistoryMergeTransform.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/SimpleNormalizationTransform.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/SimpleNormalizationTransform.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/SimpleNormalizationTransform.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/SimpleNormalizationTransform.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/CircularFifoStore.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/CircularFifoStore.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/CircularFifoStore.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/CircularFifoStore.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryMergeAssembler.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryMergeAssembler.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryMergeAssembler.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryMergeAssembler.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryMergeElementStore.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryMergeElementStore.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryMergeElementStore.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryMergeElementStore.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryStackAssembler.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryStackAssembler.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryStackAssembler.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryStackAssembler.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/ACPolicy.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/ACPolicy.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/ACPolicy.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/ACPolicy.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/BoltzmannQ.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/BoltzmannQ.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/BoltzmannQ.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/BoltzmannQ.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/DQNPolicy.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/DQNPolicy.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/DQNPolicy.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/DQNPolicy.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/EpsGreedy.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/EpsGreedy.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/EpsGreedy.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/EpsGreedy.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/INeuralNetPolicy.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/INeuralNetPolicy.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/INeuralNetPolicy.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/INeuralNetPolicy.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/IPolicy.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/IPolicy.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/IPolicy.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/IPolicy.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/Policy.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/Policy.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/Policy.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/policy/Policy.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/trainer/AsyncTrainer.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/trainer/AsyncTrainer.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/trainer/AsyncTrainer.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/trainer/AsyncTrainer.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/trainer/ITrainer.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/trainer/ITrainer.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/trainer/ITrainer.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/trainer/ITrainer.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/trainer/SyncTrainer.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/trainer/SyncTrainer.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/trainer/SyncTrainer.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/trainer/SyncTrainer.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/Constants.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/Constants.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/Constants.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/Constants.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/DataManager.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/DataManager.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/DataManager.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/DataManager.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/DataManagerTrainingListener.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/DataManagerTrainingListener.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/DataManagerTrainingListener.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/DataManagerTrainingListener.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/IDataManager.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/IDataManager.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/IDataManager.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/IDataManager.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/LegacyMDPWrapper.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/LegacyMDPWrapper.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/LegacyMDPWrapper.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/LegacyMDPWrapper.java diff --git a/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/VideoRecorder.java b/.old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/VideoRecorder.java similarity index 100% rename from rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/VideoRecorder.java rename to .old/rl4j/rl4j-core/src/main/java/org/deeplearning4j/rl4j/util/VideoRecorder.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/AgentLearnerCartpole.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/AgentLearnerCartpole.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/AgentLearnerCartpole.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/AgentLearnerCartpole.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/NStepRnn.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/NStepRnn.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/NStepRnn.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/NStepRnn.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/RobotLakeExample.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/RobotLakeExample.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/RobotLakeExample.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/RobotLakeExample.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/TMazeExample.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/TMazeExample.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/TMazeExample.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/TMazeExample.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/AgentLearnerTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/AgentLearnerTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/AgentLearnerTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/AgentLearnerTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/AgentTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/AgentTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/AgentTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/AgentTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentActorCriticHelperTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentActorCriticHelperTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentActorCriticHelperTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentActorCriticHelperTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentAdvantageActorCriticTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentAdvantageActorCriticTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentAdvantageActorCriticTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentAdvantageActorCriticTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentActorCriticHelperTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentActorCriticHelperTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentActorCriticHelperTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentActorCriticHelperTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentAdvantageActorCriticTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentAdvantageActorCriticTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentAdvantageActorCriticTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentAdvantageActorCriticTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/DoubleDQNTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/DoubleDQNTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/DoubleDQNTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/DoubleDQNTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/StandardDQNTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/StandardDQNTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/StandardDQNTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/StandardDQNTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningHelperTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningHelperTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningHelperTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningHelperTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningHelperTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningHelperTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningHelperTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningHelperTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/behavior/LearningBehaviorTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/behavior/LearningBehaviorTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/behavior/LearningBehaviorTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/behavior/LearningBehaviorTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesBuilderTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesBuilderTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesBuilderTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesBuilderTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesLabelsTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesLabelsTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesLabelsTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesLabelsTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/GradientsTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/GradientsTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/GradientsTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/GradientsTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/UpdateRuleTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/UpdateRuleTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/UpdateRuleTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/UpdateRuleTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncGradientsNeuralNetUpdaterTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncGradientsNeuralNetUpdaterTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncGradientsNeuralNetUpdaterTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncGradientsNeuralNetUpdaterTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncLabelsNeuralNetUpdaterTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncLabelsNeuralNetUpdaterTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncLabelsNeuralNetUpdaterTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncLabelsNeuralNetUpdaterTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncSharedNetworksUpdateHandlerTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncSharedNetworksUpdateHandlerTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncSharedNetworksUpdateHandlerTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncSharedNetworksUpdateHandlerTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncGradientsNeuralNetUpdaterTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncGradientsNeuralNetUpdaterTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncGradientsNeuralNetUpdaterTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncGradientsNeuralNetUpdaterTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncLabelsNeuralNetUpdaterTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncLabelsNeuralNetUpdaterTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncLabelsNeuralNetUpdaterTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncLabelsNeuralNetUpdaterTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/builder/BaseAgentLearnerBuilderTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/builder/BaseAgentLearnerBuilderTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/builder/BaseAgentLearnerBuilderTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/builder/BaseAgentLearnerBuilderTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/experience/ReplayMemoryExperienceHandlerTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/experience/ReplayMemoryExperienceHandlerTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/experience/ReplayMemoryExperienceHandlerTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/experience/ReplayMemoryExperienceHandlerTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/experience/StateActionExperienceHandlerTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/experience/StateActionExperienceHandlerTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/experience/StateActionExperienceHandlerTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/experience/StateActionExperienceHandlerTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/helper/INDArrayHelperTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/helper/INDArrayHelperTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/helper/INDArrayHelperTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/helper/INDArrayHelperTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/HistoryProcessorTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/HistoryProcessorTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/HistoryProcessorTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/HistoryProcessorTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/AsyncLearningTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/AsyncLearningTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/AsyncLearningTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/AsyncLearningTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/AsyncThreadDiscreteTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/AsyncThreadDiscreteTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/AsyncThreadDiscreteTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/AsyncThreadDiscreteTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/AsyncThreadTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/AsyncThreadTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/AsyncThreadTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/AsyncThreadTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/AdvantageActorCriticUpdateAlgorithmTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/AdvantageActorCriticUpdateAlgorithmTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/AdvantageActorCriticUpdateAlgorithmTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/a3c/discrete/AdvantageActorCriticUpdateAlgorithmTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/listener/AsyncTrainingListenerListTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/listener/AsyncTrainingListenerListTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/listener/AsyncTrainingListenerListTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/listener/AsyncTrainingListenerListTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/QLearningUpdateAlgorithmTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/QLearningUpdateAlgorithmTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/QLearningUpdateAlgorithmTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/async/nstep/discrete/QLearningUpdateAlgorithmTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/listener/TrainingListenerListTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/listener/TrainingListenerListTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/listener/TrainingListenerListTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/listener/TrainingListenerListTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/ExpReplayTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/ExpReplayTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/ExpReplayTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/ExpReplayTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/StateActionRewardStateTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/StateActionRewardStateTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/StateActionRewardStateTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/StateActionRewardStateTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/SyncLearningTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/SyncLearningTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/SyncLearningTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/SyncLearningTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/qlearning/QLearningConfigurationTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/qlearning/QLearningConfigurationTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/qlearning/QLearningConfigurationTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/qlearning/QLearningConfigurationTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscreteTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscreteTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscreteTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/qlearning/discrete/QLearningDiscreteTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/support/MockDQN.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/support/MockDQN.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/support/MockDQN.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/support/MockDQN.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/support/MockStatEntry.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/support/MockStatEntry.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/support/MockStatEntry.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/learning/sync/support/MockStatEntry.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ActorCriticNetworkTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ActorCriticNetworkTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ActorCriticNetworkTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ActorCriticNetworkTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/BaseNetworkTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/BaseNetworkTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/BaseNetworkTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/BaseNetworkTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ChannelToNetworkInputMapperTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ChannelToNetworkInputMapperTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ChannelToNetworkInputMapperTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ChannelToNetworkInputMapperTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/CompoundNetworkHandlerTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/CompoundNetworkHandlerTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/CompoundNetworkHandlerTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/CompoundNetworkHandlerTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ComputationGraphHandlerTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ComputationGraphHandlerTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ComputationGraphHandlerTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ComputationGraphHandlerTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/MultiLayerNetworkHandlerTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/MultiLayerNetworkHandlerTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/MultiLayerNetworkHandlerTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/MultiLayerNetworkHandlerTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/NetworkHelperTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/NetworkHelperTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/NetworkHelperTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/NetworkHelperTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/QNetworkTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/QNetworkTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/QNetworkTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/QNetworkTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ac/ActorCriticTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ac/ActorCriticTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ac/ActorCriticTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ac/ActorCriticTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/dqn/DQNTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/dqn/DQNTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/dqn/DQNTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/dqn/DQNTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/TransformProcessTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/TransformProcessTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/TransformProcessTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/TransformProcessTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/filter/UniformSkippingFilterTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/filter/UniformSkippingFilterTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/filter/UniformSkippingFilterTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/filter/UniformSkippingFilterTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/ArrayToINDArrayTransformTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/ArrayToINDArrayTransformTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/ArrayToINDArrayTransformTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/ArrayToINDArrayTransformTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/HistoryMergeTransformTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/HistoryMergeTransformTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/HistoryMergeTransformTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/HistoryMergeTransformTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/SimpleNormalizationTransformTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/SimpleNormalizationTransformTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/SimpleNormalizationTransformTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/SimpleNormalizationTransformTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/CircularFifoStoreTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/CircularFifoStoreTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/CircularFifoStoreTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/CircularFifoStoreTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryStackAssemblerTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryStackAssemblerTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryStackAssemblerTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryStackAssemblerTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/policy/PolicyTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/policy/PolicyTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/policy/PolicyTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/policy/PolicyTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockDQN.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockDQN.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockDQN.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockDQN.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockDataManager.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockDataManager.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockDataManager.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockDataManager.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockHistoryProcessor.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockHistoryProcessor.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockHistoryProcessor.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockHistoryProcessor.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockMDP.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockMDP.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockMDP.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockMDP.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockNeuralNet.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockNeuralNet.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockNeuralNet.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockNeuralNet.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockObservation.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockObservation.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockObservation.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockObservation.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockObservationSpace.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockObservationSpace.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockObservationSpace.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockObservationSpace.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockPolicy.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockPolicy.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockPolicy.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockPolicy.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockRandom.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockRandom.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockRandom.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/support/MockRandom.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/trainer/AsyncTrainerTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/trainer/AsyncTrainerTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/trainer/AsyncTrainerTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/trainer/AsyncTrainerTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/trainer/SyncTrainerTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/trainer/SyncTrainerTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/trainer/SyncTrainerTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/trainer/SyncTrainerTest.java diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/util/DataManagerTrainingListenerTest.java b/.old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/util/DataManagerTrainingListenerTest.java similarity index 100% rename from rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/util/DataManagerTrainingListenerTest.java rename to .old/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/util/DataManagerTrainingListenerTest.java diff --git a/rl4j/rl4j-doom/pom.xml b/.old/rl4j/rl4j-doom/pom.xml similarity index 100% rename from rl4j/rl4j-doom/pom.xml rename to .old/rl4j/rl4j-doom/pom.xml diff --git a/rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/Basic.java b/.old/rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/Basic.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/Basic.java rename to .old/rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/Basic.java diff --git a/rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/DeadlyCorridor.java b/.old/rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/DeadlyCorridor.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/DeadlyCorridor.java rename to .old/rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/DeadlyCorridor.java diff --git a/rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/PredictPosition.java b/.old/rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/PredictPosition.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/PredictPosition.java rename to .old/rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/PredictPosition.java diff --git a/rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/TakeCover.java b/.old/rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/TakeCover.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/TakeCover.java rename to .old/rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/TakeCover.java diff --git a/rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/VizDoom.java b/.old/rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/VizDoom.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/VizDoom.java rename to .old/rl4j/rl4j-doom/src/main/java/org/deeplearning4j/rl4j/mdp/vizdoom/VizDoom.java diff --git a/rl4j/rl4j-doom/src/main/java/vizdoom/AutomapMode.java b/.old/rl4j/rl4j-doom/src/main/java/vizdoom/AutomapMode.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/vizdoom/AutomapMode.java rename to .old/rl4j/rl4j-doom/src/main/java/vizdoom/AutomapMode.java diff --git a/rl4j/rl4j-doom/src/main/java/vizdoom/Button.java b/.old/rl4j/rl4j-doom/src/main/java/vizdoom/Button.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/vizdoom/Button.java rename to .old/rl4j/rl4j-doom/src/main/java/vizdoom/Button.java diff --git a/rl4j/rl4j-doom/src/main/java/vizdoom/DoomGame.java b/.old/rl4j/rl4j-doom/src/main/java/vizdoom/DoomGame.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/vizdoom/DoomGame.java rename to .old/rl4j/rl4j-doom/src/main/java/vizdoom/DoomGame.java diff --git a/rl4j/rl4j-doom/src/main/java/vizdoom/FileDoesNotExistException.java b/.old/rl4j/rl4j-doom/src/main/java/vizdoom/FileDoesNotExistException.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/vizdoom/FileDoesNotExistException.java rename to .old/rl4j/rl4j-doom/src/main/java/vizdoom/FileDoesNotExistException.java diff --git a/rl4j/rl4j-doom/src/main/java/vizdoom/GameState.java b/.old/rl4j/rl4j-doom/src/main/java/vizdoom/GameState.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/vizdoom/GameState.java rename to .old/rl4j/rl4j-doom/src/main/java/vizdoom/GameState.java diff --git a/rl4j/rl4j-doom/src/main/java/vizdoom/GameVariable.java b/.old/rl4j/rl4j-doom/src/main/java/vizdoom/GameVariable.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/vizdoom/GameVariable.java rename to .old/rl4j/rl4j-doom/src/main/java/vizdoom/GameVariable.java diff --git a/rl4j/rl4j-doom/src/main/java/vizdoom/Label.java b/.old/rl4j/rl4j-doom/src/main/java/vizdoom/Label.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/vizdoom/Label.java rename to .old/rl4j/rl4j-doom/src/main/java/vizdoom/Label.java diff --git a/rl4j/rl4j-doom/src/main/java/vizdoom/MessageQueueException.java b/.old/rl4j/rl4j-doom/src/main/java/vizdoom/MessageQueueException.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/vizdoom/MessageQueueException.java rename to .old/rl4j/rl4j-doom/src/main/java/vizdoom/MessageQueueException.java diff --git a/rl4j/rl4j-doom/src/main/java/vizdoom/Mode.java b/.old/rl4j/rl4j-doom/src/main/java/vizdoom/Mode.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/vizdoom/Mode.java rename to .old/rl4j/rl4j-doom/src/main/java/vizdoom/Mode.java diff --git a/rl4j/rl4j-doom/src/main/java/vizdoom/ScreenFormat.java b/.old/rl4j/rl4j-doom/src/main/java/vizdoom/ScreenFormat.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/vizdoom/ScreenFormat.java rename to .old/rl4j/rl4j-doom/src/main/java/vizdoom/ScreenFormat.java diff --git a/rl4j/rl4j-doom/src/main/java/vizdoom/ScreenResolution.java b/.old/rl4j/rl4j-doom/src/main/java/vizdoom/ScreenResolution.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/vizdoom/ScreenResolution.java rename to .old/rl4j/rl4j-doom/src/main/java/vizdoom/ScreenResolution.java diff --git a/rl4j/rl4j-doom/src/main/java/vizdoom/SharedMemoryException.java b/.old/rl4j/rl4j-doom/src/main/java/vizdoom/SharedMemoryException.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/vizdoom/SharedMemoryException.java rename to .old/rl4j/rl4j-doom/src/main/java/vizdoom/SharedMemoryException.java diff --git a/rl4j/rl4j-doom/src/main/java/vizdoom/SignalException.java b/.old/rl4j/rl4j-doom/src/main/java/vizdoom/SignalException.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/vizdoom/SignalException.java rename to .old/rl4j/rl4j-doom/src/main/java/vizdoom/SignalException.java diff --git a/rl4j/rl4j-doom/src/main/java/vizdoom/ViZDoomErrorException.java b/.old/rl4j/rl4j-doom/src/main/java/vizdoom/ViZDoomErrorException.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/vizdoom/ViZDoomErrorException.java rename to .old/rl4j/rl4j-doom/src/main/java/vizdoom/ViZDoomErrorException.java diff --git a/rl4j/rl4j-doom/src/main/java/vizdoom/ViZDoomIsNotRunningException.java b/.old/rl4j/rl4j-doom/src/main/java/vizdoom/ViZDoomIsNotRunningException.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/vizdoom/ViZDoomIsNotRunningException.java rename to .old/rl4j/rl4j-doom/src/main/java/vizdoom/ViZDoomIsNotRunningException.java diff --git a/rl4j/rl4j-doom/src/main/java/vizdoom/ViZDoomUnexpectedExitException.java b/.old/rl4j/rl4j-doom/src/main/java/vizdoom/ViZDoomUnexpectedExitException.java similarity index 100% rename from rl4j/rl4j-doom/src/main/java/vizdoom/ViZDoomUnexpectedExitException.java rename to .old/rl4j/rl4j-doom/src/main/java/vizdoom/ViZDoomUnexpectedExitException.java diff --git a/rl4j/rl4j-gym/pom.xml b/.old/rl4j/rl4j-gym/pom.xml similarity index 100% rename from rl4j/rl4j-gym/pom.xml rename to .old/rl4j/rl4j-gym/pom.xml diff --git a/rl4j/rl4j-gym/src/main/java/org/deeplearning4j/rl4j/mdp/gym/ActionTransformer.java b/.old/rl4j/rl4j-gym/src/main/java/org/deeplearning4j/rl4j/mdp/gym/ActionTransformer.java similarity index 100% rename from rl4j/rl4j-gym/src/main/java/org/deeplearning4j/rl4j/mdp/gym/ActionTransformer.java rename to .old/rl4j/rl4j-gym/src/main/java/org/deeplearning4j/rl4j/mdp/gym/ActionTransformer.java diff --git a/rl4j/rl4j-gym/src/main/java/org/deeplearning4j/rl4j/mdp/gym/GymEnv.java b/.old/rl4j/rl4j-gym/src/main/java/org/deeplearning4j/rl4j/mdp/gym/GymEnv.java similarity index 100% rename from rl4j/rl4j-gym/src/main/java/org/deeplearning4j/rl4j/mdp/gym/GymEnv.java rename to .old/rl4j/rl4j-gym/src/main/java/org/deeplearning4j/rl4j/mdp/gym/GymEnv.java diff --git a/rl4j/rl4j-gym/src/test/java/org/deeplearning4j/rl4j/mdp/gym/GymEnvTest.java b/.old/rl4j/rl4j-gym/src/test/java/org/deeplearning4j/rl4j/mdp/gym/GymEnvTest.java similarity index 100% rename from rl4j/rl4j-gym/src/test/java/org/deeplearning4j/rl4j/mdp/gym/GymEnvTest.java rename to .old/rl4j/rl4j-gym/src/test/java/org/deeplearning4j/rl4j/mdp/gym/GymEnvTest.java diff --git a/rl4j/rl4j-malmo/pom.xml b/.old/rl4j/rl4j-malmo/pom.xml similarity index 100% rename from rl4j/rl4j-malmo/pom.xml rename to .old/rl4j/rl4j-malmo/pom.xml diff --git a/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoActionSpace.java b/.old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoActionSpace.java similarity index 100% rename from rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoActionSpace.java rename to .old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoActionSpace.java diff --git a/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoActionSpaceDiscrete.java b/.old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoActionSpaceDiscrete.java similarity index 100% rename from rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoActionSpaceDiscrete.java rename to .old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoActionSpaceDiscrete.java diff --git a/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoBox.java b/.old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoBox.java similarity index 100% rename from rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoBox.java rename to .old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoBox.java diff --git a/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoConnectionError.java b/.old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoConnectionError.java similarity index 100% rename from rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoConnectionError.java rename to .old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoConnectionError.java diff --git a/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoDescretePositionPolicy.java b/.old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoDescretePositionPolicy.java similarity index 100% rename from rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoDescretePositionPolicy.java rename to .old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoDescretePositionPolicy.java diff --git a/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoEnv.java b/.old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoEnv.java similarity index 100% rename from rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoEnv.java rename to .old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoEnv.java diff --git a/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationPolicy.java b/.old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationPolicy.java similarity index 100% rename from rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationPolicy.java rename to .old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationPolicy.java diff --git a/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpace.java b/.old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpace.java similarity index 100% rename from rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpace.java rename to .old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpace.java diff --git a/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpaceGrid.java b/.old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpaceGrid.java similarity index 100% rename from rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpaceGrid.java rename to .old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpaceGrid.java diff --git a/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpacePixels.java b/.old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpacePixels.java similarity index 100% rename from rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpacePixels.java rename to .old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpacePixels.java diff --git a/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpacePosition.java b/.old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpacePosition.java similarity index 100% rename from rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpacePosition.java rename to .old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoObservationSpacePosition.java diff --git a/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoResetHandler.java b/.old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoResetHandler.java similarity index 100% rename from rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoResetHandler.java rename to .old/rl4j/rl4j-malmo/src/main/java/org/deeplearning4j/malmo/MalmoResetHandler.java diff --git a/tensorflow-processes.pbtxt b/.old/tensorflow-processes.pbtxt similarity index 100% rename from tensorflow-processes.pbtxt rename to .old/tensorflow-processes.pbtxt diff --git a/arbiter/.travis.yml b/arbiter/.travis.yml deleted file mode 100644 index 30638a6a9..000000000 --- a/arbiter/.travis.yml +++ /dev/null @@ -1,24 +0,0 @@ -branches: - only: - - master -notifications: - email: false -dist: trusty -sudo: false -cache: - directories: - - $HOME/.m2 -language: java -jdk: - - openjdk8 -matrix: - include: - - os: linux - env: OS=linux-x86_64 SCALA=2.10 - install: true - script: bash ./ci/build-linux-x86_64.sh - - os: linux - env: OS=linux-x86_64 SCALA=2.11 - install: true - script: bash ./ci/build-linux-x86_64.sh - diff --git a/arbiter/README.md b/arbiter/README.md deleted file mode 100644 index 67124f30a..000000000 --- a/arbiter/README.md +++ /dev/null @@ -1,45 +0,0 @@ -# Arbiter - -A tool dedicated to tuning (hyperparameter optimization) of machine learning models. Part of the DL4J Suite of Machine Learning / Deep Learning tools for the enterprise. - - -## Modules -Arbiter contains the following modules: - -- arbiter-core: Defines the API and core functionality, and also contains functionality for the Arbiter UI -- arbiter-deeplearning4j: For hyperparameter optimization of DL4J models (MultiLayerNetwork and ComputationGraph networks) - - -## Hyperparameter Optimization Functionality - -The open-source version of Arbiter currently defines two methods of hyperparameter optimization: - -- Grid search -- Random search - -For optimization of complex models such as neural networks (those with more than a few hyperparameters), random search is superior to grid search, though Bayesian hyperparameter optimization schemes -For a comparison of random and grid search methods, see [Random Search for Hyper-parameter Optimization (Bergstra and Bengio, 2012)](http://www.jmlr.org/papers/volume13/bergstra12a/bergstra12a.pdf). - -### Core Concepts and Classes in Arbiter for Hyperparameter Optimization - -In order to conduct hyperparameter optimization in Arbiter, it is necessary for the user to understand and define the following: - -- **Parameter Space**: A ```ParameterSpace

``` specifies the type and allowable values of hyperparameters for a model configuration of type ```P```. For example, ```P``` could be a MultiLayerConfiguration for DL4J -- **Candidate Generator**: A ```CandidateGenerator``` is used to generate candidate models configurations of some type ```C```. The following implementations are defined in arbiter-core: - - ```RandomSearchCandidateGenerator``` - - ```GridSearchCandidateGenerator``` -- **Score Function**: A ```ScoreFunction``` is used to score a model of type ```M``` given data of type ```D```. For example, in DL4J a score function might be used to calculate the classification accuracy from a DataSetIterator - - A key concept here is that they score is a single numerical (double precision) value that we either want to minimize or maximize - this is the goal of hyperparameter optimization -- **Termination Conditions**: One or more ```TerminationCondition``` instances must be provided to the ```OptimizationConfiguration```. ```TerminationCondition``` instances are used to control when hyperparameter optimization should be stopped. Some built-in termination conditions: - - ```MaxCandidatesCondition```: Terminate if more than the specified number of candidate hyperparameter configurations have been executed - - ```MaxTimeCondition```: Terminate after a specified amount of time has elapsed since starting the optimization -- **Result Saver**: The ```ResultSaver``` interface is used to specify how the results of each hyperparameter optimization run should be saved. For example, whether saving should be done to local disk, to a database, to HDFS, or simply stored in memory. - - Note that ```ResultSaver.saveModel``` method returns a ```ResultReference``` object, which provides a mechanism for re-loading both the model and score from wherever it may be saved. -- **Optimization Configuration**: An ```OptimizationConfiguration``` ties together the above configuration options in a fluent (builder) pattern. -- **Candidate Executor**: The ```CandidateExecutor``` interface provides a layer of abstraction between the configuration and execution of each instance of learning. Currently, the only option is the ```LocalCandidateExecutor```, which is used to execute learning on a single machine (in the current JVM). In principle, other execution methods (for example, on Spark or cloud computing machines) could be implemented. -- **Optimization Runner**: The ```OptimizationRunner``` uses an ```OptimizationConfiguration``` and a ```CandidateExecutor``` to actually run the optimization, and save the results. - - -### Optimization of DeepLearning4J Models - -(This section: forthcoming) diff --git a/arbiter/arbiter-core/pom.xml b/arbiter/arbiter-core/pom.xml deleted file mode 100644 index ab5ded1b8..000000000 --- a/arbiter/arbiter-core/pom.xml +++ /dev/null @@ -1,97 +0,0 @@ - - - - - arbiter - net.brutex.ai - 1.0.0-SNAPSHOT - - 4.0.0 - - arbiter-core - jar - - arbiter-core - - - - net.brutex.ai - nd4j-api - ${project.version} - - - com.google.code.findbugs - * - - - - - com.google.guava - guava - ${guava.jre.version} - - - org.apache.commons - commons-lang3 - ${commons.lang.version} - - - - org.apache.commons - commons-math3 - ${commons.math.version} - - - - org.slf4j - slf4j-api - ${slf4j.version} - - - - joda-time - joda-time - ${jodatime.version} - - - - com.fasterxml.jackson.core - jackson-annotations - ${jackson.version} - - - - net.brutex.ai - deeplearning4j-common-tests - ${project.version} - test - - - com.fasterxml.jackson.datatype - jackson-datatype-joda - ${jackson.version} - - - net.brutex.ai - nd4j-native - ${project.version} - test - windows-x86_64 - - - diff --git a/arbiter/arbiter-core/src/assembly/bin.xml b/arbiter/arbiter-core/src/assembly/bin.xml deleted file mode 100644 index c99d6b144..000000000 --- a/arbiter/arbiter-core/src/assembly/bin.xml +++ /dev/null @@ -1,91 +0,0 @@ - - - - bin - - - tar.gz - - - - - - - lib - - *:jar:* - - - *:sources - - - - - - - - - readme.txt - - - - - src/main/resources/bin/ - bin - - arbiter - - unix - 0755 - - - - examples - examples - - - - - - - - target - ./ - - *.jar - - - - - - \ No newline at end of file diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/AbstractParameterSpace.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/AbstractParameterSpace.java deleted file mode 100644 index 4ff9dd964..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/AbstractParameterSpace.java +++ /dev/null @@ -1,74 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api; - -import java.lang.reflect.Field; -import java.util.ArrayList; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; - -/** - * Created by Alex on 23/07/2017. - */ -public abstract class AbstractParameterSpace implements ParameterSpace { - - @Override - public Map getNestedSpaces() { - Map m = new LinkedHashMap<>(); - - //Need to manually build and walk the class heirarchy... - Class currClass = this.getClass(); - List> classHeirarchy = new ArrayList<>(); - while (currClass != Object.class) { - classHeirarchy.add(currClass); - currClass = currClass.getSuperclass(); - } - - for (int i = classHeirarchy.size() - 1; i >= 0; i--) { - //Use reflection here to avoid a mass of boilerplate code... - Field[] allFields = classHeirarchy.get(i).getDeclaredFields(); - - for (Field f : allFields) { - - String name = f.getName(); - Class fieldClass = f.getType(); - boolean isParamSpacefield = ParameterSpace.class.isAssignableFrom(fieldClass); - - if (!isParamSpacefield) { - continue; - } - - f.setAccessible(true); - - ParameterSpace p; - try { - p = (ParameterSpace) f.get(this); - } catch (IllegalAccessException e) { - throw new RuntimeException(e); - } - - if (p != null) { - m.put(name, p); - } - } - } - - return m; - } - -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/Candidate.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/Candidate.java deleted file mode 100644 index 4f00d92e7..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/Candidate.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api; - -import lombok.AllArgsConstructor; -import lombok.Data; -import org.deeplearning4j.arbiter.optimize.generator.util.SerializedSupplier; -import org.nd4j.common.function.Supplier; - -import java.io.Serializable; -import java.util.Map; - -/** - * Candidate: a proposed hyperparameter configuration. - * Also includes a map for data parameters, to configure things like data preprocessing, etc. - */ -@Data -@AllArgsConstructor -public class Candidate implements Serializable { - - private Supplier supplier; - private int index; - private double[] flatParameters; - private Map dataParameters; - private Exception exception; - - public Candidate(C value, int index, double[] flatParameters, Map dataParameters, Exception e) { - this(new SerializedSupplier(value), index, flatParameters, dataParameters, e); - } - - public Candidate(C value, int index, double[] flatParameters) { - this(new SerializedSupplier(value), index, flatParameters); - } - - public Candidate(Supplier value, int index, double[] flatParameters) { - this(value, index, flatParameters, null, null); - } - - public C getValue(){ - return supplier.get(); - } - -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/CandidateGenerator.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/CandidateGenerator.java deleted file mode 100644 index 3b070fd37..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/CandidateGenerator.java +++ /dev/null @@ -1,68 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api; - -import org.deeplearning4j.arbiter.optimize.generator.GridSearchCandidateGenerator; -import org.deeplearning4j.arbiter.optimize.generator.RandomSearchGenerator; -import com.fasterxml.jackson.annotation.JsonInclude; -import com.fasterxml.jackson.annotation.JsonSubTypes; -import com.fasterxml.jackson.annotation.JsonTypeInfo; - -/** - * A CandidateGenerator proposes candidates (i.e., hyperparameter configurations) for evaluation. - * This abstraction allows for different ways of generating the next configuration to test; for example, - * random search, grid search, Bayesian optimization methods, etc. - * - * @author Alex Black - */ -@JsonInclude(JsonInclude.Include.NON_NULL) -@JsonTypeInfo(use = JsonTypeInfo.Id.CLASS, include = JsonTypeInfo.As.PROPERTY, property = "@class") -public interface CandidateGenerator { - - /** - * Is this candidate generator able to generate more candidates? This will always return true in some - * cases, but some search strategies have a limit (grid search, for example) - */ - boolean hasMoreCandidates(); - - /** - * Generate a candidate hyperparameter configuration - */ - Candidate getCandidate(); - - /** - * Report results for the candidate generator. - * - * @param result The results to report - */ - void reportResults(OptimizationResult result); - - /** - * @return Get the parameter space for this candidate generator - */ - ParameterSpace getParameterSpace(); - - /** - * @param rngSeed Set the random number generator seed for the candidate generator - */ - void setRngSeed(long rngSeed); - - /** - * @return The type (class) of the generated candidates - */ - Class getCandidateType(); -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/OptimizationResult.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/OptimizationResult.java deleted file mode 100644 index 8868b73ba..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/OptimizationResult.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api; - -import lombok.Data; -import org.deeplearning4j.arbiter.optimize.api.saving.ResultReference; -import org.deeplearning4j.arbiter.optimize.runner.CandidateInfo; -import com.fasterxml.jackson.annotation.JsonIgnoreProperties; -import com.fasterxml.jackson.annotation.JsonProperty; -import com.fasterxml.jackson.annotation.JsonTypeInfo; - -import java.io.Serializable; - -/** - * An optimization result represents the results of an optimization run, including the canditate configuration, the - * trained model, the score for that model, and index of the model - * - * @author Alex Black - */ -@Data -@JsonTypeInfo(use = JsonTypeInfo.Id.CLASS, include = JsonTypeInfo.As.PROPERTY, property = "@class") -@JsonIgnoreProperties({"resultReference"}) -public class OptimizationResult implements Serializable { - @JsonProperty - private Candidate candidate; - @JsonProperty - private Double score; - @JsonProperty - private int index; - @JsonProperty - private Object modelSpecificResults; - @JsonProperty - private CandidateInfo candidateInfo; - private ResultReference resultReference; - - - public OptimizationResult(Candidate candidate, Double score, int index, Object modelSpecificResults, - CandidateInfo candidateInfo, ResultReference resultReference) { - this.candidate = candidate; - this.score = score; - this.index = index; - this.modelSpecificResults = modelSpecificResults; - this.candidateInfo = candidateInfo; - this.resultReference = resultReference; - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/ParameterSpace.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/ParameterSpace.java deleted file mode 100644 index 7a2dff8e7..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/ParameterSpace.java +++ /dev/null @@ -1,81 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api; - -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonInclude; -import com.fasterxml.jackson.annotation.JsonTypeInfo; - -import java.util.List; -import java.util.Map; - -/** - * ParameterSpace: defines the acceptable ranges of values a given parameter may take. - * Note that parameter spaces can be simple (like {@code ParameterSpace}) or complicated, including - * multiple nested ParameterSpaces - * - * @author Alex Black - */ -@JsonInclude(JsonInclude.Include.NON_NULL) -@JsonTypeInfo(use = JsonTypeInfo.Id.CLASS, include = JsonTypeInfo.As.PROPERTY, property = "@class") -public interface ParameterSpace

{ - - /** - * Generate a candidate given a set of values. These values are then mapped to a specific candidate, using some - * mapping function (such as the prior probability distribution) - * - * @param parameterValues A set of values, each in the range [0,1], of length {@link #numParameters()} - */ - P getValue(double[] parameterValues); - - /** - * Get the total number of parameters (hyperparameters) to be optimized. This includes optional parameters from - * different parameter subpaces. (Thus, not every parameter may be used in every candidate) - * - * @return Number of hyperparameters to be optimized - */ - int numParameters(); - - /** - * Collect a list of parameters, recursively. Note that leaf parameters are parameters that do not have any - * nested parameter spaces - */ - List collectLeaves(); - - /** - * Get a list of nested parameter spaces by name. Note that the returned parameter spaces may in turn have further - * nested parameter spaces. The map should be empty for leaf parameter spaces - * - * @return A map of nested parameter spaces - */ - Map getNestedSpaces(); - - /** - * Is this ParameterSpace a leaf? (i.e., does it contain other ParameterSpaces internally?) - */ - @JsonIgnore - boolean isLeaf(); - - /** - * For leaf ParameterSpaces: set the indices of the leaf ParameterSpace. - * Expects input of length {@link #numParameters()}. Throws exception if {@link #isLeaf()} is false. - * - * @param indices Indices to set. Length should equal {@link #numParameters()} - */ - void setIndices(int... indices); - -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/TaskCreator.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/TaskCreator.java deleted file mode 100644 index c6e58905d..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/TaskCreator.java +++ /dev/null @@ -1,62 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api; - -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSource; -import org.deeplearning4j.arbiter.optimize.api.score.ScoreFunction; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.listener.StatusListener; - -import java.util.List; -import java.util.Properties; -import java.util.concurrent.Callable; - -/** - * The TaskCreator is used to take a candidate configuration, data provider and score function, and create something - * that can be executed as a Callable - * - * @author Alex Black - */ -public interface TaskCreator { - - /** - * Generate a callable that can be executed to conduct the training of this model (given the model configuration) - * - * @param candidate Candidate (model) configuration to be trained - * @param dataProvider DataProvider, for the data - * @param scoreFunction Score function to be used to evaluate the model - * @param statusListeners Status listeners, that can be used for callbacks (to UI, for example) - * @return A callable that returns an OptimizationResult, once optimization is complete - */ - @Deprecated - Callable create(Candidate candidate, DataProvider dataProvider, ScoreFunction scoreFunction, - List statusListeners, IOptimizationRunner runner); - - /** - * Generate a callable that can be executed to conduct the training of this model (given the model configuration) - * - * @param candidate Candidate (model) configuration to be trained - * @param dataSource Data source - * @param dataSourceProperties Properties (may be null) for the data source - * @param scoreFunction Score function to be used to evaluate the model - * @param statusListeners Status listeners, that can be used for callbacks (to UI, for example) - * @return A callable that returns an OptimizationResult, once optimization is complete - */ - Callable create(Candidate candidate, Class dataSource, Properties dataSourceProperties, - ScoreFunction scoreFunction, List statusListeners, IOptimizationRunner runner); -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/TaskCreatorProvider.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/TaskCreatorProvider.java deleted file mode 100644 index ea0a4f283..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/TaskCreatorProvider.java +++ /dev/null @@ -1,43 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api; - -import java.util.HashMap; -import java.util.Map; - -public class TaskCreatorProvider { - - private static Map, Class> map = new HashMap<>(); - - public synchronized static TaskCreator defaultTaskCreatorFor(Class paramSpaceClass){ - Class c = map.get(paramSpaceClass); - try { - if(c == null){ - return null; - } - return c.newInstance(); - } catch (Exception e){ - throw new RuntimeException("Could not create new instance of task creator class: " + c + " - missing no-arg constructor?", e); - } - } - - public synchronized static void registerDefaultTaskCreatorClass(Class spaceClass, - Class creatorClass){ - map.put(spaceClass, creatorClass); - } - -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/adapter/ParameterSpaceAdapter.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/adapter/ParameterSpaceAdapter.java deleted file mode 100644 index 56bd51d69..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/adapter/ParameterSpaceAdapter.java +++ /dev/null @@ -1,82 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api.adapter; - -import lombok.AllArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; - -import java.util.Collections; -import java.util.List; -import java.util.Map; - -/** - * An abstract class used for adapting one type into another. Subclasses of this need to merely implement 2 simple methods - * - * @param Type to convert from - * @param Type to convert to - * @author Alex Black - */ -@AllArgsConstructor -public abstract class ParameterSpaceAdapter implements ParameterSpace { - - - protected abstract T convertValue(F from); - - protected abstract ParameterSpace underlying(); - - protected abstract String underlyingName(); - - - @Override - public T getValue(double[] parameterValues) { - return convertValue(underlying().getValue(parameterValues)); - } - - @Override - public int numParameters() { - return underlying().numParameters(); - } - - @Override - public List collectLeaves() { - ParameterSpace p = underlying(); - if(p.isLeaf()){ - return Collections.singletonList(p); - } - return underlying().collectLeaves(); - } - - @Override - public Map getNestedSpaces() { - return Collections.singletonMap(underlyingName(), (ParameterSpace)underlying()); - } - - @Override - public boolean isLeaf() { - return false; //Underlying may be a leaf, however - } - - @Override - public void setIndices(int... indices) { - underlying().setIndices(indices); - } - - @Override - public String toString() { - return underlying().toString(); - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/data/DataProvider.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/data/DataProvider.java deleted file mode 100644 index 23918373f..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/data/DataProvider.java +++ /dev/null @@ -1,54 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api.data; - -import com.fasterxml.jackson.annotation.JsonInclude; -import com.fasterxml.jackson.annotation.JsonTypeInfo; - -import java.io.Serializable; -import java.util.Map; - -/** - * DataProvider interface abstracts out the providing of data - * @deprecated Use {@link DataSource} - */ -@JsonInclude(JsonInclude.Include.NON_NULL) -@JsonTypeInfo(use = JsonTypeInfo.Id.CLASS, include = JsonTypeInfo.As.PROPERTY, property = "@class") -@Deprecated -public interface DataProvider extends Serializable { - - /** - * Get training data given some parameters for the data. - * Data parameters map is used to specify things like batch - * size data preprocessing - * - * @param dataParameters Parameters for data. May be null or empty for default data - * @return training data - */ - Object trainData(Map dataParameters); - - /** - * Get training data given some parameters for the data. Data parameters map is used to specify things like batch - * size data preprocessing - * - * @param dataParameters Parameters for data. May be null or empty for default data - * @return training data - */ - Object testData(Map dataParameters); - - Class getDataType(); -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/data/DataSetIteratorFactoryProvider.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/data/DataSetIteratorFactoryProvider.java deleted file mode 100644 index 3766338a9..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/data/DataSetIteratorFactoryProvider.java +++ /dev/null @@ -1,89 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api.data; - -import lombok.Data; -import org.nd4j.linalg.dataset.api.iterator.DataSetIteratorFactory; - -import java.util.Map; - -/** - * This is a {@link DataProvider} for - * an {@link DataSetIteratorFactory} which - * based on a key of {@link DataSetIteratorFactoryProvider#FACTORY_KEY} - * will create {@link org.nd4j.linalg.dataset.api.iterator.DataSetIterator} - * for use with arbiter. - * - * This {@link DataProvider} is mainly meant for use for command line driven - * applications. - * - * @author Adam Gibson - */ -@Data -public class DataSetIteratorFactoryProvider implements DataProvider { - - public final static String FACTORY_KEY = "org.deeplearning4j.arbiter.data.data.factory"; - - /** - * Get training data given some parameters for the data. - * Data parameters map is used to specify things like batch - * size data preprocessing - * - * @param dataParameters Parameters for data. May be null or empty for default data - * @return training data - */ - @Override - public DataSetIteratorFactory trainData(Map dataParameters) { - return create(dataParameters); - } - - /** - * Get training data given some parameters for the data. Data parameters map - * is used to specify things like batch - * size data preprocessing - * - * @param dataParameters Parameters for data. May be null or empty for default data - * @return training data - */ - @Override - public DataSetIteratorFactory testData(Map dataParameters) { - return create(dataParameters); - } - - @Override - public Class getDataType() { - return DataSetIteratorFactory.class; - } - - private DataSetIteratorFactory create(Map dataParameters) { - if (dataParameters == null) - throw new IllegalArgumentException( - "Data parameters is null. Please specify a class name to create a dataset iterator."); - if (!dataParameters.containsKey(FACTORY_KEY)) - throw new IllegalArgumentException( - "No data set iterator factory class found. Please specify a class name with key " - + FACTORY_KEY); - String value = dataParameters.get(FACTORY_KEY).toString(); - try { - Class clazz = - (Class) Class.forName(value); - return clazz.newInstance(); - } catch (Exception e) { - throw new RuntimeException("Could not create DataSetIteratorFactory instance - missing no-arg constructor?", e); - } - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/data/DataSource.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/data/DataSource.java deleted file mode 100644 index 0afe7bb70..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/data/DataSource.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api.data; - -import java.io.Serializable; -import java.util.Properties; - -/** - * DataSource: defines where the data should come from for training and testing. - * Note that implementations must have a no-argument contsructor - * - * @author Alex Black - */ -public interface DataSource extends Serializable { - - /** - * Configure the current data source with the specified properties - * Note: These properties are fixed for the training instance, and are optionally provided by the user - * at the configuration stage. - * The properties could be anything - and are usually specific to each DataSource implementation. - * For example, values such as batch size could be set using these properties - * @param properties Properties to apply to the data source instance - */ - void configure(Properties properties); - - /** - * Get test data to be used for the optimization. Usually a DataSetIterator or MultiDataSetIterator - */ - Object trainData(); - - /** - * Get test data to be used for the optimization. Usually a DataSetIterator or MultiDataSetIterator - */ - Object testData(); - - /** - * The type of data returned by {@link #trainData()} and {@link #testData()}. - * Usually DataSetIterator or MultiDataSetIterator - * @return Class of the objects returned by trainData and testData - */ - Class getDataType(); - -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/evaluation/ModelEvaluator.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/evaluation/ModelEvaluator.java deleted file mode 100644 index e5dd31d6e..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/evaluation/ModelEvaluator.java +++ /dev/null @@ -1,40 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api.evaluation; - -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; - -import java.io.Serializable; -import java.util.List; - -/** - * ModelEvaluator: Used to conduct additional evaluation. - * For example, this may be classification performance on a test set or similar - */ -public interface ModelEvaluator extends Serializable { - Object evaluateModel(Object model, DataProvider dataProvider); - - /** - * @return The model types supported by this class - */ - List> getSupportedModelTypes(); - - /** - * @return The datatypes supported by this class - */ - List> getSupportedDataTypes(); -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/saving/InMemoryResultSaver.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/saving/InMemoryResultSaver.java deleted file mode 100644 index 43b914cb3..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/saving/InMemoryResultSaver.java +++ /dev/null @@ -1,63 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api.saving; - -import lombok.AllArgsConstructor; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.OptimizationResult; - -import java.io.IOException; -import java.util.Collections; -import java.util.List; - -/** - * A simple class to store optimization results in-memory. - * Not recommended for large (or a large number of) models. - */ -@NoArgsConstructor -public class InMemoryResultSaver implements ResultSaver { - @Override - public ResultReference saveModel(OptimizationResult result, Object modelResult) throws IOException { - return new InMemoryResult(result, modelResult); - } - - @Override - public List> getSupportedCandidateTypes() { - return Collections.>singletonList(Object.class); - } - - @Override - public List> getSupportedModelTypes() { - return Collections.>singletonList(Object.class); - } - - @AllArgsConstructor - private static class InMemoryResult implements ResultReference { - private OptimizationResult result; - private Object modelResult; - - @Override - public OptimizationResult getResult() throws IOException { - return result; - } - - @Override - public Object getResultModel() throws IOException { - return modelResult; - } - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/saving/ResultReference.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/saving/ResultReference.java deleted file mode 100644 index 02e4ec453..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/saving/ResultReference.java +++ /dev/null @@ -1,37 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api.saving; - -import org.deeplearning4j.arbiter.optimize.api.OptimizationResult; -import com.fasterxml.jackson.annotation.JsonTypeInfo; - -import java.io.IOException; - -/** - * Idea: We can't store all results in memory in general (might have thousands of candidates with millions of - * parameters each) - * So instead: return a reference to the saved result. Idea is that the result may be saved to disk or a database, - * and we can easily load it back into memory (if/when required) using the getResult() method - */ -@JsonTypeInfo(use = JsonTypeInfo.Id.CLASS, include = JsonTypeInfo.As.PROPERTY, property = "@class") -public interface ResultReference { - - OptimizationResult getResult() throws IOException; - - Object getResultModel() throws IOException; - -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/saving/ResultSaver.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/saving/ResultSaver.java deleted file mode 100644 index 3506d536b..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/saving/ResultSaver.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api.saving; - -import org.deeplearning4j.arbiter.optimize.api.OptimizationResult; -import com.fasterxml.jackson.annotation.JsonInclude; -import com.fasterxml.jackson.annotation.JsonTypeInfo; - -import java.io.IOException; -import java.util.List; - -/** - * The ResultSaver interface provides a means of saving models in such a way that they can be loaded back into memory later, - * regardless of where/how they are saved. - * - * @author Alex Black - */ -@JsonInclude(JsonInclude.Include.NON_NULL) -@JsonTypeInfo(use = JsonTypeInfo.Id.CLASS, include = JsonTypeInfo.As.PROPERTY, property = "@class") -public interface ResultSaver { - - /** - * Save the model (including configuration and any additional evaluation/results) - * - * @param result Optimization result for the model to save - * @param modelResult Model result to save - * @return ResultReference, such that the result can be loaded back into memory - * @throws IOException If IO error occurs during model saving - */ - ResultReference saveModel(OptimizationResult result, Object modelResult) throws IOException; - - /** - * @return The candidate types supported by this class - */ - List> getSupportedCandidateTypes(); - - /** - * @return The model types supported by this class - */ - List> getSupportedModelTypes(); - - -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/score/ScoreFunction.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/score/ScoreFunction.java deleted file mode 100644 index c6ad6ed29..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/score/ScoreFunction.java +++ /dev/null @@ -1,75 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api.score; - -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSource; -import com.fasterxml.jackson.annotation.JsonInclude; -import com.fasterxml.jackson.annotation.JsonTypeInfo; - -import java.io.Serializable; -import java.util.List; -import java.util.Map; -import java.util.Properties; - -/** - * ScoreFunction defines the objective of hyperparameter optimization. - * Specifically, it is used to calculate a score for a given model, relative to the data set provided - * in the configuration. - * - */ -@JsonInclude(JsonInclude.Include.NON_NULL) -@JsonTypeInfo(use = JsonTypeInfo.Id.CLASS, include = JsonTypeInfo.As.PROPERTY, property = "@class") -public interface ScoreFunction extends Serializable { - - /** - * Calculate and return the score, for the given model and data provider - * - * @param model Model to score - * @param dataProvider Data provider - data to use - * @param dataParameters Parameters for data - * @return Calculated score - */ - double score(Object model, DataProvider dataProvider, Map dataParameters); - - /** - * Calculate and return the score, for the given model and data provider - * - * @param model Model to score - * @param dataSource Data source - * @param dataSourceProperties data source properties - * @return Calculated score - */ - double score(Object model, Class dataSource, Properties dataSourceProperties); - - /** - * Should this score function be minimized or maximized? - * - * @return true if score should be minimized, false if score should be maximized - */ - boolean minimize(); - - /** - * @return The model types supported by this class - */ - List> getSupportedModelTypes(); - - /** - * @return The data types supported by this class - */ - List> getSupportedDataTypes(); -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/termination/MaxCandidatesCondition.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/termination/MaxCandidatesCondition.java deleted file mode 100644 index 61b76dc90..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/termination/MaxCandidatesCondition.java +++ /dev/null @@ -1,50 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api.termination; - -import lombok.AllArgsConstructor; -import lombok.Data; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** - * Terminate hyperparameter search when the number of candidates exceeds a specified value. - * Note that this is counted as number of completed candidates, plus number of failed candidates. - */ -@AllArgsConstructor -@NoArgsConstructor -@Data -public class MaxCandidatesCondition implements TerminationCondition { - @JsonProperty - private int maxCandidates; - - @Override - public void initialize(IOptimizationRunner optimizationRunner) { - //No op - } - - @Override - public boolean terminate(IOptimizationRunner optimizationRunner) { - return optimizationRunner.numCandidatesCompleted() + optimizationRunner.numCandidatesFailed() >= maxCandidates; - } - - @Override - public String toString() { - return "MaxCandidatesCondition(" + maxCandidates + ")"; - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/termination/MaxTimeCondition.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/termination/MaxTimeCondition.java deleted file mode 100644 index c346c0ea5..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/termination/MaxTimeCondition.java +++ /dev/null @@ -1,81 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api.termination; - -import lombok.Data; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import org.joda.time.format.DateTimeFormat; -import org.joda.time.format.DateTimeFormatter; -import com.fasterxml.jackson.annotation.JsonProperty; - -import java.util.concurrent.TimeUnit; - -/** - * Terminate hyperparameter optimization after - * a fixed amount of time has passed - * @author Alex Black - */ -@NoArgsConstructor -@Data -public class MaxTimeCondition implements TerminationCondition { - private static final DateTimeFormatter formatter = DateTimeFormat.forPattern("dd-MMM HH:mm ZZ"); - - private long duration; - private TimeUnit timeUnit; - private long startTime; - private long endTime; - - - private MaxTimeCondition(@JsonProperty("duration") long duration, @JsonProperty("timeUnit") TimeUnit timeUnit, - @JsonProperty("startTime") long startTime, @JsonProperty("endTime") long endTime) { - this.duration = duration; - this.timeUnit = timeUnit; - this.startTime = startTime; - this.endTime = endTime; - } - - /** - * @param duration Duration of time - * @param timeUnit Unit that the duration is specified in - */ - public MaxTimeCondition(long duration, TimeUnit timeUnit) { - this.duration = duration; - this.timeUnit = timeUnit; - } - - @Override - public void initialize(IOptimizationRunner optimizationRunner) { - startTime = System.currentTimeMillis(); - this.endTime = startTime + timeUnit.toMillis(duration); - } - - @Override - public boolean terminate(IOptimizationRunner optimizationRunner) { - return System.currentTimeMillis() >= endTime; - } - - @Override - public String toString() { - if (startTime > 0) { - return "MaxTimeCondition(" + duration + "," + timeUnit + ",start=\"" + formatter.print(startTime) - + "\",end=\"" + formatter.print(endTime) + "\")"; - } else { - return "MaxTimeCondition(" + duration + "," + timeUnit + "\")"; - } - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/termination/TerminationCondition.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/termination/TerminationCondition.java deleted file mode 100644 index ec5e1982f..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/api/termination/TerminationCondition.java +++ /dev/null @@ -1,45 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.api.termination; - - -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import com.fasterxml.jackson.annotation.JsonInclude; -import com.fasterxml.jackson.annotation.JsonTypeInfo; - -/** - * Global termination condition for conducting hyperparameter optimization. - * Termination conditions are used to determine if/when the optimization should stop. - */ -@JsonTypeInfo(use = JsonTypeInfo.Id.CLASS, include = JsonTypeInfo.As.PROPERTY, property = "@class") -@JsonInclude(JsonInclude.Include.NON_NULL) -public interface TerminationCondition { - - /** - * Initialize the termination condition (such as starting timers, etc). - */ - void initialize(IOptimizationRunner optimizationRunner); - - /** - * Determine whether optimization should be terminated - * - * @param optimizationRunner Optimization runner - * @return true if learning should be terminated, false otherwise - */ - boolean terminate(IOptimizationRunner optimizationRunner); - -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/config/OptimizationConfiguration.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/config/OptimizationConfiguration.java deleted file mode 100644 index 59b3e9a6a..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/config/OptimizationConfiguration.java +++ /dev/null @@ -1,226 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.config; - -import lombok.*; -import org.deeplearning4j.arbiter.optimize.api.CandidateGenerator; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSource; -import org.deeplearning4j.arbiter.optimize.api.saving.ResultSaver; -import org.deeplearning4j.arbiter.optimize.api.score.ScoreFunction; -import org.deeplearning4j.arbiter.optimize.api.termination.TerminationCondition; -import org.deeplearning4j.arbiter.optimize.serde.jackson.JsonMapper; -import com.fasterxml.jackson.annotation.JsonTypeInfo; -import com.fasterxml.jackson.core.JsonProcessingException; -import com.fasterxml.jackson.databind.annotation.JsonSerialize; - -import java.io.IOException; -import java.lang.reflect.Constructor; -import java.util.Arrays; -import java.util.List; -import java.util.Properties; - -/** - * OptimizationConfiguration ties together all of the various - * components (such as data, score functions, result saving etc) - * required to execute hyperparameter optimization. - * - * @author Alex Black - */ -@Data -@NoArgsConstructor -@EqualsAndHashCode(exclude = {"dataProvider", "terminationConditions", "candidateGenerator", "resultSaver"}) -@JsonTypeInfo(use = JsonTypeInfo.Id.CLASS, include = JsonTypeInfo.As.PROPERTY, property = "@class") -public class OptimizationConfiguration { - @JsonSerialize - private DataProvider dataProvider; - @JsonSerialize - private Class dataSource; - @JsonSerialize - private Properties dataSourceProperties; - @JsonSerialize - private CandidateGenerator candidateGenerator; - @JsonSerialize - private ResultSaver resultSaver; - @JsonSerialize - private ScoreFunction scoreFunction; - @JsonSerialize - private List terminationConditions; - @JsonSerialize - private Long rngSeed; - - @Getter - @Setter - private long executionStartTime; - - - private OptimizationConfiguration(Builder builder) { - this.dataProvider = builder.dataProvider; - this.dataSource = builder.dataSource; - this.dataSourceProperties = builder.dataSourceProperties; - this.candidateGenerator = builder.candidateGenerator; - this.resultSaver = builder.resultSaver; - this.scoreFunction = builder.scoreFunction; - this.terminationConditions = builder.terminationConditions; - this.rngSeed = builder.rngSeed; - - if (rngSeed != null) - candidateGenerator.setRngSeed(rngSeed); - - //Validate the configuration: data types, score types, etc - //TODO - - //Validate that the dataSource has a no-arg constructor - if (dataSource != null) { - try { - dataSource.getConstructor(); - } catch (NoSuchMethodException e) { - throw new IllegalStateException("Data source class " + dataSource.getName() + " does not have a public no-argument constructor"); - } - } - } - - public static class Builder { - - private DataProvider dataProvider; - private Class dataSource; - private Properties dataSourceProperties; - private CandidateGenerator candidateGenerator; - private ResultSaver resultSaver; - private ScoreFunction scoreFunction; - private List terminationConditions; - private Long rngSeed; - - /** - * @deprecated Use {@link #dataSource(Class, Properties)} - */ - @Deprecated - public Builder dataProvider(DataProvider dataProvider) { - this.dataProvider = dataProvider; - return this; - } - - /** - * DataSource: defines where the data should come from for training and testing. - * Note that implementations must have a no-argument contsructor - * - * @param dataSource Class for the data source - * @param dataSourceProperties May be null. Properties for configuring the data source - */ - public Builder dataSource(Class dataSource, Properties dataSourceProperties) { - this.dataSource = dataSource; - this.dataSourceProperties = dataSourceProperties; - return this; - } - - public Builder candidateGenerator(CandidateGenerator candidateGenerator) { - this.candidateGenerator = candidateGenerator; - return this; - } - - public Builder modelSaver(ResultSaver resultSaver) { - this.resultSaver = resultSaver; - return this; - } - - public Builder scoreFunction(ScoreFunction scoreFunction) { - this.scoreFunction = scoreFunction; - return this; - } - - /** - * Termination conditions to use - * - * @param conditions - * @return - */ - public Builder terminationConditions(TerminationCondition... conditions) { - terminationConditions = Arrays.asList(conditions); - return this; - } - - public Builder terminationConditions(List terminationConditions) { - this.terminationConditions = terminationConditions; - return this; - } - - public Builder rngSeed(long rngSeed) { - this.rngSeed = rngSeed; - return this; - } - - public OptimizationConfiguration build() { - return new OptimizationConfiguration(this); - } - } - - - /** - * Create an optimization configuration from the json - * - * @param json the json to create the config from - * For type definitions - * @see OptimizationConfiguration - */ - public static OptimizationConfiguration fromYaml(String json) { - try { - return JsonMapper.getYamlMapper().readValue(json, OptimizationConfiguration.class); - } catch (IOException e) { - throw new RuntimeException(e); - } - } - - /** - * Create an optimization configuration from the json - * - * @param json the json to create the config from - * @see OptimizationConfiguration - */ - public static OptimizationConfiguration fromJson(String json) { - try { - return JsonMapper.getMapper().readValue(json, OptimizationConfiguration.class); - } catch (IOException e) { - throw new RuntimeException(e); - } - } - - /** - * Return a json configuration of this optimization configuration - * - * @return - */ - public String toJson() { - try { - return JsonMapper.getMapper().writeValueAsString(this); - } catch (JsonProcessingException e) { - throw new RuntimeException(e); - } - } - - /** - * Return a yaml configuration of this optimization configuration - * - * @return - */ - public String toYaml() { - try { - return JsonMapper.getYamlMapper().writeValueAsString(this); - } catch (JsonProcessingException e) { - throw new RuntimeException(e); - } - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/distribution/DegenerateIntegerDistribution.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/distribution/DegenerateIntegerDistribution.java deleted file mode 100644 index c613d08b6..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/distribution/DegenerateIntegerDistribution.java +++ /dev/null @@ -1,96 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.distribution; - -import org.apache.commons.math3.distribution.IntegerDistribution; -import org.apache.commons.math3.exception.NumberIsTooLargeException; -import org.apache.commons.math3.exception.OutOfRangeException; - -/** - * Degenerate distribution: i.e., integer "distribution" that is just a fixed value - */ -public class DegenerateIntegerDistribution implements IntegerDistribution { - private int value; - - public DegenerateIntegerDistribution(int value) { - this.value = value; - } - - - @Override - public double probability(int x) { - return (x == value ? 1.0 : 0.0); - } - - @Override - public double cumulativeProbability(int x) { - return (x >= value ? 1.0 : 0.0); - } - - @Override - public double cumulativeProbability(int x0, int x1) throws NumberIsTooLargeException { - return (value >= x0 && value <= x1 ? 1.0 : 0.0); - } - - @Override - public int inverseCumulativeProbability(double p) throws OutOfRangeException { - throw new UnsupportedOperationException(); - } - - @Override - public double getNumericalMean() { - return value; - } - - @Override - public double getNumericalVariance() { - return 0; - } - - @Override - public int getSupportLowerBound() { - return value; - } - - @Override - public int getSupportUpperBound() { - return value; - } - - @Override - public boolean isSupportConnected() { - return true; - } - - @Override - public void reseedRandomGenerator(long seed) { - //no op - } - - @Override - public int sample() { - return value; - } - - @Override - public int[] sample(int sampleSize) { - int[] out = new int[sampleSize]; - for (int i = 0; i < out.length; i++) - out[i] = value; - return out; - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/distribution/DistributionUtils.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/distribution/DistributionUtils.java deleted file mode 100644 index 24dafc726..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/distribution/DistributionUtils.java +++ /dev/null @@ -1,149 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.distribution; - -import org.apache.commons.math3.distribution.*; - -/** - * Distribution utils for Apache Commons math distributions - which don't provide equals, hashcode, toString methods, - * don't implement serializable etc. - * Which makes unit testing etc quite difficult. - * - * @author Alex Black - */ -public class DistributionUtils { - - private DistributionUtils() {} - - - public static boolean distributionsEqual(RealDistribution a, RealDistribution b) { - if (a.getClass() != b.getClass()) - return false; - Class c = a.getClass(); - if (c == BetaDistribution.class) { - BetaDistribution ba = (BetaDistribution) a; - BetaDistribution bb = (BetaDistribution) b; - - return ba.getAlpha() == bb.getAlpha() && ba.getBeta() == bb.getBeta(); - } else if (c == CauchyDistribution.class) { - CauchyDistribution ca = (CauchyDistribution) a; - CauchyDistribution cb = (CauchyDistribution) b; - return ca.getMedian() == cb.getMedian() && ca.getScale() == cb.getScale(); - } else if (c == ChiSquaredDistribution.class) { - ChiSquaredDistribution ca = (ChiSquaredDistribution) a; - ChiSquaredDistribution cb = (ChiSquaredDistribution) b; - return ca.getDegreesOfFreedom() == cb.getDegreesOfFreedom(); - } else if (c == ExponentialDistribution.class) { - ExponentialDistribution ea = (ExponentialDistribution) a; - ExponentialDistribution eb = (ExponentialDistribution) b; - return ea.getMean() == eb.getMean(); - } else if (c == FDistribution.class) { - FDistribution fa = (FDistribution) a; - FDistribution fb = (FDistribution) b; - return fa.getNumeratorDegreesOfFreedom() == fb.getNumeratorDegreesOfFreedom() - && fa.getDenominatorDegreesOfFreedom() == fb.getDenominatorDegreesOfFreedom(); - } else if (c == GammaDistribution.class) { - GammaDistribution ga = (GammaDistribution) a; - GammaDistribution gb = (GammaDistribution) b; - return ga.getShape() == gb.getShape() && ga.getScale() == gb.getScale(); - } else if (c == LevyDistribution.class) { - LevyDistribution la = (LevyDistribution) a; - LevyDistribution lb = (LevyDistribution) b; - return la.getLocation() == lb.getLocation() && la.getScale() == lb.getScale(); - } else if (c == LogNormalDistribution.class) { - LogNormalDistribution la = (LogNormalDistribution) a; - LogNormalDistribution lb = (LogNormalDistribution) b; - return la.getScale() == lb.getScale() && la.getShape() == lb.getShape(); - } else if (c == NormalDistribution.class) { - NormalDistribution na = (NormalDistribution) a; - NormalDistribution nb = (NormalDistribution) b; - return na.getMean() == nb.getMean() && na.getStandardDeviation() == nb.getStandardDeviation(); - } else if (c == ParetoDistribution.class) { - ParetoDistribution pa = (ParetoDistribution) a; - ParetoDistribution pb = (ParetoDistribution) b; - return pa.getScale() == pb.getScale() && pa.getShape() == pb.getShape(); - } else if (c == TDistribution.class) { - TDistribution ta = (TDistribution) a; - TDistribution tb = (TDistribution) b; - return ta.getDegreesOfFreedom() == tb.getDegreesOfFreedom(); - } else if (c == TriangularDistribution.class) { - TriangularDistribution ta = (TriangularDistribution) a; - TriangularDistribution tb = (TriangularDistribution) b; - return ta.getSupportLowerBound() == tb.getSupportLowerBound() - && ta.getSupportUpperBound() == tb.getSupportUpperBound() && ta.getMode() == tb.getMode(); - } else if (c == UniformRealDistribution.class) { - UniformRealDistribution ua = (UniformRealDistribution) a; - UniformRealDistribution ub = (UniformRealDistribution) b; - return ua.getSupportLowerBound() == ub.getSupportLowerBound() - && ua.getSupportUpperBound() == ub.getSupportUpperBound(); - } else if (c == WeibullDistribution.class) { - WeibullDistribution wa = (WeibullDistribution) a; - WeibullDistribution wb = (WeibullDistribution) b; - return wa.getShape() == wb.getShape() && wa.getScale() == wb.getScale(); - } else if (c == LogUniformDistribution.class ){ - LogUniformDistribution lu_a = (LogUniformDistribution)a; - LogUniformDistribution lu_b = (LogUniformDistribution)b; - return lu_a.getMin() == lu_b.getMin() && lu_a.getMax() == lu_b.getMax(); - } else { - throw new UnsupportedOperationException("Unknown or not supported RealDistribution: " + c); - } - } - - public static boolean distributionEquals(IntegerDistribution a, IntegerDistribution b) { - if (a.getClass() != b.getClass()) - return false; - Class c = a.getClass(); - - if (c == BinomialDistribution.class) { - BinomialDistribution ba = (BinomialDistribution) a; - BinomialDistribution bb = (BinomialDistribution) b; - return ba.getNumberOfTrials() == bb.getNumberOfTrials() - && ba.getProbabilityOfSuccess() == bb.getProbabilityOfSuccess(); - } else if (c == GeometricDistribution.class) { - GeometricDistribution ga = (GeometricDistribution) a; - GeometricDistribution gb = (GeometricDistribution) b; - return ga.getProbabilityOfSuccess() == gb.getProbabilityOfSuccess(); - } else if (c == HypergeometricDistribution.class) { - HypergeometricDistribution ha = (HypergeometricDistribution) a; - HypergeometricDistribution hb = (HypergeometricDistribution) b; - return ha.getPopulationSize() == hb.getPopulationSize() - && ha.getNumberOfSuccesses() == hb.getNumberOfSuccesses() - && ha.getSampleSize() == hb.getSampleSize(); - } else if (c == PascalDistribution.class) { - PascalDistribution pa = (PascalDistribution) a; - PascalDistribution pb = (PascalDistribution) b; - return pa.getNumberOfSuccesses() == pb.getNumberOfSuccesses() - && pa.getProbabilityOfSuccess() == pb.getProbabilityOfSuccess(); - } else if (c == PoissonDistribution.class) { - PoissonDistribution pa = (PoissonDistribution) a; - PoissonDistribution pb = (PoissonDistribution) b; - return pa.getMean() == pb.getMean(); - } else if (c == UniformIntegerDistribution.class) { - UniformIntegerDistribution ua = (UniformIntegerDistribution) a; - UniformIntegerDistribution ub = (UniformIntegerDistribution) b; - return ua.getSupportUpperBound() == ub.getSupportUpperBound() - && ua.getSupportUpperBound() == ub.getSupportUpperBound(); - } else if (c == ZipfDistribution.class) { - ZipfDistribution za = (ZipfDistribution) a; - ZipfDistribution zb = (ZipfDistribution) b; - return za.getNumberOfElements() == zb.getNumberOfElements() && za.getExponent() == zb.getNumberOfElements(); - } else { - throw new UnsupportedOperationException("Unknown or not supported IntegerDistribution: " + c); - } - - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/distribution/LogUniformDistribution.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/distribution/LogUniformDistribution.java deleted file mode 100644 index da790c422..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/distribution/LogUniformDistribution.java +++ /dev/null @@ -1,155 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.distribution; - -import com.google.common.base.Preconditions; -import lombok.Getter; -import org.apache.commons.math3.distribution.RealDistribution; -import org.apache.commons.math3.exception.NumberIsTooLargeException; -import org.apache.commons.math3.exception.OutOfRangeException; - -import java.util.Random; - -/** - * Log uniform distribution, with support in range [min, max] for min > 0 - * - * Reference: https://www.vosesoftware.com/riskwiki/LogUniformdistribution.php - * - * @author Alex Black - */ -public class LogUniformDistribution implements RealDistribution { - - @Getter private final double min; - @Getter private final double max; - - private final double logMin; - private final double logMax; - - private transient Random rng = new Random(); - - /** - * - * @param min Minimum value - * @param max Maximum value - */ - public LogUniformDistribution(double min, double max) { - Preconditions.checkArgument(min > 0, "Minimum must be > 0. Got: " + min); - Preconditions.checkArgument(max > min, "Maximum must be > min. Got: (min, max)=(" - + min + "," + max + ")"); - this.min = min; - this.max = max; - - this.logMin = Math.log(min); - this.logMax = Math.log(max); - } - - @Override - public double probability(double x) { - if(x < min || x > max){ - return 0; - } - - return 1.0 / (x * (logMax - logMin)); - } - - @Override - public double density(double x) { - return probability(x); - } - - @Override - public double cumulativeProbability(double x) { - if(x <= min){ - return 0.0; - } else if(x >= max){ - return 1.0; - } - - return (Math.log(x)-logMin)/(logMax-logMin); - } - - @Override - public double cumulativeProbability(double x0, double x1) throws NumberIsTooLargeException { - return cumulativeProbability(x1) - cumulativeProbability(x0); - } - - @Override - public double inverseCumulativeProbability(double p) throws OutOfRangeException { - Preconditions.checkArgument(p >= 0 && p <= 1, "Invalid input: " + p); - return Math.exp(p * (logMax-logMin) + logMin); - } - - @Override - public double getNumericalMean() { - return (max-min)/(logMax-logMin); - } - - @Override - public double getNumericalVariance() { - double d1 = (logMax-logMin)*(max*max - min*min) - 2*(max-min)*(max-min); - return d1 / (2*Math.pow(logMax-logMin, 2.0)); - } - - @Override - public double getSupportLowerBound() { - return min; - } - - @Override - public double getSupportUpperBound() { - return max; - } - - @Override - public boolean isSupportLowerBoundInclusive() { - return true; - } - - @Override - public boolean isSupportUpperBoundInclusive() { - return true; - } - - @Override - public boolean isSupportConnected() { - return true; - } - - @Override - public void reseedRandomGenerator(long seed) { - rng.setSeed(seed); - } - - @Override - public double sample() { - return inverseCumulativeProbability(rng.nextDouble()); - } - - @Override - public double[] sample(int sampleSize) { - double[] d = new double[sampleSize]; - for( int i=0; i Type of candidates to generate - */ -@Data -@EqualsAndHashCode(exclude = {"rng", "candidateCounter"}) -public abstract class BaseCandidateGenerator implements CandidateGenerator { - protected ParameterSpace parameterSpace; - protected AtomicInteger candidateCounter = new AtomicInteger(0); - protected SynchronizedRandomGenerator rng = new SynchronizedRandomGenerator(new JDKRandomGenerator()); - protected Map dataParameters; - protected boolean initDone = false; - - public BaseCandidateGenerator(ParameterSpace parameterSpace, Map dataParameters, - boolean initDone) { - this.parameterSpace = parameterSpace; - this.dataParameters = dataParameters; - this.initDone = initDone; - } - - protected void initialize() { - if(!initDone) { - //First: collect leaf parameter spaces objects and remove duplicates - List noDuplicatesList = LeafUtils.getUniqueObjects(parameterSpace.collectLeaves()); - - //Second: assign each a number - int i = 0; - for (ParameterSpace ps : noDuplicatesList) { - int np = ps.numParameters(); - if (np == 1) { - ps.setIndices(i++); - } else { - int[] values = new int[np]; - for (int j = 0; j < np; j++) - values[j] = i++; - ps.setIndices(values); - } - } - initDone = true; - } - } - - @Override - public ParameterSpace getParameterSpace() { - return parameterSpace; - } - - @Override - public void reportResults(OptimizationResult result) { - //No op - } - - @Override - public void setRngSeed(long rngSeed) { - rng.setSeed(rngSeed); - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/GeneticSearchCandidateGenerator.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/GeneticSearchCandidateGenerator.java deleted file mode 100644 index 564c194ba..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/GeneticSearchCandidateGenerator.java +++ /dev/null @@ -1,187 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator; - -import lombok.Getter; -import lombok.extern.slf4j.Slf4j; -import org.deeplearning4j.arbiter.optimize.api.Candidate; -import org.deeplearning4j.arbiter.optimize.api.OptimizationResult; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.api.score.ScoreFunction; -import org.deeplearning4j.arbiter.optimize.generator.genetic.Chromosome; -import org.deeplearning4j.arbiter.optimize.generator.genetic.ChromosomeFactory; -import org.deeplearning4j.arbiter.optimize.generator.genetic.exceptions.GeneticGenerationException; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.EmptyPopulationInitializer; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationInitializer; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationModel; -import org.deeplearning4j.arbiter.optimize.generator.genetic.selection.GeneticSelectionOperator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.selection.SelectionOperator; - -import java.util.Map; - -/** - * Uses a genetic algorithm to generate candidates. - * - * @author Alexandre Boulanger - */ -@Slf4j -public class GeneticSearchCandidateGenerator extends BaseCandidateGenerator { - - @Getter - protected final PopulationModel populationModel; - - protected final ChromosomeFactory chromosomeFactory; - protected final SelectionOperator selectionOperator; - - protected boolean hasMoreCandidates = true; - - public static class Builder { - protected final ParameterSpace parameterSpace; - - protected Map dataParameters; - protected boolean initDone; - protected boolean minimizeScore; - protected PopulationModel populationModel; - protected ChromosomeFactory chromosomeFactory; - protected SelectionOperator selectionOperator; - - /** - * @param parameterSpace ParameterSpace from which to generate candidates - * @param scoreFunction The score function that will be used in the OptimizationConfiguration - */ - public Builder(ParameterSpace parameterSpace, ScoreFunction scoreFunction) { - this.parameterSpace = parameterSpace; - this.minimizeScore = scoreFunction.minimize(); - } - - /** - * @param populationModel The PopulationModel instance to use. - */ - public Builder populationModel(PopulationModel populationModel) { - this.populationModel = populationModel; - return this; - } - - /** - * @param selectionOperator The SelectionOperator to use. Default is GeneticSelectionOperator - */ - public Builder selectionOperator(SelectionOperator selectionOperator) { - this.selectionOperator = selectionOperator; - return this; - } - - public Builder dataParameters(Map dataParameters) { - - this.dataParameters = dataParameters; - return this; - } - - public GeneticSearchCandidateGenerator.Builder initDone(boolean initDone) { - this.initDone = initDone; - return this; - } - - /** - * @param chromosomeFactory The ChromosomeFactory to use - */ - public Builder chromosomeFactory(ChromosomeFactory chromosomeFactory) { - this.chromosomeFactory = chromosomeFactory; - return this; - } - - public GeneticSearchCandidateGenerator build() { - if (populationModel == null) { - PopulationInitializer defaultPopulationInitializer = new EmptyPopulationInitializer(); - populationModel = new PopulationModel.Builder().populationInitializer(defaultPopulationInitializer) - .build(); - } - - if (chromosomeFactory == null) { - chromosomeFactory = new ChromosomeFactory(); - } - - if (selectionOperator == null) { - selectionOperator = new GeneticSelectionOperator.Builder().build(); - } - - return new GeneticSearchCandidateGenerator(this); - } - } - - private GeneticSearchCandidateGenerator(Builder builder) { - super(builder.parameterSpace, builder.dataParameters, builder.initDone); - - initialize(); - - chromosomeFactory = builder.chromosomeFactory; - populationModel = builder.populationModel; - selectionOperator = builder.selectionOperator; - - chromosomeFactory.initializeInstance(builder.parameterSpace.numParameters()); - populationModel.initializeInstance(builder.minimizeScore); - selectionOperator.initializeInstance(populationModel, chromosomeFactory); - - } - - @Override - public boolean hasMoreCandidates() { - return hasMoreCandidates; - } - - @Override - public Candidate getCandidate() { - - double[] values = null; - Object value = null; - Exception e = null; - - try { - values = selectionOperator.buildNextGenes(); - value = parameterSpace.getValue(values); - } catch (GeneticGenerationException e2) { - log.warn("Error generating candidate", e2); - e = e2; - hasMoreCandidates = false; - } catch (Exception e2) { - log.warn("Error getting configuration for candidate", e2); - e = e2; - } - - return new Candidate(value, candidateCounter.getAndIncrement(), values, dataParameters, e); - } - - @Override - public Class getCandidateType() { - return null; - } - - @Override - public String toString() { - return "GeneticSearchCandidateGenerator"; - } - - @Override - public void reportResults(OptimizationResult result) { - if (result.getScore() == null) { - return; - } - - Chromosome newChromosome = chromosomeFactory.createChromosome(result.getCandidate().getFlatParameters(), - result.getScore()); - populationModel.add(newChromosome); - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/GridSearchCandidateGenerator.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/GridSearchCandidateGenerator.java deleted file mode 100644 index 4d056087f..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/GridSearchCandidateGenerator.java +++ /dev/null @@ -1,232 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator; - -import lombok.EqualsAndHashCode; -import lombok.Getter; -import lombok.extern.slf4j.Slf4j; -import org.apache.commons.math3.random.RandomAdaptor; -import org.deeplearning4j.arbiter.optimize.api.Candidate; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.optimize.parameter.discrete.DiscreteParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.integer.IntegerParameterSpace; -import org.deeplearning4j.arbiter.util.LeafUtils; -import com.fasterxml.jackson.annotation.JsonIgnoreProperties; -import com.fasterxml.jackson.annotation.JsonProperty; - -import java.util.*; -import java.util.concurrent.ConcurrentLinkedQueue; - - -/** - * GridSearchCandidateGenerator: generates candidates in an exhaustive grid search manner.
- * Note that:
- * - For discrete parameters: the grid size (# values to check per hyperparameter) is equal to the number of values for - * that hyperparameter
- * - For integer parameters: the grid size is equal to {@code min(discretizationCount,max-min+1)}. Some integer ranges can - * be large, and we don't necessarily want to exhaustively search them. {@code discretizationCount} is a constructor argument
- * - For continuous parameters: the grid size is equal to {@code discretizationCount}.
- * In all cases, the minimum, maximum and gridSize-2 values between the min/max will be generated.
- * Also note that: if a probability distribution is provided for continuous hyperparameters, this will be taken into account - * when generating candidates. This allows the grid for a hyperparameter to be non-linear: i.e., for example, linear in log space - * - * @author Alex Black - */ -@Slf4j -@EqualsAndHashCode(exclude = {"order"}, callSuper = true) -@JsonIgnoreProperties({"numValuesPerParam", "totalNumCandidates", "order", "candidateCounter", "rng", "candidate"}) -public class GridSearchCandidateGenerator extends BaseCandidateGenerator { - - /** - * In what order should candidates be generated?
- * Sequential: generate candidates in order. The first hyperparameter will be changed most rapidly, and the last - * will be changed least rapidly.
- * RandomOrder: generate candidates in a random order
- * In both cases, the same candidates will be generated; only the order of generation is different - */ - public enum Mode { - Sequential, RandomOrder - } - - private final int discretizationCount; - private final Mode mode; - - private int[] numValuesPerParam; - @Getter - private int totalNumCandidates; - private Queue order; - - /** - * @param parameterSpace ParameterSpace from which to generate candidates - * @param discretizationCount For continuous parameters: into how many values should we discretize them into? - * For example, suppose continuous parameter is in range [0,1] with 3 bins: - * do [0.0, 0.5, 1.0]. Note that if all values - * @param mode {@link GridSearchCandidateGenerator.Mode} specifies the order - * in which candidates should be generated. - */ - public GridSearchCandidateGenerator(@JsonProperty("parameterSpace") ParameterSpace parameterSpace, - @JsonProperty("discretizationCount") int discretizationCount, @JsonProperty("mode") Mode mode, - @JsonProperty("dataParameters") Map dataParameters, - @JsonProperty("initDone") boolean initDone) { - super(parameterSpace, dataParameters, initDone); - this.discretizationCount = discretizationCount; - this.mode = mode; - initialize(); - } - - /** - * @param parameterSpace ParameterSpace from which to generate candidates - * @param discretizationCount For continuous parameters: into how many values should we discretize them into? - * For example, suppose continuous parameter is in range [0,1] with 3 bins: - * do [0.0, 0.5, 1.0]. Note that if all values - * @param mode {@link GridSearchCandidateGenerator.Mode} specifies the order - * in which candidates should be generated. - */ - public GridSearchCandidateGenerator(ParameterSpace parameterSpace, int discretizationCount, Mode mode, - Map dataParameters){ - this(parameterSpace, discretizationCount, mode, dataParameters, false); - } - - @Override - protected void initialize() { - super.initialize(); - - List leaves = LeafUtils.getUniqueObjects(parameterSpace.collectLeaves()); - int nParams = leaves.size(); - - //Work out for each parameter: is it continuous or discrete? - // for grid search: discrete values are grid-searchable as-is - // continuous values: discretize using 'discretizationCount' bins - // integer values: use min(max-min+1, discretizationCount) values. i.e., discretize if necessary - numValuesPerParam = new int[nParams]; - long searchSize = 1; - for (int i = 0; i < nParams; i++) { - ParameterSpace ps = leaves.get(i); - if (ps instanceof DiscreteParameterSpace) { - DiscreteParameterSpace dps = (DiscreteParameterSpace) ps; - numValuesPerParam[i] = dps.numValues(); - } else if (ps instanceof IntegerParameterSpace) { - IntegerParameterSpace ips = (IntegerParameterSpace) ps; - int min = ips.getMin(); - int max = ips.getMax(); - //Discretize, as some integer ranges are much too large to search (i.e., num. neural network units, between 100 and 1000) - numValuesPerParam[i] = Math.min(max - min + 1, discretizationCount); - } else if (ps instanceof FixedValue){ - numValuesPerParam[i] = 1; - } else { - numValuesPerParam[i] = discretizationCount; - } - searchSize *= numValuesPerParam[i]; - } - - if (searchSize >= Integer.MAX_VALUE) - throw new IllegalStateException("Invalid search: cannot process search with " + searchSize - + " candidates > Integer.MAX_VALUE"); //TODO find a more reasonable upper bound? - - order = new ConcurrentLinkedQueue<>(); - - totalNumCandidates = (int) searchSize; - switch (mode) { - case Sequential: - for (int i = 0; i < totalNumCandidates; i++) { - order.add(i); - } - break; - case RandomOrder: - List tempList = new ArrayList<>(totalNumCandidates); - for (int i = 0; i < totalNumCandidates; i++) { - tempList.add(i); - } - - Collections.shuffle(tempList, new RandomAdaptor(rng)); - order.addAll(tempList); - break; - default: - throw new RuntimeException(); - } - - } - - @Override - public boolean hasMoreCandidates() { - return !order.isEmpty(); - } - - @Override - public Candidate getCandidate() { - int next = order.remove(); - - //Next: max integer (candidate number) to values - double[] values = indexToValues(numValuesPerParam, next, totalNumCandidates); - - Object value = null; - Exception e = null; - try { - value = parameterSpace.getValue(values); - } catch (Exception e2) { - log.warn("Error getting configuration for candidate", e2); - e = e2; - } - - return new Candidate(value, candidateCounter.getAndIncrement(), values, dataParameters, e); - } - - @Override - public Class getCandidateType() { - return null; - } - - public static double[] indexToValues(int[] numValuesPerParam, int candidateIdx, int product) { - //How? first map to index of num possible values. Then: to double values in range 0 to 1 - // 0-> [0,0,0], 1-> [1,0,0], 2-> [2,0,0], 3-> [0,1,0] etc - //Based on: Nd4j Shape.ind2sub - - int countNon1 = 0; - for( int i : numValuesPerParam) - if(i > 1) - countNon1++; - - int denom = product; - int num = candidateIdx; - int[] index = new int[numValuesPerParam.length]; - - for (int i = index.length - 1; i >= 0; i--) { - denom /= numValuesPerParam[i]; - index[i] = num / denom; - num %= denom; - } - - //Now: convert indexes to values in range [0,1] - //min value -> 0 - //max value -> 1 - double[] out = new double[countNon1]; - int outIdx = 0; - for (int i = 0; i < numValuesPerParam.length; i++) { - if (numValuesPerParam[i] > 1){ - out[outIdx++] = index[i] / ((double) (numValuesPerParam[i] - 1)); - } - } - - return out; - } - - @Override - public String toString() { - return "GridSearchCandidateGenerator(mode=" + mode + ")"; - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/RandomSearchGenerator.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/RandomSearchGenerator.java deleted file mode 100644 index 04b5c8da8..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/RandomSearchGenerator.java +++ /dev/null @@ -1,93 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator; - -import lombok.EqualsAndHashCode; -import lombok.extern.slf4j.Slf4j; -import org.deeplearning4j.arbiter.optimize.api.Candidate; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import com.fasterxml.jackson.annotation.JsonCreator; -import com.fasterxml.jackson.annotation.JsonIgnoreProperties; -import com.fasterxml.jackson.annotation.JsonProperty; - -import java.util.Map; - -/** - * RandomSearchGenerator: generates candidates at random.
- * Note: if a probability distribution is provided for continuous hyperparameters, - * this will be taken into account - * when generating candidates. This allows the search to be weighted more towards - * certain values according to a probability - * density. For example: generate samples for learning rate according to log uniform distribution - * - * @author Alex Black - */ -@Slf4j -@EqualsAndHashCode(callSuper = true) -@JsonIgnoreProperties({"numValuesPerParam", "totalNumCandidates", "order", "candidateCounter", "rng", "candidate"}) -public class RandomSearchGenerator extends BaseCandidateGenerator { - - @JsonCreator - public RandomSearchGenerator(@JsonProperty("parameterSpace") ParameterSpace parameterSpace, - @JsonProperty("dataParameters") Map dataParameters, - @JsonProperty("initDone") boolean initDone) { - super(parameterSpace, dataParameters, initDone); - initialize(); - } - - public RandomSearchGenerator(ParameterSpace parameterSpace, Map dataParameters){ - this(parameterSpace, dataParameters, false); - } - - public RandomSearchGenerator(ParameterSpace parameterSpace){ - this(parameterSpace, null, false); - } - - - @Override - public boolean hasMoreCandidates() { - return true; - } - - @Override - public Candidate getCandidate() { - double[] randomValues = new double[parameterSpace.numParameters()]; - for (int i = 0; i < randomValues.length; i++) - randomValues[i] = rng.nextDouble(); - - Object value = null; - Exception e = null; - try { - value = parameterSpace.getValue(randomValues); - } catch (Exception e2) { - log.warn("Error getting configuration for candidate", e2); - e = e2; - } - - return new Candidate(value, candidateCounter.getAndIncrement(), randomValues, dataParameters, e); - } - - @Override - public Class getCandidateType() { - return null; - } - - @Override - public String toString() { - return "RandomSearchGenerator"; - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/Chromosome.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/Chromosome.java deleted file mode 100644 index 5d8d00f0f..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/Chromosome.java +++ /dev/null @@ -1,42 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic; - -import lombok.Data; - -/** - * Candidates are stored as Chromosome in the population model - * - * @author Alexandre Boulanger - */ -@Data -public class Chromosome { - /** - * The fitness score of the genes. - */ - protected final double fitness; - - /** - * The genes. - */ - protected final double[] genes; - - public Chromosome(double[] genes, double fitness) { - this.genes = genes; - this.fitness = fitness; - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/ChromosomeFactory.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/ChromosomeFactory.java deleted file mode 100644 index ede86406a..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/ChromosomeFactory.java +++ /dev/null @@ -1,51 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic; - -/** - * A factory that builds new chromosomes. Used by the GeneticSearchCandidateGenerator. - * - * @author Alexandre Boulanger - */ -public class ChromosomeFactory { - private int chromosomeLength; - - /** - * Called by the GeneticSearchCandidateGenerator. - */ - public void initializeInstance(int chromosomeLength) { - this.chromosomeLength = chromosomeLength; - } - - /** - * Create a new instance of a Chromosome - * - * @param genes The genes - * @param fitness The fitness score - * @return A new instance of Chromosome - */ - public Chromosome createChromosome(double[] genes, double fitness) { - return new Chromosome(genes, fitness); - } - - /** - * @return The number of genes in a chromosome - */ - public int getChromosomeLength() { - return chromosomeLength; - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/ArithmeticCrossover.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/ArithmeticCrossover.java deleted file mode 100644 index 978e7166b..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/ArithmeticCrossover.java +++ /dev/null @@ -1,120 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.crossover; - -import org.apache.commons.math3.random.JDKRandomGenerator; -import org.apache.commons.math3.random.RandomGenerator; -import org.apache.commons.math3.random.SynchronizedRandomGenerator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.parentselection.RandomTwoParentSelection; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.parentselection.TwoParentSelection; -import org.nd4j.common.base.Preconditions; - -/** - * A crossover operator that linearly combines the genes of two parents.
- * When a crossover is generated (with a of probability crossover rate), each genes is a linear combination of the corresponding genes of the parents. - *

- * t*parentA + (1-t)*parentB, where t is [0, 1] and different for each gene. - * - * @author Alexandre Boulanger - */ -public class ArithmeticCrossover extends TwoParentsCrossoverOperator { - private static final double DEFAULT_CROSSOVER_RATE = 0.85; - - private final double crossoverRate; - private final RandomGenerator rng; - - public static class Builder { - private double crossoverRate = DEFAULT_CROSSOVER_RATE; - private RandomGenerator rng; - private TwoParentSelection parentSelection; - - /** - * The probability that the operator generates a crossover (default 0.85). - * - * @param rate A value between 0.0 and 1.0 - */ - public Builder crossoverRate(double rate) { - Preconditions.checkState(rate >= 0.0 && rate <= 1.0, "Rate must be between 0.0 and 1.0, got %s", rate); - - this.crossoverRate = rate; - return this; - } - - /** - * Use a supplied RandomGenerator - * - * @param rng An instance of RandomGenerator - */ - public Builder randomGenerator(RandomGenerator rng) { - this.rng = rng; - return this; - } - - /** - * The parent selection behavior. Default is random parent selection. - * - * @param parentSelection An instance of TwoParentSelection - */ - public Builder parentSelection(TwoParentSelection parentSelection) { - this.parentSelection = parentSelection; - return this; - } - - public ArithmeticCrossover build() { - if (rng == null) { - rng = new SynchronizedRandomGenerator(new JDKRandomGenerator()); - } - - if (parentSelection == null) { - parentSelection = new RandomTwoParentSelection(); - } - - return new ArithmeticCrossover(this); - } - } - - private ArithmeticCrossover(ArithmeticCrossover.Builder builder) { - super(builder.parentSelection); - - this.crossoverRate = builder.crossoverRate; - this.rng = builder.rng; - } - - /** - * Has a probability crossoverRate of performing the crossover where each gene is a linear combination of:
- * t*parentA + (1-t)*parentB, where t is [0, 1] and different for each gene.
- * Otherwise, returns the genes of a random parent. - * - * @return The crossover result. See {@link CrossoverResult}. - */ - @Override - public CrossoverResult crossover() { - double[][] parents = parentSelection.selectParents(); - - double[] offspringValues = new double[parents[0].length]; - - if (rng.nextDouble() < crossoverRate) { - for (int i = 0; i < offspringValues.length; ++i) { - double t = rng.nextDouble(); - offspringValues[i] = t * parents[0][i] + (1.0 - t) * parents[1][i]; - } - return new CrossoverResult(true, offspringValues); - } - - return new CrossoverResult(false, parents[0]); - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/CrossoverOperator.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/CrossoverOperator.java deleted file mode 100644 index cfae61e09..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/CrossoverOperator.java +++ /dev/null @@ -1,45 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.crossover; - -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationModel; - -/** - * Abstract class for all crossover operators - * - * @author Alexandre Boulanger - */ -public abstract class CrossoverOperator { - protected PopulationModel populationModel; - - /** - * Will be called by the selection operator once the population model is instantiated. - */ - public void initializeInstance(PopulationModel populationModel) { - this.populationModel = populationModel; - } - - /** - * Performs the crossover - * - * @return The crossover result. See {@link CrossoverResult}. - */ - public abstract CrossoverResult crossover(); - - - -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/CrossoverResult.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/CrossoverResult.java deleted file mode 100644 index 68b7bdecb..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/CrossoverResult.java +++ /dev/null @@ -1,43 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.crossover; - -import lombok.Data; - -/** - * Returned by a crossover operator - * - * @author Alexandre Boulanger - */ -@Data -public class CrossoverResult { - /** - * If false, there was no crossover and the operator simply returned the genes of a random parent. - * If true, the genes are the result of a crossover. - */ - private final boolean isModified; - - /** - * The genes returned by the operator. - */ - private final double[] genes; - - public CrossoverResult(boolean isModified, double[] genes) { - this.isModified = isModified; - this.genes = genes; - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/KPointCrossover.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/KPointCrossover.java deleted file mode 100644 index 8a7bb3a2a..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/KPointCrossover.java +++ /dev/null @@ -1,178 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.crossover; - -import org.apache.commons.math3.random.JDKRandomGenerator; -import org.apache.commons.math3.random.RandomGenerator; -import org.apache.commons.math3.random.SynchronizedRandomGenerator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.parentselection.RandomTwoParentSelection; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.parentselection.TwoParentSelection; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.utils.CrossoverPointsGenerator; -import org.nd4j.common.base.Preconditions; - -import java.util.Deque; - -/** -* The K-Point crossover will select at random multiple crossover points.
-* Each gene comes from one of the two parents. Each time a crossover point is reached, the parent is switched. -*/ -public class KPointCrossover extends TwoParentsCrossoverOperator { - private static final double DEFAULT_CROSSOVER_RATE = 0.85; - private static final int DEFAULT_MIN_CROSSOVER = 1; - private static final int DEFAULT_MAX_CROSSOVER = 4; - - private final double crossoverRate; - private final int minCrossovers; - private final int maxCrossovers; - - private final RandomGenerator rng; - - public static class Builder { - private double crossoverRate = DEFAULT_CROSSOVER_RATE; - private int minCrossovers = DEFAULT_MIN_CROSSOVER; - private int maxCrossovers = DEFAULT_MAX_CROSSOVER; - private RandomGenerator rng; - private TwoParentSelection parentSelection; - - /** - * The probability that the operator generates a crossover (default 0.85). - * - * @param rate A value between 0.0 and 1.0 - */ - public Builder crossoverRate(double rate) { - Preconditions.checkState(rate >= 0.0 && rate <= 1.0, "Rate must be between 0.0 and 1.0, got %s", rate); - - this.crossoverRate = rate; - return this; - } - - /** - * The number of crossovers points (default is min 1, max 4) - * - * @param min The minimum number - * @param max The maximum number - */ - public Builder numCrossovers(int min, int max) { - Preconditions.checkState(max >= 0 && min >= 0, "Min and max must be positive"); - Preconditions.checkState(max >= min, "Max must be greater or equal to min"); - - this.minCrossovers = min; - this.maxCrossovers = max; - return this; - } - - /** - * Use a fixed number of crossover points - * - * @param num The number of crossovers - */ - public Builder numCrossovers(int num) { - Preconditions.checkState(num >= 0, "Num must be positive"); - - this.minCrossovers = num; - this.maxCrossovers = num; - return this; - } - - /** - * Use a supplied RandomGenerator - * - * @param rng An instance of RandomGenerator - */ - public Builder randomGenerator(RandomGenerator rng) { - this.rng = rng; - return this; - } - - /** - * The parent selection behavior. Default is random parent selection. - * - * @param parentSelection An instance of TwoParentSelection - */ - public Builder parentSelection(TwoParentSelection parentSelection) { - this.parentSelection = parentSelection; - return this; - } - - public KPointCrossover build() { - if (rng == null) { - rng = new SynchronizedRandomGenerator(new JDKRandomGenerator()); - } - - if (parentSelection == null) { - parentSelection = new RandomTwoParentSelection(); - } - - return new KPointCrossover(this); - } - } - - private CrossoverPointsGenerator crossoverPointsGenerator; - - private KPointCrossover(KPointCrossover.Builder builder) { - super(builder.parentSelection); - - this.crossoverRate = builder.crossoverRate; - this.maxCrossovers = builder.maxCrossovers; - this.minCrossovers = builder.minCrossovers; - this.rng = builder.rng; - } - - private CrossoverPointsGenerator getCrossoverPointsGenerator(int chromosomeLength) { - if (crossoverPointsGenerator == null) { - crossoverPointsGenerator = - new CrossoverPointsGenerator(chromosomeLength, minCrossovers, maxCrossovers, rng); - } - - return crossoverPointsGenerator; - } - - /** - * Has a probability crossoverRate of performing the crossover where the operator will select at random multiple crossover points.
- * Each gene comes from one of the two parents. Each time a crossover point is reached, the parent is switched.
- * Otherwise, returns the genes of a random parent. - * - * @return The crossover result. See {@link CrossoverResult}. - */ - @Override - public CrossoverResult crossover() { - double[][] parents = parentSelection.selectParents(); - - boolean isModified = false; - double[] resultGenes = parents[0]; - - if (rng.nextDouble() < crossoverRate) { - // Select crossover points - Deque crossoverPoints = getCrossoverPointsGenerator(parents[0].length).getCrossoverPoints(); - - // Crossover - resultGenes = new double[parents[0].length]; - int currentParent = 0; - int nextCrossover = crossoverPoints.pop(); - for (int i = 0; i < resultGenes.length; ++i) { - if (i == nextCrossover) { - currentParent = currentParent == 0 ? 1 : 0; - nextCrossover = crossoverPoints.pop(); - } - resultGenes[i] = parents[currentParent][i]; - } - isModified = true; - } - - return new CrossoverResult(isModified, resultGenes); - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/SinglePointCrossover.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/SinglePointCrossover.java deleted file mode 100644 index cbeca1232..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/SinglePointCrossover.java +++ /dev/null @@ -1,123 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.crossover; - -import org.apache.commons.math3.random.JDKRandomGenerator; -import org.apache.commons.math3.random.RandomGenerator; -import org.apache.commons.math3.random.SynchronizedRandomGenerator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.parentselection.RandomTwoParentSelection; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.parentselection.TwoParentSelection; -import org.nd4j.common.base.Preconditions; - -/** - * The single point crossover will select a random point where every genes before that point comes from one parent - * and after which every genes comes from the other parent. - * - * @author Alexandre Boulanger - */ -public class SinglePointCrossover extends TwoParentsCrossoverOperator { - private static final double DEFAULT_CROSSOVER_RATE = 0.85; - - private final RandomGenerator rng; - private final double crossoverRate; - - public static class Builder { - private double crossoverRate = DEFAULT_CROSSOVER_RATE; - private RandomGenerator rng; - private TwoParentSelection parentSelection; - - /** - * The probability that the operator generates a crossover (default 0.85). - * - * @param rate A value between 0.0 and 1.0 - */ - public Builder crossoverRate(double rate) { - Preconditions.checkState(rate >= 0.0 && rate <= 1.0, "Rate must be between 0.0 and 1.0, got %s", rate); - - this.crossoverRate = rate; - return this; - } - - /** - * Use a supplied RandomGenerator - * - * @param rng An instance of RandomGenerator - */ - public Builder randomGenerator(RandomGenerator rng) { - this.rng = rng; - return this; - } - - /** - * The parent selection behavior. Default is random parent selection. - * - * @param parentSelection An instance of TwoParentSelection - */ - public Builder parentSelection(TwoParentSelection parentSelection) { - this.parentSelection = parentSelection; - return this; - } - - public SinglePointCrossover build() { - if (rng == null) { - rng = new SynchronizedRandomGenerator(new JDKRandomGenerator()); - } - - if (parentSelection == null) { - parentSelection = new RandomTwoParentSelection(); - } - - return new SinglePointCrossover(this); - } - } - - private SinglePointCrossover(SinglePointCrossover.Builder builder) { - super(builder.parentSelection); - - this.crossoverRate = builder.crossoverRate; - this.rng = builder.rng; - } - - /** - * Has a probability crossoverRate of performing the crossover where the operator will select a random crossover point.
- * Each gene before this point comes from one of the two parents and each gene at or after this point comes from the other parent. - * Otherwise, returns the genes of a random parent. - * - * @return The crossover result. See {@link CrossoverResult}. - */ - public CrossoverResult crossover() { - double[][] parents = parentSelection.selectParents(); - - boolean isModified = false; - double[] resultGenes = parents[0]; - - if (rng.nextDouble() < crossoverRate) { - int chromosomeLength = parents[0].length; - - // Crossover - resultGenes = new double[chromosomeLength]; - - int crossoverPoint = rng.nextInt(chromosomeLength); - for (int i = 0; i < resultGenes.length; ++i) { - resultGenes[i] = ((i < crossoverPoint) ? parents[0] : parents[1])[i]; - } - isModified = true; - } - - return new CrossoverResult(isModified, resultGenes); - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/TwoParentsCrossoverOperator.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/TwoParentsCrossoverOperator.java deleted file mode 100644 index 69f1fb105..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/TwoParentsCrossoverOperator.java +++ /dev/null @@ -1,46 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.crossover; - -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.parentselection.TwoParentSelection; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationModel; - -/** - * Abstract class for all crossover operators that applies to two parents. - * - * @author Alexandre Boulanger - */ -public abstract class TwoParentsCrossoverOperator extends CrossoverOperator { - - protected final TwoParentSelection parentSelection; - - /** - * @param parentSelection A parent selection that selects two parents. - */ - protected TwoParentsCrossoverOperator(TwoParentSelection parentSelection) { - this.parentSelection = parentSelection; - } - - /** - * Will be called by the selection operator once the population model is instantiated. - */ - @Override - public void initializeInstance(PopulationModel populationModel) { - super.initializeInstance(populationModel); - parentSelection.initializeInstance(populationModel.getPopulation()); - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/UniformCrossover.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/UniformCrossover.java deleted file mode 100644 index 8912a1298..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/UniformCrossover.java +++ /dev/null @@ -1,136 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.crossover; - -import org.apache.commons.math3.random.JDKRandomGenerator; -import org.apache.commons.math3.random.RandomGenerator; -import org.apache.commons.math3.random.SynchronizedRandomGenerator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.parentselection.RandomTwoParentSelection; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.parentselection.TwoParentSelection; -import org.nd4j.common.base.Preconditions; - -/** - * The uniform crossover will, for each gene, randomly select the parent that donates the gene. - * - * @author Alexandre Boulanger - */ -public class UniformCrossover extends TwoParentsCrossoverOperator { - private static final double DEFAULT_CROSSOVER_RATE = 0.85; - private static final double DEFAULT_PARENT_BIAS_FACTOR = 0.5; - - private final double crossoverRate; - private final double parentBiasFactor; - private final RandomGenerator rng; - - public static class Builder { - private double crossoverRate = DEFAULT_CROSSOVER_RATE; - private double parentBiasFactor = DEFAULT_PARENT_BIAS_FACTOR; - private RandomGenerator rng; - private TwoParentSelection parentSelection; - - /** - * The probability that the operator generates a crossover (default 0.85). - * - * @param rate A value between 0.0 and 1.0 - */ - public Builder crossoverRate(double rate) { - Preconditions.checkState(rate >= 0.0 && rate <= 1.0, "Rate must be between 0.0 and 1.0, got %s", rate); - - this.crossoverRate = rate; - return this; - } - - /** - * A factor that will introduce a bias in the parent selection.
- * - * @param factor In the range [0, 1]. 0 will only select the first parent while 1 only select the second one. The default is 0.5; no bias. - */ - public Builder parentBiasFactor(double factor) { - Preconditions.checkState(factor >= 0.0 && factor <= 1.0, "Factor must be between 0.0 and 1.0, got %s", - factor); - - this.parentBiasFactor = factor; - return this; - } - - /** - * Use a supplied RandomGenerator - * - * @param rng An instance of RandomGenerator - */ - public Builder randomGenerator(RandomGenerator rng) { - this.rng = rng; - return this; - } - - /** - * The parent selection behavior. Default is random parent selection. - * - * @param parentSelection An instance of TwoParentSelection - */ - public Builder parentSelection(TwoParentSelection parentSelection) { - this.parentSelection = parentSelection; - return this; - } - - public UniformCrossover build() { - if (rng == null) { - rng = new SynchronizedRandomGenerator(new JDKRandomGenerator()); - } - if (parentSelection == null) { - parentSelection = new RandomTwoParentSelection(); - } - return new UniformCrossover(this); - } - } - - private UniformCrossover(UniformCrossover.Builder builder) { - super(builder.parentSelection); - - this.crossoverRate = builder.crossoverRate; - this.parentBiasFactor = builder.parentBiasFactor; - this.rng = builder.rng; - } - - /** - * Has a probability crossoverRate of performing the crossover where the operator will select randomly which parent donates the gene.
- * One of the parent may be favored if the bias is different than 0.5 - * Otherwise, returns the genes of a random parent. - * - * @return The crossover result. See {@link CrossoverResult}. - */ - @Override - public CrossoverResult crossover() { - // select the parents - double[][] parents = parentSelection.selectParents(); - - double[] resultGenes = parents[0]; - boolean isModified = false; - - if (rng.nextDouble() < crossoverRate) { - // Crossover - resultGenes = new double[parents[0].length]; - - for (int i = 0; i < resultGenes.length; ++i) { - resultGenes[i] = ((rng.nextDouble() < parentBiasFactor) ? parents[0] : parents[1])[i]; - } - isModified = true; - } - - return new CrossoverResult(isModified, resultGenes); - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/parentselection/ParentSelection.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/parentselection/ParentSelection.java deleted file mode 100644 index 4fa9ed17c..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/parentselection/ParentSelection.java +++ /dev/null @@ -1,44 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.parentselection; - -import org.deeplearning4j.arbiter.optimize.generator.genetic.Chromosome; - -import java.util.List; - -/** - * Abstract class for all parent selection behaviors - * - * @author Alexandre Boulanger - */ -public abstract class ParentSelection { - protected List population; - - /** - * Will be called by the crossover operator once the population model is instantiated. - */ - public void initializeInstance(List population) { - this.population = population; - } - - /** - * Performs the parent selection - * - * @return An array of parents genes. The outer array are the parents, and the inner array are the genes. - */ - public abstract double[][] selectParents(); -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/parentselection/RandomTwoParentSelection.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/parentselection/RandomTwoParentSelection.java deleted file mode 100644 index 81baeb07c..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/parentselection/RandomTwoParentSelection.java +++ /dev/null @@ -1,65 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.parentselection; - -import org.apache.commons.math3.random.JDKRandomGenerator; -import org.apache.commons.math3.random.RandomGenerator; -import org.apache.commons.math3.random.SynchronizedRandomGenerator; - -/** - * A parent selection behavior that returns two random parents. - * - * @author Alexandre Boulanger - */ -public class RandomTwoParentSelection extends TwoParentSelection { - - private final RandomGenerator rng; - - public RandomTwoParentSelection() { - this(new SynchronizedRandomGenerator(new JDKRandomGenerator())); - } - - /** - * Use a supplied RandomGenerator - * - * @param rng An instance of RandomGenerator - */ - public RandomTwoParentSelection(RandomGenerator rng) { - this.rng = rng; - } - - /** - * Selects two random parents - * - * @return An array of parents genes. The outer array are the parents, and the inner array are the genes. - */ - @Override - public double[][] selectParents() { - double[][] parents = new double[2][]; - - int parent1Idx = rng.nextInt(population.size()); - int parent2Idx; - do { - parent2Idx = rng.nextInt(population.size()); - } while (parent1Idx == parent2Idx); - - parents[0] = population.get(parent1Idx).getGenes(); - parents[1] = population.get(parent2Idx).getGenes(); - - return parents; - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/parentselection/TwoParentSelection.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/parentselection/TwoParentSelection.java deleted file mode 100644 index b4b4f4843..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/parentselection/TwoParentSelection.java +++ /dev/null @@ -1,25 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.parentselection; - -/** - * Abstract class for all parent selection behaviors that selects two parents. - * - * @author Alexandre Boulanger - */ -public abstract class TwoParentSelection extends ParentSelection { -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/utils/CrossoverPointsGenerator.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/utils/CrossoverPointsGenerator.java deleted file mode 100644 index 7e6e799e7..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/crossover/utils/CrossoverPointsGenerator.java +++ /dev/null @@ -1,68 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.utils; - -import org.apache.commons.math3.random.RandomGenerator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.KPointCrossover; - -import java.util.*; - -/** - * A helper class used by {@link KPointCrossover} to generate the crossover points - * - * @author Alexandre Boulanger - */ -public class CrossoverPointsGenerator { - private final int minCrossovers; - private final int maxCrossovers; - private final RandomGenerator rng; - private List parameterIndexes; - - /** - * Constructor - * - * @param chromosomeLength The number of genes - * @param minCrossovers The minimum number of crossover points to generate - * @param maxCrossovers The maximum number of crossover points to generate - * @param rng A RandomGenerator instance - */ - public CrossoverPointsGenerator(int chromosomeLength, int minCrossovers, int maxCrossovers, RandomGenerator rng) { - this.minCrossovers = minCrossovers; - this.maxCrossovers = maxCrossovers; - this.rng = rng; - parameterIndexes = new ArrayList(); - for (int i = 0; i < chromosomeLength; ++i) { - parameterIndexes.add(i); - } - } - - /** - * Generate a list of crossover points. - * - * @return An ordered list of crossover point indexes and with Integer.MAX_VALUE as the last element - */ - public Deque getCrossoverPoints() { - Collections.shuffle(parameterIndexes); - List crossoverPointLists = - parameterIndexes.subList(0, rng.nextInt(maxCrossovers - minCrossovers) + minCrossovers); - Collections.sort(crossoverPointLists); - Deque crossoverPoints = new ArrayDeque(crossoverPointLists); - crossoverPoints.add(Integer.MAX_VALUE); - - return crossoverPoints; - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/culling/CullOperator.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/culling/CullOperator.java deleted file mode 100644 index 95452a7eb..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/culling/CullOperator.java +++ /dev/null @@ -1,41 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.culling; - -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationModel; - -/** - * The cull operator will remove from the population the least desirables chromosomes. - * - * @author Alexandre Boulanger - */ -public interface CullOperator { - /** - * Will be called by the population model once created. - */ - void initializeInstance(PopulationModel populationModel); - - /** - * Cull the population to the culled size. - */ - void cullPopulation(); - - /** - * @return The target population size after culling. - */ - int getCulledSize(); -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/culling/LeastFitCullOperator.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/culling/LeastFitCullOperator.java deleted file mode 100644 index 6ec5c64df..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/culling/LeastFitCullOperator.java +++ /dev/null @@ -1,50 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.culling; - -/** - * An elitist cull operator that discards the chromosomes with the worst fitness while keeping the best ones. - * - * @author Alexandre Boulanger - */ -public class LeastFitCullOperator extends RatioCullOperator { - - /** - * The default cull ratio is 1/3. - */ - public LeastFitCullOperator() { - super(); - } - - /** - * @param cullRatio The ratio of the maximum population size to be culled.
- * For example, a ratio of 1/3 on a population with a maximum size of 30 will cull back a given population to 20. - */ - public LeastFitCullOperator(double cullRatio) { - super(cullRatio); - } - - /** - * Will discard the chromosomes with the worst fitness until the population size fall back at the culled size. - */ - @Override - public void cullPopulation() { - while (population.size() > culledSize) { - population.remove(population.size() - 1); - } - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/culling/RatioCullOperator.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/culling/RatioCullOperator.java deleted file mode 100644 index 9c838acc8..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/culling/RatioCullOperator.java +++ /dev/null @@ -1,70 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.culling; - -import org.deeplearning4j.arbiter.optimize.generator.genetic.Chromosome; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationModel; -import org.nd4j.common.base.Preconditions; - -import java.util.List; - -/** - * An abstract base for cull operators that culls back the population to a ratio of its maximum size. - * - * @author Alexandre Boulanger - */ -public abstract class RatioCullOperator implements CullOperator { - private static final double DEFAULT_CULL_RATIO = 1.0 / 3.0; - protected int culledSize; - protected List population; - protected final double cullRatio; - - /** - * @param cullRatio The ratio of the maximum population size to be culled.
- * For example, a ratio of 1/3 on a population with a maximum size of 30 will cull back a given population to 20. - */ - public RatioCullOperator(double cullRatio) { - Preconditions.checkState(cullRatio >= 0.0 && cullRatio <= 1.0, "Cull ratio must be between 0.0 and 1.0, got %s", - cullRatio); - - this.cullRatio = cullRatio; - } - - /** - * The default cull ratio is 1/3 - */ - public RatioCullOperator() { - this(DEFAULT_CULL_RATIO); - } - - /** - * Will be called by the population model once created. - */ - public void initializeInstance(PopulationModel populationModel) { - this.population = populationModel.getPopulation(); - culledSize = (int) (populationModel.getPopulationSize() * (1.0 - cullRatio) + 0.5); - } - - /** - * @return The target population size after culling. - */ - @Override - public int getCulledSize() { - return culledSize; - } - -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/exceptions/GeneticGenerationException.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/exceptions/GeneticGenerationException.java deleted file mode 100644 index b0a9a42b3..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/exceptions/GeneticGenerationException.java +++ /dev/null @@ -1,23 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.exceptions; - -public class GeneticGenerationException extends RuntimeException { - public GeneticGenerationException(String message) { - super(message); - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/mutation/MutationOperator.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/mutation/MutationOperator.java deleted file mode 100644 index 56f459a73..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/mutation/MutationOperator.java +++ /dev/null @@ -1,33 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.mutation; - -/** - * The mutation operator will apply a mutation to the given genes. - * - * @author Alexandre Boulanger - */ -public interface MutationOperator { - - /** - * Performs a mutation. - * - * @param genes The genes to be mutated - * @return True if the genes were mutated, otherwise false. - */ - boolean mutate(double[] genes); -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/mutation/RandomMutationOperator.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/mutation/RandomMutationOperator.java deleted file mode 100644 index ba10676b6..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/mutation/RandomMutationOperator.java +++ /dev/null @@ -1,93 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.mutation; - -import org.apache.commons.math3.random.JDKRandomGenerator; -import org.apache.commons.math3.random.RandomGenerator; -import org.apache.commons.math3.random.SynchronizedRandomGenerator; -import org.nd4j.common.base.Preconditions; - -/** - * A mutation operator where each gene has a chance of being mutated with a mutation rate probability. - * - * @author Alexandre Boulanger - */ -public class RandomMutationOperator implements MutationOperator { - private static final double DEFAULT_MUTATION_RATE = 0.005; - - private final double mutationRate; - private final RandomGenerator rng; - - public static class Builder { - private double mutationRate = DEFAULT_MUTATION_RATE; - private RandomGenerator rng; - - /** - * Each gene will have this probability of being mutated. - * - * @param rate The mutation rate. (default 0.005) - */ - public Builder mutationRate(double rate) { - Preconditions.checkState(rate >= 0.0 && rate <= 1.0, "Rate must be between 0.0 and 1.0, got %s", rate); - - this.mutationRate = rate; - return this; - } - - /** - * Use a supplied RandomGenerator - * - * @param rng An instance of RandomGenerator - */ - public Builder randomGenerator(RandomGenerator rng) { - this.rng = rng; - return this; - } - - public RandomMutationOperator build() { - if (rng == null) { - rng = new SynchronizedRandomGenerator(new JDKRandomGenerator()); - } - return new RandomMutationOperator(this); - } - } - - private RandomMutationOperator(RandomMutationOperator.Builder builder) { - this.mutationRate = builder.mutationRate; - this.rng = builder.rng; - } - - /** - * Performs the mutation. Each gene has a mutation rate probability of being mutated. - * - * @param genes The genes to be mutated - * @return True if the genes were mutated, otherwise false. - */ - @Override - public boolean mutate(double[] genes) { - boolean hasMutation = false; - - for (int i = 0; i < genes.length; ++i) { - if (rng.nextDouble() < mutationRate) { - genes[i] = rng.nextDouble(); - hasMutation = true; - } - } - - return hasMutation; - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/population/EmptyPopulationInitializer.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/population/EmptyPopulationInitializer.java deleted file mode 100644 index 20c147385..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/population/EmptyPopulationInitializer.java +++ /dev/null @@ -1,41 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.population; - -import org.deeplearning4j.arbiter.optimize.generator.genetic.Chromosome; - -import java.util.ArrayList; -import java.util.List; - -/** - * A population initializer that build an empty population. - * - * @author Alexandre Boulanger - */ -public class EmptyPopulationInitializer implements PopulationInitializer { - - /** - * Initialize an empty population - * - * @param size The maximum size of the population. - * @return The initialized population. - */ - @Override - public List getInitializedPopulation(int size) { - return new ArrayList<>(size); - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/population/PopulationInitializer.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/population/PopulationInitializer.java deleted file mode 100644 index 40dd4f438..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/population/PopulationInitializer.java +++ /dev/null @@ -1,36 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.population; - -import org.deeplearning4j.arbiter.optimize.generator.genetic.Chromosome; - -import java.util.List; - -/** - * An initializer that construct the population used by the population model. - * - * @author Alexandre Boulanger - */ -public interface PopulationInitializer { - /** - * Called by the population model to construct the population - * - * @param size The maximum size of the population - * @return An initialized population - */ - List getInitializedPopulation(int size); -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/population/PopulationListener.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/population/PopulationListener.java deleted file mode 100644 index aca266b57..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/population/PopulationListener.java +++ /dev/null @@ -1,35 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.population; - -import org.deeplearning4j.arbiter.optimize.generator.genetic.Chromosome; - -import java.util.List; - -/** - * A listener that is called when the population changes. - * - * @author Alexandre Boulanger - */ -public interface PopulationListener { - /** - * Called after the population has changed. - * - * @param population The population after it has changed. - */ - void onChanged(List population); -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/population/PopulationModel.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/population/PopulationModel.java deleted file mode 100644 index 9c5a4c7e1..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/population/PopulationModel.java +++ /dev/null @@ -1,182 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.population; - -import lombok.Getter; -import org.deeplearning4j.arbiter.optimize.generator.genetic.Chromosome; -import org.deeplearning4j.arbiter.optimize.generator.genetic.culling.CullOperator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.culling.LeastFitCullOperator; - -import java.util.ArrayList; -import java.util.Collections; -import java.util.Comparator; -import java.util.List; - -/** - * The population model handles all aspects of the population (initialization, additions and culling) - * - * @author Alexandre Boulanger - */ -public class PopulationModel { - private static final int DEFAULT_POPULATION_SIZE = 30; - - private final CullOperator cullOperator; - private final List populationListeners = new ArrayList<>(); - private Comparator chromosomeComparator; - - /** - * The maximum population size - */ - @Getter - private final int populationSize; - - /** - * The population - */ - @Getter - public final List population; - - /** - * A comparator used when higher fitness value is better - */ - public static class MaximizeScoreComparator implements Comparator { - @Override - public int compare(Chromosome lhs, Chromosome rhs) { - return -Double.compare(lhs.getFitness(), rhs.getFitness()); - } - } - - /** - * A comparator used when lower fitness value is better - */ - public static class MinimizeScoreComparator implements Comparator { - @Override - public int compare(Chromosome lhs, Chromosome rhs) { - return Double.compare(lhs.getFitness(), rhs.getFitness()); - } - } - - public static class Builder { - private int populationSize = DEFAULT_POPULATION_SIZE; - private PopulationInitializer populationInitializer; - private CullOperator cullOperator; - - /** - * Use an alternate population initialization behavior. Default is empty population. - * - * @param populationInitializer An instance of PopulationInitializer - */ - public Builder populationInitializer(PopulationInitializer populationInitializer) { - this.populationInitializer = populationInitializer; - return this; - } - - /** - * The maximum population size.
- * If using a ratio based culling, using a population with culled size of around 1.5 to 2 times the number of genes generally gives good results. - * (e.g. For a chromosome having 10 genes, the culled size should be between 15 and 20. And with a cull ratio of 1/3 we should set the population size to 23 to 30. (15 / (1 - 1/3)), rounded up) - * - * @param size The maximum size of the population - */ - public Builder populationSize(int size) { - populationSize = size; - return this; - } - - /** - * Use an alternate cull operator behavior. Default is least fit culling. - * - * @param cullOperator An instance of a CullOperator - */ - public Builder cullOperator(CullOperator cullOperator) { - this.cullOperator = cullOperator; - return this; - } - - public PopulationModel build() { - if (cullOperator == null) { - cullOperator = new LeastFitCullOperator(); - } - - if (populationInitializer == null) { - populationInitializer = new EmptyPopulationInitializer(); - } - - return new PopulationModel(this); - } - - } - - public PopulationModel(PopulationModel.Builder builder) { - populationSize = builder.populationSize; - population = new ArrayList<>(builder.populationSize); - PopulationInitializer populationInitializer = builder.populationInitializer; - - List initializedPopulation = populationInitializer.getInitializedPopulation(populationSize); - population.clear(); - population.addAll(initializedPopulation); - - cullOperator = builder.cullOperator; - cullOperator.initializeInstance(this); - } - - /** - * Called by the GeneticSearchCandidateGenerator - */ - public void initializeInstance(boolean minimizeScore) { - chromosomeComparator = minimizeScore ? new MinimizeScoreComparator() : new MaximizeScoreComparator(); - } - - /** - * Add a PopulationListener to the list of change listeners - * @param listener A PopulationListener instance - */ - public void addListener(PopulationListener listener) { - populationListeners.add(listener); - } - - /** - * Add a Chromosome to the population and call the PopulationListeners. Culling may be triggered. - * - * @param element The chromosome to be added - */ - public void add(Chromosome element) { - if (population.size() == populationSize) { - cullOperator.cullPopulation(); - } - - population.add(element); - - Collections.sort(population, chromosomeComparator); - - triggerPopulationChangedListeners(population); - } - - /** - * @return Return false when the population is below the culled size, otherwise true.
- * Used by the selection operator to know if the population is still too small and should generate random genes. - */ - public boolean isReadyToBreed() { - return population.size() >= cullOperator.getCulledSize(); - } - - private void triggerPopulationChangedListeners(List population) { - for (PopulationListener listener : populationListeners) { - listener.onChanged(population); - } - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/selection/GeneticSelectionOperator.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/selection/GeneticSelectionOperator.java deleted file mode 100644 index 40b6a49c8..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/selection/GeneticSelectionOperator.java +++ /dev/null @@ -1,197 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.selection; - -import org.apache.commons.math3.random.JDKRandomGenerator; -import org.apache.commons.math3.random.RandomGenerator; -import org.apache.commons.math3.random.SynchronizedRandomGenerator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.ChromosomeFactory; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.CrossoverOperator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.CrossoverResult; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.SinglePointCrossover; -import org.deeplearning4j.arbiter.optimize.generator.genetic.exceptions.GeneticGenerationException; -import org.deeplearning4j.arbiter.optimize.generator.genetic.mutation.MutationOperator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.mutation.RandomMutationOperator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationModel; - -import java.util.Arrays; - -/** - * A selection operator that will generate random genes initially. Once the population has reached the culled size, - * will start to generate offsprings of parents selected in the population. - * - * @author Alexandre Boulanger - */ -public class GeneticSelectionOperator extends SelectionOperator { - - private final static int PREVIOUS_GENES_TO_KEEP = 100; - private final static int MAX_NUM_GENERATION_ATTEMPTS = 1024; - - private final CrossoverOperator crossoverOperator; - private final MutationOperator mutationOperator; - private final RandomGenerator rng; - private double[][] previousGenes = new double[PREVIOUS_GENES_TO_KEEP][]; - private int previousGenesIdx = 0; - - public static class Builder { - private ChromosomeFactory chromosomeFactory; - private PopulationModel populationModel; - private CrossoverOperator crossoverOperator; - private MutationOperator mutationOperator; - private RandomGenerator rng; - - /** - * Use an alternate crossover behavior. Default is SinglePointCrossover. - * - * @param crossoverOperator An instance of CrossoverOperator - */ - public Builder crossoverOperator(CrossoverOperator crossoverOperator) { - this.crossoverOperator = crossoverOperator; - return this; - } - - /** - * Use an alternate mutation behavior. Default is RandomMutationOperator. - * - * @param mutationOperator An instance of MutationOperator - */ - public Builder mutationOperator(MutationOperator mutationOperator) { - this.mutationOperator = mutationOperator; - return this; - } - - /** - * Use a supplied RandomGenerator - * - * @param rng An instance of RandomGenerator - */ - public Builder randomGenerator(RandomGenerator rng) { - this.rng = rng; - return this; - } - - public GeneticSelectionOperator build() { - if (crossoverOperator == null) { - crossoverOperator = new SinglePointCrossover.Builder().build(); - } - - if (mutationOperator == null) { - mutationOperator = new RandomMutationOperator.Builder().build(); - } - - if (rng == null) { - rng = new SynchronizedRandomGenerator(new JDKRandomGenerator()); - } - - return new GeneticSelectionOperator(crossoverOperator, mutationOperator, rng); - } - } - - private GeneticSelectionOperator(CrossoverOperator crossoverOperator, MutationOperator mutationOperator, - RandomGenerator rng) { - this.crossoverOperator = crossoverOperator; - this.mutationOperator = mutationOperator; - this.rng = rng; - } - - /** - * Called by GeneticSearchCandidateGenerator - */ - @Override - public void initializeInstance(PopulationModel populationModel, ChromosomeFactory chromosomeFactory) { - super.initializeInstance(populationModel, chromosomeFactory); - crossoverOperator.initializeInstance(populationModel); - } - - /** - * Build a new set of genes. Has two distinct modes of operation - *

- * @return Returns the generated set of genes - * @throws GeneticGenerationException If buildNextGenes() can't generate a set that has not already been tried, - * or if the crossover and the mutation operators can't generate a set, - * this exception is thrown. - */ - @Override - public double[] buildNextGenes() { - double[] result; - - boolean hasAlreadyBeenTried; - int attemptsRemaining = MAX_NUM_GENERATION_ATTEMPTS; - do { - if (populationModel.isReadyToBreed()) { - result = buildOffspring(); - } else { - result = buildRandomGenes(); - } - - hasAlreadyBeenTried = hasAlreadyBeenTried(result); - if (hasAlreadyBeenTried && --attemptsRemaining == 0) { - throw new GeneticGenerationException("Failed to generate a set of genes not already tried."); - } - } while (hasAlreadyBeenTried); - - previousGenes[previousGenesIdx] = result; - previousGenesIdx = ++previousGenesIdx % previousGenes.length; - - return result; - } - - private boolean hasAlreadyBeenTried(double[] genes) { - for (int i = 0; i < previousGenes.length; ++i) { - double[] current = previousGenes[i]; - if (current != null && Arrays.equals(current, genes)) { - return true; - } - } - - return false; - } - - private double[] buildOffspring() { - double[] offspringValues; - - boolean isModified; - int attemptsRemaining = MAX_NUM_GENERATION_ATTEMPTS; - do { - CrossoverResult crossoverResult = crossoverOperator.crossover(); - offspringValues = crossoverResult.getGenes(); - isModified = crossoverResult.isModified(); - isModified |= mutationOperator.mutate(offspringValues); - - if (!isModified && --attemptsRemaining == 0) { - throw new GeneticGenerationException( - String.format("Crossover and mutation operators failed to generate a new set of genes after %s attempts.", - MAX_NUM_GENERATION_ATTEMPTS)); - } - } while (!isModified); - - return offspringValues; - } - - private double[] buildRandomGenes() { - double[] randomValues = new double[chromosomeFactory.getChromosomeLength()]; - for (int i = 0; i < randomValues.length; ++i) { - randomValues[i] = rng.nextDouble(); - } - - return randomValues; - } - -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/selection/SelectionOperator.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/selection/SelectionOperator.java deleted file mode 100644 index 7be470ea6..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/genetic/selection/SelectionOperator.java +++ /dev/null @@ -1,44 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.genetic.selection; - -import org.deeplearning4j.arbiter.optimize.generator.genetic.ChromosomeFactory; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationModel; - -/** - * An abstract class for all selection operators. Used by the GeneticSearchCandidateGenerator to generate new candidates. - * - * @author Alexandre Boulanger - */ -public abstract class SelectionOperator { - protected PopulationModel populationModel; - protected ChromosomeFactory chromosomeFactory; - - /** - * Called by GeneticSearchCandidateGenerator - */ - public void initializeInstance(PopulationModel populationModel, ChromosomeFactory chromosomeFactory) { - - this.populationModel = populationModel; - this.chromosomeFactory = chromosomeFactory; - } - - /** - * Generate a new set of genes. - */ - public abstract double[] buildNextGenes(); -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/util/SerializedSupplier.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/util/SerializedSupplier.java deleted file mode 100644 index 81109816d..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/generator/util/SerializedSupplier.java +++ /dev/null @@ -1,46 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.generator.util; - -import org.nd4j.common.function.Supplier; - -import java.io.*; - -public class SerializedSupplier implements Serializable, Supplier { - - private byte[] asBytes; - - public SerializedSupplier(T obj){ - try(ByteArrayOutputStream baos = new ByteArrayOutputStream(); ObjectOutputStream oos = new ObjectOutputStream(baos)){ - oos.writeObject(obj); - oos.flush(); - oos.close(); - asBytes = baos.toByteArray(); - } catch (Exception e){ - throw new RuntimeException("Error serializing object - must be serializable",e); - } - } - - @Override - public T get() { - try(ObjectInputStream ois = new ObjectInputStream(new ByteArrayInputStream(asBytes))){ - return (T)ois.readObject(); - } catch (Exception e){ - throw new RuntimeException("Error deserializing object",e); - } - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/BooleanSpace.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/BooleanSpace.java deleted file mode 100644 index fd20afb47..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/BooleanSpace.java +++ /dev/null @@ -1,76 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.parameter; - -import lombok.EqualsAndHashCode; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; - -import java.util.Collections; -import java.util.List; -import java.util.Map; - -/** - * BooleanParameterSpace is a {@code ParameterSpace}; Defines {True, False} as a parameter space - * If argument to setValue is less than or equal to 0.5 it will return True else False - * - * @author susaneraly - */ -@EqualsAndHashCode -public class BooleanSpace implements ParameterSpace { - private int index = -1; - - @Override - public Boolean getValue(double[] input) { - if (index == -1) { - throw new IllegalStateException("Cannot get value: ParameterSpace index has not been set"); - } - if (input[index] <= 0.5) return Boolean.TRUE; - else return Boolean.FALSE; - } - - @Override - public int numParameters() { - return 1; - } - - @Override - public List collectLeaves() { - return Collections.singletonList((ParameterSpace) this); - } - - @Override - public Map getNestedSpaces() { - return Collections.emptyMap(); - } - - @Override - public boolean isLeaf() { - return true; - } - - @Override - public void setIndices(int... indices) { - if (indices == null || indices.length != 1) - throw new IllegalArgumentException("Invalid index"); - this.index = indices[0]; - } - - @Override - public String toString() { - return "BooleanSpace()"; - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/FixedValue.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/FixedValue.java deleted file mode 100644 index b22f77a52..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/FixedValue.java +++ /dev/null @@ -1,90 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.parameter; - -import lombok.EqualsAndHashCode; -import lombok.Getter; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.serde.jackson.FixedValueDeserializer; -import org.deeplearning4j.arbiter.optimize.serde.jackson.FixedValueSerializer; -import org.deeplearning4j.arbiter.util.ObjectUtils; -import com.fasterxml.jackson.annotation.JsonCreator; -import com.fasterxml.jackson.annotation.JsonProperty; -import com.fasterxml.jackson.annotation.JsonTypeInfo; -import com.fasterxml.jackson.databind.annotation.JsonDeserialize; -import com.fasterxml.jackson.databind.annotation.JsonSerialize; - -import java.util.Collections; -import java.util.List; -import java.util.Map; - -/** - * FixedValue is a ParameterSpace that defines only a single fixed value - * - * @param Type of (fixed) value - */ -@EqualsAndHashCode -@JsonSerialize(using = FixedValueSerializer.class) -@JsonDeserialize(using = FixedValueDeserializer.class) -@JsonTypeInfo(use = JsonTypeInfo.Id.CLASS, include = JsonTypeInfo.As.PROPERTY, property = "@class") -public class FixedValue implements ParameterSpace { - @Getter - private Object value; - private int index; - - @JsonCreator - public FixedValue(@JsonProperty("value") T value) { - this.value = value; - } - - @Override - public String toString() { - return "FixedValue(" + ObjectUtils.valueToString(value) + ")"; - } - - @Override - public T getValue(double[] input) { - return (T) value; - } - - @Override - public int numParameters() { - return 0; - } - - @Override - public List collectLeaves() { - return Collections.emptyList(); - } - - @Override - public Map getNestedSpaces() { - return Collections.emptyMap(); - } - - @Override - public boolean isLeaf() { - return true; - } - - @Override - public void setIndices(int... indices) { - if (indices != null && indices.length != 0) - throw new IllegalArgumentException( - "Invalid call: FixedValue ParameterSpace " + "should not be given an index (0 params)"); - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/continuous/ContinuousParameterSpace.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/continuous/ContinuousParameterSpace.java deleted file mode 100644 index c8f139ebb..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/continuous/ContinuousParameterSpace.java +++ /dev/null @@ -1,137 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.parameter.continuous; - -import org.apache.commons.math3.distribution.RealDistribution; -import org.apache.commons.math3.distribution.UniformRealDistribution; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.distribution.DistributionUtils; -import org.deeplearning4j.arbiter.optimize.serde.jackson.RealDistributionDeserializer; -import org.deeplearning4j.arbiter.optimize.serde.jackson.RealDistributionSerializer; -import com.fasterxml.jackson.annotation.JsonIgnoreProperties; -import com.fasterxml.jackson.annotation.JsonProperty; -import com.fasterxml.jackson.databind.annotation.JsonDeserialize; -import com.fasterxml.jackson.databind.annotation.JsonSerialize; - -import java.util.Collections; -import java.util.List; -import java.util.Map; - -/** - * ContinuousParametSpace is a {@code ParameterSpace} that (optionally) takes an Apache Commons - * {@link RealDistribution} when used for random sampling (such as in a RandomSearchCandidateGenerator) - * - * @author Alex Black - */ -public class ContinuousParameterSpace implements ParameterSpace { - - //Need to use custom serializers/deserializers for commons RealDistribution instances - @JsonSerialize(using = RealDistributionSerializer.class) - @JsonDeserialize(using = RealDistributionDeserializer.class) - private RealDistribution distribution; - private int index = -1; - - /** - * ContinuousParameterSpace with uniform distribution between the minimum and maximum values - * - * @param min Minimum value that can be generated - * @param max Maximum value that can be generated - */ - public ContinuousParameterSpace(double min, double max) { - this(new UniformRealDistribution(min, max)); - } - - /** - * ConditiousParameterSpcae wiht a specified probability distribution. The provided distribution defines the min/max - * values, and (for random search, etc) will be used when generating random values - * - * @param distribution Distribution to sample from - */ - public ContinuousParameterSpace(@JsonProperty("distribution") RealDistribution distribution) { - this.distribution = distribution; - } - - - @Override - public Double getValue(double[] input) { - if (index == -1) { - throw new IllegalStateException("Cannot get value: ParameterSpace index has not been set"); - } - return distribution.inverseCumulativeProbability(input[index]); - } - - @Override - public int numParameters() { - return 1; - } - - @Override - public List collectLeaves() { - return Collections.singletonList((ParameterSpace) this); - } - - @Override - public Map getNestedSpaces() { - return Collections.emptyMap(); - } - - @Override - public boolean isLeaf() { - return true; - } - - @Override - public void setIndices(int... indices) { - if (indices == null || indices.length != 1) { - throw new IllegalArgumentException("Invalid index"); - } - this.index = indices[0]; - } - - - @Override - public String toString() { - if (distribution instanceof UniformRealDistribution) { - return "ContinuousParameterSpace(min=" + distribution.getSupportLowerBound() + ",max=" - + distribution.getSupportUpperBound() + ")"; - } else { - return "ContinuousParameterSpace(" + distribution + ")"; - } - } - - public boolean equals(Object o) { - if (o == this) - return true; - if (!(o instanceof ContinuousParameterSpace)) - return false; - final ContinuousParameterSpace other = (ContinuousParameterSpace) o; - if (distribution == null ? other.distribution != null - : !DistributionUtils.distributionsEqual(distribution, other.distribution)) - return false; - if (this.index != other.index) - return false; - return true; - } - - public int hashCode() { - final int PRIME = 59; - int result = 1; - result = result * PRIME + (distribution == null ? 43 : distribution.getClass().hashCode()); - result = result * PRIME + this.index; - return result; - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/discrete/DiscreteParameterSpace.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/discrete/DiscreteParameterSpace.java deleted file mode 100644 index 3c70aaa03..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/discrete/DiscreteParameterSpace.java +++ /dev/null @@ -1,113 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.parameter.discrete; - -import lombok.EqualsAndHashCode; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.util.ObjectUtils; -import com.fasterxml.jackson.annotation.JsonIgnoreProperties; -import com.fasterxml.jackson.annotation.JsonProperty; -import com.fasterxml.jackson.databind.annotation.JsonSerialize; - -import java.util.*; - -/** - * A DiscreteParameterSpace is used for a set of un-ordered values - * - * @param

Parameter type - * @author Alex Black - */ -@EqualsAndHashCode -public class DiscreteParameterSpace

implements ParameterSpace

{ - - @JsonSerialize - private List

values; - private int index = -1; - - public DiscreteParameterSpace(@JsonProperty("values") P... values) { - if (values != null) - this.values = Arrays.asList(values); - } - - public DiscreteParameterSpace(Collection

values) { - this.values = new ArrayList<>(values); - } - - public int numValues() { - return values.size(); - } - - @Override - public P getValue(double[] input) { - if (index == -1) { - throw new IllegalStateException("Cannot get value: ParameterSpace index has not been set"); - } - if (values == null) - throw new IllegalStateException("Values are null."); - //Map a value in range [0,1] to one of the list of values - //First value: [0,width], second: (width,2*width], third: (3*width,4*width] etc - int size = values.size(); - if (size == 1) - return values.get(0); - double width = 1.0 / size; - int val = (int) (input[index] / width); - return values.get(Math.min(val, size - 1)); - } - - @Override - public int numParameters() { - return 1; - } - - @Override - public List collectLeaves() { - return Collections.singletonList((ParameterSpace) this); - } - - @Override - public Map getNestedSpaces() { - return Collections.emptyMap(); - } - - @Override - public boolean isLeaf() { - return true; - } - - @Override - public void setIndices(int... indices) { - if (indices == null || indices.length != 1) { - throw new IllegalArgumentException("Invalid index"); - } - this.index = indices[0]; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - sb.append("DiscreteParameterSpace("); - int n = values.size(); - for (int i = 0; i < n; i++) { - P value = values.get(i); - sb.append(ObjectUtils.valueToString(value)); - sb.append((i == n - 1 ? ")" : ",")); - } - return sb.toString(); - } - - -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/integer/IntegerParameterSpace.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/integer/IntegerParameterSpace.java deleted file mode 100644 index d76381244..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/integer/IntegerParameterSpace.java +++ /dev/null @@ -1,151 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.parameter.integer; - -import lombok.NoArgsConstructor; -import org.apache.commons.math3.distribution.IntegerDistribution; -import org.apache.commons.math3.distribution.UniformIntegerDistribution; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.distribution.DistributionUtils; -import org.deeplearning4j.arbiter.optimize.serde.jackson.IntegerDistributionDeserializer; -import org.deeplearning4j.arbiter.optimize.serde.jackson.IntegerDistributionSerializer; -import com.fasterxml.jackson.annotation.JsonCreator; -import com.fasterxml.jackson.annotation.JsonIgnoreProperties; -import com.fasterxml.jackson.annotation.JsonProperty; -import com.fasterxml.jackson.databind.annotation.JsonDeserialize; -import com.fasterxml.jackson.databind.annotation.JsonSerialize; - -import java.util.Collections; -import java.util.List; -import java.util.Map; - -/** - * IntegerParameterSpace is a {@code ParameterSpace}; i.e., defines an ordered space of integers between - * some minimum and maximum value - * - * @author Alex Black - */ -@JsonIgnoreProperties({"min", "max"}) -@NoArgsConstructor -public class IntegerParameterSpace implements ParameterSpace { - - @JsonSerialize(using = IntegerDistributionSerializer.class) - @JsonDeserialize(using = IntegerDistributionDeserializer.class) - private IntegerDistribution distribution; - private int index = -1; - - /** - * Create an IntegerParameterSpace with a uniform distribution between the specified min/max (inclusive) - * - * @param min Min value, inclusive - * @param max Max value, inclusive - */ - public IntegerParameterSpace(int min, int max) { - this(new UniformIntegerDistribution(min, max)); - } - - /** - * Crate an IntegerParametSpace from the given IntegerDistribution - * - * @param distribution Distribution to use - */ - @JsonCreator - public IntegerParameterSpace(@JsonProperty("distribution") IntegerDistribution distribution) { - this.distribution = distribution; - } - - public int getMin() { - return distribution.getSupportLowerBound(); - } - - public int getMax() { - return distribution.getSupportUpperBound(); - } - - @Override - public Integer getValue(double[] input) { - if (index == -1) { - throw new IllegalStateException("Cannot get value: ParameterSpace index has not been set"); - } - return distribution.inverseCumulativeProbability(input[index]); - } - - @Override - public int numParameters() { - return 1; - } - - @Override - public List collectLeaves() { - return Collections.singletonList((ParameterSpace) this); - } - - @Override - public Map getNestedSpaces() { - return Collections.emptyMap(); - } - - @Override - public boolean isLeaf() { - return true; - } - - @Override - public void setIndices(int... indices) { - if (indices == null || indices.length != 1) - throw new IllegalArgumentException("Invalid index"); - this.index = indices[0]; - } - - @Override - public String toString() { - if (distribution instanceof UniformIntegerDistribution) { - return "IntegerParameterSpace(min=" + distribution.getSupportLowerBound() + ",max=" - + distribution.getSupportUpperBound() + ")"; - } else { - return "IntegerParameterSpace(" + distribution + ")"; - } - } - - public boolean equals(Object o) { - if (o == this) - return true; - if (!(o instanceof IntegerParameterSpace)) - return false; - final IntegerParameterSpace other = (IntegerParameterSpace) o; - if (!other.canEqual(this)) - return false; - if (distribution == null ? other.distribution != null - : !DistributionUtils.distributionEquals(distribution, other.distribution)) - return false; - if (this.index != other.index) - return false; - return true; - } - - public int hashCode() { - final int PRIME = 59; - int result = 1; - result = result * PRIME + (distribution == null ? 43 : distribution.getClass().hashCode()); - result = result * PRIME + this.index; - return result; - } - - protected boolean canEqual(Object other) { - return other instanceof IntegerParameterSpace; - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/math/MathOp.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/math/MathOp.java deleted file mode 100644 index 2d567536f..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/math/MathOp.java +++ /dev/null @@ -1,69 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.parameter.math; - -import org.deeplearning4j.arbiter.optimize.api.AbstractParameterSpace; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; - -import java.util.List; - -/** - * A simple parameter space that implements scalar mathematical operations on another parameter space. This allows you - * to do things like Y = X * 2, where X is a parameter space. For example, a layer size hyperparameter could be set - * using this to 2x the size of the previous layer - * - * @param Type of the parameter space - * @author Alex Black - */ -public class MathOp extends AbstractParameterSpace { - - private ParameterSpace parameterSpace; - private Op op; - private T scalar; - - public MathOp(ParameterSpace parameterSpace, Op op, T scalar){ - this.parameterSpace = parameterSpace; - this.op = op; - this.scalar = scalar; - } - - @Override - public T getValue(double[] parameterValues) { - T u = parameterSpace.getValue(parameterValues); - return op.doOp(u, scalar); - } - - @Override - public int numParameters() { - return parameterSpace.numParameters(); - } - - @Override - public List collectLeaves() { - return parameterSpace.collectLeaves(); - } - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices) { - parameterSpace.setIndices(indices); - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/math/Op.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/math/Op.java deleted file mode 100644 index 2102804ce..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/math/Op.java +++ /dev/null @@ -1,76 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.parameter.math; - -public enum Op { - ADD, SUB, MUL, DIV; - - - //Package private - T doOp(T first, T second){ - if(first instanceof Integer || first instanceof Long){ - long result; - switch (this){ - case ADD: - result = Long.valueOf(first.longValue() + second.longValue()); - break; - case SUB: - result = Long.valueOf(first.longValue() - second.longValue()); - break; - case MUL: - result = Long.valueOf(first.longValue() * second.longValue()); - break; - case DIV: - result = Long.valueOf(first.longValue() / second.longValue()); - break; - default: - throw new UnsupportedOperationException("Unknown op: " + this); - } - if(first instanceof Long){ - return (T)Long.valueOf(result); - } else { - return (T)Integer.valueOf((int)result); - } - } else if(first instanceof Double || first instanceof Float){ - double result; - switch (this){ - case ADD: - result = Double.valueOf(first.doubleValue() + second.doubleValue()); - break; - case SUB: - result = Double.valueOf(first.doubleValue() - second.doubleValue()); - break; - case MUL: - result = Double.valueOf(first.doubleValue() * second.doubleValue()); - break; - case DIV: - result = Double.valueOf(first.doubleValue() / second.doubleValue()); - break; - default: - throw new UnsupportedOperationException("Unknown op: " + this); - } - if(first instanceof Double){ - return (T)Double.valueOf(result); - } else { - return (T)Float.valueOf((float)result); - } - } else { - throw new UnsupportedOperationException("Not supported type: only Integer, Long, Double, Float supported" + - " here. Got type: " + first.getClass()); - } - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/math/PairMathOp.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/math/PairMathOp.java deleted file mode 100644 index db0a9c98b..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/parameter/math/PairMathOp.java +++ /dev/null @@ -1,79 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.parameter.math; - -import org.deeplearning4j.arbiter.optimize.api.AbstractParameterSpace; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; - -/** - * A simple parameter space that implements pairwise mathematical operations on another parameter space. This allows you - * to do things like Z = X + Y, where X and Y are parameter spaces. - * - * @param Type of the parameter space - * @author Alex Black - */ -public class PairMathOp extends AbstractParameterSpace { - - private ParameterSpace first; - private ParameterSpace second; - private Op op; - - public PairMathOp(ParameterSpace first, ParameterSpace second, Op op){ - this.first = first; - this.second = second; - this.op = op; - } - - @Override - public T getValue(double[] parameterValues) { - T f = first.getValue(parameterValues); - T s = second.getValue(parameterValues); - return op.doOp(f, s); - } - - @Override - public int numParameters() { - return first.numParameters() + second.numParameters(); - } - - @Override - public List collectLeaves() { - List l = new ArrayList<>(); - l.addAll(first.collectLeaves()); - l.addAll(second.collectLeaves()); - return l; - } - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices) { - int n1 = first.numParameters(); - int n2 = second.numParameters(); - int[] s1 = Arrays.copyOfRange(indices, 0, n1); - int[] s2 = Arrays.copyOfRange(indices, n1, n1+n2); - first.setIndices(s1); - second.setIndices(s2); - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/BaseOptimizationRunner.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/BaseOptimizationRunner.java deleted file mode 100644 index fa503ef6d..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/BaseOptimizationRunner.java +++ /dev/null @@ -1,383 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.runner; - -import com.google.common.util.concurrent.ListenableFuture; -import lombok.AllArgsConstructor; -import lombok.Data; -import lombok.extern.slf4j.Slf4j; -import org.apache.commons.lang3.exception.ExceptionUtils; -import org.deeplearning4j.arbiter.optimize.api.Candidate; -import org.deeplearning4j.arbiter.optimize.api.OptimizationResult; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSource; -import org.deeplearning4j.arbiter.optimize.api.saving.ResultReference; -import org.deeplearning4j.arbiter.optimize.api.score.ScoreFunction; -import org.deeplearning4j.arbiter.optimize.api.termination.TerminationCondition; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; -import org.deeplearning4j.arbiter.optimize.runner.listener.StatusListener; - -import java.util.*; -import java.util.concurrent.*; -import java.util.concurrent.atomic.AtomicInteger; -import java.util.concurrent.atomic.AtomicLong; - -/** - * BaseOptimization runner: responsible for scheduling tasks, saving results using the result saver, etc. - * - * @author Alex Black - */ -@Slf4j -public abstract class BaseOptimizationRunner implements IOptimizationRunner { - private static final int POLLING_FREQUENCY = 1; - private static final TimeUnit POLLING_FREQUENCY_UNIT = TimeUnit.SECONDS; - - protected OptimizationConfiguration config; - protected Queue> queuedFutures = new ConcurrentLinkedQueue<>(); - protected BlockingQueue> completedFutures = new LinkedBlockingQueue<>(); - protected AtomicInteger totalCandidateCount = new AtomicInteger(); - protected AtomicInteger numCandidatesCompleted = new AtomicInteger(); - protected AtomicInteger numCandidatesFailed = new AtomicInteger(); - protected Double bestScore = null; - protected Long bestScoreTime = null; - protected AtomicInteger bestScoreCandidateIndex = new AtomicInteger(-1); - protected List allResults = new ArrayList<>(); - - protected Map currentStatus = new ConcurrentHashMap<>(); //TODO: better design possible? - - protected ExecutorService futureListenerExecutor; - - protected List statusListeners = new ArrayList<>(); - - - protected BaseOptimizationRunner(OptimizationConfiguration config) { - this.config = config; - - if (config.getTerminationConditions() == null || config.getTerminationConditions().size() == 0) { - throw new IllegalArgumentException("Cannot create BaseOptimizationRunner without TerminationConditions (" - + "termination conditions are null or empty)"); - } - - } - - protected void init() { - futureListenerExecutor = Executors.newFixedThreadPool(maxConcurrentTasks(), new ThreadFactory() { - private AtomicLong counter = new AtomicLong(0); - - @Override - public Thread newThread(Runnable r) { - Thread t = Executors.defaultThreadFactory().newThread(r); - t.setDaemon(true); - t.setName("ArbiterOptimizationRunner-" + counter.getAndIncrement()); - return t; - } - }); - } - - /** - * - */ - @Override - public void execute() { - log.info("{}: execution started", this.getClass().getSimpleName()); - config.setExecutionStartTime(System.currentTimeMillis()); - for (StatusListener listener : statusListeners) { - listener.onInitialization(this); - } - - //Initialize termination conditions (start timers, etc) - for (TerminationCondition c : config.getTerminationConditions()) { - c.initialize(this); - } - - //Queue initial tasks: - List> tempList = new ArrayList<>(100); - while (true) { - //Otherwise: add tasks if required - Future future = null; - try { - future = completedFutures.poll(POLLING_FREQUENCY, POLLING_FREQUENCY_UNIT); - } catch (InterruptedException e) { - //No op? - } - if (future != null) { - tempList.add(future); - } - completedFutures.drainTo(tempList); - - //Process results (if any) - for (Future f : tempList) { - queuedFutures.remove(f); - processReturnedTask(f); - } - - if (tempList.size() > 0) { - for (StatusListener sl : statusListeners) { - sl.onRunnerStatusChange(this); - } - } - tempList.clear(); - - //Check termination conditions: - if (terminate()) { - shutdown(true); - break; - } - - //Add additional tasks - while (config.getCandidateGenerator().hasMoreCandidates() && queuedFutures.size() < maxConcurrentTasks()) { - Candidate candidate = config.getCandidateGenerator().getCandidate(); - CandidateInfo status; - if (candidate.getException() != null) { - //Failed on generation... - status = processFailedCandidates(candidate); - } else { - long created = System.currentTimeMillis(); - ListenableFuture f; - if(config.getDataSource() != null){ - f = execute(candidate, config.getDataSource(), config.getDataSourceProperties(), config.getScoreFunction()); - } else { - f = execute(candidate, config.getDataProvider(), config.getScoreFunction()); - } - f.addListener(new OnCompletionListener(f), futureListenerExecutor); - queuedFutures.add(f); - totalCandidateCount.getAndIncrement(); - - status = new CandidateInfo(candidate.getIndex(), CandidateStatus.Created, null, - created, null, null, candidate.getFlatParameters(), null); - currentStatus.put(candidate.getIndex(), status); - } - - for (StatusListener listener : statusListeners) { - listener.onCandidateStatusChange(status, this, null); - } - } - } - - //Process any final (completed) tasks: - completedFutures.drainTo(tempList); - for (Future f : tempList) { - queuedFutures.remove(f); - processReturnedTask(f); - } - tempList.clear(); - - log.info("Optimization runner: execution complete"); - for (StatusListener listener : statusListeners) { - listener.onShutdown(this); - } - } - - - private CandidateInfo processFailedCandidates(Candidate candidate) { - //In case the candidate fails during the creation of the candidate - - long time = System.currentTimeMillis(); - String stackTrace = ExceptionUtils.getStackTrace(candidate.getException()); - CandidateInfo newStatus = new CandidateInfo(candidate.getIndex(), CandidateStatus.Failed, null, time, time, - time, candidate.getFlatParameters(), stackTrace); - currentStatus.put(candidate.getIndex(), newStatus); - - return newStatus; - } - - /** - * Process returned task (either completed or failed - */ - private void processReturnedTask(Future future) { - long currentTime = System.currentTimeMillis(); - OptimizationResult result; - try { - result = future.get(100, TimeUnit.MILLISECONDS); - } catch (InterruptedException e) { - throw new RuntimeException("Unexpected InterruptedException thrown for task", e); - } catch (ExecutionException e) { - //Note that most of the time, an OptimizationResult is returned even for an exception - //This is just to handle any that are missed there (or, by implementations that don't properly do this) - log.warn("Task failed", e); - - numCandidatesFailed.getAndIncrement(); - return; - } catch (TimeoutException e) { - throw new RuntimeException(e); //TODO - } - - //Update internal status: - CandidateInfo status = currentStatus.get(result.getIndex()); - CandidateInfo newStatus = new CandidateInfo(result.getIndex(), result.getCandidateInfo().getCandidateStatus(), - result.getScore(), status.getCreatedTime(), result.getCandidateInfo().getStartTime(), - currentTime, status.getFlatParams(), result.getCandidateInfo().getExceptionStackTrace()); - currentStatus.put(result.getIndex(), newStatus); - - //Listeners (on complete, etc) should be executed in underlying task - - - if (result.getCandidateInfo().getCandidateStatus() == CandidateStatus.Failed) { - log.info("Task {} failed during execution: {}", result.getIndex(), result.getCandidateInfo().getExceptionStackTrace()); - numCandidatesFailed.getAndIncrement(); - } else { - - //Report completion to candidate generator - config.getCandidateGenerator().reportResults(result); - - Double score = result.getScore(); - log.info("Completed task {}, score = {}", result.getIndex(), result.getScore()); - - boolean minimize = config.getScoreFunction().minimize(); - if (score != null && (bestScore == null - || ((minimize && score < bestScore) || (!minimize && score > bestScore)))) { - if (bestScore == null) { - log.info("New best score: {} (first completed model)", score); - } else { - int idx = result.getIndex(); - int lastBestIdx = bestScoreCandidateIndex.get(); - log.info("New best score: {}, model {} (prev={}, model {})", score, idx, bestScore, lastBestIdx); - } - bestScore = score; - bestScoreTime = System.currentTimeMillis(); - bestScoreCandidateIndex.set(result.getIndex()); - } - numCandidatesCompleted.getAndIncrement(); - - //Model saving is done in the optimization tasks, to avoid CUDA threading issues - ResultReference resultReference = result.getResultReference(); - - if (resultReference != null) - allResults.add(resultReference); - } - } - - @Override - public int numCandidatesTotal() { - return totalCandidateCount.get(); - } - - @Override - public int numCandidatesCompleted() { - return numCandidatesCompleted.get(); - } - - @Override - public int numCandidatesFailed() { - return numCandidatesFailed.get(); - } - - @Override - public int numCandidatesQueued() { - return queuedFutures.size(); - } - - @Override - public Double bestScore() { - return bestScore; - } - - @Override - public Long bestScoreTime() { - return bestScoreTime; - } - - @Override - public int bestScoreCandidateIndex() { - return bestScoreCandidateIndex.get(); - } - - @Override - public List getResults() { - return new ArrayList<>(allResults); - } - - @Override - public OptimizationConfiguration getConfiguration() { - return config; - } - - - @Override - public void addListeners(StatusListener... listeners) { - for (StatusListener l : listeners) { - if (!statusListeners.contains(l)) { - statusListeners.add(l); - } - } - } - - @Override - public void removeListeners(StatusListener... listeners) { - for (StatusListener l : listeners) { - if (statusListeners.contains(l)) { - statusListeners.remove(l); - } - } - } - - @Override - public void removeAllListeners() { - statusListeners.clear(); - } - - @Override - public List getCandidateStatus() { - List list = new ArrayList<>(); - list.addAll(currentStatus.values()); - return list; - } - - private boolean terminate() { - for (TerminationCondition c : config.getTerminationConditions()) { - if (c.terminate(this)) { - log.info("BaseOptimizationRunner global termination condition hit: {}", c); - return true; - } - } - return false; - } - - @AllArgsConstructor - @Data - private class FutureDetails { - private final Future future; - private final long startTime; - private final int index; - } - - @AllArgsConstructor - private class OnCompletionListener implements Runnable { - private Future future; - - @Override - public void run() { - completedFutures.add(future); - } - } - - - protected abstract int maxConcurrentTasks(); - - @Deprecated - protected abstract ListenableFuture execute(Candidate candidate, DataProvider dataProvider, - ScoreFunction scoreFunction); - @Deprecated - protected abstract List> execute(List candidates, - DataProvider dataProvider, ScoreFunction scoreFunction); - - protected abstract ListenableFuture execute(Candidate candidate, Class dataSource, - Properties dataSourceProperties, ScoreFunction scoreFunction); - - protected abstract List> execute(List candidates, Class dataSource, - Properties dataSourceProperties, ScoreFunction scoreFunction); -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/CandidateInfo.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/CandidateInfo.java deleted file mode 100644 index e8c7ccf25..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/CandidateInfo.java +++ /dev/null @@ -1,41 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.runner; - -import lombok.AllArgsConstructor; -import lombok.Data; - -/** - * Simple helper class to store status of a candidate that is/has been/will be executed - */ -@AllArgsConstructor -@Data -public class CandidateInfo { - - public CandidateInfo() { - //No arg constructor for Jackson - } - - private int index; - private CandidateStatus candidateStatus; - private Double score; - private long createdTime; - private Long startTime; - private Long endTime; - private double[] flatParams; //Same as parameters in Candidate class - private String exceptionStackTrace; -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/CandidateStatus.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/CandidateStatus.java deleted file mode 100644 index a19f89a52..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/CandidateStatus.java +++ /dev/null @@ -1,24 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.runner; - -/** - * Status for candidates - */ -public enum CandidateStatus { - Created, Running, Complete, Failed, Cancelled -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/IOptimizationRunner.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/IOptimizationRunner.java deleted file mode 100644 index 50e6dc4b0..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/IOptimizationRunner.java +++ /dev/null @@ -1,67 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.runner; - -import org.deeplearning4j.arbiter.optimize.api.saving.ResultReference; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; -import org.deeplearning4j.arbiter.optimize.runner.listener.StatusListener; -import com.fasterxml.jackson.annotation.JsonTypeInfo; - -import java.util.List; - -@JsonTypeInfo(use = JsonTypeInfo.Id.CLASS, include = JsonTypeInfo.As.PROPERTY, property = "@class") -public interface IOptimizationRunner { - - void execute(); - - /** Total number of candidates: created (scheduled), completed and failed */ - int numCandidatesTotal(); - - int numCandidatesCompleted(); - - int numCandidatesFailed(); - - /** Number of candidates running or queued */ - int numCandidatesQueued(); - - /** Best score found so far */ - Double bestScore(); - - /** Time that the best score was found at, or 0 if no jobs have completed successfully */ - Long bestScoreTime(); - - /** Index of the best scoring candidate, or -1 if no candidate has scored yet*/ - int bestScoreCandidateIndex(); - - List getResults(); - - OptimizationConfiguration getConfiguration(); - - void addListeners(StatusListener... listeners); - - void removeListeners(StatusListener... listeners); - - void removeAllListeners(); - - List getCandidateStatus(); - - /** - * @param awaitCompletion If true: await completion of currently scheduled tasks. If false: shutdown immediately, - * cancelling any currently executing tasks - */ - void shutdown(boolean awaitCompletion); -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/LocalOptimizationRunner.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/LocalOptimizationRunner.java deleted file mode 100644 index a3992b09a..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/LocalOptimizationRunner.java +++ /dev/null @@ -1,150 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.runner; - -import com.google.common.util.concurrent.ListenableFuture; -import com.google.common.util.concurrent.ListeningExecutorService; -import com.google.common.util.concurrent.MoreExecutors; -import lombok.Setter; -import org.deeplearning4j.arbiter.optimize.api.*; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSource; -import org.deeplearning4j.arbiter.optimize.api.score.ScoreFunction; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; - -import java.util.ArrayList; -import java.util.Collections; -import java.util.List; -import java.util.Properties; -import java.util.concurrent.*; -import java.util.concurrent.atomic.AtomicLong; - -/** - * LocalOptimizationRunner: execute hyperparameter optimization - * locally (on current machine, in current JVM). - * - * @author Alex Black - */ -public class LocalOptimizationRunner extends BaseOptimizationRunner { - - public static final int DEFAULT_MAX_CONCURRENT_TASKS = 1; - - private final int maxConcurrentTasks; - - private TaskCreator taskCreator; - private ListeningExecutorService executor; - @Setter - private long shutdownMaxWaitMS = 2L * 24 * 60 * 60 * 1000; - - public LocalOptimizationRunner(OptimizationConfiguration config){ - this(config, null); - } - - public LocalOptimizationRunner(OptimizationConfiguration config, TaskCreator taskCreator) { - this(DEFAULT_MAX_CONCURRENT_TASKS, config, taskCreator); - } - - public LocalOptimizationRunner(int maxConcurrentTasks, OptimizationConfiguration config){ - this(maxConcurrentTasks, config, null); - } - - public LocalOptimizationRunner(int maxConcurrentTasks, OptimizationConfiguration config, TaskCreator taskCreator) { - super(config); - if (maxConcurrentTasks <= 0) - throw new IllegalArgumentException("maxConcurrentTasks must be > 0 (got: " + maxConcurrentTasks + ")"); - this.maxConcurrentTasks = maxConcurrentTasks; - - if(taskCreator == null){ - Class psClass = config.getCandidateGenerator().getParameterSpace().getClass(); - taskCreator = TaskCreatorProvider.defaultTaskCreatorFor(psClass); - if(taskCreator == null){ - throw new IllegalStateException("No TaskCreator was provided and a default TaskCreator cannot be " + - "inferred for ParameterSpace class " + psClass.getName() + ". Please provide a TaskCreator " + - "via the LocalOptimizationRunner constructor"); - } - } - - this.taskCreator = taskCreator; - - ExecutorService exec = Executors.newFixedThreadPool(maxConcurrentTasks, new ThreadFactory() { - private AtomicLong counter = new AtomicLong(0); - - @Override - public Thread newThread(Runnable r) { - Thread t = Executors.defaultThreadFactory().newThread(r); - t.setDaemon(true); - t.setName("LocalCandidateExecutor-" + counter.getAndIncrement()); - return t; - } - }); - executor = MoreExecutors.listeningDecorator(exec); - - init(); - } - - @Override - protected int maxConcurrentTasks() { - return maxConcurrentTasks; - } - - @Override - protected ListenableFuture execute(Candidate candidate, DataProvider dataProvider, - ScoreFunction scoreFunction) { - return execute(Collections.singletonList(candidate), dataProvider, scoreFunction).get(0); - } - - @Override - protected List> execute(List candidates, DataProvider dataProvider, - ScoreFunction scoreFunction) { - List> list = new ArrayList<>(candidates.size()); - for (Candidate candidate : candidates) { - Callable task = - taskCreator.create(candidate, dataProvider, scoreFunction, statusListeners, this); - list.add(executor.submit(task)); - } - return list; - } - - @Override - protected ListenableFuture execute(Candidate candidate, Class dataSource, Properties dataSourceProperties, ScoreFunction scoreFunction) { - return execute(Collections.singletonList(candidate), dataSource, dataSourceProperties, scoreFunction).get(0); - } - - @Override - protected List> execute(List candidates, Class dataSource, Properties dataSourceProperties, ScoreFunction scoreFunction) { - List> list = new ArrayList<>(candidates.size()); - for (Candidate candidate : candidates) { - Callable task = taskCreator.create(candidate, dataSource, dataSourceProperties, scoreFunction, statusListeners, this); - list.add(executor.submit(task)); - } - return list; - } - - @Override - public void shutdown(boolean awaitTermination) { - if(awaitTermination){ - try { - executor.shutdown(); - executor.awaitTermination(shutdownMaxWaitMS, TimeUnit.MILLISECONDS); - } catch (InterruptedException e){ - throw new RuntimeException(e); - } - } else { - executor.shutdownNow(); - } - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/listener/BaseStatusListener.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/listener/BaseStatusListener.java deleted file mode 100644 index aca25d95d..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/listener/BaseStatusListener.java +++ /dev/null @@ -1,54 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.runner.listener; - -import org.deeplearning4j.arbiter.optimize.api.OptimizationResult; -import org.deeplearning4j.arbiter.optimize.runner.CandidateInfo; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; - -/** - * BaseStatusListener: implements all methods of {@link StatusListener} as no-op. - * Users can extend this and override only the methods actually required - * - * @author Alex Black - */ -public abstract class BaseStatusListener implements StatusListener{ - @Override - public void onInitialization(IOptimizationRunner runner) { - //No op - } - - @Override - public void onShutdown(IOptimizationRunner runner) { - //No op - } - - @Override - public void onRunnerStatusChange(IOptimizationRunner runner) { - //No op - } - - @Override - public void onCandidateStatusChange(CandidateInfo candidateInfo, IOptimizationRunner runner, OptimizationResult result) { - //No op - } - - @Override - public void onCandidateIteration(CandidateInfo candidateInfo, Object candidate, int iteration) { - //No op - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/listener/StatusChangeType.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/listener/StatusChangeType.java deleted file mode 100644 index d8e2f429b..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/listener/StatusChangeType.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.runner.listener; - -/** - * Created by Alex on 20/07/2017. - */ -public enum StatusChangeType { - - CandidateCompleted, CandidateFailed, CandidateNewScheduled, CandidateNewBestScore - -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/listener/StatusListener.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/listener/StatusListener.java deleted file mode 100644 index fa5ba25a2..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/listener/StatusListener.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.runner.listener; - -import org.deeplearning4j.arbiter.optimize.api.OptimizationResult; -import org.deeplearning4j.arbiter.optimize.runner.CandidateInfo; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; - -/** - * The status Listener interface is used to inspect/track the status of execution, both for individual candidates, - * and for the optimisation runner overall. - * - * @author Alex Black - */ -public interface StatusListener { - - /** Called when optimization runner starts execution */ - void onInitialization(IOptimizationRunner runner); - - /** Called when optimization runner terminates */ - void onShutdown(IOptimizationRunner runner); - - /** Called when any of the summary stats change, for the optimization runner: - * number scheduled, number completed, number failed, best score, etc. */ - void onRunnerStatusChange(IOptimizationRunner runner); - - /** - * Called when the status of the candidate is change. For example created, completed, failed. - * - * @param candidateInfo Candidate information - * @param runner Optimisation runner calling this method - * @param result Optimisation result. Maybe null. - */ - void onCandidateStatusChange(CandidateInfo candidateInfo, IOptimizationRunner runner, OptimizationResult result); - - /** - * This method may be called by tasks as they are executing. The intent of this method is to report partial results, - * such as different stages of learning, or scores/evaluations so far - * - * @param candidateInfo Candidate information - * @param candidate Current candidate value/configuration - * @param iteration Current iteration number - */ - void onCandidateIteration(CandidateInfo candidateInfo, Object candidate, int iteration); - -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/listener/impl/LoggingStatusListener.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/listener/impl/LoggingStatusListener.java deleted file mode 100644 index add0d4ff7..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/runner/listener/impl/LoggingStatusListener.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.runner.listener.impl; - -import lombok.extern.slf4j.Slf4j; -import org.deeplearning4j.arbiter.optimize.api.OptimizationResult; -import org.deeplearning4j.arbiter.optimize.runner.CandidateInfo; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.listener.StatusListener; - -/** - * Created by Alex on 20/07/2017. - */ -@Slf4j -public class LoggingStatusListener implements StatusListener { - - - @Override - public void onInitialization(IOptimizationRunner runner) { - log.info("Optimization runner: initialized"); - } - - @Override - public void onShutdown(IOptimizationRunner runner) { - log.info("Optimization runner: shut down"); - } - - @Override - public void onRunnerStatusChange(IOptimizationRunner runner) { - log.info("Optimization runner: status change"); - } - - @Override - public void onCandidateStatusChange(CandidateInfo candidateInfo, IOptimizationRunner runner, - OptimizationResult result) { - log.info("Candidate status change: {}", candidateInfo); - } - - @Override - public void onCandidateIteration(CandidateInfo candidateInfo, Object candidate, int iteration) { - log.info("Candidate iteration #{} - {}", iteration, candidate); - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/FixedValueDeserializer.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/FixedValueDeserializer.java deleted file mode 100644 index 7ca349878..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/FixedValueDeserializer.java +++ /dev/null @@ -1,52 +0,0 @@ -package org.deeplearning4j.arbiter.optimize.serde.jackson; - -import org.apache.commons.codec.binary.Base64; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import com.fasterxml.jackson.core.JsonParser; -import com.fasterxml.jackson.core.JsonProcessingException; -import com.fasterxml.jackson.databind.DeserializationContext; -import com.fasterxml.jackson.databind.JsonDeserializer; -import com.fasterxml.jackson.databind.JsonNode; -import com.fasterxml.jackson.databind.ObjectMapper; - -import java.io.ByteArrayInputStream; -import java.io.IOException; -import java.io.ObjectInputStream; - -/** - * A custom deserializer to be used in conjunction with {@link FixedValueSerializer} - * @author Alex Black - */ -public class FixedValueDeserializer extends JsonDeserializer { - @Override - public FixedValue deserialize(JsonParser p, DeserializationContext deserializationContext) throws IOException, JsonProcessingException { - JsonNode node = p.getCodec().readTree(p); - String className = node.get("@valueclass").asText(); - Class c; - try { - c = Class.forName(className); - } catch (Exception e) { - throw new RuntimeException(e); - } - - if(node.has("value")){ - //Number, String, Enum - JsonNode valueNode = node.get("value"); - Object o = new ObjectMapper().treeToValue(valueNode, c); - return new FixedValue<>(o); - } else { - //Everything else - JsonNode valueNode = node.get("data"); - String data = valueNode.asText(); - - byte[] b = new Base64().decode(data); - ObjectInputStream ois = new ObjectInputStream(new ByteArrayInputStream(b)); - try { - Object o = ois.readObject(); - return new FixedValue<>(o); - } catch (Throwable t) { - throw new RuntimeException(t); - } - } - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/FixedValueSerializer.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/FixedValueSerializer.java deleted file mode 100644 index 80ff7d61d..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/FixedValueSerializer.java +++ /dev/null @@ -1,52 +0,0 @@ -package org.deeplearning4j.arbiter.optimize.serde.jackson; - -import org.apache.commons.net.util.Base64; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import com.fasterxml.jackson.core.JsonGenerator; -import com.fasterxml.jackson.core.type.WritableTypeId; -import com.fasterxml.jackson.databind.JsonSerializer; -import com.fasterxml.jackson.databind.SerializerProvider; -import com.fasterxml.jackson.databind.jsontype.TypeSerializer; - -import java.io.ByteArrayOutputStream; -import java.io.IOException; -import java.io.ObjectOutputStream; - -import static com.fasterxml.jackson.core.JsonToken.START_OBJECT; - - -/** - * A custom serializer to handle arbitrary object types - * Uses standard JSON where safe (number, string, enumerations) or Java object serialization (bytes -> base64) - * The latter is not an ideal approach, but Jackson doesn't support serialization/deserialization of arbitrary - * objects very well - * - * @author Alex Black - */ -public class FixedValueSerializer extends JsonSerializer { - @Override - public void serialize(FixedValue fixedValue, JsonGenerator j, SerializerProvider serializerProvider) throws IOException { - Object o = fixedValue.getValue(); - - j.writeStringField("@valueclass", o.getClass().getName()); - if(o instanceof Number || o instanceof String || o instanceof Enum){ - j.writeObjectField("value", o); - } else { - ByteArrayOutputStream baos = new ByteArrayOutputStream(); - ObjectOutputStream oos = new ObjectOutputStream(baos); - oos.writeObject(o); - baos.close(); - byte[] b = baos.toByteArray(); - String base64 = new Base64().encodeToString(b); - j.writeStringField("data", base64); - } - } - - @Override - public void serializeWithType(FixedValue value, JsonGenerator gen, SerializerProvider serializers, TypeSerializer typeSer) throws IOException { - WritableTypeId typeId = typeSer.typeId(value, START_OBJECT); - typeSer.writeTypePrefix(gen, typeId); - serialize(value, gen, serializers); - typeSer.writeTypeSuffix(gen, typeId); - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/IntegerDistributionDeserializer.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/IntegerDistributionDeserializer.java deleted file mode 100644 index 6700e9753..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/IntegerDistributionDeserializer.java +++ /dev/null @@ -1,59 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.serde.jackson; - -import org.apache.commons.math3.distribution.*; -import com.fasterxml.jackson.core.JsonParser; -import com.fasterxml.jackson.databind.DeserializationContext; -import com.fasterxml.jackson.databind.JsonDeserializer; -import com.fasterxml.jackson.databind.JsonNode; - -import java.io.IOException; - -/** - * Custom Jackson deserializer for integer distributions - * - * @author Alex Black - */ -public class IntegerDistributionDeserializer extends JsonDeserializer { - - @Override - public IntegerDistribution deserialize(JsonParser p, DeserializationContext ctxt) throws IOException { - JsonNode node = p.getCodec().readTree(p); - String simpleName = node.get("distribution").asText(); - - switch (simpleName) { - case "BinomialDistribution": - return new BinomialDistribution(node.get("trials").asInt(), node.get("p").asDouble()); - case "GeometricDistribution": - return new GeometricDistribution(node.get("p").asDouble()); - case "HypergeometricDistribution": - return new HypergeometricDistribution(node.get("populationSize").asInt(), - node.get("numberOfSuccesses").asInt(), node.get("sampleSize").asInt()); - case "PascalDistribution": - return new PascalDistribution(node.get("r").asInt(), node.get("p").asDouble()); - case "PoissonDistribution": - return new PoissonDistribution(node.get("p").asDouble()); - case "UniformIntegerDistribution": - return new UniformIntegerDistribution(node.get("lower").asInt(), node.get("upper").asInt()); - case "ZipfDistribution": - return new ZipfDistribution(node.get("numElements").asInt(), node.get("exponent").asDouble()); - default: - throw new RuntimeException("Unknown or not supported distribution: " + simpleName); - } - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/IntegerDistributionSerializer.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/IntegerDistributionSerializer.java deleted file mode 100644 index 4157df2f7..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/IntegerDistributionSerializer.java +++ /dev/null @@ -1,74 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.serde.jackson; - -import org.apache.commons.math3.distribution.*; -import com.fasterxml.jackson.core.JsonGenerator; -import com.fasterxml.jackson.databind.JsonSerializer; -import com.fasterxml.jackson.databind.SerializerProvider; - -import java.io.IOException; - -/** - * Custom Jackson serializer for integer distributions - * - * @author Alex Black - */ -public class IntegerDistributionSerializer extends JsonSerializer { - @Override - public void serialize(IntegerDistribution d, JsonGenerator j, SerializerProvider serializerProvider) - throws IOException { - Class c = d.getClass(); - String s = c.getSimpleName(); - - j.writeStartObject(); - j.writeStringField("distribution", s); - - if (c == BinomialDistribution.class) { - BinomialDistribution bd = (BinomialDistribution) d; - j.writeNumberField("trials", bd.getNumberOfTrials()); - j.writeNumberField("p", bd.getProbabilityOfSuccess()); - } else if (c == GeometricDistribution.class) { - GeometricDistribution gd = (GeometricDistribution) d; - j.writeNumberField("p", gd.getProbabilityOfSuccess()); - } else if (c == HypergeometricDistribution.class) { - HypergeometricDistribution hd = (HypergeometricDistribution) d; - j.writeNumberField("populationSize", hd.getPopulationSize()); - j.writeNumberField("numberOfSuccesses", hd.getNumberOfSuccesses()); - j.writeNumberField("sampleSize", hd.getSampleSize()); - } else if (c == PascalDistribution.class) { - PascalDistribution pd = (PascalDistribution) d; - j.writeNumberField("r", pd.getNumberOfSuccesses()); - j.writeNumberField("p", pd.getProbabilityOfSuccess()); - } else if (c == PoissonDistribution.class) { - PoissonDistribution pd = (PoissonDistribution) d; - j.writeNumberField("p", pd.getMean()); - } else if (c == UniformIntegerDistribution.class) { - UniformIntegerDistribution ud = (UniformIntegerDistribution) d; - j.writeNumberField("lower", ud.getSupportLowerBound()); - j.writeNumberField("upper", ud.getSupportUpperBound()); - } else if (c == ZipfDistribution.class) { - ZipfDistribution zd = (ZipfDistribution) d; - j.writeNumberField("numElements", zd.getNumberOfElements()); - j.writeNumberField("exponent", zd.getExponent()); - } else { - throw new UnsupportedOperationException("Unknown or not supported IntegerDistribution: " + c); - } - - j.writeEndObject(); - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/JsonMapper.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/JsonMapper.java deleted file mode 100644 index 7ed1bfe45..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/JsonMapper.java +++ /dev/null @@ -1,77 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.serde.jackson; - -import com.fasterxml.jackson.annotation.JsonAutoDetect; -import com.fasterxml.jackson.annotation.PropertyAccessor; -import com.fasterxml.jackson.databind.DeserializationFeature; -import com.fasterxml.jackson.databind.ObjectMapper; -import com.fasterxml.jackson.databind.SerializationFeature; -import com.fasterxml.jackson.dataformat.yaml.YAMLFactory; -import com.fasterxml.jackson.datatype.joda.JodaModule; - -/** - * Created by Alex on 16/11/2016. - */ -public class JsonMapper { - - private static ObjectMapper mapper; - private static ObjectMapper yamlMapper; - - static { - mapper = new ObjectMapper(); - mapper.registerModule(new JodaModule()); - mapper.configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false); - mapper.configure(SerializationFeature.FAIL_ON_EMPTY_BEANS, false); - mapper.enable(SerializationFeature.INDENT_OUTPUT); - mapper.setVisibility(PropertyAccessor.ALL, JsonAutoDetect.Visibility.NONE); - mapper.setVisibility(PropertyAccessor.FIELD, JsonAutoDetect.Visibility.ANY); - mapper.setVisibility(PropertyAccessor.CREATOR, JsonAutoDetect.Visibility.ANY); - mapper.setVisibility(PropertyAccessor.SETTER, JsonAutoDetect.Visibility.ANY); - yamlMapper = new ObjectMapper(new YAMLFactory()); - yamlMapper.registerModule(new JodaModule()); - yamlMapper.configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false); - yamlMapper.configure(SerializationFeature.FAIL_ON_EMPTY_BEANS, false); - yamlMapper.enable(SerializationFeature.INDENT_OUTPUT); - yamlMapper.setVisibility(PropertyAccessor.ALL, JsonAutoDetect.Visibility.NONE); - yamlMapper.setVisibility(PropertyAccessor.FIELD, JsonAutoDetect.Visibility.ANY); - yamlMapper.setVisibility(PropertyAccessor.CREATOR, JsonAutoDetect.Visibility.ANY); - } - - private JsonMapper() { - } - - - /** - * Return the yaml mapper - * - * @return - */ - public static ObjectMapper getYamlMapper() { - return yamlMapper; - } - - /** - * Return a json mapper - * - * @return - */ - public static ObjectMapper getMapper() { - return mapper; - } - -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/RealDistributionDeserializer.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/RealDistributionDeserializer.java deleted file mode 100644 index a30626560..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/RealDistributionDeserializer.java +++ /dev/null @@ -1,78 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.serde.jackson; - -import org.apache.commons.math3.distribution.*; -import org.deeplearning4j.arbiter.optimize.distribution.LogUniformDistribution; -import com.fasterxml.jackson.core.JsonParser; -import com.fasterxml.jackson.core.JsonProcessingException; -import com.fasterxml.jackson.databind.DeserializationContext; -import com.fasterxml.jackson.databind.JsonDeserializer; -import com.fasterxml.jackson.databind.JsonNode; - -import java.io.IOException; - -/** - * Created by Alex on 14/02/2017. - */ -public class RealDistributionDeserializer extends JsonDeserializer { - - @Override - public RealDistribution deserialize(JsonParser p, DeserializationContext ctxt) - throws IOException, JsonProcessingException { - JsonNode node = p.getCodec().readTree(p); - String simpleName = node.get("distribution").asText(); - - switch (simpleName) { - case "BetaDistribution": - return new BetaDistribution(node.get("alpha").asDouble(), node.get("beta").asDouble()); - case "CauchyDistribution": - return new CauchyDistribution(node.get("median").asDouble(), node.get("scale").asDouble()); - case "ChiSquaredDistribution": - return new ChiSquaredDistribution(node.get("dof").asDouble()); - case "ExponentialDistribution": - return new ExponentialDistribution(node.get("mean").asDouble()); - case "FDistribution": - return new FDistribution(node.get("numeratorDof").asDouble(), node.get("denominatorDof").asDouble()); - case "GammaDistribution": - return new GammaDistribution(node.get("shape").asDouble(), node.get("scale").asDouble()); - case "LevyDistribution": - return new LevyDistribution(node.get("mu").asDouble(), node.get("c").asDouble()); - case "LogNormalDistribution": - return new LogNormalDistribution(node.get("scale").asDouble(), node.get("shape").asDouble()); - case "NormalDistribution": - return new NormalDistribution(node.get("mean").asDouble(), node.get("stdev").asDouble()); - case "ParetoDistribution": - return new ParetoDistribution(node.get("scale").asDouble(), node.get("shape").asDouble()); - case "TDistribution": - return new TDistribution(node.get("dof").asDouble()); - case "TriangularDistribution": - return new TriangularDistribution(node.get("a").asDouble(), node.get("b").asDouble(), - node.get("c").asDouble()); - case "UniformRealDistribution": - return new UniformRealDistribution(node.get("lower").asDouble(), node.get("upper").asDouble()); - case "WeibullDistribution": - return new WeibullDistribution(node.get("alpha").asDouble(), node.get("beta").asDouble()); - case "LogUniformDistribution": - return new LogUniformDistribution(node.get("min").asDouble(), node.get("max").asDouble()); - default: - throw new RuntimeException("Unknown or not supported distribution: " + simpleName); - } - - - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/RealDistributionSerializer.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/RealDistributionSerializer.java deleted file mode 100644 index b108aad0a..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/RealDistributionSerializer.java +++ /dev/null @@ -1,107 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.serde.jackson; - -import org.apache.commons.math3.distribution.*; -import org.deeplearning4j.arbiter.optimize.distribution.LogUniformDistribution; -import com.fasterxml.jackson.core.JsonGenerator; -import com.fasterxml.jackson.databind.JsonSerializer; -import com.fasterxml.jackson.databind.SerializerProvider; - -import java.io.IOException; - -/** - * Custom JSON serializer for Apache commons RealDistribution instances. - * The custom serializer is set up to use the built-in c - */ -public class RealDistributionSerializer extends JsonSerializer { - - @Override - public void serialize(RealDistribution d, JsonGenerator j, SerializerProvider serializerProvider) - throws IOException { - Class c = d.getClass(); - String s = c.getSimpleName(); - - j.writeStartObject(); - j.writeStringField("distribution", s); - - - if (c == BetaDistribution.class) { - BetaDistribution bd = (BetaDistribution) d; - j.writeNumberField("alpha", bd.getAlpha()); - j.writeNumberField("beta", bd.getBeta()); - } else if (c == CauchyDistribution.class) { - CauchyDistribution cd = (CauchyDistribution) d; - j.writeNumberField("median", cd.getMedian()); - j.writeNumberField("scale", cd.getScale()); - } else if (c == ChiSquaredDistribution.class) { - ChiSquaredDistribution cd = (ChiSquaredDistribution) d; - j.writeNumberField("dof", cd.getDegreesOfFreedom()); - } else if (c == ExponentialDistribution.class) { - ExponentialDistribution ed = (ExponentialDistribution) d; - j.writeNumberField("mean", ed.getMean()); - } else if (c == FDistribution.class) { - FDistribution fd = (FDistribution) d; - j.writeNumberField("numeratorDof", fd.getNumeratorDegreesOfFreedom()); - j.writeNumberField("denominatorDof", fd.getDenominatorDegreesOfFreedom()); - } else if (c == GammaDistribution.class) { - GammaDistribution gd = (GammaDistribution) d; - j.writeNumberField("shape", gd.getShape()); - j.writeNumberField("scale", gd.getScale()); - } else if (c == LevyDistribution.class) { - LevyDistribution ld = (LevyDistribution) d; - j.writeNumberField("mu", ld.getLocation()); - j.writeNumberField("c", ld.getScale()); - } else if (c == LogNormalDistribution.class) { - LogNormalDistribution ln = (LogNormalDistribution) d; - j.writeNumberField("scale", ln.getScale()); - j.writeNumberField("shape", ln.getShape()); - } else if (c == NormalDistribution.class) { - NormalDistribution nd = (NormalDistribution) d; - j.writeNumberField("mean", nd.getMean()); - j.writeNumberField("stdev", nd.getStandardDeviation()); - } else if (c == ParetoDistribution.class) { - ParetoDistribution pd = (ParetoDistribution) d; - j.writeNumberField("scale", pd.getScale()); - j.writeNumberField("shape", pd.getShape()); - } else if (c == TDistribution.class) { - TDistribution td = (TDistribution) d; - j.writeNumberField("dof", td.getDegreesOfFreedom()); - } else if (c == TriangularDistribution.class) { - TriangularDistribution td = (TriangularDistribution) d; - j.writeNumberField("a", td.getSupportLowerBound()); - j.writeNumberField("b", td.getMode()); - j.writeNumberField("c", td.getSupportUpperBound()); - } else if (c == UniformRealDistribution.class) { - UniformRealDistribution u = (UniformRealDistribution) d; - j.writeNumberField("lower", u.getSupportLowerBound()); - j.writeNumberField("upper", u.getSupportUpperBound()); - } else if (c == WeibullDistribution.class) { - WeibullDistribution wb = (WeibullDistribution) d; - j.writeNumberField("alpha", wb.getShape()); - j.writeNumberField("beta", wb.getScale()); - } else if (c == LogUniformDistribution.class){ - LogUniformDistribution lud = (LogUniformDistribution) d; - j.writeNumberField("min", lud.getMin()); - j.writeNumberField("max", lud.getMax()); - } else { - throw new UnsupportedOperationException("Unknown or not supported RealDistribution: " + d.getClass()); - } - - j.writeEndObject(); - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/YamlMapper.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/YamlMapper.java deleted file mode 100644 index b1aae22b2..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/optimize/serde/jackson/YamlMapper.java +++ /dev/null @@ -1,52 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.serde.jackson; - -import com.fasterxml.jackson.annotation.JsonAutoDetect; -import com.fasterxml.jackson.annotation.PropertyAccessor; -import com.fasterxml.jackson.databind.DeserializationFeature; -import com.fasterxml.jackson.databind.ObjectMapper; -import com.fasterxml.jackson.databind.SerializationFeature; -import com.fasterxml.jackson.dataformat.yaml.YAMLFactory; -import com.fasterxml.jackson.datatype.joda.JodaModule; - -/** - * Created by Alex on 16/11/2016. - */ -public class YamlMapper { - - private static final ObjectMapper mapper; - - static { - mapper = new ObjectMapper(new YAMLFactory()); - mapper.registerModule(new JodaModule()); - mapper.configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false); - mapper.configure(SerializationFeature.FAIL_ON_EMPTY_BEANS, false); - mapper.enable(SerializationFeature.INDENT_OUTPUT); - mapper.setVisibility(PropertyAccessor.ALL, JsonAutoDetect.Visibility.NONE); - mapper.setVisibility(PropertyAccessor.FIELD, JsonAutoDetect.Visibility.ANY); - mapper.setVisibility(PropertyAccessor.CREATOR, JsonAutoDetect.Visibility.ANY); - } - - - private YamlMapper() {} - - public static ObjectMapper getMapper() { - return mapper; - } - -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/util/ClassPathResource.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/util/ClassPathResource.java deleted file mode 100644 index d22db15c8..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/util/ClassPathResource.java +++ /dev/null @@ -1,233 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.util; - -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -import java.io.*; -import java.net.MalformedURLException; -import java.net.URI; -import java.net.URISyntaxException; -import java.net.URL; -import java.util.zip.ZipEntry; -import java.util.zip.ZipFile; - -/** - * Simple utility class used to get access to files at the classpath, or packed into jar. - * Based on Spring ClassPathResource implementation + jar internals access implemented. - * - * @author raver119@gmail.com - */ -public class ClassPathResource { - - private String resourceName; - - private static Logger log = LoggerFactory.getLogger(ClassPathResource.class); - - /** - * Builds new ClassPathResource object - * - * @param resourceName String name of resource, to be retrieved - */ - public ClassPathResource(String resourceName) { - if (resourceName == null) - throw new IllegalStateException("Resource name can't be null"); - this.resourceName = resourceName; - } - - /** - * Returns URL of the requested resource - * - * @return URL of the resource, if it's available in current Jar - */ - private URL getUrl() { - ClassLoader loader = null; - try { - loader = Thread.currentThread().getContextClassLoader(); - } catch (Exception e) { - // do nothing - } - - if (loader == null) { - loader = ClassPathResource.class.getClassLoader(); - } - - URL url = loader.getResource(this.resourceName); - if (url == null) { - // try to check for mis-used starting slash - // TODO: see TODO below - if (this.resourceName.startsWith("/")) { - url = loader.getResource(this.resourceName.replaceFirst("[\\\\/]", "")); - if (url != null) - return url; - } else { - // try to add slash, to make clear it's not an issue - // TODO: change this mechanic to actual path purifier - url = loader.getResource("/" + this.resourceName); - if (url != null) - return url; - } - throw new IllegalStateException("Resource '" + this.resourceName + "' cannot be found."); - } - return url; - } - - /** - * Returns requested ClassPathResource as File object - *

- * Please note: if this method called from compiled jar, temporary file will be created to provide File access - * - * @return File requested at constructor call - * @throws FileNotFoundException - */ - public File getFile() throws FileNotFoundException { - URL url = this.getUrl(); - - if (isJarURL(url)) { - /* - This is actually request for file, that's packed into jar. Probably the current one, but that doesn't matters. - */ - try { - url = extractActualUrl(url); - File file = File.createTempFile("canova_temp", "file"); - file.deleteOnExit(); - - ZipFile zipFile = new ZipFile(url.getFile()); - ZipEntry entry = zipFile.getEntry(this.resourceName); - if (entry == null) { - if (this.resourceName.startsWith("/")) { - entry = zipFile.getEntry(this.resourceName.replaceFirst("/", "")); - if (entry == null) { - throw new FileNotFoundException("Resource " + this.resourceName + " not found"); - } - } else - throw new FileNotFoundException("Resource " + this.resourceName + " not found"); - } - - long size = entry.getSize(); - - InputStream stream = zipFile.getInputStream(entry); - FileOutputStream outputStream = new FileOutputStream(file); - byte[] array = new byte[1024]; - int rd = 0; - long bytesRead = 0; - do { - rd = stream.read(array); - outputStream.write(array, 0, rd); - bytesRead += rd; - } while (bytesRead < size); - - outputStream.flush(); - outputStream.close(); - - stream.close(); - zipFile.close(); - - return file; - } catch (Exception e) { - throw new RuntimeException(e); - } - - } else { - /* - It's something in the actual underlying filesystem, so we can just go for it - */ - - try { - URI uri = new URI(url.toString().replaceAll(" ", "%20")); - return new File(uri.getSchemeSpecificPart()); - } catch (URISyntaxException e) { - return new File(url.getFile()); - } - } - } - - /** - * Checks, if proposed URL is packed into archive. - * - * @param url URL to be checked - * @return True, if URL is archive entry, False otherwise - */ - private boolean isJarURL(URL url) { - String protocol = url.getProtocol(); - return "jar".equals(protocol) || "zip".equals(protocol) || "wsjar".equals(protocol) - || "code-source".equals(protocol) && url.getPath().contains("!/"); - } - - /** - * Extracts parent Jar URL from original ClassPath entry URL. - * - * @param jarUrl Original URL of the resource - * @return URL of the Jar file, containing requested resource - * @throws MalformedURLException - */ - private URL extractActualUrl(URL jarUrl) throws MalformedURLException { - String urlFile = jarUrl.getFile(); - int separatorIndex = urlFile.indexOf("!/"); - if (separatorIndex != -1) { - String jarFile = urlFile.substring(0, separatorIndex); - - try { - return new URL(jarFile); - } catch (MalformedURLException var5) { - if (!jarFile.startsWith("/")) { - jarFile = "/" + jarFile; - } - - return new URL("file:" + jarFile); - } - } else { - return jarUrl; - } - } - - /** - * Returns requested ClassPathResource as InputStream object - * - * @return File requested at constructor call - * @throws FileNotFoundException - */ - public InputStream getInputStream() throws FileNotFoundException { - URL url = this.getUrl(); - if (isJarURL(url)) { - try { - url = extractActualUrl(url); - ZipFile zipFile = new ZipFile(url.getFile()); - ZipEntry entry = zipFile.getEntry(this.resourceName); - - if (entry == null) { - if (this.resourceName.startsWith("/")) { - entry = zipFile.getEntry(this.resourceName.replaceFirst("/", "")); - if (entry == null) { - throw new FileNotFoundException("Resource " + this.resourceName + " not found"); - } - } else - throw new FileNotFoundException("Resource " + this.resourceName + " not found"); - } - - InputStream stream = zipFile.getInputStream(entry); - return stream; - } catch (Exception e) { - throw new RuntimeException(e); - } - } else { - File srcFile = this.getFile(); - return new FileInputStream(srcFile); - } - } -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/util/CollectionUtils.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/util/CollectionUtils.java deleted file mode 100644 index eb9275d82..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/util/CollectionUtils.java +++ /dev/null @@ -1,49 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.util; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.HashSet; -import java.util.List; - -public class CollectionUtils { - - /** - * Count the number of unique values in a collection - */ - public static int countUnique(Collection collection) { - HashSet set = new HashSet<>(collection); - return set.size(); - } - - /** - * Returns a list containing only unique values in a collection - */ - public static List getUnique(Collection collection) { - HashSet set = new HashSet<>(); - List out = new ArrayList<>(); - for (T t : collection) { - if (!set.contains(t)) { - out.add(t); - set.add(t); - } - } - return out; - } - -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/util/LeafUtils.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/util/LeafUtils.java deleted file mode 100644 index 2a86dc48f..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/util/LeafUtils.java +++ /dev/null @@ -1,73 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.util; - -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; - -import java.util.ArrayList; -import java.util.List; - -/** - * Created by Alex on 29/06/2017. - */ -public class LeafUtils { - - private LeafUtils() {} - - /** - * Returns a list of unique objects, not using the .equals() method, but rather using == - * - * @param allLeaves Leaf values to process - * @return A list of unique parameter space values - */ - public static List getUniqueObjects(List allLeaves) { - List unique = new ArrayList<>(); - for (ParameterSpace p : allLeaves) { - //This isn't especially efficient, but small number of parameters in general means it's fine - boolean found = false; - for (ParameterSpace q : unique) { - if (p == q) { - found = true; - } - } - if (!found) { - unique.add(p); - } - } - - return unique; - } - - /** - * Count the number of unique parameters in the specified leaf nodes - * - * @param allLeaves Leaf values to count the parameters fore - * @return Number of parameters for all unique objects - */ - public static int countUniqueParameters(List allLeaves) { - List unique = getUniqueObjects(allLeaves); - int count = 0; - for (ParameterSpace ps : unique) { - if (!ps.isLeaf()) { - throw new IllegalStateException("Method should only be used with leaf nodes"); - } - count += ps.numParameters(); - } - return count; - } - -} diff --git a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/util/ObjectUtils.java b/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/util/ObjectUtils.java deleted file mode 100644 index 9c3213430..000000000 --- a/arbiter/arbiter-core/src/main/java/org/deeplearning4j/arbiter/util/ObjectUtils.java +++ /dev/null @@ -1,61 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.util; - -import java.util.Arrays; - -/** - * @author Alex Black - */ -public class ObjectUtils { - - private ObjectUtils() {} - - /** - * Get the string representation of the object. Arrays, including primitive arrays, are printed using - * Arrays.toString(...) methods. - * - * @param v Value to convert to a string - * @return String representation - */ - public static String valueToString(Object v) { - if (v.getClass().isArray()) { - if (v.getClass().getComponentType().isPrimitive()) { - Class c = v.getClass().getComponentType(); - if (c == int.class) { - return Arrays.toString((int[]) v); - } else if (c == double.class) { - return Arrays.toString((double[]) v); - } else if (c == float.class) { - return Arrays.toString((float[]) v); - } else if (c == long.class) { - return Arrays.toString((long[]) v); - } else if (c == byte.class) { - return Arrays.toString((byte[]) v); - } else if (c == short.class) { - return Arrays.toString((short[]) v); - } else { - return v.toString(); - } - } else { - return Arrays.toString((Object[]) v); - } - } else { - return v.toString(); - } - } -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/AssertTestsExtendBaseClass.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/AssertTestsExtendBaseClass.java deleted file mode 100644 index cfb5e2556..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/AssertTestsExtendBaseClass.java +++ /dev/null @@ -1,49 +0,0 @@ -/* ****************************************************************************** - * Copyright (c) 2020 Konduit K.K. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ -package org.deeplearning4j.arbiter.optimize; - -import lombok.extern.slf4j.Slf4j; -import org.deeplearning4j.BaseDL4JTest; -import org.nd4j.common.tests.AbstractAssertTestsClass; -import java.util.*; - -/** - * This class checks that all test classes (i.e., anything with one or more methods annotated with @Test) - * extends BaseDl4jTest - either directly or indirectly. - * Other than a small set of exceptions, all tests must extend this - * - * @author Alex Black - */ - -@Slf4j -public class AssertTestsExtendBaseClass extends AbstractAssertTestsClass { - - @Override - protected Set> getExclusions() { - //Set of classes that are exclusions to the rule (either run manually or have their own logging + timeouts) - return new HashSet<>(); - } - - @Override - protected String getPackageName() { - return "org.deeplearning4j.arbiter.optimize"; - } - - @Override - protected Class getBaseClass() { - return BaseDL4JTest.class; - } -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/BraninFunction.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/BraninFunction.java deleted file mode 100644 index 4d507ee7d..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/BraninFunction.java +++ /dev/null @@ -1,156 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize; - -import lombok.AllArgsConstructor; -import lombok.Data; -import org.deeplearning4j.arbiter.optimize.api.*; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSource; -import org.deeplearning4j.arbiter.optimize.api.score.ScoreFunction; -import org.deeplearning4j.arbiter.optimize.parameter.continuous.ContinuousParameterSpace; -import org.deeplearning4j.arbiter.optimize.runner.CandidateInfo; -import org.deeplearning4j.arbiter.optimize.runner.CandidateStatus; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.listener.StatusListener; - -import java.io.Serializable; -import java.util.*; -import java.util.concurrent.Callable; - -public class BraninFunction { - public static class BraninSpace extends AbstractParameterSpace { - private int[] indices; - private ParameterSpace first = new ContinuousParameterSpace(-5, 10); - private ParameterSpace second = new ContinuousParameterSpace(0, 15); - - @Override - public BraninConfig getValue(double[] parameterValues) { - double f = first.getValue(parameterValues); - double s = second.getValue(parameterValues); - return new BraninConfig(f, s); //-5 to +10 and 0 to 15 - } - - @Override - public int numParameters() { - return 2; - } - - @Override - public List collectLeaves() { - List list = new ArrayList<>(); - list.addAll(first.collectLeaves()); - list.addAll(second.collectLeaves()); - return list; - } - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices) { - throw new UnsupportedOperationException(); - } - } - - @AllArgsConstructor - @Data - public static class BraninConfig implements Serializable { - private double x1; - private double x2; - } - - public static class BraninScoreFunction implements ScoreFunction { - private static final double a = 1.0; - private static final double b = 5.1 / (4.0 * Math.PI * Math.PI); - private static final double c = 5.0 / Math.PI; - private static final double r = 6.0; - private static final double s = 10.0; - private static final double t = 1.0 / (8.0 * Math.PI); - - @Override - public double score(Object m, DataProvider data, Map dataParameters) { - BraninConfig model = (BraninConfig) m; - double x1 = model.getX1(); - double x2 = model.getX2(); - - return a * Math.pow(x2 - b * x1 * x1 + c * x1 - r, 2.0) + s * (1 - t) * Math.cos(x1) + s; - } - - @Override - public double score(Object model, Class dataSource, Properties dataSourceProperties) { - throw new UnsupportedOperationException(); - } - - @Override - public boolean minimize() { - return true; - } - - @Override - public List> getSupportedModelTypes() { - return Collections.>singletonList(BraninConfig.class); - } - - @Override - public List> getSupportedDataTypes() { - return Collections.>singletonList(Object.class); - } - } - - public static class BraninTaskCreator implements TaskCreator { - @Override - public Callable create(final Candidate c, DataProvider dataProvider, - final ScoreFunction scoreFunction, final List statusListeners, - IOptimizationRunner runner) { - - return new Callable() { - @Override - public OptimizationResult call() throws Exception { - - BraninConfig candidate = (BraninConfig) c.getValue(); - - double score = scoreFunction.score(candidate, null, (Map) null); -// System.out.println(candidate.getX1() + "\t" + candidate.getX2() + "\t" + score); - - Thread.sleep(20); - - if (statusListeners != null) { - for (StatusListener sl : statusListeners) { - sl.onCandidateIteration(null, null, 0); - } - } - - CandidateInfo ci = new CandidateInfo(-1, CandidateStatus.Complete, score, - System.currentTimeMillis(), null, null, null, null); - - return new OptimizationResult(c, score, c.getIndex(), null, ci, null); - } - }; - } - - @Override - public Callable create(Candidate candidate, Class dataSource, - Properties dataSourceProperties, ScoreFunction scoreFunction, - List statusListeners, IOptimizationRunner runner) { - throw new UnsupportedOperationException(); - } - } - -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/TestGeneticSearch.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/TestGeneticSearch.java deleted file mode 100644 index 9410fa602..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/TestGeneticSearch.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize; - -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.api.CandidateGenerator; -import org.deeplearning4j.arbiter.optimize.api.score.ScoreFunction; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxCandidatesCondition; -import org.deeplearning4j.arbiter.optimize.api.termination.TerminationCondition; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; -import org.deeplearning4j.arbiter.optimize.generator.GeneticSearchCandidateGenerator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.exceptions.GeneticGenerationException; -import org.deeplearning4j.arbiter.optimize.generator.genetic.selection.SelectionOperator; -import org.deeplearning4j.arbiter.optimize.runner.CandidateInfo; -import org.deeplearning4j.arbiter.optimize.runner.CandidateStatus; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.LocalOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.listener.impl.LoggingStatusListener; -import org.junit.jupiter.api.Assertions; -import org.junit.jupiter.api.Test; - -public class TestGeneticSearch extends BaseDL4JTest { - public class TestSelectionOperator extends SelectionOperator { - - @Override - public double[] buildNextGenes() { - throw new GeneticGenerationException("Forced exception to test exception handling."); - } - } - - public class TestTerminationCondition implements TerminationCondition { - - public boolean hasAFailedCandidate = false; - public int evalCount = 0; - - @Override - public void initialize(IOptimizationRunner optimizationRunner) {} - - @Override - public boolean terminate(IOptimizationRunner optimizationRunner) { - if (++evalCount == 50) { - // Generator did not handle GeneticGenerationException - return true; - } - - for (CandidateInfo candidateInfo : optimizationRunner.getCandidateStatus()) { - if (candidateInfo.getCandidateStatus() == CandidateStatus.Failed) { - hasAFailedCandidate = true; - return true; - } - } - - return false; - } - } - - @Test - public void GeneticSearchCandidateGenerator_getCandidate_ShouldGenerateCandidates() throws Exception { - - ScoreFunction scoreFunction = new BraninFunction.BraninScoreFunction(); - - //Define configuration: - CandidateGenerator candidateGenerator = - new GeneticSearchCandidateGenerator.Builder(new BraninFunction.BraninSpace(), scoreFunction) - .build(); - - TestTerminationCondition testTerminationCondition = new TestTerminationCondition(); - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).scoreFunction(scoreFunction) - .terminationConditions(new MaxCandidatesCondition(50), testTerminationCondition).build(); - - IOptimizationRunner runner = new LocalOptimizationRunner(configuration, new BraninFunction.BraninTaskCreator()); - - runner.addListeners(new LoggingStatusListener()); - runner.execute(); - - Assertions.assertFalse(testTerminationCondition.hasAFailedCandidate); - } - - @Test - public void GeneticSearchCandidateGenerator_getCandidate_GeneticExceptionShouldMarkCandidateAsFailed() { - - ScoreFunction scoreFunction = new BraninFunction.BraninScoreFunction(); - - //Define configuration: - CandidateGenerator candidateGenerator = - new GeneticSearchCandidateGenerator.Builder(new BraninFunction.BraninSpace(), scoreFunction) - .selectionOperator(new TestSelectionOperator()).build(); - - TestTerminationCondition testTerminationCondition = new TestTerminationCondition(); - - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).scoreFunction(scoreFunction) - .terminationConditions(testTerminationCondition).build(); - - IOptimizationRunner runner = new LocalOptimizationRunner(configuration, new BraninFunction.BraninTaskCreator()); - - runner.addListeners(new LoggingStatusListener()); - runner.execute(); - - Assertions.assertTrue(testTerminationCondition.hasAFailedCandidate); - } - -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/TestGridSearch.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/TestGridSearch.java deleted file mode 100644 index 45a9aadf5..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/TestGridSearch.java +++ /dev/null @@ -1,104 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize; - -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.api.CandidateGenerator; -import org.deeplearning4j.arbiter.optimize.api.data.DataSetIteratorFactoryProvider; -import org.deeplearning4j.arbiter.optimize.generator.GridSearchCandidateGenerator; -import org.junit.jupiter.api.Test; - -import java.util.HashMap; -import java.util.Map; - -import static org.junit.jupiter.api.Assertions.*; - -public class TestGridSearch extends BaseDL4JTest { - - @Test - public void testIndexing() { - int[] nValues = {2, 3}; - int prod = 2 * 3; - double[][] expVals = new double[][] {{0.0, 0.0}, {1.0, 0.0}, {0.0, 0.5}, {1.0, 0.5}, {0.0, 1.0}, {1.0, 1.0}}; - for (int i = 0; i < prod; i++) { - double[] out = GridSearchCandidateGenerator.indexToValues(nValues, i, prod); - double[] exp = expVals[i]; - assertArrayEquals(exp, out, 1e-4); - } - } - - @Test - public void testGeneration() throws Exception { - Map commands = new HashMap<>(); - commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY, new HashMap<>()); - - //Define configuration: - CandidateGenerator candidateGenerator = new GridSearchCandidateGenerator(new BraninFunction.BraninSpace(), 4, - GridSearchCandidateGenerator.Mode.Sequential, commands); - - //Check sequential: - double[] expValuesFirst = {-5, 0, 5, 10}; //Range: -5 to +10, with 4 values - double[] expValuesSecond = {0, 5, 10, 15}; //Range: 0 to +15, with 4 values - for (int i = 0; i < 4 * 4; i++) { - BraninFunction.BraninConfig conf = (BraninFunction.BraninConfig) candidateGenerator.getCandidate().getValue(); - double expF = expValuesFirst[i % 4]; //Changes most rapidly - double expS = expValuesSecond[i / 4]; - - double actF = conf.getX1(); - double actS = conf.getX2(); - - assertEquals(expF, actF, 1e-4); - assertEquals(expS, actS, 1e-4); - } - - //Check random order. specifically: check that all values are generated, in some order - double[][] orderedOutput = new double[16][2]; - for (int i = 0; i < expValuesFirst.length; i++) { - for (int j = 0; j < expValuesSecond.length; j++) { - orderedOutput[4 * j + i][0] = expValuesFirst[i]; - orderedOutput[4 * j + i][1] = expValuesSecond[j]; - } - } - - - candidateGenerator = new GridSearchCandidateGenerator(new BraninFunction.BraninSpace(), 4, - GridSearchCandidateGenerator.Mode.RandomOrder, commands); - boolean[] seen = new boolean[16]; - int seenCount = 0; - for (int i = 0; i < 4 * 4; i++) { - assertTrue(candidateGenerator.hasMoreCandidates()); - BraninFunction.BraninConfig config = (BraninFunction.BraninConfig) candidateGenerator.getCandidate().getValue(); - double x1 = config.getX1(); - double x2 = config.getX2(); - //Work out which of the values this is... - boolean matched = false; - for (int j = 0; j < 16; j++) { - if (Math.abs(orderedOutput[j][0] - x1) < 1e-5 && Math.abs(orderedOutput[j][1] - x2) < 1e-5) { - matched = true; - if (seen[j]) - fail("Same candidate generated multiple times"); - seen[j] = true; - seenCount++; - break; - } - } - assertTrue(matched, "Candidate " + x1 + ", " + x2 + " not found; invalid?"); - } - assertFalse(candidateGenerator.hasMoreCandidates()); - assertEquals(16, seenCount); - } -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/TestJson.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/TestJson.java deleted file mode 100644 index 225894d6f..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/TestJson.java +++ /dev/null @@ -1,122 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize; - -import org.apache.commons.math3.distribution.LogNormalDistribution; -import org.apache.commons.math3.distribution.NormalDistribution; -import org.apache.commons.math3.distribution.UniformIntegerDistribution; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.api.CandidateGenerator; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.api.data.DataSetIteratorFactoryProvider; -import org.deeplearning4j.arbiter.optimize.generator.GridSearchCandidateGenerator; -import org.deeplearning4j.arbiter.optimize.generator.RandomSearchGenerator; -import org.deeplearning4j.arbiter.optimize.parameter.BooleanSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.optimize.parameter.continuous.ContinuousParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.discrete.DiscreteParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.integer.IntegerParameterSpace; -import org.junit.jupiter.api.Test; -import com.fasterxml.jackson.annotation.JsonAutoDetect; -import com.fasterxml.jackson.annotation.PropertyAccessor; -import com.fasterxml.jackson.core.JsonFactory; -import com.fasterxml.jackson.databind.DeserializationFeature; -import com.fasterxml.jackson.databind.ObjectMapper; -import com.fasterxml.jackson.databind.SerializationFeature; -import com.fasterxml.jackson.dataformat.yaml.YAMLFactory; -import com.fasterxml.jackson.datatype.joda.JodaModule; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import static org.junit.jupiter.api.Assertions.assertEquals; - -/** - * Created by Alex on 02/02/2017. - */ -public class TestJson extends BaseDL4JTest { - - protected static ObjectMapper getObjectMapper(JsonFactory factory) { - ObjectMapper om = new ObjectMapper(factory); - om.registerModule(new JodaModule()); - om.configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false); - om.configure(SerializationFeature.FAIL_ON_EMPTY_BEANS, false); - om.enable(SerializationFeature.INDENT_OUTPUT); - om.setVisibility(PropertyAccessor.ALL, JsonAutoDetect.Visibility.NONE); - om.setVisibility(PropertyAccessor.FIELD, JsonAutoDetect.Visibility.ANY); - om.setVisibility(PropertyAccessor.CREATOR, JsonAutoDetect.Visibility.ANY); - return om; - } - - private static ObjectMapper jsonMapper = getObjectMapper(new JsonFactory()); - private static ObjectMapper yamlMapper = getObjectMapper(new YAMLFactory()); - - - @Test - public void testParameterSpaceJson() throws Exception { - - List> l = new ArrayList<>(); - l.add(new FixedValue<>(1.0)); - l.add(new FixedValue<>(1)); - l.add(new FixedValue<>("string")); - l.add(new ContinuousParameterSpace(-1, 1)); - l.add(new ContinuousParameterSpace(new LogNormalDistribution(1, 1))); - l.add(new ContinuousParameterSpace(new NormalDistribution(2, 0.01))); - l.add(new DiscreteParameterSpace<>(1, 5, 7)); - l.add(new DiscreteParameterSpace<>("first", "second", "third")); - l.add(new IntegerParameterSpace(0, 10)); - l.add(new IntegerParameterSpace(new UniformIntegerDistribution(0, 50))); - l.add(new BooleanSpace()); - - for (ParameterSpace ps : l) { - String strJson = jsonMapper.writeValueAsString(ps); - String strYaml = yamlMapper.writeValueAsString(ps); - - ParameterSpace fromJson = jsonMapper.readValue(strJson, ParameterSpace.class); - ParameterSpace fromYaml = yamlMapper.readValue(strYaml, ParameterSpace.class); - - assertEquals(ps, fromJson); - assertEquals(ps, fromYaml); - } - } - - @Test - public void testCandidateGeneratorJson() throws Exception { - Map commands = new HashMap<>(); - commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY, new HashMap<>()); - - List l = new ArrayList<>(); - l.add(new GridSearchCandidateGenerator(new DiscreteParameterSpace<>(0, 1, 2, 3, 4, 5), 10, - GridSearchCandidateGenerator.Mode.Sequential, commands)); - l.add(new GridSearchCandidateGenerator(new DiscreteParameterSpace<>(0, 1, 2, 3, 4, 5), 10, - GridSearchCandidateGenerator.Mode.RandomOrder, commands)); - l.add(new RandomSearchGenerator(new DiscreteParameterSpace<>(0, 1, 2, 3, 4, 5), commands)); - - for (CandidateGenerator cg : l) { - String strJson = jsonMapper.writeValueAsString(cg); - String strYaml = yamlMapper.writeValueAsString(cg); - - CandidateGenerator fromJson = jsonMapper.readValue(strJson, CandidateGenerator.class); - CandidateGenerator fromYaml = yamlMapper.readValue(strYaml, CandidateGenerator.class); - - assertEquals(cg, fromJson); - assertEquals(cg, fromYaml); - } - } -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/TestRandomSearch.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/TestRandomSearch.java deleted file mode 100644 index db7702b76..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/TestRandomSearch.java +++ /dev/null @@ -1,61 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize; - -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.api.CandidateGenerator; -import org.deeplearning4j.arbiter.optimize.api.data.DataSetIteratorFactoryProvider; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxCandidatesCondition; -import org.deeplearning4j.arbiter.optimize.generator.RandomSearchGenerator; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.LocalOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.listener.impl.LoggingStatusListener; -import org.junit.jupiter.api.Test; - -import java.util.HashMap; -import java.util.Map; - -/** - * - * Test random search on the Branin Function: - * http://www.sfu.ca/~ssurjano/branin.html - */ -public class TestRandomSearch extends BaseDL4JTest { - - @Test - public void test() throws Exception { - Map commands = new HashMap<>(); - commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY, new HashMap<>()); - - //Define configuration: - CandidateGenerator candidateGenerator = new RandomSearchGenerator(new BraninFunction.BraninSpace(), commands); - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).scoreFunction(new BraninFunction.BraninScoreFunction()) - .terminationConditions(new MaxCandidatesCondition(50)).build(); - - IOptimizationRunner runner = new LocalOptimizationRunner(configuration, new BraninFunction.BraninTaskCreator()); - - runner.addListeners(new LoggingStatusListener()); - runner.execute(); - - -// System.out.println("----- Complete -----"); - } - - -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/distribution/TestLogUniform.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/distribution/TestLogUniform.java deleted file mode 100644 index e2a6044ce..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/distribution/TestLogUniform.java +++ /dev/null @@ -1,70 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.distribution; - -import org.apache.commons.math3.distribution.RealDistribution; -import org.deeplearning4j.BaseDL4JTest; -import org.junit.jupiter.api.Test; - -import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.junit.jupiter.api.Assertions.assertTrue; - -public class TestLogUniform extends BaseDL4JTest { - - @Test - public void testSimple(){ - - double min = 0.5; - double max = 3; - - double logMin = Math.log(min); - double logMax = Math.log(max); - - RealDistribution rd = new LogUniformDistribution(min, max); - - for(double d = 0.1; d<= 3.5; d+= 0.1){ - double density = rd.density(d); - double cumulative = rd.cumulativeProbability(d); - double dExp; - double cumExp; - if(d < min){ - dExp = 0; - cumExp = 0; - } else if( d > max){ - dExp = 0; - cumExp = 1; - } else { - dExp = 1.0 / (d * (logMax-logMin)); - cumExp = (Math.log(d) - logMin) / (logMax - logMin); - } - - assertTrue(dExp >= 0); - assertTrue(cumExp >= 0); - assertTrue(cumExp <= 1.0); - assertEquals(dExp, density, 1e-5); - assertEquals(cumExp, cumulative, 1e-5); - } - - rd.reseedRandomGenerator(12345); - for( int i=0; i<100; i++ ){ - double d = rd.sample(); - assertTrue(d >= min); - assertTrue(d <= max); - } - } - -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestCrossoverOperator.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestCrossoverOperator.java deleted file mode 100644 index 9297c3df7..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestCrossoverOperator.java +++ /dev/null @@ -1,40 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic; - -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.CrossoverOperator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.CrossoverResult; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationModel; - -public class TestCrossoverOperator extends CrossoverOperator { - - private final CrossoverResult[] results; - private int resultIdx = 0; - - public PopulationModel getPopulationModel() { - return populationModel; - } - - public TestCrossoverOperator(CrossoverResult[] results) { - this.results = results; - } - - @Override - public CrossoverResult crossover() { - return results[resultIdx++]; - } -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestMutationOperator.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestMutationOperator.java deleted file mode 100644 index 4718714d1..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestMutationOperator.java +++ /dev/null @@ -1,34 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic; - -import org.deeplearning4j.arbiter.optimize.generator.genetic.mutation.MutationOperator; - -public class TestMutationOperator implements MutationOperator { - - private final boolean[] results; - private int resultIdx = 0; - - public TestMutationOperator(boolean[] results) { - this.results = results; - } - - @Override - public boolean mutate(double[] genes) { - return results[resultIdx++]; - } -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestParentSelection.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestParentSelection.java deleted file mode 100644 index 7f9c33b14..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestParentSelection.java +++ /dev/null @@ -1,52 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic; - -import org.deeplearning4j.arbiter.optimize.generator.genetic.Chromosome; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.parentselection.TwoParentSelection; - -import java.util.List; - -public class TestParentSelection extends TwoParentSelection { - - public boolean hasBeenInitialized; - - private final double[][] parents; - - public TestParentSelection(double[][] parents) { - this.parents = parents; - } - - public TestParentSelection() { - this(null); - } - - @Override - public void initializeInstance(List population) { - super.initializeInstance(population); - hasBeenInitialized = true; - } - - @Override - public double[][] selectParents() { - return parents; - } - - public List getPopulation() { - return population; - } -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestPopulationInitializer.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestPopulationInitializer.java deleted file mode 100644 index 926555f79..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestPopulationInitializer.java +++ /dev/null @@ -1,30 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic; - -import org.deeplearning4j.arbiter.optimize.generator.genetic.Chromosome; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationInitializer; - -import java.util.ArrayList; -import java.util.List; - -public class TestPopulationInitializer implements PopulationInitializer { - @Override - public List getInitializedPopulation(int size) { - return new ArrayList<>(); - } -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestRandomGenerator.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestRandomGenerator.java deleted file mode 100644 index abeba96e8..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/TestRandomGenerator.java +++ /dev/null @@ -1,88 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic; - -import org.apache.commons.lang3.NotImplementedException; -import org.apache.commons.math3.random.RandomGenerator; - -public class TestRandomGenerator implements RandomGenerator { - private final int[] intRandomNumbers; - private int currentIntIdx = 0; - private final double[] doubleRandomNumbers; - private int currentDoubleIdx = 0; - - - public TestRandomGenerator(int[] intRandomNumbers, double[] doubleRandomNumbers) { - this.intRandomNumbers = intRandomNumbers; - this.doubleRandomNumbers = doubleRandomNumbers; - } - - @Override - public void setSeed(int i) { - - } - - @Override - public void setSeed(int[] ints) { - - } - - @Override - public void setSeed(long l) { - - } - - @Override - public void nextBytes(byte[] bytes) { - - } - - @Override - public int nextInt() { - return intRandomNumbers[currentIntIdx++]; - } - - @Override - public int nextInt(int i) { - return intRandomNumbers[currentIntIdx++]; - } - - @Override - public long nextLong() { - throw new NotImplementedException("Not implemented"); - } - - @Override - public boolean nextBoolean() { - throw new NotImplementedException("Not implemented"); - } - - @Override - public float nextFloat() { - throw new NotImplementedException("Not implemented"); - } - - @Override - public double nextDouble() { - return doubleRandomNumbers[currentDoubleIdx++]; - } - - @Override - public double nextGaussian() { - throw new NotImplementedException("Not implemented"); - } -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/ArithmeticCrossoverTests.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/ArithmeticCrossoverTests.java deleted file mode 100644 index f234465b0..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/ArithmeticCrossoverTests.java +++ /dev/null @@ -1,68 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic.crossover; - -import org.apache.commons.math3.random.RandomGenerator; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.ArithmeticCrossover; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.CrossoverResult; -import org.deeplearning4j.arbiter.optimize.genetic.TestParentSelection; -import org.deeplearning4j.arbiter.optimize.genetic.TestRandomGenerator; -import org.junit.jupiter.api.Assertions; -import org.junit.jupiter.api.Test; - -public class ArithmeticCrossoverTests extends BaseDL4JTest { - - @Test - public void ArithmeticCrossover_Crossover_OutsideCrossoverRate_ShouldReturnParent0() { - double[][] parents = new double[2][]; - parents[0] = new double[] {1.0}; - parents[1] = new double[] {2.0}; - - TestParentSelection parentSelection = new TestParentSelection(parents); - - RandomGenerator rng = new TestRandomGenerator(null, new double[] {1.0}); - - ArithmeticCrossover sut = - new ArithmeticCrossover.Builder().parentSelection(parentSelection).randomGenerator(rng).build(); - CrossoverResult result = sut.crossover(); - - Assertions.assertFalse(result.isModified()); - Assertions.assertEquals(1, result.getGenes().length); - Assertions.assertEquals(1.0, result.getGenes()[0], 0.001); - } - - @Test - public void ArithmeticCrossover_Crossover_WithinCrossoverRate_ShouldReturnLinearCombination() { - double[][] parents = new double[2][]; - parents[0] = new double[] {1.0}; - parents[1] = new double[] {2.0}; - - TestParentSelection parentSelection = new TestParentSelection(parents); - - RandomGenerator rng = new TestRandomGenerator(null, new double[] {0.1, 0.1}); - - ArithmeticCrossover sut = - new ArithmeticCrossover.Builder().parentSelection(parentSelection).randomGenerator(rng).build(); - CrossoverResult result = sut.crossover(); - - Assertions.assertTrue(result.isModified()); - Assertions.assertEquals(1, result.getGenes().length); - Assertions.assertEquals(1.9, result.getGenes()[0], 0.001); - } - -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/CrossoverOperatorTests.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/CrossoverOperatorTests.java deleted file mode 100644 index 2cea0b608..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/CrossoverOperatorTests.java +++ /dev/null @@ -1,43 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic.crossover; - -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationInitializer; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationModel; -import org.deeplearning4j.arbiter.optimize.genetic.TestCrossoverOperator; -import org.deeplearning4j.arbiter.optimize.genetic.TestPopulationInitializer; -import org.junit.jupiter.api.Assertions; -import org.junit.jupiter.api.Test; - -public class CrossoverOperatorTests extends BaseDL4JTest { - - @Test - public void CrossoverOperator_initializeInstance_ShouldInitPopulationModel() throws IllegalAccessException { - TestCrossoverOperator sut = new TestCrossoverOperator(null); - - PopulationInitializer populationInitializer = new TestPopulationInitializer(); - - PopulationModel populationModel = - new PopulationModel.Builder().populationInitializer(populationInitializer).build(); - sut.initializeInstance(populationModel); - - Assertions.assertSame(populationModel, sut.getPopulationModel()); - - - } -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/CrossoverPointsGeneratorTests.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/CrossoverPointsGeneratorTests.java deleted file mode 100644 index 120fa8a28..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/CrossoverPointsGeneratorTests.java +++ /dev/null @@ -1,45 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic.crossover; - -import org.apache.commons.math3.random.RandomGenerator; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.utils.CrossoverPointsGenerator; -import org.deeplearning4j.arbiter.optimize.genetic.TestRandomGenerator; -import org.junit.jupiter.api.Assertions; -import org.junit.jupiter.api.Test; - -import java.util.Deque; - -public class CrossoverPointsGeneratorTests extends BaseDL4JTest { - - @Test - public void CrossoverPointsGenerator_FixedNumberCrossovers() { - RandomGenerator rng = new TestRandomGenerator(new int[] {0}, null); - CrossoverPointsGenerator sut = new CrossoverPointsGenerator(10, 2, 2, rng); - - Deque result = sut.getCrossoverPoints(); - - Assertions.assertEquals(3, result.size()); - int a = result.pop(); - int b = result.pop(); - int c = result.pop(); - Assertions.assertTrue(a < b); - Assertions.assertTrue(b < c); - Assertions.assertEquals(Integer.MAX_VALUE, c); - } -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/KPointCrossoverTests.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/KPointCrossoverTests.java deleted file mode 100644 index 64d56e5ac..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/KPointCrossoverTests.java +++ /dev/null @@ -1,67 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic.crossover; - -import org.apache.commons.math3.random.RandomGenerator; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.CrossoverResult; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.KPointCrossover; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.parentselection.TwoParentSelection; -import org.deeplearning4j.arbiter.optimize.genetic.TestParentSelection; -import org.deeplearning4j.arbiter.optimize.genetic.TestRandomGenerator; -import org.junit.jupiter.api.Assertions; -import org.junit.jupiter.api.Test; - -public class KPointCrossoverTests extends BaseDL4JTest { - - @Test - public void KPointCrossover_BelowCrossoverRate_ShouldReturnParent0() { - RandomGenerator rng = new TestRandomGenerator(null, new double[] {1.0}); - - double[][] parents = new double[2][]; - parents[0] = new double[] {0.0}; - parents[1] = new double[] {1.0}; - TwoParentSelection parentSelection = new TestParentSelection(parents); - KPointCrossover sut = new KPointCrossover.Builder().randomGenerator(rng).crossoverRate(0.0) - .parentSelection(parentSelection).build(); - - CrossoverResult result = sut.crossover(); - - Assertions.assertFalse(result.isModified()); - Assertions.assertSame(parents[0], result.getGenes()); - } - - @Test - public void KPointCrossover_FixedNumberOfCrossovers() { - RandomGenerator rng = new TestRandomGenerator(new int[] {0, 1}, new double[] {0.0}); - - double[][] parents = new double[3][]; - parents[0] = new double[] {0.0, 0.0, 0.0, 0.0, 0.0}; - parents[1] = new double[] {1.0, 1.0, 1.0, 1.0, 1.0}; - parents[2] = new double[] {2.0, 2.0, 2.0, 2.0, 2.0}; - TwoParentSelection parentSelection = new TestParentSelection(parents); - KPointCrossover sut = new KPointCrossover.Builder().randomGenerator(rng).crossoverRate(1.0) - .parentSelection(parentSelection).numCrossovers(2).build(); - - CrossoverResult result = sut.crossover(); - - Assertions.assertTrue(result.isModified()); - for (double x : result.getGenes()) { - Assertions.assertTrue(x == 0.0 || x == 1.0); - } - } -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/ParentSelectionTests.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/ParentSelectionTests.java deleted file mode 100644 index ca65e6ef0..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/ParentSelectionTests.java +++ /dev/null @@ -1,39 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic.crossover; - -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.generator.genetic.Chromosome; -import org.deeplearning4j.arbiter.optimize.genetic.TestParentSelection; -import org.junit.jupiter.api.Assertions; -import org.junit.jupiter.api.Test; - -import java.util.ArrayList; -import java.util.List; - -public class ParentSelectionTests extends BaseDL4JTest { - - @Test - public void ParentSelection_InitializeInstance_ShouldInitPopulation() { - TestParentSelection sut = new TestParentSelection(); - - List population = new ArrayList<>(); - sut.initializeInstance(population); - - Assertions.assertSame(population, sut.getPopulation()); - } -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/RandomTwoParentSelectionTests.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/RandomTwoParentSelectionTests.java deleted file mode 100644 index 214ee0181..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/RandomTwoParentSelectionTests.java +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic.crossover; - -import org.apache.commons.math3.random.RandomGenerator; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.generator.genetic.Chromosome; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.parentselection.RandomTwoParentSelection; -import org.deeplearning4j.arbiter.optimize.genetic.TestRandomGenerator; -import org.junit.jupiter.api.Assertions; -import org.junit.jupiter.api.Test; - -import java.util.ArrayList; -import java.util.List; - -public class RandomTwoParentSelectionTests extends BaseDL4JTest { - @Test - public void RandomTwoParentSelection_ShouldReturnTwoDifferentParents() { - RandomGenerator rng = new TestRandomGenerator(new int[] {1, 1, 1, 0}, null); - RandomTwoParentSelection sut = new RandomTwoParentSelection(rng); - - List population = new ArrayList<>(); - population.add(new Chromosome(new double[] {1, 1, 1}, 1.0)); - population.add(new Chromosome(new double[] {2, 2, 2}, 2.0)); - population.add(new Chromosome(new double[] {3, 3, 3}, 3.0)); - sut.initializeInstance(population); - - double[][] result = sut.selectParents(); - - Assertions.assertSame(population.get(1).getGenes(), result[0]); - Assertions.assertSame(population.get(0).getGenes(), result[1]); - } -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/SinglePointCrossoverTests.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/SinglePointCrossoverTests.java deleted file mode 100644 index 52fba0c59..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/SinglePointCrossoverTests.java +++ /dev/null @@ -1,68 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic.crossover; - -import org.apache.commons.math3.random.RandomGenerator; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.CrossoverResult; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.SinglePointCrossover; -import org.deeplearning4j.arbiter.optimize.genetic.TestParentSelection; -import org.deeplearning4j.arbiter.optimize.genetic.TestRandomGenerator; -import org.junit.jupiter.api.Assertions; -import org.junit.jupiter.api.Test; - -public class SinglePointCrossoverTests extends BaseDL4JTest { - @Test - public void SinglePointCrossover_BelowCrossoverRate_ShouldReturnParent0() { - RandomGenerator rng = new TestRandomGenerator(null, new double[] {1.0}); - - double[][] parents = new double[2][]; - parents[0] = new double[] {1.0, 1.0, 1.0}; - parents[1] = new double[] {2.0, 2.0, 2.0}; - TestParentSelection parentSelection = new TestParentSelection(parents); - - SinglePointCrossover sut = new SinglePointCrossover.Builder().parentSelection(parentSelection) - .randomGenerator(rng).crossoverRate(0.0).build(); - - CrossoverResult result = sut.crossover(); - - Assertions.assertFalse(result.isModified()); - Assertions.assertSame(parents[0], result.getGenes()); - } - - @Test - public void SinglePointCrossover_ShouldReturnSingleSplit() { - RandomGenerator rng = new TestRandomGenerator(new int[] {2}, new double[] {0.1}); - - double[][] parents = new double[2][]; - parents[0] = new double[] {1.0, 1.0, 1.0}; - parents[1] = new double[] {2.0, 2.0, 2.0}; - TestParentSelection parentSelection = new TestParentSelection(parents); - - SinglePointCrossover sut = new SinglePointCrossover.Builder().parentSelection(parentSelection) - .randomGenerator(rng).crossoverRate(0.5).build(); - - CrossoverResult result = sut.crossover(); - - Assertions.assertTrue(result.isModified()); - Assertions.assertEquals(1.0, result.getGenes()[0], 0.0); - Assertions.assertEquals(1.0, result.getGenes()[1], 0.0); - Assertions.assertEquals(2.0, result.getGenes()[2], 0.0); - - } - -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/TwoParentsCrossoverOperatorTests.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/TwoParentsCrossoverOperatorTests.java deleted file mode 100644 index 972d528ed..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/TwoParentsCrossoverOperatorTests.java +++ /dev/null @@ -1,71 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic.crossover; - -import org.apache.commons.lang3.NotImplementedException; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.CrossoverResult; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.TwoParentsCrossoverOperator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.parentselection.TwoParentSelection; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationInitializer; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationModel; -import org.deeplearning4j.arbiter.optimize.genetic.TestParentSelection; -import org.deeplearning4j.arbiter.optimize.genetic.TestPopulationInitializer; -import org.junit.jupiter.api.Assertions; -import org.junit.jupiter.api.Test; - -public class TwoParentsCrossoverOperatorTests extends BaseDL4JTest { - - class TestTwoParentsCrossoverOperator extends TwoParentsCrossoverOperator { - - public TestTwoParentsCrossoverOperator(TwoParentSelection parentSelection) { - super(parentSelection); - } - - public TwoParentSelection getParentSelection() { - return parentSelection; - } - - @Override - public CrossoverResult crossover() { - throw new NotImplementedException("Not implemented"); - } - } - - @Test - public void TwoParentsCrossoverOperator_ctor_ShouldInitParentSelection() { - TestParentSelection parentSelection = new TestParentSelection(); - TestTwoParentsCrossoverOperator sut = new TestTwoParentsCrossoverOperator(parentSelection); - - Assertions.assertSame(parentSelection, sut.getParentSelection()); - } - - @Test - public void TwoParentsCrossoverOperator_initializeInstanceShouldInitializeParentSelection() { - TestParentSelection parentSelection = new TestParentSelection(); - TestTwoParentsCrossoverOperator sut = new TestTwoParentsCrossoverOperator(parentSelection); - - PopulationInitializer populationInitializer = new TestPopulationInitializer(); - PopulationModel populationModel = - new PopulationModel.Builder().populationInitializer(populationInitializer).build(); - - sut.initializeInstance(populationModel); - - Assertions.assertTrue(parentSelection.hasBeenInitialized); - } - -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/UniformCrossoverTests.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/UniformCrossoverTests.java deleted file mode 100644 index 5efff80b2..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/crossover/UniformCrossoverTests.java +++ /dev/null @@ -1,68 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic.crossover; - -import org.apache.commons.math3.random.RandomGenerator; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.CrossoverResult; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.UniformCrossover; -import org.deeplearning4j.arbiter.optimize.genetic.TestParentSelection; -import org.deeplearning4j.arbiter.optimize.genetic.TestRandomGenerator; -import org.junit.jupiter.api.Assertions; -import org.junit.jupiter.api.Test; - -public class UniformCrossoverTests extends BaseDL4JTest { - - @Test - public void UniformCrossover_BelowCrossoverRate_ShouldReturnParent0() { - RandomGenerator rng = new TestRandomGenerator(null, new double[] {1.0}); - - double[][] parents = new double[2][]; - parents[0] = new double[] {1.0, 1.0, 1.0}; - parents[1] = new double[] {2.0, 2.0, 2.0}; - TestParentSelection parentSelection = new TestParentSelection(parents); - - UniformCrossover sut = new UniformCrossover.Builder().parentSelection(parentSelection).randomGenerator(rng) - .crossoverRate(0.0).build(); - - CrossoverResult result = sut.crossover(); - - Assertions.assertFalse(result.isModified()); - Assertions.assertSame(parents[0], result.getGenes()); - } - - @Test - public void UniformCrossover_ShouldReturnMixedParents() { - RandomGenerator rng = new TestRandomGenerator(null, new double[] {0.1, 0.1, 0.3, 0.2}); - - double[][] parents = new double[2][]; - parents[0] = new double[] {1.0, 1.0, 1.0}; - parents[1] = new double[] {2.0, 2.0, 2.0}; - TestParentSelection parentSelection = new TestParentSelection(parents); - - UniformCrossover sut = new UniformCrossover.Builder().parentSelection(parentSelection).randomGenerator(rng) - .crossoverRate(0.5).parentBiasFactor(0.3).build(); - - CrossoverResult result = sut.crossover(); - - Assertions.assertTrue(result.isModified()); - Assertions.assertEquals(1.0, result.getGenes()[0], 0.0); - Assertions.assertEquals(2.0, result.getGenes()[1], 0.0); - Assertions.assertEquals(1.0, result.getGenes()[2], 0.0); - } - -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/culling/LeastFitCullOperatorTests.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/culling/LeastFitCullOperatorTests.java deleted file mode 100644 index c5cde76d6..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/culling/LeastFitCullOperatorTests.java +++ /dev/null @@ -1,62 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic.culling; - -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.generator.genetic.Chromosome; -import org.deeplearning4j.arbiter.optimize.generator.genetic.culling.LeastFitCullOperator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationInitializer; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationModel; -import org.deeplearning4j.arbiter.optimize.genetic.TestPopulationInitializer; -import org.junit.jupiter.api.Assertions; -import org.junit.jupiter.api.Test; - -import java.util.ArrayList; -import java.util.List; - -public class LeastFitCullOperatorTests extends BaseDL4JTest { - - @Test - public void LeastFitCullingOperation_ShouldCullLastElements() { - LeastFitCullOperator sut = new LeastFitCullOperator(0.50); - - PopulationInitializer populationInitializer = new TestPopulationInitializer(); - - PopulationModel populationModel = new PopulationModel.Builder().populationInitializer(populationInitializer) - .populationSize(10).build(); - sut.initializeInstance(populationModel); - - List originalChromosomes = new ArrayList<>(); - for (int i = 0; i < 10; ++i) { - originalChromosomes.add(new Chromosome(null, (double) i)); - } - - List chromosomes = populationModel.getPopulation(); - for (int i = 0; i < 10; ++i) { - chromosomes.add(originalChromosomes.get(i)); - } - - sut.cullPopulation(); - - Assertions.assertEquals(5, chromosomes.size()); - for (int i = 0; i < 5; ++i) { - Assertions.assertSame(originalChromosomes.get(i), chromosomes.get(i)); - } - } - - -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/culling/RatioCullOperatorTests.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/culling/RatioCullOperatorTests.java deleted file mode 100644 index ae09537f6..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/culling/RatioCullOperatorTests.java +++ /dev/null @@ -1,78 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic.culling; - -import org.apache.commons.lang3.NotImplementedException; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.generator.genetic.Chromosome; -import org.deeplearning4j.arbiter.optimize.generator.genetic.culling.RatioCullOperator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationInitializer; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationModel; -import org.deeplearning4j.arbiter.optimize.genetic.TestPopulationInitializer; -import org.junit.jupiter.api.Assertions; -import org.junit.jupiter.api.Test; - -import java.util.List; - -public class RatioCullOperatorTests extends BaseDL4JTest { - - class TestRatioCullOperator extends RatioCullOperator { - - public TestRatioCullOperator() { - super(); - } - - public TestRatioCullOperator(double ratio) { - super(ratio); - } - - public List getPopulation() { - return population; - } - - @Override - public void cullPopulation() { - throw new NotImplementedException("Not implemented"); - } - - public double getCullRatio() { - return cullRatio; - } - } - - @Test - public void RatioCullingOperation_ctorWithCullRatio_ShouldHaveParamRatio() { - TestRatioCullOperator sut = new TestRatioCullOperator(0.123); - - Assertions.assertEquals(0.123, sut.getCullRatio(), 0.0); - } - - @Test - public void RatioCullingOperation_initialize_shouldSetCulledSizeAndPopulation() throws IllegalAccessException { - TestRatioCullOperator sut = new TestRatioCullOperator(0.50); - - PopulationInitializer populationInitializer = new TestPopulationInitializer(); - - PopulationModel populationModel = new PopulationModel.Builder().populationInitializer(populationInitializer) - .populationSize(10).build(); - sut.initializeInstance(populationModel); - - Assertions.assertSame(populationModel.getPopulation(), sut.getPopulation()); - Assertions.assertEquals(5, sut.getCulledSize()); - } - -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/mutation/RandomMutationOperatorTests.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/mutation/RandomMutationOperatorTests.java deleted file mode 100644 index 8b45ec9ad..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/mutation/RandomMutationOperatorTests.java +++ /dev/null @@ -1,73 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic.mutation; - -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.generator.genetic.mutation.RandomMutationOperator; -import org.deeplearning4j.arbiter.optimize.genetic.TestRandomGenerator; -import org.junit.jupiter.api.Assertions; -import org.junit.jupiter.api.Test; - -import java.lang.reflect.Field; -import java.util.Arrays; - -public class RandomMutationOperatorTests extends BaseDL4JTest { - @Test - public void RandomMutationOperator_DefaultBuild_ShouldNotBeNull() { - RandomMutationOperator sut = new RandomMutationOperator.Builder().build(); - Assertions.assertNotNull(sut); - } - - @Test - public void RandomMutationOperator_BuildWithMutationRate_ShouldUseSuppliedRate() throws Exception { - RandomMutationOperator sut = new RandomMutationOperator.Builder().mutationRate(0.123).build(); - - Field f = sut.getClass().getDeclaredField("mutationRate"); - f.setAccessible(true); - Double mutationRate = (Double) f.get(sut); - - Assertions.assertEquals(0.123, mutationRate, 0.0); - } - - @Test - public void RandomMutationOperator_BelowMutationRate_ShouldNotMutate() { - double[] randomNumbers = new double[] {0.1, 1.0, 1.0}; - - RandomMutationOperator sut = new RandomMutationOperator.Builder().mutationRate(0.1) - .randomGenerator(new TestRandomGenerator(null, randomNumbers)).build(); - - double[] genes = new double[] {-1.0, -1.0, -1.0}; - boolean hasMutated = sut.mutate(genes); - - Assertions.assertFalse(hasMutated); - Assertions.assertTrue(Arrays.equals(new double[] {-1.0, -1.0, -1.0}, genes)); - } - - @Test - public void RandomMutationOperator_AboveMutationRate_ShouldMutate() { - double[] randomNumbers = new double[] {0.099, 0.123, 1.0, 1.0}; - - RandomMutationOperator sut = new RandomMutationOperator.Builder().mutationRate(0.1) - .randomGenerator(new TestRandomGenerator(null, randomNumbers)).build(); - - double[] genes = new double[] {-1.0, -1.0, -1.0}; - boolean hasMutated = sut.mutate(genes); - - Assertions.assertTrue(hasMutated); - Assertions.assertTrue(Arrays.equals(new double[] {0.123, -1.0, -1.0}, genes)); - } -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/population/PopulationModelTests.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/population/PopulationModelTests.java deleted file mode 100644 index 914a4be40..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/population/PopulationModelTests.java +++ /dev/null @@ -1,195 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic.population; - -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.generator.genetic.Chromosome; -import org.deeplearning4j.arbiter.optimize.generator.genetic.culling.CullOperator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationInitializer; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationListener; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationModel; -import org.deeplearning4j.arbiter.optimize.genetic.TestPopulationInitializer; -import org.junit.jupiter.api.Assertions; -import org.junit.jupiter.api.Test; - -import java.util.List; - -public class PopulationModelTests extends BaseDL4JTest { - - private class TestCullOperator implements CullOperator { - - private final int culledSize; - public boolean hasCulled = false; - - public TestCullOperator(int culledSize) { - this.culledSize = culledSize; - } - - @Override - public void initializeInstance(PopulationModel populationModel) { - - } - - @Override - public void cullPopulation() { - hasCulled = true; - } - - @Override - public int getCulledSize() { - return culledSize; - } - } - - private class TestPopulationListener implements PopulationListener { - - public List population; - - @Override - public void onChanged(List population) { - this.population = population; - } - } - - @Test - public void PopulationModel_IsReadyToBreed_NotReadyToBreed_ShouldReturnFalse() { - PopulationInitializer populationInitializer = new TestPopulationInitializer(); - - PopulationModel sut = new PopulationModel.Builder().populationInitializer(populationInitializer) - .populationSize(5).cullOperator(new TestCullOperator(2)).build(); - - boolean result = sut.isReadyToBreed(); - - Assertions.assertFalse(result); - } - - @Test - public void PopulationModel_IsReadyToBreed_ReadyToBreed_ShouldReturnTrue() { - PopulationInitializer populationInitializer = new TestPopulationInitializer(); - - PopulationModel sut = new PopulationModel.Builder().populationInitializer(populationInitializer) - .populationSize(5).cullOperator(new TestCullOperator(1)).build(); - - sut.getPopulation().add(null); - - boolean result = sut.isReadyToBreed(); - - Assertions.assertTrue(result); - } - - @Test - public void PopulationModel_Add_MaximizeScore_ShouldOrderDescendingPopulation() { - PopulationInitializer populationInitializer = new TestPopulationInitializer(); - - PopulationModel sut = new PopulationModel.Builder().populationInitializer(populationInitializer) - .populationSize(5).cullOperator(new TestCullOperator(2)).build(); - - sut.initializeInstance(false); - - Chromosome[] chromosomes = new Chromosome[3]; - chromosomes[0] = new Chromosome(new double[0], 1.0); - chromosomes[1] = new Chromosome(new double[0], 100.0); - chromosomes[2] = new Chromosome(new double[0], 10.0); - sut.add(chromosomes[0]); - sut.add(chromosomes[1]); - sut.add(chromosomes[2]); - - Assertions.assertSame(chromosomes[1], sut.getPopulation().get(0)); - Assertions.assertSame(chromosomes[2], sut.getPopulation().get(1)); - Assertions.assertSame(chromosomes[0], sut.getPopulation().get(2)); - } - - @Test - public void PopulationModel_Add_MinimizeScore_ShouldOrderAscendingPopulation() { - PopulationInitializer populationInitializer = new TestPopulationInitializer(); - - PopulationModel sut = new PopulationModel.Builder().populationInitializer(populationInitializer) - .populationSize(5).cullOperator(new TestCullOperator(2)).build(); - - sut.initializeInstance(true); - - Chromosome[] chromosomes = new Chromosome[3]; - chromosomes[0] = new Chromosome(new double[0], 100.0); - chromosomes[1] = new Chromosome(new double[0], 1.0); - chromosomes[2] = new Chromosome(new double[0], 10.0); - sut.add(chromosomes[0]); - sut.add(chromosomes[1]); - sut.add(chromosomes[2]); - - Assertions.assertSame(chromosomes[1], sut.getPopulation().get(0)); - Assertions.assertSame(chromosomes[2], sut.getPopulation().get(1)); - Assertions.assertSame(chromosomes[0], sut.getPopulation().get(2)); - } - - @Test - public void PopulationModel_Add_ShouldTriggerPopulationListeners() { - PopulationInitializer populationInitializer = new TestPopulationInitializer(); - - PopulationModel sut = new PopulationModel.Builder().populationInitializer(populationInitializer) - .populationSize(5).cullOperator(new TestCullOperator(2)).build(); - - sut.initializeInstance(true); - - TestPopulationListener populationListener = new TestPopulationListener(); - sut.addListener(populationListener); - - sut.add(new Chromosome(new double[0], 100.0)); - - Assertions.assertSame(sut.getPopulation(), populationListener.population); - } - - @Test - public void PopulationModel_Add_BelowPopulationSize_ShouldNotCull() { - PopulationInitializer populationInitializer = new TestPopulationInitializer(); - - TestCullOperator cullOperator = new TestCullOperator(3); - - PopulationModel sut = new PopulationModel.Builder().populationInitializer(populationInitializer) - .populationSize(5).cullOperator(cullOperator).build(); - - sut.initializeInstance(true); - - sut.add(new Chromosome(new double[0], 1.0)); - sut.add(new Chromosome(new double[0], 2.0)); - sut.add(new Chromosome(new double[0], 3.0)); - sut.add(new Chromosome(new double[0], 4.0)); - sut.add(new Chromosome(new double[0], 5.0)); - - Assertions.assertFalse(cullOperator.hasCulled); - } - - @Test - public void PopulationModel_Add_AbovePopulationSize_ShouldCull() { - PopulationInitializer populationInitializer = new TestPopulationInitializer(); - - TestCullOperator cullOperator = new TestCullOperator(3); - - PopulationModel sut = new PopulationModel.Builder().populationInitializer(populationInitializer) - .populationSize(5).cullOperator(cullOperator).build(); - - sut.initializeInstance(true); - - sut.add(new Chromosome(new double[0], 1.0)); - sut.add(new Chromosome(new double[0], 2.0)); - sut.add(new Chromosome(new double[0], 3.0)); - sut.add(new Chromosome(new double[0], 4.0)); - sut.add(new Chromosome(new double[0], 5.0)); - sut.add(new Chromosome(new double[0], 6.0)); - - Assertions.assertTrue(cullOperator.hasCulled); - } -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/selection/GeneticSelectionOperatorTests.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/selection/GeneticSelectionOperatorTests.java deleted file mode 100644 index 4a0b2a498..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/selection/GeneticSelectionOperatorTests.java +++ /dev/null @@ -1,255 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic.selection; - -import org.apache.commons.lang3.NotImplementedException; -import org.apache.commons.math3.random.RandomGenerator; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.generator.genetic.ChromosomeFactory; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.CrossoverOperator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.crossover.CrossoverResult; -import org.deeplearning4j.arbiter.optimize.generator.genetic.culling.CullOperator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.exceptions.GeneticGenerationException; -import org.deeplearning4j.arbiter.optimize.generator.genetic.mutation.MutationOperator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationInitializer; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationModel; -import org.deeplearning4j.arbiter.optimize.generator.genetic.selection.GeneticSelectionOperator; -import org.deeplearning4j.arbiter.optimize.genetic.TestCrossoverOperator; -import org.deeplearning4j.arbiter.optimize.genetic.TestMutationOperator; -import org.deeplearning4j.arbiter.optimize.genetic.TestPopulationInitializer; -import org.deeplearning4j.arbiter.optimize.genetic.TestRandomGenerator; -import org.junit.jupiter.api.Assertions; -import org.junit.jupiter.api.Test; - -import static org.junit.jupiter.api.Assertions.assertArrayEquals; - -public class GeneticSelectionOperatorTests extends BaseDL4JTest { - - private class TestCullOperator implements CullOperator { - - private final int culledSize; - - public TestCullOperator(int culledSize) { - - this.culledSize = culledSize; - } - - @Override - public void initializeInstance(PopulationModel populationModel) { - - } - - @Override - public void cullPopulation() { - throw new NotImplementedException("Not implemented"); - } - - @Override - public int getCulledSize() { - return culledSize; - } - } - - private class GeneticSelectionOperatorTestsMutationOperator implements MutationOperator { - - private boolean mutateResult; - - public GeneticSelectionOperatorTestsMutationOperator(boolean mutateResult) { - - this.mutateResult = mutateResult; - } - - @Override - public boolean mutate(double[] genes) { - return mutateResult; - } - } - - private class GeneticSelectionOperatorTestsCrossoverOperator extends CrossoverOperator { - - private CrossoverResult result; - - public GeneticSelectionOperatorTestsCrossoverOperator(CrossoverResult result) { - - this.result = result; - } - - @Override - public CrossoverResult crossover() { - return result; - } - } - - @Test - public void GeneticSelectionOperator_PopulationNotReadyToBreed_ShouldReturnRandomGenes() { - RandomGenerator rng = new TestRandomGenerator(null, new double[] {123.0}); - - PopulationInitializer populationInitializer = new TestPopulationInitializer(); - - TestCullOperator cullOperator = new TestCullOperator(1000); - PopulationModel populationModel = new PopulationModel.Builder().populationInitializer(populationInitializer) - .cullOperator(cullOperator).build(); - ChromosomeFactory chromosomeFactory = new ChromosomeFactory(); - chromosomeFactory.initializeInstance(1); - GeneticSelectionOperator sut = new GeneticSelectionOperator.Builder().randomGenerator(rng).build(); - sut.initializeInstance(populationModel, chromosomeFactory); - - double[] newGenes = sut.buildNextGenes(); - - Assertions.assertEquals(1, newGenes.length); - Assertions.assertEquals(123.0, newGenes[0], 0.0); - } - - @Test - public void GeneticSelectionOperator_NoModificationOnFirstTry() { - RandomGenerator rng = new TestRandomGenerator(null, new double[] {123.0}); - - PopulationInitializer populationInitializer = new TestPopulationInitializer(); - - TestCullOperator cullOperator = new TestCullOperator(-1); - - PopulationModel populationModel = new PopulationModel.Builder().populationInitializer(populationInitializer) - .cullOperator(cullOperator).build(); - - ChromosomeFactory chromosomeFactory = new ChromosomeFactory(); - chromosomeFactory.initializeInstance(1); - - CrossoverResult[] crossoverResults = new CrossoverResult[2]; - crossoverResults[0] = new CrossoverResult(false, new double[0]); - crossoverResults[1] = new CrossoverResult(true, new double[0]); - TestCrossoverOperator crossoverOperator = new TestCrossoverOperator(crossoverResults); - - boolean[] mutationResults = new boolean[] {false, false}; - TestMutationOperator mutationOperator = new TestMutationOperator(mutationResults); - - GeneticSelectionOperator sut = new GeneticSelectionOperator.Builder().randomGenerator(rng) - .crossoverOperator(crossoverOperator).mutationOperator(mutationOperator).build(); - sut.initializeInstance(populationModel, chromosomeFactory); - - double[] newGenes = sut.buildNextGenes(); - - Assertions.assertSame(crossoverResults[1].getGenes(), newGenes); - } - - @Test - public void GeneticSelectionOperator_MutationNoModificationOnFirstTry() { - RandomGenerator rng = new TestRandomGenerator(null, new double[] {123.0}); - - PopulationInitializer populationInitializer = new TestPopulationInitializer(); - - TestCullOperator cullOperator = new TestCullOperator(-1); - - PopulationModel populationModel = new PopulationModel.Builder().populationInitializer(populationInitializer) - .cullOperator(cullOperator).build(); - - ChromosomeFactory chromosomeFactory = new ChromosomeFactory(); - chromosomeFactory.initializeInstance(1); - - CrossoverResult[] crossoverResults = new CrossoverResult[3]; - crossoverResults[0] = new CrossoverResult(false, new double[0]); - crossoverResults[1] = new CrossoverResult(false, new double[0]); - crossoverResults[2] = new CrossoverResult(true, new double[0]); - TestCrossoverOperator crossoverOperator = new TestCrossoverOperator(crossoverResults); - - boolean[] mutationResults = new boolean[] {false, false, true}; - TestMutationOperator mutationOperator = new TestMutationOperator(mutationResults); - - GeneticSelectionOperator sut = new GeneticSelectionOperator.Builder().randomGenerator(rng) - .crossoverOperator(crossoverOperator).mutationOperator(mutationOperator).build(); - sut.initializeInstance(populationModel, chromosomeFactory); - - double[] newGenes = sut.buildNextGenes(); - - Assertions.assertSame(crossoverResults[2].getGenes(), newGenes); - } - - @Test - public void GeneticSelectionOperator_ShouldNotBuildDuplicates() { - RandomGenerator rng = new TestRandomGenerator(null, new double[] {123.0}); - - PopulationInitializer populationInitializer = new TestPopulationInitializer(); - - TestCullOperator cullOperator = new TestCullOperator(-1); - - PopulationModel populationModel = new PopulationModel.Builder().populationInitializer(populationInitializer) - .cullOperator(cullOperator).build(); - - ChromosomeFactory chromosomeFactory = new ChromosomeFactory(); - chromosomeFactory.initializeInstance(1); - - CrossoverResult[] crossoverResults = new CrossoverResult[3]; - crossoverResults[0] = new CrossoverResult(true, new double[] {1.0}); - crossoverResults[1] = new CrossoverResult(true, new double[] {1.0}); - crossoverResults[2] = new CrossoverResult(true, new double[] {2.0}); - TestCrossoverOperator crossoverOperator = new TestCrossoverOperator(crossoverResults); - - boolean[] mutationResults = new boolean[] {false, false, false}; - TestMutationOperator mutationOperator = new TestMutationOperator(mutationResults); - - GeneticSelectionOperator sut = new GeneticSelectionOperator.Builder().randomGenerator(rng) - .crossoverOperator(crossoverOperator).mutationOperator(mutationOperator).build(); - sut.initializeInstance(populationModel, chromosomeFactory); - - double[] newGenes = sut.buildNextGenes(); - assertArrayEquals(crossoverResults[0].getGenes(), newGenes, 1e-6); - - newGenes = sut.buildNextGenes(); - assertArrayEquals(crossoverResults[2].getGenes(), newGenes, 1e-6); - } - - @Test() - public void GeneticSelectionOperator_CrossoverAndMutationCantGenerateNew_ShouldThrow() { - Assertions.assertThrows(GeneticGenerationException.class, () -> { - TestCullOperator cullOperator = new TestCullOperator(-1); - - - PopulationModel populationModel = new PopulationModel.Builder().cullOperator(cullOperator).build(); - - MutationOperator mutationOperator = new GeneticSelectionOperatorTestsMutationOperator(false); - CrossoverOperator crossoverOperator = - new GeneticSelectionOperatorTestsCrossoverOperator(new CrossoverResult(false, null)); - - GeneticSelectionOperator sut = new GeneticSelectionOperator.Builder().crossoverOperator(crossoverOperator) - .mutationOperator(mutationOperator).build(); - sut.initializeInstance(populationModel, null); - - sut.buildNextGenes(); - }); - } - - @Test - public void GeneticSelectionOperator_CrossoverAndMutationAlwaysGenerateSame_ShouldThrow() { - Assertions.assertThrows(GeneticGenerationException.class, () -> { - TestCullOperator cullOperator = new TestCullOperator(-1); - - PopulationModel populationModel = new PopulationModel.Builder().cullOperator(cullOperator).build(); - - MutationOperator mutationOperator = new GeneticSelectionOperatorTestsMutationOperator(false); - CrossoverOperator crossoverOperator = new GeneticSelectionOperatorTestsCrossoverOperator( - new CrossoverResult(true, new double[]{1.0})); - - GeneticSelectionOperator sut = new GeneticSelectionOperator.Builder().crossoverOperator(crossoverOperator) - .mutationOperator(mutationOperator).build(); - sut.initializeInstance(populationModel, null); - - // This call is used to add the genes to the previousGenes collection - sut.buildNextGenes(); - - sut.buildNextGenes(); - }); - } -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/selection/SelectionOperatorTests.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/selection/SelectionOperatorTests.java deleted file mode 100644 index 47bb3e37c..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/genetic/selection/SelectionOperatorTests.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2019 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.genetic.selection; - -import org.apache.commons.lang3.NotImplementedException; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.generator.genetic.ChromosomeFactory; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationInitializer; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationModel; -import org.deeplearning4j.arbiter.optimize.generator.genetic.selection.SelectionOperator; -import org.deeplearning4j.arbiter.optimize.genetic.TestPopulationInitializer; -import org.junit.jupiter.api.Assertions; -import org.junit.jupiter.api.Test; - -public class SelectionOperatorTests extends BaseDL4JTest { - private class TestSelectionOperator extends SelectionOperator { - - public PopulationModel getPopulationModel() { - return populationModel; - } - - public ChromosomeFactory getChromosomeFactory() { - return chromosomeFactory; - } - - @Override - public double[] buildNextGenes() { - throw new NotImplementedException("Not implemented"); - } - } - - @Test - public void SelectionOperator_InitializeInstance_ShouldInitializeFields() { - TestSelectionOperator sut = new TestSelectionOperator(); - - PopulationInitializer populationInitializer = new TestPopulationInitializer(); - - PopulationModel populationModel = - new PopulationModel.Builder().populationInitializer(populationInitializer).build(); - ChromosomeFactory chromosomeFactory = new ChromosomeFactory(); - sut.initializeInstance(populationModel, chromosomeFactory); - - Assertions.assertSame(populationModel, sut.getPopulationModel()); - Assertions.assertSame(chromosomeFactory, sut.getChromosomeFactory()); - } -} diff --git a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/parameter/TestParameterSpaces.java b/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/parameter/TestParameterSpaces.java deleted file mode 100644 index 5f477018c..000000000 --- a/arbiter/arbiter-core/src/test/java/org/deeplearning4j/arbiter/optimize/parameter/TestParameterSpaces.java +++ /dev/null @@ -1,103 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize.parameter; - -import org.apache.commons.math3.distribution.NormalDistribution; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.continuous.ContinuousParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.discrete.DiscreteParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.integer.IntegerParameterSpace; -import org.junit.jupiter.api.Test; - -import static org.junit.jupiter.api.Assertions.assertEquals; - -public class TestParameterSpaces extends BaseDL4JTest { - - - @Test - public void testContinuousParameterSpace() { - - ContinuousParameterSpace cps = new ContinuousParameterSpace(0, 1); - cps.setIndices(0); - - for (int i = 0; i < 10; i++) { - double d = i / 10.0; - assertEquals(d, cps.getValue(new double[]{d}), 0.0); - } - - cps = new ContinuousParameterSpace(10, 20); - cps.setIndices(0); - - for (int i = 0; i < 10; i++) { - double d = i / 10.0; - double exp = d * 10 + 10; - assertEquals(exp, cps.getValue(new double[]{d}), 0.0); - } - - - cps = new ContinuousParameterSpace(new NormalDistribution(0, 1)); - NormalDistribution nd = new NormalDistribution(0, 1); - cps.setIndices(0); - for (int i = 0; i < 11; i++) { - double d = i / 10.0; - assertEquals(nd.inverseCumulativeProbability(d), cps.getValue(new double[]{d}), 1e-4); - } - } - - @Test - public void testDiscreteParameterSpace() { - ParameterSpace dps = new DiscreteParameterSpace<>(0, 1, 2, 3, 4); - dps.setIndices(0); - - for (int i = 0; i < 5; i++) { - double d = i / 5.0 + 0.1; //Center - double dEdgeLower = i / 5.0 + 1e-8; //Edge case: just above split threshold - double dEdgeUpper = (i + 1) / 5.0 - 1e-8; //Edge case: just below split threshold - assertEquals(i, (int) dps.getValue(new double[]{d})); - assertEquals(i, (int) dps.getValue(new double[]{dEdgeLower})); - assertEquals(i, (int) dps.getValue(new double[]{dEdgeUpper})); - } - } - - @Test - public void testIntegerParameterSpace() { - ParameterSpace ips = new IntegerParameterSpace(0, 4); - ips.setIndices(0); - - for (int i = 0; i < 5; i++) { - double d = i / 5.0 + 0.1; //Center - double dEdgeLower = i / 5.0 + 1e-8; //Edge case: just above split threshold - double dEdgeUpper = (i + 1) / 5.0 - 1e-8; //Edge case: just below split threshold - assertEquals(i, (int) ips.getValue(new double[]{d})); - assertEquals(i, (int) ips.getValue(new double[]{dEdgeLower})); - assertEquals(i, (int) ips.getValue(new double[]{dEdgeUpper})); - } - } - - @Test - public void testBooleanSpace() { - ParameterSpace bSpace = new BooleanSpace(); - bSpace.setIndices(1); //randomly setting to non zero - - assertEquals(true, (boolean) bSpace.getValue(new double[]{0.0, 0.0})); - assertEquals(true, (boolean) bSpace.getValue(new double[]{0.1, 0.5})); - assertEquals(false, (boolean) bSpace.getValue(new double[]{0.2, 0.7})); - assertEquals(false, (boolean) bSpace.getValue(new double[]{0.3, 1.0})); - } - -} diff --git a/arbiter/arbiter-core/src/test/resources/logback.xml b/arbiter/arbiter-core/src/test/resources/logback.xml deleted file mode 100644 index 410bdaae9..000000000 --- a/arbiter/arbiter-core/src/test/resources/logback.xml +++ /dev/null @@ -1,51 +0,0 @@ - - - - - - logs/application.log - - %date - [%level] - from %logger in %thread - %n%message%n%xException%n - - - - - - %logger{15} - %message%n%xException{5} - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/arbiter/arbiter-deeplearning4j/pom.xml b/arbiter/arbiter-deeplearning4j/pom.xml deleted file mode 100644 index 2f7e202a3..000000000 --- a/arbiter/arbiter-deeplearning4j/pom.xml +++ /dev/null @@ -1,78 +0,0 @@ - - - - - arbiter - net.brutex.ai - 1.0.0-SNAPSHOT - - 4.0.0 - - arbiter-deeplearning4j - - - - - net.brutex.ai - arbiter-core - ${project.version} - - - - net.brutex.ai - deeplearning4j-core - ${project.version} - - - - ch.qos.logback - logback-classic - ${logback.version} - test - - - - com.fasterxml.jackson.core - jackson-core - ${jackson.version} - - - com.fasterxml.jackson.core - jackson-annotations - ${jackson.version} - - - com.fasterxml.jackson.core - jackson-databind - ${jackson.databind.version} - - - - com.google.code.gson - gson - ${gson.version} - - - - net.brutex.ai - deeplearning4j-common-tests - ${project.version} - test - - - - diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/BaseNetworkSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/BaseNetworkSpace.java deleted file mode 100644 index 69621330d..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/BaseNetworkSpace.java +++ /dev/null @@ -1,615 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter; - -import lombok.AllArgsConstructor; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.adapter.ActivationParameterSpaceAdapter; -import org.deeplearning4j.arbiter.conf.dropout.DropoutSpace; -import org.deeplearning4j.arbiter.layers.LayerSpace; -import org.deeplearning4j.arbiter.optimize.api.AbstractParameterSpace; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.optimize.serde.jackson.JsonMapper; -import org.deeplearning4j.arbiter.optimize.serde.jackson.YamlMapper; -import org.deeplearning4j.earlystopping.EarlyStoppingConfiguration; -import org.deeplearning4j.nn.api.OptimizationAlgorithm; -import org.deeplearning4j.nn.api.layers.LayerConstraint; -import org.deeplearning4j.nn.conf.*; -import org.deeplearning4j.nn.conf.distribution.Distribution; -import org.deeplearning4j.nn.conf.dropout.Dropout; -import org.deeplearning4j.nn.conf.dropout.IDropout; -import org.deeplearning4j.nn.conf.stepfunctions.StepFunction; -import org.deeplearning4j.nn.conf.weightnoise.IWeightNoise; -import org.deeplearning4j.nn.weights.WeightInit; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.activations.IActivation; -import org.nd4j.linalg.learning.config.IUpdater; -import com.fasterxml.jackson.annotation.JsonTypeInfo; -import com.fasterxml.jackson.core.JsonProcessingException; - -import java.util.*; - -/** - * This is an abstract ParameterSpace for both MultiLayerNetworks (MultiLayerSpace) and ComputationGraph (ComputationGraphSpace) - *

- * Functionality here should match {@link org.deeplearning4j.nn.conf.NeuralNetConfiguration.Builder} - * - * @param Type of network (MultiLayerNetwork or ComputationGraph) - * @author Alex Black - */ -@EqualsAndHashCode(callSuper = false) -@JsonTypeInfo(use = JsonTypeInfo.Id.CLASS, include = JsonTypeInfo.As.PROPERTY, property = "@class") -@Data -public abstract class BaseNetworkSpace extends AbstractParameterSpace { - - protected Long seed; - protected ParameterSpace optimizationAlgo; - protected ParameterSpace activationFunction; - protected ParameterSpace biasInit; - protected ParameterSpace weightInit; - protected ParameterSpace dist; - protected ParameterSpace maxNumLineSearchIterations; - protected ParameterSpace miniBatch; - protected ParameterSpace minimize; - protected ParameterSpace stepFunction; - protected ParameterSpace l1; - protected ParameterSpace l2; - protected ParameterSpace l1Bias; - protected ParameterSpace l2Bias; - protected ParameterSpace updater; - protected ParameterSpace biasUpdater; - protected ParameterSpace weightNoise; - private ParameterSpace dropout; - protected ParameterSpace gradientNormalization; - protected ParameterSpace gradientNormalizationThreshold; - protected ParameterSpace convolutionMode; - - protected List layerSpaces = new ArrayList<>(); - - //NeuralNetConfiguration.ListBuilder/MultiLayerConfiguration.Builder options: - protected ParameterSpace backpropType; - protected ParameterSpace tbpttFwdLength; - protected ParameterSpace tbpttBwdLength; - - protected ParameterSpace> allParamConstraints; - protected ParameterSpace> weightConstraints; - protected ParameterSpace> biasConstraints; - - protected int numEpochs = 1; - - - static { - JsonMapper.getMapper().registerSubtypes(ComputationGraphSpace.class, MultiLayerSpace.class); - YamlMapper.getMapper().registerSubtypes(ComputationGraphSpace.class, MultiLayerSpace.class); - } - - @SuppressWarnings("unchecked") - protected BaseNetworkSpace(Builder builder) { - this.seed = builder.seed; - this.optimizationAlgo = builder.optimizationAlgo; - this.activationFunction = builder.activationFunction; - this.biasInit = builder.biasInit; - this.weightInit = builder.weightInit; - this.dist = builder.dist; - this.maxNumLineSearchIterations = builder.maxNumLineSearchIterations; - this.miniBatch = builder.miniBatch; - this.minimize = builder.minimize; - this.stepFunction = builder.stepFunction; - this.l1 = builder.l1; - this.l2 = builder.l2; - this.l1Bias = builder.l1Bias; - this.l2Bias = builder.l2Bias; - this.updater = builder.updater; - this.biasUpdater = builder.biasUpdater; - this.weightNoise = builder.weightNoise; - this.dropout = builder.dropout; - this.gradientNormalization = builder.gradientNormalization; - this.gradientNormalizationThreshold = builder.gradientNormalizationThreshold; - this.convolutionMode = builder.convolutionMode; - this.allParamConstraints = builder.allParamConstraints; - this.weightConstraints = builder.weightConstraints; - this.biasConstraints = builder.biasConstraints; - - this.backpropType = builder.backpropType; - this.tbpttFwdLength = builder.tbpttFwdLength; - this.tbpttBwdLength = builder.tbpttBwdLength; - - this.numEpochs = builder.numEpochs; - } - - protected BaseNetworkSpace() { - //Default constructor for Jackson json/yaml serialization - } - - - protected NeuralNetConfiguration.Builder randomGlobalConf(double[] values) { - //Create MultiLayerConfiguration... - NeuralNetConfiguration.Builder builder = new NeuralNetConfiguration.Builder(); - if (seed != null) - builder.seed(seed); - if (optimizationAlgo != null) - builder.optimizationAlgo(optimizationAlgo.getValue(values)); - if (activationFunction != null) - builder.activation(activationFunction.getValue(values)); - if (biasInit != null) - builder.biasInit(biasInit.getValue(values)); - if (weightInit != null) - builder.weightInit(weightInit.getValue(values)); - if (dist != null) - builder.dist(dist.getValue(values)); - if (maxNumLineSearchIterations != null) - builder.maxNumLineSearchIterations(maxNumLineSearchIterations.getValue(values)); - if (miniBatch != null) - builder.miniBatch(miniBatch.getValue(values)); - if (minimize != null) - builder.minimize(minimize.getValue(values)); - if (stepFunction != null) - builder.stepFunction(stepFunction.getValue(values)); - if (l1 != null) - builder.l1(l1.getValue(values)); - if (l2 != null) - builder.l2(l2.getValue(values)); - if (l1Bias != null) - builder.l1Bias(l1Bias.getValue(values)); - if (l2Bias != null) - builder.l2Bias(l2Bias.getValue(values)); - if (updater != null) - builder.updater(updater.getValue(values)); - if (biasUpdater != null) - builder.biasUpdater(biasUpdater.getValue(values)); - if (weightNoise != null) - builder.weightNoise(weightNoise.getValue(values)); - if (dropout != null) - builder.dropOut(dropout.getValue(values)); - if (gradientNormalization != null) - builder.gradientNormalization(gradientNormalization.getValue(values)); - if (gradientNormalizationThreshold != null) - builder.gradientNormalizationThreshold(gradientNormalizationThreshold.getValue(values)); - if (convolutionMode != null) - builder.convolutionMode(convolutionMode.getValue(values)); - if (allParamConstraints != null){ - List c = allParamConstraints.getValue(values); - if(c != null){ - builder.constrainAllParameters(c.toArray(new LayerConstraint[c.size()])); - } - } - if (weightConstraints != null){ - List c = weightConstraints.getValue(values); - if(c != null){ - builder.constrainWeights(c.toArray(new LayerConstraint[c.size()])); - } - } - if (biasConstraints != null){ - List c = biasConstraints.getValue(values); - if(c != null){ - builder.constrainBias(c.toArray(new LayerConstraint[c.size()])); - } - } - - return builder; - } - - @Override - public List collectLeaves() { - Map global = getNestedSpaces(); - //Note: Results on previous line does NOT include the LayerSpaces, therefore we need to add these manually... - //This is because the type is a list, not a ParameterSpace - LinkedList stack = new LinkedList<>(); - stack.add(this); - - for (LayerConf layerConf : layerSpaces) { - LayerSpace ls = layerConf.getLayerSpace(); - stack.addAll(ls.collectLeaves()); - } - - List out = new ArrayList<>(); - while (!stack.isEmpty()) { - ParameterSpace next = stack.removeLast(); - if (next.isLeaf()) { - out.add(next); - } else { - Map m = next.getNestedSpaces(); - ParameterSpace[] arr = m.values().toArray(new ParameterSpace[m.size()]); - for (int i = arr.length - 1; i >= 0; i--) { - stack.add(arr[i]); - } - } - } - return out; - } - - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices) { - throw new UnsupportedOperationException("Cannot set indices for non leaf"); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - - for (Map.Entry e : getNestedSpaces().entrySet()) { - sb.append(e.getKey()).append(": ").append(e.getValue()).append("\n"); - } - - int i = 0; - for (LayerConf conf : layerSpaces) { - - sb.append("Layer config ").append(i++).append(": (Number layers:").append(conf.numLayers) - .append(", duplicate: ").append(conf.duplicateConfig).append("), ") - .append(conf.layerSpace.toString()).append("\n"); - } - - - return sb.toString(); - } - - @AllArgsConstructor - @Data - @NoArgsConstructor - public static class LayerConf { - protected LayerSpace layerSpace; - protected String layerName; - protected String[] inputs; - protected ParameterSpace numLayers; - protected boolean duplicateConfig; - protected InputPreProcessor preProcessor; - } - - @SuppressWarnings("unchecked") - protected abstract static class Builder> { - private Long seed; - private ParameterSpace optimizationAlgo; - private ParameterSpace activationFunction; - private ParameterSpace biasInit; - private ParameterSpace weightInit; - private ParameterSpace dist; - private ParameterSpace maxNumLineSearchIterations; - private ParameterSpace miniBatch; - private ParameterSpace minimize; - private ParameterSpace stepFunction; - private ParameterSpace l1; - private ParameterSpace l2; - private ParameterSpace l1Bias; - private ParameterSpace l2Bias; - private ParameterSpace updater; - private ParameterSpace biasUpdater; - private ParameterSpace weightNoise; - private ParameterSpace dropout; - private ParameterSpace gradientNormalization; - private ParameterSpace gradientNormalizationThreshold; - private ParameterSpace convolutionMode; - - private ParameterSpace> allParamConstraints; - private ParameterSpace> weightConstraints; - private ParameterSpace> biasConstraints; - - //NeuralNetConfiguration.ListBuilder/MultiLayerConfiguration.Builder options: - private ParameterSpace backpropType; - private ParameterSpace tbpttFwdLength; - private ParameterSpace tbpttBwdLength; - - //Early stopping configuration / (fixed) number of epochs: - private EarlyStoppingConfiguration earlyStoppingConfiguration; - private int numEpochs = 1; - - protected boolean validateOutputLayerConfig = true; - - public T seed(long seed) { - this.seed = seed; - return (T) this; - } - - public T optimizationAlgo(OptimizationAlgorithm optimizationAlgorithm) { - return optimizationAlgo(new FixedValue<>(optimizationAlgorithm)); - } - - public T optimizationAlgo(ParameterSpace parameterSpace) { - this.optimizationAlgo = parameterSpace; - return (T) this; - } - - - public T activation(Activation activationFunction) { - return activation(new FixedValue<>(activationFunction)); - } - - public T activation(ParameterSpace activationFunction) { - return activationFn(new ActivationParameterSpaceAdapter(activationFunction)); - } - - public T activationFn(ParameterSpace activationFunction) { - this.activationFunction = activationFunction; - return (T) this; - } - - public T biasInit(double biasInit){ - return biasInit(new FixedValue<>(biasInit)); - } - - public T biasInit(ParameterSpace biasInit){ - this.biasInit = biasInit; - return (T) this; - } - - public T weightInit(WeightInit weightInit) { - return weightInit(new FixedValue<>(weightInit)); - } - - public T weightInit(ParameterSpace weightInit) { - this.weightInit = weightInit; - return (T) this; - } - - public T dist(Distribution dist) { - return dist(new FixedValue<>(dist)); - } - - public T dist(ParameterSpace dist) { - this.dist = dist; - return (T) this; - } - - public T maxNumLineSearchIterations(int maxNumLineSearchIterations) { - return maxNumLineSearchIterations(new FixedValue<>(maxNumLineSearchIterations)); - } - - public T maxNumLineSearchIterations(ParameterSpace maxNumLineSearchIterations) { - this.maxNumLineSearchIterations = maxNumLineSearchIterations; - return (T) this; - } - - public T miniBatch(boolean minibatch) { - return miniBatch(new FixedValue<>(minibatch)); - } - - public T miniBatch(ParameterSpace miniBatch) { - this.miniBatch = miniBatch; - return (T) this; - } - - public T minimize(boolean minimize) { - return minimize(new FixedValue<>(minimize)); - } - - public T minimize(ParameterSpace minimize) { - this.minimize = minimize; - return (T) this; - } - - public T stepFunction(StepFunction stepFunction) { - return stepFunction(new FixedValue<>(stepFunction)); - } - - public T stepFunction(ParameterSpace stepFunction) { - this.stepFunction = stepFunction; - return (T) this; - } - - public T l1(double l1) { - return l1(new FixedValue<>(l1)); - } - - public T l1(ParameterSpace l1) { - this.l1 = l1; - return (T) this; - } - - public T l2(double l2) { - return l2(new FixedValue<>(l2)); - } - - public T l2(ParameterSpace l2) { - this.l2 = l2; - return (T) this; - } - public T l1Bias(double l1Bias) { - return l1Bias(new FixedValue<>(l1Bias)); - } - - public T l1Bias(ParameterSpace l1Bias) { - this.l1Bias = l1Bias; - return (T) this; - } - - public T l2Bias(double l2Bias) { - return l2Bias(new FixedValue<>(l2Bias)); - } - - public T l2Bias(ParameterSpace l2Bias) { - this.l2Bias = l2Bias; - return (T) this; - } - - public T updater(IUpdater updater){ - return updater(new FixedValue<>(updater)); - } - - public T updater(ParameterSpace updater) { - this.updater = updater; - return (T) this; - } - - public T biasUpdater(IUpdater biasUpdater){ - return biasUpdater(new FixedValue<>(biasUpdater)); - } - - public T biasUpdater(ParameterSpace biasUpdater){ - this.biasUpdater = biasUpdater; - return (T)this; - } - - public T weightNoise(IWeightNoise weightNoise){ - return weightNoise(new FixedValue<>(weightNoise)); - } - - public T weightNoise(ParameterSpace weightNoise){ - this.weightNoise = weightNoise; - return (T) this; - } - - public T dropOut(double dropout){ - return idropOut(new Dropout(dropout)); - } - - public T dropOut(ParameterSpace dropOut){ - return idropOut(new DropoutSpace(dropOut)); - } - - public T idropOut(IDropout idropOut){ - return idropOut(new FixedValue<>(idropOut)); - } - - public T idropOut(ParameterSpace idropOut){ - this.dropout = idropOut; - return (T) this; - } - - public T gradientNormalization(GradientNormalization gradientNormalization) { - return gradientNormalization(new FixedValue<>(gradientNormalization)); - } - - public T gradientNormalization(ParameterSpace gradientNormalization) { - this.gradientNormalization = gradientNormalization; - return (T) this; - } - - public T gradientNormalizationThreshold(double threshold) { - return gradientNormalizationThreshold(new FixedValue<>(threshold)); - } - - public T gradientNormalizationThreshold(ParameterSpace gradientNormalizationThreshold) { - this.gradientNormalizationThreshold = gradientNormalizationThreshold; - return (T) this; - } - - public T convolutionMode(ConvolutionMode convolutionMode) { - return convolutionMode(new FixedValue(convolutionMode)); - } - - public T convolutionMode(ParameterSpace convolutionMode) { - this.convolutionMode = convolutionMode; - return (T) this; - } - - public T backpropType(BackpropType backpropType) { - return backpropType(new FixedValue<>(backpropType)); - } - - public T backpropType(ParameterSpace backpropType) { - this.backpropType = backpropType; - return (T) this; - } - - public T tbpttFwdLength(int tbpttFwdLength) { - return tbpttFwdLength(new FixedValue<>(tbpttFwdLength)); - } - - public T tbpttFwdLength(ParameterSpace tbpttFwdLength) { - this.tbpttFwdLength = tbpttFwdLength; - return (T) this; - } - - public T tbpttBwdLength(int tbpttBwdLength) { - return tbpttBwdLength(new FixedValue<>(tbpttBwdLength)); - } - - public T tbpttBwdLength(ParameterSpace tbpttBwdLength) { - this.tbpttBwdLength = tbpttBwdLength; - return (T) this; - } - - public T constrainWeights(LayerConstraint... constraints){ - return constrainWeights(new FixedValue>(Arrays.asList(constraints))); - } - - public T constrainWeights(ParameterSpace> constraints){ - this.weightConstraints = constraints; - return (T) this; - } - - public T constrainBias(LayerConstraint... constraints){ - return constrainBias(new FixedValue>(Arrays.asList(constraints))); - } - - public T constrainBias(ParameterSpace> constraints){ - this.biasConstraints = constraints; - return (T) this; - } - - public T constrainAllParams(LayerConstraint... constraints){ - return constrainAllParams(new FixedValue>(Arrays.asList(constraints))); - } - - public T constrainAllParams(ParameterSpace> constraints){ - this.allParamConstraints = constraints; - return (T) this; - } - - public T validateOutputLayerConfig(boolean validate){ - this.validateOutputLayerConfig = validate; - return (T) this; - } - - /** - * Fixed number of training epochs. Default: 1 - * Note if both EarlyStoppingConfiguration and number of epochs is present, early stopping will be used in preference. - */ - public T numEpochs(int numEpochs) { - this.numEpochs = numEpochs; - return (T) this; - } - - - public abstract E build(); - } - - /** - * Return a json configuration of this configuration space. - * - * @return - */ - public String toJson() { - try { - return JsonMapper.getMapper().writeValueAsString(this); - } catch (JsonProcessingException e) { - throw new RuntimeException(e); - } - } - - /** - * Return a yaml configuration of this configuration space. - * - * @return - */ - public String toYaml() { - try { - return YamlMapper.getMapper().writeValueAsString(this); - } catch (JsonProcessingException e) { - throw new RuntimeException(e); - } - } - -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/ComputationGraphSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/ComputationGraphSpace.java deleted file mode 100644 index 369300829..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/ComputationGraphSpace.java +++ /dev/null @@ -1,316 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter; - -import lombok.*; -import org.deeplearning4j.arbiter.layers.LayerSpace; -import org.deeplearning4j.arbiter.layers.fixed.FixedLayerSpace; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.api.TaskCreatorProvider; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.optimize.serde.jackson.JsonMapper; -import org.deeplearning4j.arbiter.optimize.serde.jackson.YamlMapper; -import org.deeplearning4j.arbiter.task.ComputationGraphTaskCreator; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.earlystopping.EarlyStoppingConfiguration; -import org.deeplearning4j.nn.conf.ComputationGraphConfiguration; -import org.deeplearning4j.nn.conf.InputPreProcessor; -import org.deeplearning4j.nn.conf.NeuralNetConfiguration; -import org.deeplearning4j.nn.conf.WorkspaceMode; -import org.deeplearning4j.nn.conf.graph.GraphVertex; -import org.deeplearning4j.nn.conf.inputs.InputType; -import org.deeplearning4j.nn.conf.layers.Layer; -import org.deeplearning4j.nn.graph.ComputationGraph; -import com.fasterxml.jackson.annotation.JsonProperty; -import com.fasterxml.jackson.annotation.JsonTypeInfo; -import com.fasterxml.jackson.annotation.JsonTypeName; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; - -/** - * ComputationGraphSpace: Defines the space of valid hyperparameters for a ComputationGraph. - * Note that this for fixed graph structures only - * - * @author Alex Black - */ -@NoArgsConstructor(access = AccessLevel.PRIVATE) //For Jackson JSON ser/de -@Data -@EqualsAndHashCode(callSuper = true) -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "@class") -@JsonTypeName("ComputationGraphSpace") -public class ComputationGraphSpace extends BaseNetworkSpace { - static { - TaskCreatorProvider.registerDefaultTaskCreatorClass(ComputationGraphSpace.class, ComputationGraphTaskCreator.class); - } - - @JsonProperty - protected List layerSpaces = new ArrayList<>(); - @JsonProperty - protected List vertices = new ArrayList<>(); - @JsonProperty - protected String[] networkInputs; - @JsonProperty - protected String[] networkOutputs; - @JsonProperty - protected ParameterSpace inputTypes; - @JsonProperty - protected int numParameters; - @JsonProperty - protected WorkspaceMode trainingWorkspaceMode; - @JsonProperty - protected WorkspaceMode inferenceWorkspaceMode; - @JsonProperty - protected boolean validateOutputLayerConfig = true; - - //Early stopping configuration / (fixed) number of epochs: - protected EarlyStoppingConfiguration earlyStoppingConfiguration; - - protected ComputationGraphSpace(Builder builder) { - super(builder); - - this.earlyStoppingConfiguration = builder.earlyStoppingConfiguration; - this.layerSpaces = builder.layerList; - this.vertices = builder.vertexList; - - this.networkInputs = builder.networkInputs; - this.networkOutputs = builder.networkOutputs; - this.inputTypes = builder.inputTypes; - this.trainingWorkspaceMode = builder.trainingWorkspaceMode; - this.inferenceWorkspaceMode = builder.inferenceWorkspaceMode; - this.validateOutputLayerConfig = builder.validateOutputLayerConfig; - - //Determine total number of parameters: - List list = LeafUtils.getUniqueObjects(collectLeaves()); - for (ParameterSpace ps : list) - numParameters += ps.numParameters(); - } - - - @Override - public GraphConfiguration getValue(double[] values) { - //Create ComputationGraphConfiguration... - NeuralNetConfiguration.Builder builder = randomGlobalConf(values); - - ComputationGraphConfiguration.GraphBuilder graphBuilder = builder.graphBuilder(); - graphBuilder.addInputs(this.networkInputs); - graphBuilder.setOutputs(this.networkOutputs); - if (inputTypes != null) - graphBuilder.setInputTypes(inputTypes.getValue(values)); - - //Build/add our layers and vertices: - for (LayerConf c : layerSpaces) { - org.deeplearning4j.nn.conf.layers.Layer l = c.layerSpace.getValue(values); - graphBuilder.addLayer(c.getLayerName(), l, c.getPreProcessor(), c.getInputs()); - } - for (VertexConf gv : vertices) { - graphBuilder.addVertex(gv.getVertexName(), gv.getGraphVertex(), gv.getInputs()); - } - - if (backpropType != null) - graphBuilder.backpropType(backpropType.getValue(values)); - if (tbpttFwdLength != null) - graphBuilder.tBPTTForwardLength(tbpttFwdLength.getValue(values)); - if (tbpttBwdLength != null) - graphBuilder.tBPTTBackwardLength(tbpttBwdLength.getValue(values)); - graphBuilder.validateOutputLayerConfig(validateOutputLayerConfig); - - ComputationGraphConfiguration configuration = graphBuilder.build(); - - if (trainingWorkspaceMode != null) - configuration.setTrainingWorkspaceMode(trainingWorkspaceMode); - if (inferenceWorkspaceMode != null) - configuration.setInferenceWorkspaceMode(inferenceWorkspaceMode); - - return new GraphConfiguration(configuration, earlyStoppingConfiguration, numEpochs); - } - - @Override - public int numParameters() { - return numParameters; - } - - @Override - public List collectLeaves() { - List list = super.collectLeaves(); - for (LayerConf lc : layerSpaces) { - list.addAll(lc.layerSpace.collectLeaves()); - } - if (inputTypes != null) - list.add(inputTypes); - return list; - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(super.toString()); - - for (LayerConf conf : layerSpaces) { - sb.append("Layer config: \"").append(conf.layerName).append("\", ").append(conf.layerSpace) - .append(", inputs: ").append(conf.inputs == null ? "[]" : Arrays.toString(conf.inputs)) - .append("\n"); - } - - for (VertexConf conf : vertices) { - sb.append("GraphVertex: \"").append(conf.vertexName).append("\", ").append(conf.graphVertex) - .append(", inputs: ").append(conf.inputs == null ? "[]" : Arrays.toString(conf.inputs)) - .append("\n"); - } - - if (earlyStoppingConfiguration != null) { - sb.append("Early stopping configuration:").append(earlyStoppingConfiguration.toString()).append("\n"); - } else { - sb.append("Training # epochs:").append(numEpochs).append("\n"); - } - - if (inputTypes != null) { - sb.append("Input types: ").append(inputTypes).append("\n"); - } - - return sb.toString(); - } - - @AllArgsConstructor - @Data - @NoArgsConstructor //For Jackson JSON - protected static class VertexConf { - protected GraphVertex graphVertex; - protected String vertexName; - protected String[] inputs; - } - - public static class Builder extends BaseNetworkSpace.Builder { - - protected List layerList = new ArrayList<>(); - protected List vertexList = new ArrayList<>(); - protected EarlyStoppingConfiguration earlyStoppingConfiguration; - protected String[] networkInputs; - protected String[] networkOutputs; - protected ParameterSpace inputTypes; - protected WorkspaceMode trainingWorkspaceMode; - protected WorkspaceMode inferenceWorkspaceMode; - - //Need: input types - //Early stopping configuration - //Graph nodes - - /** - * Early stopping configuration (optional). Note if both EarlyStoppingConfiguration and number of epochs is - * present, early stopping will be used in preference. - */ - public Builder earlyStoppingConfiguration( - EarlyStoppingConfiguration earlyStoppingConfiguration) { - this.earlyStoppingConfiguration = earlyStoppingConfiguration; - return this; - } - - public Builder layer(String layerName, LayerSpace layerSpace, String... layerInputs){ - return addLayer(layerName, layerSpace, layerInputs); - } - - public Builder layer(String layerName, LayerSpace layerSpace, InputPreProcessor preProcessor, - String... layerInputs) { - return addLayer(layerName, layerSpace, preProcessor, layerInputs); - } - - public Builder layer(String layerName, Layer layer, String... layerInputs){ - return layer(layerName, new FixedLayerSpace<>(layer), layerInputs); - } - - public Builder addLayer(String layerName, LayerSpace layerSpace, String... layerInputs) { - layerList.add(new LayerConf(layerSpace, layerName, layerInputs, new FixedValue<>(1), false, null)); - return this; - } - - public Builder addLayer(String layerName, LayerSpace layerSpace, InputPreProcessor preProcessor, - String... layerInputs){ - layerList.add(new LayerConf(layerSpace, layerName, layerInputs, new FixedValue<>(1), false, preProcessor)); - return this; - } - - public Builder addVertex(String vertexName, GraphVertex vertex, String... vertexInputs) { - vertexList.add(new VertexConf(vertex, vertexName, vertexInputs)); - return this; - } - - public Builder addInputs(String... networkInputs) { - this.networkInputs = networkInputs; - return this; - } - - public Builder setOutputs(String... networkOutputs) { - this.networkOutputs = networkOutputs; - return this; - } - - public Builder setInputTypes(InputType... inputTypes) { - return setInputTypes(new FixedValue(inputTypes)); - } - - public Builder setInputTypes(ParameterSpace inputTypes) { - this.inputTypes = inputTypes; - return this; - } - - public Builder trainingWorkspaceMode(WorkspaceMode workspaceMode){ - this.trainingWorkspaceMode = workspaceMode; - return this; - } - - public Builder inferenceWorkspaceMode(WorkspaceMode workspaceMode){ - this.inferenceWorkspaceMode = workspaceMode; - return this; - } - - @SuppressWarnings("unchecked") - public ComputationGraphSpace build() { - return new ComputationGraphSpace(this); - } - } - - - /** - * Instantiate a computation graph space from - * a raw json string - * @param json - * @return - */ - public static ComputationGraphSpace fromJson(String json) { - try { - return JsonMapper.getMapper().readValue(json, ComputationGraphSpace.class); - } catch (IOException e) { - throw new RuntimeException(e); - } - } - - /** - * Instantiate a computation graph space - * from a raw yaml string - * @param yaml - * @return - */ - public static ComputationGraphSpace fromYaml(String yaml) { - try { - return YamlMapper.getMapper().readValue(yaml, ComputationGraphSpace.class); - } catch (IOException e) { - throw new RuntimeException(e); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/DL4JConfiguration.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/DL4JConfiguration.java deleted file mode 100644 index 15eb7e3ba..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/DL4JConfiguration.java +++ /dev/null @@ -1,73 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter; - -import lombok.AllArgsConstructor; -import lombok.Data; -import org.deeplearning4j.arbiter.optimize.serde.jackson.JsonMapper; -import org.deeplearning4j.arbiter.optimize.serde.jackson.YamlMapper; -import org.deeplearning4j.earlystopping.EarlyStoppingConfiguration; -import org.deeplearning4j.nn.conf.MultiLayerConfiguration; -import com.fasterxml.jackson.core.JsonProcessingException; -import com.fasterxml.jackson.databind.annotation.JsonSerialize; - -import java.io.Serializable; - -/** - * DL4JConfiguration: simple configuration method that contains the following:
- * - MultiLayerConfiguration
- * - Early stopping settings, OR number of epochs
- * Note: if early stopping configuration is absent, a fixed number of epochs (default: 1) will be used. - * If both early stopping and number of epochs is present: early stopping will be used. - */ -@AllArgsConstructor -@Data -public class DL4JConfiguration implements Serializable { - @JsonSerialize - private MultiLayerConfiguration multiLayerConfiguration; - @JsonSerialize - private EarlyStoppingConfiguration earlyStoppingConfiguration; - @JsonSerialize - private Integer numEpochs; - - - /** - * Yaml mapping - * @return - */ - public String toYaml() { - try { - return YamlMapper.getMapper().writeValueAsString(this); - } catch (JsonProcessingException e) { - throw new RuntimeException(e); - } - } - - /** - * Json mapping - * @return - */ - public String toJson() { - try { - return JsonMapper.getMapper().writeValueAsString(this); - } catch (JsonProcessingException e) { - throw new RuntimeException(e); - } - } - - -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/GraphConfiguration.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/GraphConfiguration.java deleted file mode 100644 index 4cb6cf685..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/GraphConfiguration.java +++ /dev/null @@ -1,67 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter; - - -import lombok.AllArgsConstructor; -import lombok.Data; -import org.deeplearning4j.arbiter.optimize.serde.jackson.JsonMapper; -import org.deeplearning4j.arbiter.optimize.serde.jackson.YamlMapper; -import org.deeplearning4j.earlystopping.EarlyStoppingConfiguration; -import org.deeplearning4j.nn.conf.ComputationGraphConfiguration; -import org.deeplearning4j.nn.graph.ComputationGraph; -import com.fasterxml.jackson.core.JsonProcessingException; - -import java.io.Serializable; - -/** - * Analogous to {@link DL4JConfiguration}, GraphConfiguration includes a configuration for ComputationGraphs, as well - * as early stopping (or, optionally numEpochs) fields. - */ -@AllArgsConstructor -@Data -public class GraphConfiguration implements Serializable { - private ComputationGraphConfiguration configuration; - private EarlyStoppingConfiguration earlyStoppingConfiguration; - private Integer numEpochs; - - - - /** - * Yaml mapping - * @return - */ - public String toYaml() { - try { - return YamlMapper.getMapper().writeValueAsString(this); - } catch (JsonProcessingException e) { - throw new RuntimeException(e); - } - } - - /** - * Json mapping - * @return - */ - public String toJson() { - try { - return JsonMapper.getMapper().writeValueAsString(this); - } catch (JsonProcessingException e) { - throw new RuntimeException(e); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/MultiLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/MultiLayerSpace.java deleted file mode 100644 index beeb0420b..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/MultiLayerSpace.java +++ /dev/null @@ -1,320 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter; - -import lombok.Data; -import lombok.EqualsAndHashCode; -import org.deeplearning4j.arbiter.layers.LayerSpace; -import org.deeplearning4j.arbiter.layers.fixed.FixedLayerSpace; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.api.TaskCreatorProvider; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.optimize.serde.jackson.JsonMapper; -import org.deeplearning4j.arbiter.optimize.serde.jackson.YamlMapper; -import org.deeplearning4j.arbiter.task.MultiLayerNetworkTaskCreator; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.earlystopping.EarlyStoppingConfiguration; -import org.deeplearning4j.nn.conf.InputPreProcessor; -import org.deeplearning4j.nn.conf.MultiLayerConfiguration; -import org.deeplearning4j.nn.conf.NeuralNetConfiguration; -import org.deeplearning4j.nn.conf.WorkspaceMode; -import org.deeplearning4j.nn.conf.inputs.InputType; -import org.deeplearning4j.nn.conf.layers.Layer; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import com.fasterxml.jackson.annotation.JsonProperty; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; - -@Data -@EqualsAndHashCode(callSuper = true) -public class MultiLayerSpace extends BaseNetworkSpace { - - static { - TaskCreatorProvider.registerDefaultTaskCreatorClass(MultiLayerSpace.class, MultiLayerNetworkTaskCreator.class); - } - - @JsonProperty - protected ParameterSpace inputType; - @JsonProperty - protected ParameterSpace> inputPreProcessors; - - //Early stopping configuration / (fixed) number of epochs: - @JsonProperty - protected EarlyStoppingConfiguration earlyStoppingConfiguration; - @JsonProperty - protected int numParameters; - @JsonProperty - protected WorkspaceMode trainingWorkspaceMode; - @JsonProperty - protected WorkspaceMode inferenceWorkspaceMode; - @JsonProperty - protected boolean validateOutputLayerConfig = true; - - - protected MultiLayerSpace(Builder builder) { - super(builder); - this.inputType = builder.inputType; - this.inputPreProcessors = builder.inputPreProcessors; - - this.earlyStoppingConfiguration = builder.earlyStoppingConfiguration; - - this.layerSpaces = builder.layerSpaces; - - //Determine total number of parameters: - //Collect the leaves, and make sure they are unique. - //Note that the *object instances* must be unique - and consequently we don't want to use .equals(), as - // this would incorrectly filter out equal range parameter spaces - List allLeaves = collectLeaves(); - List list = LeafUtils.getUniqueObjects(allLeaves); - - for (ParameterSpace ps : list) { - int n = ps.numParameters(); - numParameters += ps.numParameters(); - } - - this.trainingWorkspaceMode = builder.trainingWorkspaceMode; - this.inferenceWorkspaceMode = builder.inferenceWorkspaceMode; - this.validateOutputLayerConfig = builder.validateOutputLayerConfig; - } - - protected MultiLayerSpace() { - //Default constructor for Jackson json/yaml serialization - } - - @Override - public DL4JConfiguration getValue(double[] values) { - //First: create layer configs - List layers = new ArrayList<>(); - for (LayerConf c : layerSpaces) { - int n = c.numLayers.getValue(values); - if (c.duplicateConfig) { - //Generate N identical configs - org.deeplearning4j.nn.conf.layers.Layer l = c.layerSpace.getValue(values); - for (int i = 0; i < n; i++) { - layers.add(l.clone()); - } - } else { - throw new UnsupportedOperationException("Not yet implemented"); - } - } - - //Create MultiLayerConfiguration... - NeuralNetConfiguration.Builder builder = randomGlobalConf(values); - - NeuralNetConfiguration.ListBuilder listBuilder = builder.list(); - for (int i = 0; i < layers.size(); i++) { - listBuilder.layer(i, layers.get(i)); - } - - if (backpropType != null) - listBuilder.backpropType(backpropType.getValue(values)); - if (tbpttFwdLength != null) - listBuilder.tBPTTForwardLength(tbpttFwdLength.getValue(values)); - if (tbpttBwdLength != null) - listBuilder.tBPTTBackwardLength(tbpttBwdLength.getValue(values)); - if (inputType != null) - listBuilder.setInputType(inputType.getValue(values)); - if (inputPreProcessors != null) - listBuilder.setInputPreProcessors(inputPreProcessors.getValue(values)); - listBuilder.validateOutputLayerConfig(validateOutputLayerConfig); - - MultiLayerConfiguration configuration = listBuilder.build(); - - if (trainingWorkspaceMode != null) - configuration.setTrainingWorkspaceMode(trainingWorkspaceMode); - if (inferenceWorkspaceMode != null) - configuration.setInferenceWorkspaceMode(inferenceWorkspaceMode); - - - return new DL4JConfiguration(configuration, earlyStoppingConfiguration, numEpochs); - } - - @Override - public int numParameters() { - return numParameters; - } - - @Override - public List collectLeaves() { - List list = super.collectLeaves(); - for (LayerConf lc : layerSpaces) { - list.addAll(lc.numLayers.collectLeaves()); - list.addAll(lc.layerSpace.collectLeaves()); - } - if (inputType != null) - list.addAll(inputType.collectLeaves()); - if (inputPreProcessors != null) - list.addAll(inputPreProcessors.collectLeaves()); - return list; - } - - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(super.toString()); - - int i = 0; - for (LayerConf conf : layerSpaces) { - - sb.append("Layer config ").append(i++).append(": (Number layers:").append(conf.numLayers) - .append(", duplicate: ").append(conf.duplicateConfig).append("), ") - .append(conf.layerSpace.toString()).append("\n"); - } - - if (inputType != null) - sb.append("inputType: ").append(inputType).append("\n"); - if (inputPreProcessors != null) - sb.append("inputPreProcessors: ").append(inputPreProcessors).append("\n"); - - if (earlyStoppingConfiguration != null) { - sb.append("Early stopping configuration:").append(earlyStoppingConfiguration.toString()).append("\n"); - } else { - sb.append("Training # epochs:").append(numEpochs).append("\n"); - } - - return sb.toString(); - } - - public LayerSpace getLayerSpace(int layerNumber) { - return layerSpaces.get(layerNumber).getLayerSpace(); - } - - public static class Builder extends BaseNetworkSpace.Builder { - protected List layerSpaces = new ArrayList<>(); - protected ParameterSpace inputType; - protected ParameterSpace> inputPreProcessors; - protected WorkspaceMode trainingWorkspaceMode; - protected WorkspaceMode inferenceWorkspaceMode; - - //Early stopping configuration - protected EarlyStoppingConfiguration earlyStoppingConfiguration; - - - - public Builder setInputType(InputType inputType) { - return setInputType(new FixedValue<>(inputType)); - } - - public Builder setInputType(ParameterSpace inputType) { - this.inputType = inputType; - return this; - } - - public Builder layer(Layer layer){ - return layer(new FixedLayerSpace<>(layer)); - } - - public Builder layer(LayerSpace layerSpace) { - return layer(layerSpace, new FixedValue<>(1)); - } - - public Builder layer(LayerSpace layerSpace, ParameterSpace numLayersDistribution) { - return addLayer(layerSpace, numLayersDistribution); - } - - - public Builder addLayer(LayerSpace layerSpace) { - return addLayer(layerSpace, new FixedValue<>(1)); - } - - /** - * duplicateConfig not supported. Will always be true - * @param layerSpace - * @param numLayersDistribution - * @param duplicateConfig - * @return - */ - @Deprecated - public Builder addLayer(LayerSpace layerSpace, ParameterSpace numLayersDistribution, boolean duplicateConfig) { - if (!duplicateConfig) throw new IllegalArgumentException("Duplicate Config false not supported"); - String layerName = "layer_" + layerSpaces.size(); - duplicateConfig = true; //hard coded to always duplicate layers - layerSpaces.add(new LayerConf(layerSpace, layerName, null, numLayersDistribution, duplicateConfig, null)); - return this; - } - - /** - * @param layerSpace - * @param numLayersDistribution Distribution for number of layers to generate - */ - public Builder addLayer(LayerSpace layerSpace, ParameterSpace numLayersDistribution) { - String layerName = "layer_" + layerSpaces.size(); - boolean duplicateConfig = true; //hard coded to always duplicate layers - layerSpaces.add(new LayerConf(layerSpace, layerName, null, numLayersDistribution, duplicateConfig, null)); - return this; - } - - /** - * Early stopping configuration (optional). Note if both EarlyStoppingConfiguration and number of epochs is - * present, early stopping will be used in preference. - */ - public Builder earlyStoppingConfiguration( - EarlyStoppingConfiguration earlyStoppingConfiguration) { - this.earlyStoppingConfiguration = earlyStoppingConfiguration; - return this; - } - - /** - * @param inputPreProcessors Input preprocessors to set for the model - */ - public Builder setInputPreProcessors(Map inputPreProcessors) { - return setInputPreProcessors(new FixedValue<>(inputPreProcessors)); - } - - /** - * @param inputPreProcessors Input preprocessors to set for the model - */ - public Builder setInputPreProcessors(ParameterSpace> inputPreProcessors) { - this.inputPreProcessors = inputPreProcessors; - return this; - } - - public Builder trainingWorkspaceMode(WorkspaceMode workspaceMode){ - this.trainingWorkspaceMode = workspaceMode; - return this; - } - - public Builder inferenceWorkspaceMode(WorkspaceMode workspaceMode){ - this.inferenceWorkspaceMode = workspaceMode; - return this; - } - - @SuppressWarnings("unchecked") - public MultiLayerSpace build() { - return new MultiLayerSpace(this); - } - } - - public static MultiLayerSpace fromJson(String json) { - try { - return JsonMapper.getMapper().readValue(json, MultiLayerSpace.class); - } catch (IOException e) { - throw new RuntimeException(e); - } - } - - public static MultiLayerSpace fromYaml(String yaml) { - try { - return YamlMapper.getMapper().readValue(yaml, MultiLayerSpace.class); - } catch (IOException e) { - throw new RuntimeException(e); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/adapter/ActivationParameterSpaceAdapter.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/adapter/ActivationParameterSpaceAdapter.java deleted file mode 100644 index 5e666a00d..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/adapter/ActivationParameterSpaceAdapter.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.adapter; - -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.api.adapter.ParameterSpaceAdapter; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.activations.IActivation; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** - * A simple class to adapt a {@link Activation} parameter space to a {@link IActivation} parameter space - * - * @author Alex Black - */ -@Data -@NoArgsConstructor -@EqualsAndHashCode(callSuper = false) -public class ActivationParameterSpaceAdapter extends ParameterSpaceAdapter { - - private ParameterSpace activation; - - public ActivationParameterSpaceAdapter(@JsonProperty("activation") ParameterSpace activation) { - this.activation = activation; - } - - @Override - public IActivation convertValue(Activation from) { - return from.getActivationFunction(); - } - - @Override - protected ParameterSpace underlying() { - return activation; - } - - @Override - protected String underlyingName() { - return "activation"; - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/adapter/LossFunctionParameterSpaceAdapter.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/adapter/LossFunctionParameterSpaceAdapter.java deleted file mode 100644 index 2c4c2899c..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/adapter/LossFunctionParameterSpaceAdapter.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.adapter; - -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.api.adapter.ParameterSpaceAdapter; -import org.nd4j.linalg.lossfunctions.ILossFunction; -import org.nd4j.linalg.lossfunctions.LossFunctions; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** - * A simple class to adapt a {@link LossFunctions.LossFunction} parameter space to a {@link ILossFunction} parameter space - * - * @author Alex Black - */ -@Data -@NoArgsConstructor -@EqualsAndHashCode(callSuper = false) -public class LossFunctionParameterSpaceAdapter - extends ParameterSpaceAdapter { - - private ParameterSpace lossFunction; - - public LossFunctionParameterSpaceAdapter( - @JsonProperty("lossFunction") ParameterSpace lossFunction) { - this.lossFunction = lossFunction; - } - - @Override - protected ILossFunction convertValue(LossFunctions.LossFunction from) { - return from.getILossFunction(); - } - - @Override - protected ParameterSpace underlying() { - return lossFunction; - } - - @Override - protected String underlyingName() { - return "lossFunction"; - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/dropout/DropoutSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/dropout/DropoutSpace.java deleted file mode 100644 index 76443109e..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/dropout/DropoutSpace.java +++ /dev/null @@ -1,63 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.conf.dropout; - -import lombok.AllArgsConstructor; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.AbstractParameterSpace; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.nn.conf.dropout.Dropout; -import org.deeplearning4j.nn.conf.dropout.IDropout; - -import java.util.List; - -@AllArgsConstructor -@NoArgsConstructor -public class DropoutSpace extends AbstractParameterSpace { - - private ParameterSpace dropout; - - @Override - public Dropout getValue(double[] parameterValues) { - double p = dropout.getValue(parameterValues); - if(p == 0){ - //Special case: 0 dropout = "disabled" in DL4J. But Dropout class doesn't support this - return null; - } - return new Dropout(p); - } - - @Override - public int numParameters() { - return dropout.numParameters(); - } - - @Override - public List collectLeaves() { - return dropout.collectLeaves(); - } - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices) { - dropout.setIndices(indices); - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/AdaGradSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/AdaGradSpace.java deleted file mode 100644 index ca94a386a..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/AdaGradSpace.java +++ /dev/null @@ -1,66 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.conf.updater; - -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.Getter; -import lombok.Setter; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.nd4j.linalg.learning.config.AdaGrad; -import org.nd4j.linalg.learning.config.IUpdater; -import org.nd4j.linalg.schedule.ISchedule; -import com.fasterxml.jackson.annotation.JsonProperty; - -import java.util.Collections; -import java.util.List; -import java.util.Map; - -@Data -@EqualsAndHashCode(callSuper = false) -public class AdaGradSpace extends BaseUpdaterSpace { - - private ParameterSpace learningRate; - private ParameterSpace lrSchedule; - - public AdaGradSpace(ParameterSpace learningRate) { - this(learningRate, null); - } - - public static AdaGradSpace withLR(ParameterSpace lr){ - return new AdaGradSpace(lr, null); - } - - public static AdaGradSpace withLRSchedule(ParameterSpace lrSchedule){ - return new AdaGradSpace(null, lrSchedule); - } - - protected AdaGradSpace(@JsonProperty("learningRate") ParameterSpace learningRate, - @JsonProperty("lrSchedule") ParameterSpace lrSchedule){ - this.learningRate = learningRate; - this.lrSchedule = lrSchedule; - } - - @Override - public IUpdater getValue(double[] parameterValues) { - if(lrSchedule != null){ - return new AdaGrad(lrSchedule.getValue(parameterValues)); - } else { - return new AdaGrad(learningRate.getValue(parameterValues)); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/AdaMaxSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/AdaMaxSpace.java deleted file mode 100644 index 137e62f8d..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/AdaMaxSpace.java +++ /dev/null @@ -1,83 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.conf.updater; - -import lombok.Data; -import lombok.EqualsAndHashCode; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.nd4j.linalg.learning.config.AdaMax; -import org.nd4j.linalg.learning.config.IUpdater; -import org.nd4j.linalg.schedule.ISchedule; -import com.fasterxml.jackson.annotation.JsonProperty; - -@Data -@EqualsAndHashCode(callSuper = false) -public class AdaMaxSpace extends BaseUpdaterSpace { - - private ParameterSpace learningRate; - private ParameterSpace learningRateSchedule; - private ParameterSpace beta1; - private ParameterSpace beta2; - private ParameterSpace epsilon; - - public AdaMaxSpace(ParameterSpace learningRate) { - this(learningRate, null, null, null); - } - - public AdaMaxSpace(ParameterSpace learningRate, ParameterSpace beta1, - ParameterSpace beta2, ParameterSpace epsilon) { - this(learningRate, null, beta1, beta2, epsilon); - } - - public AdaMaxSpace(@JsonProperty("learningRate") ParameterSpace learningRate, - @JsonProperty("learningRateSchedule") ParameterSpace learningRateSchedule, - @JsonProperty("beta1") ParameterSpace beta1, - @JsonProperty("beta2") ParameterSpace beta2, - @JsonProperty("epsilon") ParameterSpace epsilon){ - this.learningRate = learningRate; - this.learningRateSchedule = learningRateSchedule; - this.beta1 = beta1; - this.beta2 = beta2; - this.epsilon = epsilon; - } - - public static AdaMaxSpace withLR(ParameterSpace lr){ - return new AdaMaxSpace(lr, null, null, null, null); - } - - public static AdaMaxSpace withLRSchedule(ParameterSpace lrSchedule){ - return new AdaMaxSpace(null, lrSchedule, null, null, null); - } - - @Override - public IUpdater getValue(double[] parameterValues) { - double lr = learningRate == null ? AdaMax.DEFAULT_ADAMAX_LEARNING_RATE : learningRate.getValue(parameterValues); - ISchedule lrS = learningRateSchedule == null ? null : learningRateSchedule.getValue(parameterValues); - double b1 = beta1 == null ? AdaMax.DEFAULT_ADAMAX_LEARNING_RATE : beta1.getValue(parameterValues); - double b2 = beta2 == null ? AdaMax.DEFAULT_ADAMAX_LEARNING_RATE : beta2.getValue(parameterValues); - double eps = epsilon == null ? AdaMax.DEFAULT_ADAMAX_LEARNING_RATE : epsilon.getValue(parameterValues); - if(lrS == null){ - return new AdaMax(lr, b1, b2, eps); - } else { - AdaMax a = new AdaMax(lrS); - a.setBeta1(b1); - a.setBeta2(b2); - a.setEpsilon(eps); - return a; - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/AdamSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/AdamSpace.java deleted file mode 100644 index 638b60782..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/AdamSpace.java +++ /dev/null @@ -1,83 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.conf.updater; - -import lombok.Data; -import lombok.EqualsAndHashCode; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.nd4j.linalg.learning.config.Adam; -import org.nd4j.linalg.learning.config.IUpdater; -import org.nd4j.linalg.schedule.ISchedule; -import com.fasterxml.jackson.annotation.JsonProperty; - -@Data -@EqualsAndHashCode(callSuper = false) -public class AdamSpace extends BaseUpdaterSpace { - - private ParameterSpace learningRate; - private ParameterSpace learningRateSchedule; - private ParameterSpace beta1; - private ParameterSpace beta2; - private ParameterSpace epsilon; - - public AdamSpace(ParameterSpace learningRate) { - this(learningRate, null, null, null); - } - - public AdamSpace(ParameterSpace learningRate, ParameterSpace beta1, - ParameterSpace beta2, ParameterSpace epsilon) { - this(learningRate, null, beta1, beta2, epsilon); - } - - public static AdamSpace withLR(ParameterSpace lr){ - return new AdamSpace(lr, null, null, null, null); - } - - public static AdamSpace withLRSchedule(ParameterSpace lrSchedule){ - return new AdamSpace(null, lrSchedule, null, null, null); - } - - protected AdamSpace(@JsonProperty("learningRate") ParameterSpace learningRate, - @JsonProperty("learningRateSchedule") ParameterSpace learningRateSchedule, - @JsonProperty("beta1") ParameterSpace beta1, - @JsonProperty("beta2") ParameterSpace beta2, - @JsonProperty("epsilon") ParameterSpace epsilon){ - this.learningRate = learningRate; - this.learningRateSchedule = learningRateSchedule; - this.beta1 = beta1; - this.beta2 = beta2; - this.epsilon = epsilon; - } - - @Override - public IUpdater getValue(double[] parameterValues) { - double lr = learningRate == null ? Adam.DEFAULT_ADAM_LEARNING_RATE : learningRate.getValue(parameterValues); - ISchedule lrS = learningRateSchedule == null ? null : learningRateSchedule.getValue(parameterValues); - double b1 = beta1 == null ? Adam.DEFAULT_ADAM_LEARNING_RATE : beta1.getValue(parameterValues); - double b2 = beta2 == null ? Adam.DEFAULT_ADAM_LEARNING_RATE : beta2.getValue(parameterValues); - double eps = epsilon == null ? Adam.DEFAULT_ADAM_LEARNING_RATE : epsilon.getValue(parameterValues); - if(lrS == null){ - return new Adam(lr, b1, b2, eps); - } else { - Adam a = new Adam(lrS); - a.setBeta1(b1); - a.setBeta2(b2); - a.setEpsilon(eps); - return a; - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/BaseUpdaterSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/BaseUpdaterSpace.java deleted file mode 100644 index ec1eca996..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/BaseUpdaterSpace.java +++ /dev/null @@ -1,70 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.conf.updater; - -import lombok.Data; -import lombok.Getter; -import lombok.Setter; -import org.deeplearning4j.arbiter.optimize.api.AbstractParameterSpace; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.nd4j.linalg.learning.config.IUpdater; - -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; -import java.util.Map; - -@Data -public abstract class BaseUpdaterSpace extends AbstractParameterSpace { - - @Override - public int numParameters() { - int count = 0; - for(ParameterSpace p : collectLeaves()){ - count += p.numParameters(); - } - return count; - } - - @Override - public List collectLeaves() { - Map nested = getNestedSpaces(); - List out = new ArrayList<>(); - for(ParameterSpace p : nested.values()){ - out.addAll(p.collectLeaves()); - } - return out; - } - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices){ - int soFar = 0; - for(ParameterSpace p : collectLeaves()){ - int numParams = p.numParameters(); - if(numParams <= 0){ - continue; - } - int[] subset = Arrays.copyOfRange(indices, soFar, soFar + numParams); - p.setIndices(subset); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/NadamSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/NadamSpace.java deleted file mode 100644 index 16bc09127..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/NadamSpace.java +++ /dev/null @@ -1,83 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.conf.updater; - -import lombok.Data; -import lombok.EqualsAndHashCode; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.nd4j.linalg.learning.config.Nadam; -import org.nd4j.linalg.learning.config.IUpdater; -import org.nd4j.linalg.schedule.ISchedule; -import com.fasterxml.jackson.annotation.JsonProperty; - -@Data -@EqualsAndHashCode(callSuper = false) -public class NadamSpace extends BaseUpdaterSpace { - - private ParameterSpace learningRate; - private ParameterSpace learningRateSchedule; - private ParameterSpace beta1; - private ParameterSpace beta2; - private ParameterSpace epsilon; - - public NadamSpace(ParameterSpace learningRate) { - this(learningRate, null, null, null); - } - - public NadamSpace(ParameterSpace learningRate, ParameterSpace beta1, - ParameterSpace beta2, ParameterSpace epsilon) { - this(learningRate, null, beta1, beta2, epsilon); - } - - public NadamSpace(@JsonProperty("learningRate") ParameterSpace learningRate, - @JsonProperty("learningRateSchedule") ParameterSpace learningRateSchedule, - @JsonProperty("beta1") ParameterSpace beta1, - @JsonProperty("beta2") ParameterSpace beta2, - @JsonProperty("epsilon") ParameterSpace epsilon){ - this.learningRate = learningRate; - this.learningRateSchedule = learningRateSchedule; - this.beta1 = beta1; - this.beta2 = beta2; - this.epsilon = epsilon; - } - - public static NadamSpace withLR(ParameterSpace lr){ - return new NadamSpace(lr, null, null, null, null); - } - - public static NadamSpace withLRSchedule(ParameterSpace lrSchedule){ - return new NadamSpace(null, lrSchedule, null, null, null); - } - - @Override - public IUpdater getValue(double[] parameterValues) { - double lr = learningRate == null ? Nadam.DEFAULT_NADAM_LEARNING_RATE : learningRate.getValue(parameterValues); - ISchedule lrS = learningRateSchedule == null ? null : learningRateSchedule.getValue(parameterValues); - double b1 = beta1 == null ? Nadam.DEFAULT_NADAM_LEARNING_RATE : beta1.getValue(parameterValues); - double b2 = beta2 == null ? Nadam.DEFAULT_NADAM_LEARNING_RATE : beta2.getValue(parameterValues); - double eps = epsilon == null ? Nadam.DEFAULT_NADAM_LEARNING_RATE : epsilon.getValue(parameterValues); - if(lrS == null){ - return new Nadam(lr, b1, b2, eps); - } else { - Nadam a = new Nadam(lrS); - a.setBeta1(b1); - a.setBeta2(b2); - a.setEpsilon(eps); - return a; - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/NesterovsSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/NesterovsSpace.java deleted file mode 100644 index 6bb059493..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/NesterovsSpace.java +++ /dev/null @@ -1,100 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.conf.updater; - -import lombok.Data; -import lombok.EqualsAndHashCode; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.nd4j.linalg.learning.config.IUpdater; -import org.nd4j.linalg.learning.config.Nesterovs; -import org.nd4j.linalg.schedule.ISchedule; -import com.fasterxml.jackson.annotation.JsonProperty; - -@Data -@EqualsAndHashCode(callSuper = false) -public class NesterovsSpace extends BaseUpdaterSpace { - - protected ParameterSpace learningRate; - protected ParameterSpace learningRateSchedule; - protected ParameterSpace momentum; - protected ParameterSpace momentumSchedule; - - public NesterovsSpace(ParameterSpace learningRate) { - this(learningRate, null); - } - - public NesterovsSpace(ParameterSpace learningRate, ParameterSpace momentum) { - this(learningRate, null, momentum, null); - } - - public NesterovsSpace(@JsonProperty("learningRate") ParameterSpace learningRate, - @JsonProperty("learningRateSchedule") ParameterSpace learningRateSchedule, - @JsonProperty("momentum") ParameterSpace momentum, - @JsonProperty("momentumSchedule") ParameterSpace momentumSchedule) { - this.learningRate = learningRate; - this.learningRateSchedule = learningRateSchedule; - this.momentum = momentum; - this.momentumSchedule = momentumSchedule; - } - - public static NesterovsSpace withLR(ParameterSpace lr){ - return new NesterovsSpace(lr, null, null, null); - } - - public static NesterovsSpace withLR(ParameterSpace lr, double momentum){ - return new NesterovsSpace(lr, null, new FixedValue<>(momentum), null); - } - - public static NesterovsSpace withLR(ParameterSpace lr, ParameterSpace momentum){ - return new NesterovsSpace(lr, null, momentum, null); - } - - public static NesterovsSpace withLRSchedule(ParameterSpace lrSchedule){ - return new NesterovsSpace(null, lrSchedule, null, null); - } - - public static NesterovsSpace withLRSchedule(ParameterSpace lrSchedule, double momentum){ - return new NesterovsSpace(null, lrSchedule, new FixedValue<>(momentum), null); - } - - public static NesterovsSpace withLRSchedule(ParameterSpace lrSchedule, ParameterSpace momentum){ - return new NesterovsSpace(null, lrSchedule, momentum, null); - } - - - @Override - public IUpdater getValue(double[] parameterValues) { - double lr = learningRate == null ? Nesterovs.DEFAULT_NESTEROV_LEARNING_RATE : learningRate.getValue(parameterValues); - ISchedule lrS = learningRateSchedule == null ? null : learningRateSchedule.getValue(parameterValues); - double m = momentum == null ? Nesterovs.DEFAULT_NESTEROV_MOMENTUM : momentum.getValue(parameterValues); - ISchedule mS = momentumSchedule == null ? null : momentumSchedule.getValue(parameterValues); - if(lrS == null){ - if(momentumSchedule == null){ - return new Nesterovs(lr, m); - } else { - return new Nesterovs(lr, mS); - } - } else { - if(momentumSchedule == null){ - return new Nesterovs(lrS, m); - } else { - return new Nesterovs(lrS, mS); - } - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/RmsPropSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/RmsPropSpace.java deleted file mode 100644 index 8590947d6..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/RmsPropSpace.java +++ /dev/null @@ -1,54 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.conf.updater; - -import lombok.Data; -import lombok.EqualsAndHashCode; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.nd4j.linalg.learning.config.IUpdater; -import org.nd4j.linalg.learning.config.RmsProp; -import org.nd4j.linalg.schedule.ISchedule; -import com.fasterxml.jackson.annotation.JsonProperty; - -@Data -@EqualsAndHashCode(callSuper = false) -public class RmsPropSpace extends BaseUpdaterSpace { - - protected ParameterSpace learningRate; - protected ParameterSpace learningRateSchedule; - - public RmsPropSpace(ParameterSpace learningRate) { - this(learningRate, null); - } - - public RmsPropSpace(@JsonProperty("learningRate") ParameterSpace learningRate, - @JsonProperty("learningRateSchedule") ParameterSpace learningRateSchedule){ - this.learningRate = learningRate; - this.learningRateSchedule = learningRateSchedule; - } - - @Override - public IUpdater getValue(double[] parameterValues) { - double lr = learningRate == null ? RmsProp.DEFAULT_RMSPROP_LEARNING_RATE : learningRate.getValue(parameterValues); - ISchedule lrS = learningRateSchedule == null ? null : learningRateSchedule.getValue(parameterValues); - if(lrS == null){ - return new RmsProp(lr); - } else { - return new RmsProp(lrS); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/SgdSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/SgdSpace.java deleted file mode 100644 index 0c136e114..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/SgdSpace.java +++ /dev/null @@ -1,54 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.conf.updater; - -import lombok.Data; -import lombok.EqualsAndHashCode; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.nd4j.linalg.learning.config.IUpdater; -import org.nd4j.linalg.learning.config.Sgd; -import org.nd4j.linalg.schedule.ISchedule; -import com.fasterxml.jackson.annotation.JsonProperty; - -@Data -@EqualsAndHashCode(callSuper = false) -public class SgdSpace extends BaseUpdaterSpace { - - protected ParameterSpace learningRate; - protected ParameterSpace learningRateSchedule; - - public SgdSpace(ParameterSpace learningRate) { - this(learningRate, null); - } - - public SgdSpace(@JsonProperty("learningRate") ParameterSpace learningRate, - @JsonProperty("learningRateSchedule") ParameterSpace learningRateSchedule){ - this.learningRate = learningRate; - this.learningRateSchedule = learningRateSchedule; - } - - @Override - public IUpdater getValue(double[] parameterValues) { - double lr = learningRate == null ? Sgd.DEFAULT_SGD_LR : learningRate.getValue(parameterValues); - ISchedule lrS = learningRateSchedule == null ? null : learningRateSchedule.getValue(parameterValues); - if(lrS == null){ - return new Sgd(lr); - } else { - return new Sgd(lrS); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/ExponentialScheduleSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/ExponentialScheduleSpace.java deleted file mode 100644 index 3977faa25..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/ExponentialScheduleSpace.java +++ /dev/null @@ -1,92 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.conf.updater.schedule; - -import lombok.Data; -import lombok.NoArgsConstructor; -import lombok.NonNull; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.nd4j.linalg.schedule.ExponentialSchedule; -import org.nd4j.linalg.schedule.ISchedule; -import org.nd4j.linalg.schedule.ScheduleType; -import com.fasterxml.jackson.annotation.JsonProperty; - -import java.util.*; - -@NoArgsConstructor //JSON -@Data -public class ExponentialScheduleSpace implements ParameterSpace { - - private ScheduleType scheduleType; - private ParameterSpace initialValue; - private ParameterSpace gamma; - - public ExponentialScheduleSpace(@NonNull ScheduleType scheduleType, - @NonNull ParameterSpace initialValue, double gamma){ - this(scheduleType, initialValue, new FixedValue<>(gamma)); - } - - public ExponentialScheduleSpace(@NonNull @JsonProperty("scheduleType") ScheduleType scheduleType, - @NonNull @JsonProperty("initialValue") ParameterSpace initialValue, - @NonNull @JsonProperty("gamma") ParameterSpace gamma){ - this.scheduleType = scheduleType; - this.initialValue = initialValue; - this.gamma = gamma; - } - - @Override - public ISchedule getValue(double[] parameterValues) { - return new ExponentialSchedule(scheduleType, initialValue.getValue(parameterValues), gamma.getValue(parameterValues)); - } - - @Override - public int numParameters() { - return initialValue.numParameters() + gamma.numParameters(); - } - - @Override - public List collectLeaves() { - return Arrays.asList(initialValue, gamma); - } - - @Override - public Map getNestedSpaces() { - Map out = new LinkedHashMap<>(); - out.put("initialValue", initialValue); - out.put("gamma", gamma); - return out; - } - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices) { - if(initialValue.numParameters() > 0){ - int[] sub = Arrays.copyOfRange(indices, 0, initialValue.numParameters()); - initialValue.setIndices(sub); - } - if(gamma.numParameters() > 0){ - int inp = initialValue.numParameters(); - int[] sub = Arrays.copyOfRange(indices, inp, inp + gamma.numParameters()); - gamma.setIndices(sub); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/InverseScheduleSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/InverseScheduleSpace.java deleted file mode 100644 index a22c640a9..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/InverseScheduleSpace.java +++ /dev/null @@ -1,106 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.conf.updater.schedule; - -import lombok.Data; -import lombok.NoArgsConstructor; -import lombok.NonNull; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.nd4j.linalg.schedule.ExponentialSchedule; -import org.nd4j.linalg.schedule.ISchedule; -import org.nd4j.linalg.schedule.InverseSchedule; -import org.nd4j.linalg.schedule.ScheduleType; -import com.fasterxml.jackson.annotation.JsonProperty; - -import java.util.Arrays; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; - -@NoArgsConstructor //JSON -@Data -public class InverseScheduleSpace implements ParameterSpace { - - private ScheduleType scheduleType; - private ParameterSpace initialValue; - private ParameterSpace gamma; - private ParameterSpace power; - - public InverseScheduleSpace(@NonNull ScheduleType scheduleType, @NonNull ParameterSpace initialValue, - double gamma, double power){ - this(scheduleType, initialValue, new FixedValue<>(gamma), new FixedValue<>(power)); - } - - public InverseScheduleSpace(@NonNull @JsonProperty("scheduleType") ScheduleType scheduleType, - @NonNull @JsonProperty("initialValue") ParameterSpace initialValue, - @NonNull @JsonProperty("gamma") ParameterSpace gamma, - @NonNull @JsonProperty("power") ParameterSpace power){ - this.scheduleType = scheduleType; - this.initialValue = initialValue; - this.gamma = gamma; - this.power = power; - } - - @Override - public ISchedule getValue(double[] parameterValues) { - return new InverseSchedule(scheduleType, initialValue.getValue(parameterValues), - gamma.getValue(parameterValues), power.getValue(parameterValues)); - } - - @Override - public int numParameters() { - return initialValue.numParameters() + gamma.numParameters() + power.numParameters(); - } - - @Override - public List collectLeaves() { - return Arrays.asList(initialValue, gamma, power); - } - - @Override - public Map getNestedSpaces() { - Map out = new LinkedHashMap<>(); - out.put("initialValue", initialValue); - out.put("gamma", gamma); - out.put("power", power); - return out; - } - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices) { - if(initialValue.numParameters() > 0){ - int[] sub = Arrays.copyOfRange(indices, 0, initialValue.numParameters()); - initialValue.setIndices(sub); - } - if(gamma.numParameters() > 0){ - int inp = initialValue.numParameters(); - int[] sub = Arrays.copyOfRange(indices, inp, inp + gamma.numParameters()); - gamma.setIndices(sub); - } - if(power.numParameters() > 0){ - int np = initialValue.numParameters() + gamma.numParameters(); - int[] sub = Arrays.copyOfRange(indices, np, np + power.numParameters()); - power.setIndices(sub); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/PolyScheduleSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/PolyScheduleSpace.java deleted file mode 100644 index 9beff30b5..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/PolyScheduleSpace.java +++ /dev/null @@ -1,106 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.conf.updater.schedule; - -import lombok.Data; -import lombok.NoArgsConstructor; -import lombok.NonNull; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.nd4j.linalg.schedule.ISchedule; -import org.nd4j.linalg.schedule.InverseSchedule; -import org.nd4j.linalg.schedule.PolySchedule; -import org.nd4j.linalg.schedule.ScheduleType; -import com.fasterxml.jackson.annotation.JsonProperty; - -import java.util.Arrays; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; - -@NoArgsConstructor //JSON -@Data -public class PolyScheduleSpace implements ParameterSpace { - - private ScheduleType scheduleType; - private ParameterSpace initialValue; - private ParameterSpace power; - private ParameterSpace maxIter; - - public PolyScheduleSpace(@NonNull ScheduleType scheduleType, @NonNull ParameterSpace initialValue, - double power, int maxIter){ - this(scheduleType, initialValue, new FixedValue<>(power), new FixedValue<>(maxIter)); - } - - public PolyScheduleSpace(@NonNull @JsonProperty("scheduleType") ScheduleType scheduleType, - @NonNull @JsonProperty("initialValue") ParameterSpace initialValue, - @NonNull @JsonProperty("power") ParameterSpace power, - @NonNull @JsonProperty("maxIter") ParameterSpace maxIter){ - this.scheduleType = scheduleType; - this.initialValue = initialValue; - this.power = power; - this.maxIter = maxIter; - } - - @Override - public ISchedule getValue(double[] parameterValues) { - return new PolySchedule(scheduleType, initialValue.getValue(parameterValues), - power.getValue(parameterValues), maxIter.getValue(parameterValues)); - } - - @Override - public int numParameters() { - return initialValue.numParameters() + power.numParameters() + maxIter.numParameters(); - } - - @Override - public List collectLeaves() { - return Arrays.asList(initialValue, power, maxIter); - } - - @Override - public Map getNestedSpaces() { - Map out = new LinkedHashMap<>(); - out.put("initialValue", initialValue); - out.put("power", power); - out.put("maxIter", maxIter); - return out; - } - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices) { - if(initialValue.numParameters() > 0){ - int[] sub = Arrays.copyOfRange(indices, 0, initialValue.numParameters()); - initialValue.setIndices(sub); - } - if(power.numParameters() > 0){ - int np = initialValue.numParameters(); - int[] sub = Arrays.copyOfRange(indices, np, np + power.numParameters()); - power.setIndices(sub); - } - if(maxIter.numParameters() > 0){ - int np = initialValue.numParameters() + power.numParameters(); - int[] sub = Arrays.copyOfRange(indices, np, np + maxIter.numParameters()); - maxIter.setIndices(sub); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/SigmoidScheduleSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/SigmoidScheduleSpace.java deleted file mode 100644 index c8c5e4c3c..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/SigmoidScheduleSpace.java +++ /dev/null @@ -1,106 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.conf.updater.schedule; - -import lombok.Data; -import lombok.NoArgsConstructor; -import lombok.NonNull; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.nd4j.linalg.schedule.ISchedule; -import org.nd4j.linalg.schedule.PolySchedule; -import org.nd4j.linalg.schedule.ScheduleType; -import org.nd4j.linalg.schedule.SigmoidSchedule; -import com.fasterxml.jackson.annotation.JsonProperty; - -import java.util.Arrays; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; - -@NoArgsConstructor //JSON -@Data -public class SigmoidScheduleSpace implements ParameterSpace { - - private ScheduleType scheduleType; - private ParameterSpace initialValue; - private ParameterSpace gamma; - private ParameterSpace stepSize; - - public SigmoidScheduleSpace(@NonNull ScheduleType scheduleType, @NonNull ParameterSpace initialValue, - double gamma, int stepSize){ - this(scheduleType, initialValue, new FixedValue<>(gamma), new FixedValue<>(stepSize)); - } - - public SigmoidScheduleSpace(@NonNull @JsonProperty("scheduleType") ScheduleType scheduleType, - @NonNull @JsonProperty("initialValue") ParameterSpace initialValue, - @NonNull @JsonProperty("gamma") ParameterSpace gamma, - @NonNull @JsonProperty("stepSize") ParameterSpace stepSize){ - this.scheduleType = scheduleType; - this.initialValue = initialValue; - this.gamma = gamma; - this.stepSize = stepSize; - } - - @Override - public ISchedule getValue(double[] parameterValues) { - return new SigmoidSchedule(scheduleType, initialValue.getValue(parameterValues), - gamma.getValue(parameterValues), stepSize.getValue(parameterValues)); - } - - @Override - public int numParameters() { - return initialValue.numParameters() + gamma.numParameters() + stepSize.numParameters(); - } - - @Override - public List collectLeaves() { - return Arrays.asList(initialValue, gamma, stepSize); - } - - @Override - public Map getNestedSpaces() { - Map out = new LinkedHashMap<>(); - out.put("initialValue", initialValue); - out.put("gamma", gamma); - out.put("stepSize", stepSize); - return out; - } - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices) { - if(initialValue.numParameters() > 0){ - int[] sub = Arrays.copyOfRange(indices, 0, initialValue.numParameters()); - initialValue.setIndices(sub); - } - if(gamma.numParameters() > 0){ - int np = initialValue.numParameters(); - int[] sub = Arrays.copyOfRange(indices, np, np + gamma.numParameters()); - gamma.setIndices(sub); - } - if(stepSize.numParameters() > 0){ - int np = initialValue.numParameters() + gamma.numParameters(); - int[] sub = Arrays.copyOfRange(indices, np, np + stepSize.numParameters()); - stepSize.setIndices(sub); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/StepScheduleSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/StepScheduleSpace.java deleted file mode 100644 index d37638e8d..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/conf/updater/schedule/StepScheduleSpace.java +++ /dev/null @@ -1,106 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.conf.updater.schedule; - -import lombok.Data; -import lombok.NoArgsConstructor; -import lombok.NonNull; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.nd4j.linalg.schedule.ISchedule; -import org.nd4j.linalg.schedule.InverseSchedule; -import org.nd4j.linalg.schedule.ScheduleType; -import org.nd4j.linalg.schedule.StepSchedule; -import com.fasterxml.jackson.annotation.JsonProperty; - -import java.util.Arrays; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; - -@NoArgsConstructor //JSON -@Data -public class StepScheduleSpace implements ParameterSpace { - - private ScheduleType scheduleType; - private ParameterSpace initialValue; - private ParameterSpace decayRate; - private ParameterSpace step; - - public StepScheduleSpace(@NonNull ScheduleType scheduleType, @NonNull ParameterSpace initialValue, - double decayRate, double step){ - this(scheduleType, initialValue, new FixedValue<>(decayRate), new FixedValue<>(step)); - } - - public StepScheduleSpace(@NonNull @JsonProperty("scheduleType") ScheduleType scheduleType, - @NonNull @JsonProperty("initialValue") ParameterSpace initialValue, - @NonNull @JsonProperty("decayRate") ParameterSpace decayRate, - @NonNull @JsonProperty("step") ParameterSpace step){ - this.scheduleType = scheduleType; - this.initialValue = initialValue; - this.decayRate = decayRate; - this.step = step; - } - - @Override - public ISchedule getValue(double[] parameterValues) { - return new StepSchedule(scheduleType, initialValue.getValue(parameterValues), - decayRate.getValue(parameterValues), step.getValue(parameterValues)); - } - - @Override - public int numParameters() { - return initialValue.numParameters() + decayRate.numParameters() + step.numParameters(); - } - - @Override - public List collectLeaves() { - return Arrays.asList(initialValue, decayRate, step); - } - - @Override - public Map getNestedSpaces() { - Map out = new LinkedHashMap<>(); - out.put("initialValue", initialValue); - out.put("decayRate", decayRate); - out.put("step", step); - return out; - } - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices) { - if(initialValue.numParameters() > 0){ - int[] sub = Arrays.copyOfRange(indices, 0, initialValue.numParameters()); - initialValue.setIndices(sub); - } - if(decayRate.numParameters() > 0){ - int inp = initialValue.numParameters(); - int[] sub = Arrays.copyOfRange(indices, inp, inp + decayRate.numParameters()); - decayRate.setIndices(sub); - } - if(step.numParameters() > 0){ - int np = initialValue.numParameters() + decayRate.numParameters(); - int[] sub = Arrays.copyOfRange(indices, np, np + step.numParameters()); - step.setIndices(sub); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/data/DataSetIteratorFactoryProvider.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/data/DataSetIteratorFactoryProvider.java deleted file mode 100644 index e5443c0d3..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/data/DataSetIteratorFactoryProvider.java +++ /dev/null @@ -1,85 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.data; - -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.nd4j.linalg.dataset.api.iterator.DataSetIteratorFactory; - -import java.util.Map; - -/** - * This is a {@link DataProvider} for - * an {@link DataSetIteratorFactory} which - * based on a key of {@link DataSetIteratorFactoryProvider#FACTORY_KEY} - * will create {@link org.nd4j.linalg.dataset.api.iterator.DataSetIterator} - * for use with arbiter. - * - * This {@link DataProvider} is mainly meant for use for command line driven - * applications. - * - * @author Adam Gibson - */ -public class DataSetIteratorFactoryProvider implements DataProvider { - - public final static String FACTORY_KEY = "org.deeplearning4j.arbiter.data.data.factory"; - - /** - * Get training data given some parameters for the data. - * Data parameters map is used to specify things like batch - * size data preprocessing - * - * @param dataParameters Parameters for data. May be null or empty for default data - * @return training data - */ - @Override - public DataSetIteratorFactory trainData(Map dataParameters) { - return create(dataParameters); - } - - /** - * Get training data given some parameters for the data. Data parameters map - * is used to specify things like batch - * size data preprocessing - * - * @param dataParameters Parameters for data. May be null or empty for default data - * @return training data - */ - @Override - public DataSetIteratorFactory testData(Map dataParameters) { - return create(dataParameters); - } - - @Override - public Class getDataType() { - return DataSetIteratorFactory.class; - } - - private DataSetIteratorFactory create(Map dataParameters) { - if (!dataParameters.containsKey(FACTORY_KEY)) - throw new IllegalArgumentException( - "No data set iterator factory class found. Please specify a class name with key " - + FACTORY_KEY); - String value = dataParameters.get(FACTORY_KEY).toString(); - try { - Class clazz = - (Class) Class.forName(value); - return clazz.newInstance(); - } catch (Exception e) { - throw new RuntimeException("Could not create DataSetIteratorFactory instance - missing no-arg constructor?", e); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/data/MnistDataProvider.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/data/MnistDataProvider.java deleted file mode 100644 index c42837896..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/data/MnistDataProvider.java +++ /dev/null @@ -1,80 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.data; - -import lombok.Data; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.datasets.iterator.impl.MnistDataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.MultipleEpochsIterator; -import com.fasterxml.jackson.annotation.JsonProperty; - -import java.io.IOException; -import java.util.Map; -import java.util.Random; - -/** - * - * MnistDataProvider - a DataProvider for the MNIST data set, with configurable number of epochs, batch size - * and RNG seed - * - * @author Alex Black - */ -@Data -@NoArgsConstructor -public class MnistDataProvider implements DataProvider{ - - private int numEpochs; - private int batchSize; - private int rngSeed; - - public MnistDataProvider(int numEpochs, int batchSize){ - this(numEpochs, batchSize, new Random().nextInt()); - } - - public MnistDataProvider(@JsonProperty("numEpochs") int numEpochs, @JsonProperty("batchSize") int batchSize, - @JsonProperty("rngSeed") int rngSeed) { - this.numEpochs = numEpochs; - this.batchSize = batchSize; - this.rngSeed = rngSeed; - } - - - @Override - public Object trainData(Map dataParameters) { - try { - return new MultipleEpochsIterator(numEpochs, new MnistDataSetIterator(batchSize, true, rngSeed)); - } catch (IOException e) { - throw new RuntimeException(e); - } - } - - @Override - public Object testData(Map dataParameters) { - try { - return new MnistDataSetIterator(batchSize, false, 12345); - } catch (IOException e) { - throw new RuntimeException(e); - } - } - - @Override - public Class getDataType() { - return DataSetIterator.class; - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/dropout/AlphaDropoutSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/dropout/AlphaDropoutSpace.java deleted file mode 100644 index f4e3801f5..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/dropout/AlphaDropoutSpace.java +++ /dev/null @@ -1,67 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.dropout; - -import lombok.AllArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.nn.conf.dropout.AlphaDropout; -import org.deeplearning4j.nn.conf.dropout.IDropout; - -import java.util.Collections; -import java.util.List; -import java.util.Map; - -@AllArgsConstructor -public class AlphaDropoutSpace implements ParameterSpace { - - private ParameterSpace dropout; - - public AlphaDropoutSpace(double activationRetainProbability){ - this(new FixedValue<>(activationRetainProbability)); - } - - @Override - public IDropout getValue(double[] parameterValues) { - return new AlphaDropout(dropout.getValue(parameterValues)); - } - - @Override - public int numParameters() { - return dropout.numParameters(); - } - - @Override - public List collectLeaves() { - return Collections.singletonList(dropout); - } - - @Override - public Map getNestedSpaces() { - return Collections.singletonMap("dropout", dropout); - } - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices) { - dropout.setIndices(indices); - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/dropout/DropoutSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/dropout/DropoutSpace.java deleted file mode 100644 index 52dea3155..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/dropout/DropoutSpace.java +++ /dev/null @@ -1,67 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.dropout; - -import lombok.AllArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.nn.conf.dropout.Dropout; -import org.deeplearning4j.nn.conf.dropout.IDropout; - -import java.util.Collections; -import java.util.List; -import java.util.Map; - -@AllArgsConstructor -public class DropoutSpace implements ParameterSpace { - - private ParameterSpace dropout; - - public DropoutSpace(double activationRetainProbability){ - this(new FixedValue<>(activationRetainProbability)); - } - - @Override - public IDropout getValue(double[] parameterValues) { - return new Dropout(dropout.getValue(parameterValues)); - } - - @Override - public int numParameters() { - return dropout.numParameters(); - } - - @Override - public List collectLeaves() { - return Collections.singletonList(dropout); - } - - @Override - public Map getNestedSpaces() { - return Collections.singletonMap("dropout", dropout); - } - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices) { - dropout.setIndices(indices); - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/dropout/GaussianDropoutSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/dropout/GaussianDropoutSpace.java deleted file mode 100644 index 0cb345f40..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/dropout/GaussianDropoutSpace.java +++ /dev/null @@ -1,68 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.dropout; - -import lombok.AllArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.nn.conf.dropout.Dropout; -import org.deeplearning4j.nn.conf.dropout.GaussianDropout; -import org.deeplearning4j.nn.conf.dropout.IDropout; - -import java.util.Collections; -import java.util.List; -import java.util.Map; - -@AllArgsConstructor -public class GaussianDropoutSpace implements ParameterSpace { - - private ParameterSpace rate; - - public GaussianDropoutSpace(double rate){ - this(new FixedValue<>(rate)); - } - - @Override - public IDropout getValue(double[] parameterValues) { - return new GaussianDropout(rate.getValue(parameterValues)); - } - - @Override - public int numParameters() { - return rate.numParameters(); - } - - @Override - public List collectLeaves() { - return Collections.singletonList(rate); - } - - @Override - public Map getNestedSpaces() { - return Collections.singletonMap("rate", rate); - } - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices) { - rate.setIndices(indices); - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/dropout/GaussianNoiseSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/dropout/GaussianNoiseSpace.java deleted file mode 100644 index 706d389ee..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/dropout/GaussianNoiseSpace.java +++ /dev/null @@ -1,67 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.dropout; - -import lombok.AllArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.nn.conf.dropout.GaussianNoise; -import org.deeplearning4j.nn.conf.dropout.IDropout; - -import java.util.Collections; -import java.util.List; -import java.util.Map; - -@AllArgsConstructor -public class GaussianNoiseSpace implements ParameterSpace { - - private ParameterSpace stddev; - - public GaussianNoiseSpace(double stddev){ - this(new FixedValue<>(stddev)); - } - - @Override - public IDropout getValue(double[] parameterValues) { - return new GaussianNoise(stddev.getValue(parameterValues)); - } - - @Override - public int numParameters() { - return stddev.numParameters(); - } - - @Override - public List collectLeaves() { - return Collections.singletonList(stddev); - } - - @Override - public Map getNestedSpaces() { - return Collections.singletonMap("stddev", stddev); - } - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices) { - stddev.setIndices(indices); - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/evaluator/multilayer/ClassificationEvaluator.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/evaluator/multilayer/ClassificationEvaluator.java deleted file mode 100644 index 3d13ea2f1..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/evaluator/multilayer/ClassificationEvaluator.java +++ /dev/null @@ -1,68 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.evaluator.multilayer; - -import lombok.AllArgsConstructor; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.evaluation.ModelEvaluator; -import org.deeplearning4j.arbiter.scoring.util.ScoreUtil; -import org.deeplearning4j.eval.Evaluation; -import org.deeplearning4j.nn.graph.ComputationGraph; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator; - -import java.util.Arrays; -import java.util.List; -import java.util.Map; - -/** - * A model evaluator for doing additional - * evaluation (classification evaluation) - * for a {@link MultiLayerNetwork} given a {@link DataSetIterator} - * - * @author Alex Black - */ -@NoArgsConstructor -@AllArgsConstructor -public class ClassificationEvaluator implements ModelEvaluator { - private Map params = null; - - - @Override - public Evaluation evaluateModel(Object model, DataProvider dataProvider) { - - if (model instanceof MultiLayerNetwork) { - DataSetIterator iterator = ScoreUtil.getIterator(dataProvider.testData(params)); - return ScoreUtil.getEvaluation((MultiLayerNetwork) model, iterator); - } else { - DataSetIterator iterator = ScoreUtil.getIterator(dataProvider.testData(params)); - return ScoreUtil.getEvaluation((ComputationGraph) model, iterator); - } - } - - @Override - public List> getSupportedModelTypes() { - return Arrays.>asList(MultiLayerNetwork.class, ComputationGraph.class); - } - - @Override - public List> getSupportedDataTypes() { - return Arrays.>asList(DataSetIterator.class, MultiDataSetIterator.class); - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/evaluator/multilayer/RegressionDataEvaluator.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/evaluator/multilayer/RegressionDataEvaluator.java deleted file mode 100644 index 7973b11e0..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/evaluator/multilayer/RegressionDataEvaluator.java +++ /dev/null @@ -1,62 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.evaluator.multilayer; - -import lombok.AllArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.evaluation.ModelEvaluator; -import org.deeplearning4j.arbiter.scoring.RegressionValue; -import org.deeplearning4j.arbiter.scoring.util.ScoreUtil; -import org.deeplearning4j.nn.graph.ComputationGraph; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator; - -import java.util.Arrays; -import java.util.List; -import java.util.Map; - -/** - * Created by agibsonccc on 3/12/17. - */ -@AllArgsConstructor -public class RegressionDataEvaluator implements ModelEvaluator { - private RegressionValue regressionValue; - private Map params = null; - - @Override - public Double evaluateModel(Object model, DataProvider dataProvider) { - - if (model instanceof MultiLayerNetwork) { - DataSetIterator iterator = ScoreUtil.getIterator(dataProvider.testData(params)); - return ScoreUtil.score((MultiLayerNetwork) model, iterator, regressionValue); - } else { - DataSetIterator iterator = ScoreUtil.getIterator(dataProvider.testData(params)); - return ScoreUtil.score((ComputationGraph) model, iterator, regressionValue); - } - } - - @Override - public List> getSupportedModelTypes() { - return Arrays.>asList(MultiLayerNetwork.class, ComputationGraph.class); - } - - @Override - public List> getSupportedDataTypes() { - return Arrays.>asList(DataSetIterator.class, MultiDataSetIterator.class); - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/AbstractLSTMLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/AbstractLSTMLayerSpace.java deleted file mode 100644 index 7cad81a82..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/AbstractLSTMLayerSpace.java +++ /dev/null @@ -1,108 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.adapter.ActivationParameterSpaceAdapter; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.layers.AbstractLSTM; -import org.deeplearning4j.nn.conf.layers.GravesLSTM; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.activations.IActivation; - -/** - * Layer space for LSTM layers - * - * @author Alex Black - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PROTECTED) //For Jackson JSON/YAML deserialization -public abstract class AbstractLSTMLayerSpace extends FeedForwardLayerSpace { - - protected ParameterSpace forgetGateBiasInit; - protected ParameterSpace gateActivationFn; - - protected AbstractLSTMLayerSpace(Builder builder) { - super(builder); - this.forgetGateBiasInit = builder.forgetGateBiasInit; - this.gateActivationFn = builder.gateActivationFn; - - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - protected void setLayerOptionsBuilder(AbstractLSTM.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - if (forgetGateBiasInit != null) - builder.forgetGateBiasInit(forgetGateBiasInit.getValue(values)); - if(gateActivationFn != null) - builder.gateActivationFunction(gateActivationFn.getValue(values)); - } - - @Override - public String toString() { - return toString(", "); - } - - @Override - public String toString(String delim) { - StringBuilder sb = new StringBuilder(); //"AbstractLSTMLayerSpace("); - if (forgetGateBiasInit != null) - sb.append("forgetGateBiasInit: ").append(forgetGateBiasInit).append(delim); - if (gateActivationFn != null) - sb.append("gateActivationFn: ").append(gateActivationFn).append(delim); - sb.append(super.toString(delim)); - return sb.toString(); - } - - public static abstract class Builder extends FeedForwardLayerSpace.Builder { - - private ParameterSpace forgetGateBiasInit; - private ParameterSpace gateActivationFn; - - public T forgetGateBiasInit(double forgetGateBiasInit) { - return forgetGateBiasInit(new FixedValue<>(forgetGateBiasInit)); - } - - public T forgetGateBiasInit(ParameterSpace forgetGateBiasInit) { - this.forgetGateBiasInit = forgetGateBiasInit; - return (T)this; - } - - public T gateActivationFn(Activation activation){ - return gateActivationFn(activation.getActivationFunction()); - } - - public T gateActivation(ParameterSpace gateActivationFn){ - return gateActivationFn(new ActivationParameterSpaceAdapter(gateActivationFn)); - } - - public T gateActivationFn(IActivation gateActivationFn){ - return gateActivationFn(new FixedValue<>(gateActivationFn)); - } - - public T gateActivationFn(ParameterSpace gateActivationFn){ - this.gateActivationFn = gateActivationFn; - return (T)this; - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/ActivationLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/ActivationLayerSpace.java deleted file mode 100644 index 1d45d23c8..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/ActivationLayerSpace.java +++ /dev/null @@ -1,94 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.adapter.ActivationParameterSpaceAdapter; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.layers.ActivationLayer; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.activations.IActivation; - -/** - * Layer space for {@link ActivationLayer} - * - * @author Alex Black - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PRIVATE) //For Jackson JSON/YAML deserialization -public class ActivationLayerSpace extends LayerSpace { - - private ParameterSpace activationFunction; - - protected ActivationLayerSpace(Builder builder) { - super(builder); - this.activationFunction = builder.activationFunction; - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - - @Override - public ActivationLayer getValue(double[] parameterValues) { - ActivationLayer.Builder b = new ActivationLayer.Builder(); - super.setLayerOptionsBuilder(b, parameterValues); - b.activation(activationFunction.getValue(parameterValues)); - return b.build(); - } - - public static class Builder extends LayerSpace.Builder { - - private ParameterSpace activationFunction; - - public Builder activation(Activation activation) { - return activation(new FixedValue<>(activation)); - } - - public Builder activation(IActivation iActivation) { - return activationFn(new FixedValue<>(iActivation)); - } - - public Builder activation(ParameterSpace activationFunction) { - return activationFn(new ActivationParameterSpaceAdapter(activationFunction)); - } - - public Builder activationFn(ParameterSpace activationFunction) { - this.activationFunction = activationFunction; - return this; - } - - @SuppressWarnings("unchecked") - public ActivationLayerSpace build() { - return new ActivationLayerSpace(this); - } - } - - @Override - public String toString() { - return toString(", "); - } - - @Override - public String toString(String delim) { - return "ActivationLayerSpace(" + super.toString(delim) + ")"; - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/AutoEncoderLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/AutoEncoderLayerSpace.java deleted file mode 100644 index a429a2c96..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/AutoEncoderLayerSpace.java +++ /dev/null @@ -1,107 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.layers.AutoEncoder; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** - * Layer space for autoencoder layers - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PRIVATE) //For Jackson JSON/YAML deserialization -public class AutoEncoderLayerSpace extends BasePretrainNetworkLayerSpace { - @JsonProperty - private ParameterSpace corruptionLevel; - @JsonProperty - private ParameterSpace sparsity; - - private AutoEncoderLayerSpace(Builder builder) { - super(builder); - this.corruptionLevel = builder.corruptionLevel; - this.sparsity = builder.sparsity; - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - @Override - public AutoEncoder getValue(double[] values) { - AutoEncoder.Builder b = new AutoEncoder.Builder(); - setLayerOptionsBuilder(b, values); - return b.build(); - } - - protected void setLayerOptionsBuilder(AutoEncoder.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - if (corruptionLevel != null) - builder.corruptionLevel(corruptionLevel.getValue(values)); - if (sparsity != null) - builder.sparsity(sparsity.getValue(values)); - } - - @Override - public String toString() { - return toString(", "); - } - - @Override - public String toString(String delim) { - StringBuilder sb = new StringBuilder("AutoEncoderLayerSpace("); - if (corruptionLevel != null) - sb.append("corruptionLevel: ").append(corruptionLevel).append(delim); - if (sparsity != null) - sb.append("sparsity: ").append(sparsity).append(delim); - sb.append(super.toString(delim)).append(")"); - return sb.toString(); - } - - public static class Builder extends BasePretrainNetworkLayerSpace.Builder { - - private ParameterSpace corruptionLevel; - private ParameterSpace sparsity; - - public Builder corruptionLevel(double corruptionLevel) { - return corruptionLevel(new FixedValue<>(corruptionLevel)); - } - - public Builder corruptionLevel(ParameterSpace corruptionLevel) { - this.corruptionLevel = corruptionLevel; - return this; - } - - public Builder sparsity(double sparsity) { - return sparsity(new FixedValue<>(sparsity)); - } - - public Builder sparsity(ParameterSpace sparsity) { - this.sparsity = sparsity; - return this; - } - - public AutoEncoderLayerSpace build() { - return new AutoEncoderLayerSpace(this); - } - - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BaseConvolutionLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BaseConvolutionLayerSpace.java deleted file mode 100644 index 11bf1f274..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BaseConvolutionLayerSpace.java +++ /dev/null @@ -1,162 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.ConvolutionMode; -import org.deeplearning4j.nn.conf.layers.ConvolutionLayer; -import org.deeplearning4j.nn.conf.layers.FeedForwardLayer; - -/** - * Layer space for convolutional layers - * - * @author Alex Black - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PROTECTED) //For Jackson JSON/YAML deserialization -public abstract class BaseConvolutionLayerSpace extends FeedForwardLayerSpace { - protected ParameterSpace dilation; - protected ParameterSpace kernelSize; - protected ParameterSpace stride; - protected ParameterSpace padding; - protected ParameterSpace convolutionMode; - protected ParameterSpace hasBias; - - protected BaseConvolutionLayerSpace(Builder builder) { - super(builder); - this.dilation = builder.dilation; - this.kernelSize = builder.kernelSize; - this.stride = builder.stride; - this.padding = builder.padding; - this.convolutionMode = builder.convolutionMode; - this.hasBias = builder.hasBias; - - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - protected void setLayerOptionsBuilder(ConvolutionLayer.BaseConvBuilder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - if (dilation != null) - builder.dilation(dilation.getValue(values)); - if (kernelSize != null) - builder.kernelSize(kernelSize.getValue(values)); - if (stride != null) - builder.stride(stride.getValue(values)); - if (padding != null) - builder.padding(padding.getValue(values)); - if (convolutionMode != null) - builder.convolutionMode(convolutionMode.getValue(values)); - if (hasBias != null) - builder.hasBias(hasBias.getValue(values)); - } - - @Override - public String toString() { - return toString(", "); - } - - @Override - public String toString(String delim) { - StringBuilder sb = new StringBuilder(); - if (dilation != null) - sb.append("dilation: ").append(dilation).append(delim); - if (kernelSize != null) - sb.append("kernelSize: ").append(kernelSize).append(delim); - if (stride != null) - sb.append("stride: ").append(stride).append(delim); - if (padding != null) - sb.append("padding: ").append(padding).append(delim); - if (convolutionMode != null) - sb.append("convolutionMode: ").append(convolutionMode).append(delim); - if (hasBias != null) - sb.append("hasBias: ").append(hasBias).append(delim); - sb.append(super.toString(delim)); - return sb.toString(); - } - - - public static abstract class Builder extends FeedForwardLayerSpace.Builder { - protected ParameterSpace dilation; - protected ParameterSpace kernelSize; - protected ParameterSpace stride; - protected ParameterSpace padding; - protected ParameterSpace convolutionMode; - protected ParameterSpace hasBias; - - public T dilation(int... dilation) { - return dilation(new FixedValue<>(dilation)); - } - - public T dilation(ParameterSpace dilation) { - this.dilation = dilation; - return (T) this; - } - public T kernelSize(int... kernelSize) { - return kernelSize(new FixedValue<>(kernelSize)); - } - - public T kernelSize(ParameterSpace kernelSize) { - this.kernelSize = kernelSize; - return (T)this; - } - - public T stride(int... stride) { - return stride(new FixedValue<>(stride)); - } - - public T stride(ParameterSpace stride) { - this.stride = stride; - return (T)this; - } - - public T padding(int... padding) { - return padding(new FixedValue<>(padding)); - } - - public T padding(ParameterSpace padding) { - this.padding = padding; - return (T)this; - } - - public T convolutionMode(ConvolutionMode convolutionMode) { - return convolutionMode(new FixedValue<>(convolutionMode)); - } - - public T convolutionMode(ParameterSpace convolutionMode) { - this.convolutionMode = convolutionMode; - return (T)this; - } - - public T hasBias(boolean hasBias){ - return hasBias(new FixedValue<>(hasBias)); - } - - public T hasBias(ParameterSpace hasBias){ - this.hasBias = hasBias; - return (T)this; - } - - } - -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BaseLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BaseLayerSpace.java deleted file mode 100644 index 255e76be5..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BaseLayerSpace.java +++ /dev/null @@ -1,292 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import com.google.common.base.Preconditions; -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.adapter.ActivationParameterSpaceAdapter; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.optimize.parameter.discrete.DiscreteParameterSpace; -import org.deeplearning4j.nn.conf.GradientNormalization; -import org.deeplearning4j.nn.conf.Updater; -import org.deeplearning4j.nn.conf.distribution.Distribution; -import org.deeplearning4j.nn.conf.layers.BaseLayer; -import org.deeplearning4j.nn.conf.weightnoise.IWeightNoise; -import org.deeplearning4j.nn.weights.WeightInit; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.activations.IActivation; -import org.nd4j.linalg.learning.config.IUpdater; -import com.fasterxml.jackson.annotation.JsonInclude; - -import java.util.Map; - -/** - * BaseLayerSpace contains the common Layer hyperparameters; should match {@link BaseLayer} in terms of features - * - * @author Alex Black - */ -@JsonInclude(JsonInclude.Include.NON_NULL) - -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PROTECTED) //For Jackson JSON/YAML deserialization -public abstract class BaseLayerSpace extends LayerSpace { - protected ParameterSpace activationFunction; - protected ParameterSpace weightInit; - protected ParameterSpace biasInit; - protected ParameterSpace dist; - protected ParameterSpace l1; - protected ParameterSpace l2; - protected ParameterSpace l1Bias; - protected ParameterSpace l2Bias; - protected ParameterSpace updater; - protected ParameterSpace biasUpdater; - protected ParameterSpace weightNoise; - protected ParameterSpace gradientNormalization; - protected ParameterSpace gradientNormalizationThreshold; - protected int numParameters; - - @SuppressWarnings("unchecked") - protected BaseLayerSpace(Builder builder) { - super(builder); - this.activationFunction = builder.activationFunction; - this.weightInit = builder.weightInit; - this.biasInit = builder.biasInit; - this.dist = builder.dist; - this.l1 = builder.l1; - this.l2 = builder.l2; - this.l1Bias = builder.l1Bias; - this.l2Bias = builder.l2Bias; - this.updater = builder.updater; - this.biasUpdater = builder.biasUpdater; - this.weightNoise = builder.weightNoise; - this.gradientNormalization = builder.gradientNormalization; - this.gradientNormalizationThreshold = builder.gradientNormalizationThreshold; - } - - @Override - public int numParameters() { - return numParameters; - } - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices) { - throw new UnsupportedOperationException("Cannot set indices for non-leaf parameter space"); - } - - - protected void setLayerOptionsBuilder(BaseLayer.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - if (activationFunction != null) - builder.activation(activationFunction.getValue(values)); - if (biasInit != null) - builder.biasInit(biasInit.getValue(values)); - if (weightInit != null) - builder.weightInit(weightInit.getValue(values)); - if (dist != null) - builder.dist(dist.getValue(values)); - if (l1 != null) - builder.l1(l1.getValue(values)); - if (l2 != null) - builder.l2(l2.getValue(values)); - if (l1Bias != null) - builder.l1Bias(l1Bias.getValue(values)); - if (l2Bias != null) - builder.l2Bias(l2Bias.getValue(values)); - if (updater != null) - builder.updater(updater.getValue(values)); - if (biasUpdater != null) - builder.biasUpdater(biasUpdater.getValue(values)); - if (weightNoise != null) - builder.weightNoise(weightNoise.getValue(values)); - if (gradientNormalization != null) - builder.gradientNormalization(gradientNormalization.getValue(values)); - if (gradientNormalizationThreshold != null) - builder.gradientNormalizationThreshold(gradientNormalizationThreshold.getValue(values)); - } - - - @Override - public String toString() { - return toString(", "); - } - - protected String toString(String delim) { - StringBuilder sb = new StringBuilder(); - - for (Map.Entry e : getNestedSpaces().entrySet()) { - sb.append(e.getKey()).append(": ").append(e.getValue()).append("\n"); - } - return sb.toString(); - } - - @SuppressWarnings("unchecked") - public abstract static class Builder extends LayerSpace.Builder { - protected ParameterSpace activationFunction; - protected ParameterSpace weightInit; - protected ParameterSpace biasInit; - protected ParameterSpace dist; - protected ParameterSpace l1; - protected ParameterSpace l2; - protected ParameterSpace l1Bias; - protected ParameterSpace l2Bias; - protected ParameterSpace updater; - protected ParameterSpace biasUpdater; - protected ParameterSpace weightNoise; - protected ParameterSpace gradientNormalization; - protected ParameterSpace gradientNormalizationThreshold; - - public T activation(Activation... activations){ - Preconditions.checkArgument(activations.length > 0, "Activations length must be 1 or more"); - if(activations.length == 1){ - return activation(activations[0]); - } - return activation(new DiscreteParameterSpace<>(activations)); - } - - public T activation(Activation activation) { - return activation(new FixedValue<>(activation)); - } - - public T activation(IActivation iActivation) { - return activationFn(new FixedValue<>(iActivation)); - } - - public T activation(ParameterSpace activationFunction) { - return activationFn(new ActivationParameterSpaceAdapter(activationFunction)); - } - - public T activationFn(ParameterSpace activationFunction) { - this.activationFunction = activationFunction; - return (T) this; - } - - public T weightInit(WeightInit weightInit) { - return (T) weightInit(new FixedValue(weightInit)); - } - - public T weightInit(ParameterSpace weightInit) { - this.weightInit = weightInit; - return (T) this; - } - - public T weightInit(Distribution distribution){ - weightInit(WeightInit.DISTRIBUTION); - return dist(distribution); - } - - public T biasInit(double biasInit){ - return biasInit(new FixedValue<>(biasInit)); - } - - public T biasInit(ParameterSpace biasInit){ - this.biasInit = biasInit; - return (T) this; - } - - public T dist(Distribution dist) { - return dist(new FixedValue<>(dist)); - } - - public T dist(ParameterSpace dist) { - this.dist = dist; - return (T) this; - } - - public T l1(double l1) { - return l1(new FixedValue(l1)); - } - - public T l1(ParameterSpace l1) { - this.l1 = l1; - return (T) this; - } - - public T l2(double l2) { - return l2(new FixedValue(l2)); - } - - public T l2(ParameterSpace l2) { - this.l2 = l2; - return (T) this; - } - - public T l1Bias(double l1Bias) { - return l1Bias(new FixedValue(l1Bias)); - } - - public T l1Bias(ParameterSpace l1Bias) { - this.l1Bias = l1Bias; - return (T) this; - } - - public T l2Bias(double l2Bias) { - return l2Bias(new FixedValue<>(l2Bias)); - } - - public T l2Bias(ParameterSpace l2Bias) { - this.l2Bias = l2Bias; - return (T) this; - } - - public T updater(IUpdater updater) { - return updater(new FixedValue<>(updater)); - } - - public T updater(ParameterSpace updater) { - this.updater = updater; - return (T) this; - } - - public T biasUpdater(IUpdater biasUpdater) { - return biasUpdater(new FixedValue<>(biasUpdater)); - } - - public T biasUpdater(ParameterSpace biasUpdater) { - this.biasUpdater = biasUpdater; - return (T) this; - } - - public T gradientNormalization(GradientNormalization gradientNormalization) { - return gradientNormalization(new FixedValue(gradientNormalization)); - } - - public T gradientNormalization(ParameterSpace gradientNormalization) { - this.gradientNormalization = gradientNormalization; - return (T) this; - } - - public T gradientNormalizationThreshold(double threshold) { - return gradientNormalizationThreshold(new FixedValue<>(threshold)); - } - - public T gradientNormalizationThreshold(ParameterSpace gradientNormalizationThreshold) { - this.gradientNormalizationThreshold = gradientNormalizationThreshold; - return (T) this; - } - } - -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BaseOutputLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BaseOutputLayerSpace.java deleted file mode 100644 index 857f729ad..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BaseOutputLayerSpace.java +++ /dev/null @@ -1,87 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.adapter.LossFunctionParameterSpaceAdapter; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.nn.conf.layers.BaseOutputLayer; -import org.nd4j.linalg.lossfunctions.ILossFunction; -import org.nd4j.linalg.lossfunctions.LossFunctions.LossFunction; - -/** - * @param Type of the (concrete) output layer - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PUBLIC) //For Jackson JSON/YAML deserialization -public abstract class BaseOutputLayerSpace extends FeedForwardLayerSpace { - - protected ParameterSpace lossFunction; - protected ParameterSpace hasBias; - - protected BaseOutputLayerSpace(Builder builder) { - super(builder); - this.lossFunction = builder.lossFunction; - this.hasBias = builder.hasBias; - } - - protected void setLayerOptionsBuilder(BaseOutputLayer.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - if (lossFunction != null) - builder.lossFunction(lossFunction.getValue(values)); - if (hasBias != null) - builder.hasBias(hasBias.getValue(values)); - } - - @SuppressWarnings("unchecked") - public static abstract class Builder extends FeedForwardLayerSpace.Builder { - - protected ParameterSpace lossFunction; - protected ParameterSpace hasBias; - - public T lossFunction(LossFunction lossFunction) { - return lossFunction(new FixedValue<>(lossFunction)); - } - - public T lossFunction(ParameterSpace lossFunction) { - return iLossFunction(new LossFunctionParameterSpaceAdapter(lossFunction)); - } - - public T iLossFunction(ILossFunction lossFunction) { - return iLossFunction(new FixedValue<>(lossFunction)); - } - - public T iLossFunction(ParameterSpace lossFunction) { - this.lossFunction = lossFunction; - return (T) this; - } - - public T hasBias(boolean hasBias){ - return hasBias(new FixedValue<>(hasBias)); - } - - public T hasBias(ParameterSpace hasBias){ - this.hasBias = hasBias; - return (T)this; - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BasePretrainNetworkLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BasePretrainNetworkLayerSpace.java deleted file mode 100644 index 9f554911b..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BasePretrainNetworkLayerSpace.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.nn.conf.layers.BasePretrainNetwork; -import org.nd4j.linalg.lossfunctions.LossFunctions.LossFunction; -import com.fasterxml.jackson.annotation.JsonProperty; - - -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PROTECTED) //For Jackson JSON/YAML deserialization -public abstract class BasePretrainNetworkLayerSpace extends FeedForwardLayerSpace { - @JsonProperty - protected ParameterSpace lossFunction; - - protected BasePretrainNetworkLayerSpace(Builder builder) { - super(builder); - this.lossFunction = builder.lossFunction; - } - - - public static abstract class Builder extends FeedForwardLayerSpace.Builder { - protected ParameterSpace lossFunction; - - public T lossFunction(LossFunction lossFunction) { - return lossFunction(new FixedValue(lossFunction)); - } - - public T lossFunction(ParameterSpace lossFunction) { - this.lossFunction = lossFunction; - return (T) this; - } - - } - -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BatchNormalizationSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BatchNormalizationSpace.java deleted file mode 100644 index 9b55555ed..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/BatchNormalizationSpace.java +++ /dev/null @@ -1,214 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.api.layers.LayerConstraint; -import org.deeplearning4j.nn.conf.layers.BatchNormalization; - -import java.util.Arrays; -import java.util.List; - -/** - * LayerSpace for batch normalization layers - * - * @author Alex Black - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PRIVATE) //For Jackson JSON/YAML deserialization -public class BatchNormalizationSpace extends FeedForwardLayerSpace { - - protected ParameterSpace decay; - protected ParameterSpace eps; - protected ParameterSpace isMinibatch; - protected ParameterSpace lockGammaBeta; - protected ParameterSpace gamma; - protected ParameterSpace beta; - protected ParameterSpace> constrainBeta; - protected ParameterSpace> constrainGamma; - - private BatchNormalizationSpace(Builder builder) { - super(builder); - this.decay = builder.decay; - this.eps = builder.eps; - this.isMinibatch = builder.isMinibatch; - this.lockGammaBeta = builder.lockGammaBeta; - this.gamma = builder.gamma; - this.beta = builder.beta; - this.constrainBeta = builder.betaConstraints; - this.constrainGamma = builder.gammaConstraints; - - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - @Override - public BatchNormalization getValue(double[] parameterValues) { - BatchNormalization.Builder b = new BatchNormalization.Builder(); - setLayerOptionsBuilder(b, parameterValues); - return b.build(); - } - - protected void setLayerOptionsBuilder(BatchNormalization.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - if (decay != null) - builder.decay(decay.getValue(values)); - if (eps != null) - builder.eps(eps.getValue(values)); - if (isMinibatch != null) - builder.minibatch(isMinibatch.getValue(values)); - if (lockGammaBeta != null) - builder.lockGammaBeta(lockGammaBeta.getValue(values)); - if (gamma != null) - builder.gamma(gamma.getValue(values)); - if (beta != null) - builder.beta(beta.getValue(values)); - if (constrainBeta != null){ - List c = constrainBeta.getValue(values); - if(c != null){ - builder.constrainBeta(c.toArray(new LayerConstraint[c.size()])); - } - } - if (constrainGamma != null){ - List c = constrainGamma.getValue(values); - if(c != null){ - builder.constrainGamma(c.toArray(new LayerConstraint[c.size()])); - } - } - } - - @Override - public String toString() { - return toString(", "); - } - - @Override - public String toString(String delim) { - StringBuilder sb = new StringBuilder(); - sb.append("BatchNormalizationSpace(").append(super.toString(delim)); - if (decay != null) - sb.append("decay: ").append(decay).append(delim); - if (eps != null) - sb.append("eps: ").append(eps).append(delim); - if (isMinibatch != null) - sb.append("isMinibatch: ").append(isMinibatch).append(delim); - if (lockGammaBeta != null) - sb.append("lockGammaBeta: ").append(lockGammaBeta).append(delim); - if (gamma != null) - sb.append("gamma: ").append(gamma).append(delim); - if (beta != null) - sb.append("beta: ").append(beta).append(delim); - sb.append(")"); - return sb.toString(); - } - - public static class Builder extends FeedForwardLayerSpace.Builder { - - protected ParameterSpace decay; - protected ParameterSpace eps; - protected ParameterSpace isMinibatch; - protected ParameterSpace lockGammaBeta; - protected ParameterSpace gamma; - protected ParameterSpace beta; - protected ParameterSpace> betaConstraints; - protected ParameterSpace> gammaConstraints; - - public Builder minibatch(boolean minibatch) { - return minibatch(new FixedValue<>(minibatch)); - } - - public Builder minibatch(ParameterSpace minibatch) { - this.isMinibatch = minibatch; - return this; - } - - public Builder gamma(double gamma) { - return gamma(new FixedValue<>(gamma)); - } - - public Builder gamma(ParameterSpace gamma) { - this.gamma = gamma; - return this; - } - - public Builder beta(double beta) { - return beta(new FixedValue<>(beta)); - } - - public Builder beta(ParameterSpace beta) { - this.beta = beta; - return this; - } - - public Builder eps(double eps) { - return eps(new FixedValue<>(eps)); - } - - public Builder eps(ParameterSpace eps) { - this.eps = eps; - return this; - } - - public Builder decay(double decay) { - return decay(new FixedValue(decay)); - } - - public Builder decay(ParameterSpace decay) { - this.decay = decay; - return this; - } - - public Builder lockGammaBeta(boolean lockGammaBeta) { - return lockGammaBeta(new FixedValue<>(lockGammaBeta)); - } - - public Builder lockGammaBeta(ParameterSpace lockGammaBeta) { - this.lockGammaBeta = lockGammaBeta; - return this; - } - - public Builder constrainBeta(LayerConstraint... constraints) { - return constrainBeta(new FixedValue<>(Arrays.asList(constraints))); - } - - public Builder constrainBeta(ParameterSpace> constraints) { - this.betaConstraints = constraints; - return this; - } - - public Builder constrainGamma(LayerConstraint... constraints) { - return constrainGamma(new FixedValue<>(Arrays.asList(constraints))); - } - - public Builder constrainGamma(ParameterSpace> constraints) { - this.gammaConstraints = constraints; - return this; - } - - - @Override - public BatchNormalizationSpace build() { - return new BatchNormalizationSpace(this); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/Bidirectional.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/Bidirectional.java deleted file mode 100644 index 64cdfd369..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/Bidirectional.java +++ /dev/null @@ -1,67 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.Data; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.nn.conf.layers.Layer; - -import java.util.List; - -/** - * Bidirectional layer wrapper. Can be used wrap an existing layer space, in the same way that - * {@link org.deeplearning4j.nn.conf.layers.recurrent.Bidirectional} wraps a DL4J layer - * - * @author Alex Black - */ -@NoArgsConstructor //JSON -@Data -public class Bidirectional extends LayerSpace { - - protected LayerSpace layerSpace; - - public Bidirectional(LayerSpace layerSpace){ - this.layerSpace = layerSpace; - } - - @Override - public Layer getValue(double[] parameterValues) { - Layer underlying = layerSpace.getValue(parameterValues); - return new org.deeplearning4j.nn.conf.layers.recurrent.Bidirectional(underlying); - } - - @Override - public int numParameters() { - return layerSpace.numParameters(); - } - - @Override - public List collectLeaves() { - return layerSpace.collectLeaves(); - } - - @Override - public boolean isLeaf() { - return layerSpace.isLeaf(); - } - - @Override - public void setIndices(int... indices) { - layerSpace.setIndices(indices); - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/CenterLossOutputLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/CenterLossOutputLayerSpace.java deleted file mode 100644 index ecba732c3..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/CenterLossOutputLayerSpace.java +++ /dev/null @@ -1,87 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.layers.CenterLossOutputLayer; - -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PROTECTED) //For Jackson JSON/YAML deserialization -public class CenterLossOutputLayerSpace extends BaseOutputLayerSpace { - - ParameterSpace alpha; - ParameterSpace lambda; - - protected CenterLossOutputLayerSpace(Builder builder){ - super(builder); - this.alpha = builder.alpha; - this.lambda = builder.lambda; - - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - @Override - public CenterLossOutputLayer getValue(double[] parameterValues) { - CenterLossOutputLayer.Builder b = new CenterLossOutputLayer.Builder(); - setLayerOptionsBuilder(b, parameterValues); - return b.build(); - } - - protected void setLayerBuilderOptions(CenterLossOutputLayer.Builder builder, double[] values){ - super.setLayerOptionsBuilder(builder, values); - if(alpha != null) - builder.alpha(alpha.getValue(values)); - if(lambda != null) - builder.lambda(lambda.getValue(values)); - } - - public static class Builder extends BaseOutputLayerSpace.Builder { - - ParameterSpace alpha; - ParameterSpace lambda; - - public Builder alpha(double alpha){ - return alpha(new FixedValue<>(alpha)); - } - - public Builder alpha(ParameterSpace alpha){ - this.alpha = alpha; - return this; - } - - public Builder lambda(double lambda){ - return lambda(new FixedValue<>(lambda)); - } - - public Builder lambda(ParameterSpace lambda){ - this.lambda = lambda; - return this; - } - - @Override - public CenterLossOutputLayerSpace build() { - return new CenterLossOutputLayerSpace(this); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/ConvolutionLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/ConvolutionLayerSpace.java deleted file mode 100644 index 110e5b6e7..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/ConvolutionLayerSpace.java +++ /dev/null @@ -1,172 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.ConvolutionMode; -import org.deeplearning4j.nn.conf.layers.ConvolutionLayer; - -/** - * Layer space for convolutional layers - * - * @author Alex Black - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PRIVATE) //For Jackson JSON/YAML deserialization -public class ConvolutionLayerSpace extends FeedForwardLayerSpace { - protected ParameterSpace dilation; - protected ParameterSpace kernelSize; - protected ParameterSpace stride; - protected ParameterSpace padding; - protected ParameterSpace convolutionMode; - protected ParameterSpace hasBias; - - private ConvolutionLayerSpace(Builder builder) { - super(builder); - this.dilation = builder.dilation; - this.kernelSize = builder.kernelSize; - this.stride = builder.stride; - this.padding = builder.padding; - this.convolutionMode = builder.convolutionMode; - this.hasBias = builder.hasBias; - - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - @Override - public ConvolutionLayer getValue(double[] values) { - ConvolutionLayer.Builder b = new ConvolutionLayer.Builder(); - setLayerOptionsBuilder(b, values); - return b.build(); - } - - protected void setLayerOptionsBuilder(ConvolutionLayer.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - if (dilation != null) - builder.dilation(dilation.getValue(values)); - if (kernelSize != null) - builder.kernelSize(kernelSize.getValue(values)); - if (stride != null) - builder.stride(stride.getValue(values)); - if (padding != null) - builder.padding(padding.getValue(values)); - if (convolutionMode != null) - builder.convolutionMode(convolutionMode.getValue(values)); - if (hasBias != null) - builder.hasBias(hasBias.getValue(values)); - } - - @Override - public String toString() { - return toString(", "); - } - - @Override - public String toString(String delim) { - StringBuilder sb = new StringBuilder("ConvolutionLayerSpace("); - if (dilation != null) - sb.append("dilation: ").append(dilation).append(delim); - if (kernelSize != null) - sb.append("kernelSize: ").append(kernelSize).append(delim); - if (stride != null) - sb.append("stride: ").append(stride).append(delim); - if (padding != null) - sb.append("padding: ").append(padding).append(delim); - if (convolutionMode != null) - sb.append("convolutionMode: ").append(convolutionMode).append(delim); - if (hasBias != null) - sb.append("hasBias: ").append(hasBias).append(delim); - sb.append(super.toString(delim)).append(")"); - return sb.toString(); - } - - - public static class Builder extends FeedForwardLayerSpace.Builder { - protected ParameterSpace dilation; - protected ParameterSpace kernelSize; - protected ParameterSpace stride; - protected ParameterSpace padding; - protected ParameterSpace convolutionMode; - protected ParameterSpace hasBias; - - public Builder dilation(int... dilation) { - return dilation(new FixedValue<>(dilation)); - } - - public Builder dilation(ParameterSpace dilation) { - this.dilation = dilation; - return this; - } - public Builder kernelSize(int... kernelSize) { - return kernelSize(new FixedValue<>(kernelSize)); - } - - public Builder kernelSize(ParameterSpace kernelSize) { - this.kernelSize = kernelSize; - return this; - } - - public Builder stride(int... stride) { - return stride(new FixedValue<>(stride)); - } - - public Builder stride(ParameterSpace stride) { - this.stride = stride; - return this; - } - - public Builder padding(int... padding) { - return padding(new FixedValue<>(padding)); - } - - public Builder padding(ParameterSpace padding) { - this.padding = padding; - return this; - } - - public Builder convolutionMode(ConvolutionMode convolutionMode) { - return convolutionMode(new FixedValue<>(convolutionMode)); - } - - public Builder convolutionMode(ParameterSpace convolutionMode) { - this.convolutionMode = convolutionMode; - return this; - } - - public Builder hasBias(boolean hasBias){ - return hasBias(new FixedValue<>(hasBias)); - } - - public Builder hasBias(ParameterSpace hasBias){ - this.hasBias = hasBias; - return this; - } - - public ConvolutionLayerSpace build() { - return new ConvolutionLayerSpace(this); - } - - } - -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/Deconvolution2DLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/Deconvolution2DLayerSpace.java deleted file mode 100644 index 72231f246..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/Deconvolution2DLayerSpace.java +++ /dev/null @@ -1,52 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.nn.conf.layers.Deconvolution2D; - -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PROTECTED) //For Jackson JSON/YAML deserialization -public class Deconvolution2DLayerSpace extends BaseConvolutionLayerSpace { - - protected Deconvolution2DLayerSpace(Builder builder) { - super(builder); - } - - @Override - public Deconvolution2D getValue(double[] parameterValues) { - Deconvolution2D.Builder b = new Deconvolution2D.Builder(); - setLayerOptionsBuilder(b, parameterValues); - return b.build(); - } - - protected void setLayerOptionsBuilder(Deconvolution2D.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - } - - public static class Builder extends BaseConvolutionLayerSpace.Builder { - @Override - public Deconvolution2DLayerSpace build() { - return new Deconvolution2DLayerSpace(this); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/DenseLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/DenseLayerSpace.java deleted file mode 100644 index 4a7ac3f28..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/DenseLayerSpace.java +++ /dev/null @@ -1,90 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.layers.DenseLayer; - -/** - * layer hyperparameter configuration space for dense layers (i.e., multi-layer perceptron layers) - * - * @author Alex Black - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor //For Jackson JSON/YAML deserialization -public class DenseLayerSpace extends FeedForwardLayerSpace { - - protected ParameterSpace hasBias; - - private DenseLayerSpace(Builder builder) { - super(builder); - - this.hasBias = builder.hasBias; - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - @Override - public DenseLayer getValue(double[] values) { - //Using the builder here, to get default options - DenseLayer.Builder b = new DenseLayer.Builder(); - setLayerOptionsBuilder(b, values); - return b.build(); - } - - protected void setLayerOptionsBuilder(DenseLayer.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - if(hasBias != null) - builder.hasBias(hasBias.getValue(values)); - } - - public static class Builder extends FeedForwardLayerSpace.Builder { - - protected ParameterSpace hasBias; - - public Builder hasBias(boolean hasBias){ - return hasBias(new FixedValue<>(hasBias)); - } - - public Builder hasBias(ParameterSpace hasBias){ - this.hasBias = hasBias; - return this; - } - - @Override - @SuppressWarnings("unchecked") - public DenseLayerSpace build() { - return new DenseLayerSpace(this); - } - } - - @Override - public String toString() { - return toString(", "); - } - - @Override - public String toString(String delim) { - return "DenseLayerSpace(" + super.toString(delim) + ")"; - } - -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/DropoutLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/DropoutLayerSpace.java deleted file mode 100644 index 1e6ca7157..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/DropoutLayerSpace.java +++ /dev/null @@ -1,89 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.*; -import org.deeplearning4j.arbiter.dropout.DropoutSpace; -import org.deeplearning4j.arbiter.optimize.api.AbstractParameterSpace; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.nn.conf.dropout.IDropout; -import org.deeplearning4j.nn.conf.layers.DropoutLayer; - -import java.util.Collections; -import java.util.List; - -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PROTECTED) //For Jackson JSON/YAML deserialization -public class DropoutLayerSpace extends LayerSpace { - - public DropoutLayerSpace(@NonNull ParameterSpace dropout){ - this.dropOut = dropout; - } - - protected DropoutLayerSpace(Builder builder){ - super(builder); - } - - @Override - public DropoutLayer getValue(double[] parameterValues) { - return new DropoutLayer.Builder().dropOut(dropOut.getValue(parameterValues)).build(); - } - - @Override - public int numParameters() { - return dropOut.numParameters(); - } - - @Override - public List collectLeaves() { - return dropOut.collectLeaves(); - } - - - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices) { - dropOut.setIndices(indices); - } - - public static class Builder extends LayerSpace.Builder { - - public Builder dropOut(double d){ - return iDropOut(new DropoutSpace(new FixedValue<>(d))); - } - - public Builder dropOut(ParameterSpace dropOut){ - return iDropOut(new DropoutSpace(dropOut)); - } - - public Builder iDropOut(ParameterSpace dropout){ - this.dropOut = dropout; - return this; - } - - public DropoutLayerSpace build(){ - return new DropoutLayerSpace(this); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/EmbeddingLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/EmbeddingLayerSpace.java deleted file mode 100644 index 7aa5c5444..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/EmbeddingLayerSpace.java +++ /dev/null @@ -1,88 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.layers.EmbeddingLayer; - -/** - * Layer hyperparameter configuration space for {@link org.deeplearning4j.nn.conf.layers.EmbeddingLayer} - * - * @author Alex Black - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PRIVATE) //For Jackson JSON/YAML deserialization -public class EmbeddingLayerSpace extends FeedForwardLayerSpace { - private ParameterSpace hasBias; - - private EmbeddingLayerSpace(Builder builder) { - super(builder); - this.hasBias = builder.hasBias; - - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - @Override - public EmbeddingLayer getValue(double[] values) { - //Using the builder here, to get default options - EmbeddingLayer.Builder b = new EmbeddingLayer.Builder(); - setLayerOptionsBuilder(b, values); - return b.build(); - } - - protected void setLayerOptionsBuilder(EmbeddingLayer.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - if(hasBias != null) - builder.hasBias(hasBias.getValue(values)); - } - - public static class Builder extends FeedForwardLayerSpace.Builder { - protected ParameterSpace hasBias; - - public Builder hasBias(boolean hasBias){ - return hasBias(new FixedValue<>(hasBias)); - } - - public Builder hasBias(ParameterSpace hasBias){ - this.hasBias = hasBias; - return this; - } - - @Override - @SuppressWarnings("unchecked") - public EmbeddingLayerSpace build() { - return new EmbeddingLayerSpace(this); - } - } - - @Override - public String toString() { - return toString(", "); - } - - @Override - public String toString(String delim) { - return "EmbeddingLayerSpace(" + super.toString(delim) + ")"; - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/FeedForwardLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/FeedForwardLayerSpace.java deleted file mode 100644 index 3ba0f3a06..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/FeedForwardLayerSpace.java +++ /dev/null @@ -1,154 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.nn.api.layers.LayerConstraint; -import org.deeplearning4j.nn.conf.layers.FeedForwardLayer; - -import java.util.Arrays; -import java.util.List; - -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor //For Jackson JSON/YAML deserialization -public abstract class FeedForwardLayerSpace extends BaseLayerSpace { - protected ParameterSpace nIn; - protected ParameterSpace nOut; - protected ParameterSpace> constrainWeights; - protected ParameterSpace> constrainBias; - protected ParameterSpace> constrainAll; - - - protected FeedForwardLayerSpace(Builder builder) { - super(builder); - nIn = builder.nIn; - nOut = builder.nOut; - constrainWeights = builder.constrainWeights; - constrainBias = builder.constrainBias; - constrainAll = builder.constrainAll; - } - - protected void setLayerOptionsBuilder(FeedForwardLayer.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - if (nIn != null) - builder.nIn(nIn.getValue(values)); - if (nOut != null) - builder.nOut(nOut.getValue(values)); - if (constrainWeights != null){ - List c = constrainWeights.getValue(values); - if(c != null){ - builder.constrainWeights(c.toArray(new LayerConstraint[c.size()])); - } - } - if (constrainBias != null){ - List c = constrainBias.getValue(values); - if(c != null){ - builder.constrainBias(c.toArray(new LayerConstraint[c.size()])); - } - } - if (constrainAll != null){ - List c = constrainAll.getValue(values); - if(c != null){ - builder.constrainAllParameters(c.toArray(new LayerConstraint[c.size()])); - } - } - - } - - - public abstract static class Builder extends BaseLayerSpace.Builder { - - protected ParameterSpace nIn; - protected ParameterSpace nOut; - protected ParameterSpace> constrainWeights; - protected ParameterSpace> constrainBias; - protected ParameterSpace> constrainAll; - - public T nIn(int nIn) { - return nIn(new FixedValue<>(nIn)); - } - - public T nIn(ParameterSpace nIn) { - this.nIn = nIn; - return (T) this; - } - - public T nOut(int nOut) { - return nOut(new FixedValue<>(nOut)); - } - - public T nOut(ParameterSpace nOut) { - this.nOut = nOut; - return (T) this; - } - - public T constrainWeights(LayerConstraint... constraints){ - return constrainWeights(new FixedValue>(Arrays.asList(constraints))); - } - - public T constrainWeights(ParameterSpace> constraints){ - this.constrainWeights = constraints; - return (T) this; - } - - public T constrainBias(LayerConstraint... constraints){ - return constrainBias(new FixedValue>(Arrays.asList(constraints))); - } - - public T constrainBias(ParameterSpace> constraints){ - this.constrainBias = constraints; - return (T) this; - } - - public T constrainAllParams(LayerConstraint... constraints){ - return constrainAllParams(new FixedValue>(Arrays.asList(constraints))); - } - - public T constrainAllParams(ParameterSpace> constraints){ - this.constrainAll = constraints; - return (T) this; - } - } - - @Override - public String toString() { - return toString(", "); - } - - @Override - protected String toString(String delim) { - StringBuilder sb = new StringBuilder(); - if (nIn != null) - sb.append("nIn: ").append(nIn).append(delim); - if (nOut != null) - sb.append("nOut: ").append(nOut).append(delim); - if (constrainWeights != null) - sb.append("constrainWeights: ").append(constrainWeights).append(delim); - if (constrainBias != null) - sb.append("constrainBias: ").append(constrainBias).append(delim); - if (constrainAll != null) - sb.append("constrainAllParams: ").append(constrainAll).append(delim); - sb.append(super.toString(delim)); - return sb.toString(); - } - -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/GlobalPoolingLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/GlobalPoolingLayerSpace.java deleted file mode 100644 index 17bd22103..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/GlobalPoolingLayerSpace.java +++ /dev/null @@ -1,135 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.layers.GlobalPoolingLayer; -import org.deeplearning4j.nn.conf.layers.PoolingType; - -/** - * Layer space for a {@link GlobalPoolingLayer} - * - * @author Alex Black - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PRIVATE) //For Jackson JSON/YAML deserialization -public class GlobalPoolingLayerSpace extends LayerSpace { - - protected ParameterSpace poolingDimensions; - protected ParameterSpace collapseDimensions; - protected ParameterSpace poolingType; - protected ParameterSpace pNorm; - - private int numParameters; - - private GlobalPoolingLayerSpace(Builder builder) { - super(builder); - this.poolingDimensions = builder.poolingDimensions; - this.collapseDimensions = builder.collapseDimensions; - this.poolingType = builder.poolingType; - this.pNorm = builder.pNorm; - - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - @Override - public GlobalPoolingLayer getValue(double[] parameterValues) { - GlobalPoolingLayer.Builder builder = new GlobalPoolingLayer.Builder(); - super.setLayerOptionsBuilder(builder, parameterValues); - if (poolingDimensions != null) - builder.poolingDimensions(poolingDimensions.getValue(parameterValues)); - if (collapseDimensions != null) - builder.collapseDimensions(collapseDimensions.getValue(parameterValues)); - if (poolingType != null) - builder.poolingType(poolingType.getValue(parameterValues)); - if (pNorm != null) - builder.pnorm(pNorm.getValue(parameterValues)); - return builder.build(); - } - - @Override - public int numParameters() { - return numParameters; - } - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices) { - throw new UnsupportedOperationException("Cannot set indices for non-leaf parameter space"); - } - - - - public static class Builder extends LayerSpace.Builder { - - protected ParameterSpace poolingDimensions; - protected ParameterSpace collapseDimensions; - protected ParameterSpace poolingType; - protected ParameterSpace pNorm; - - public Builder poolingDimensions(int... poolingDimensions) { - return poolingDimensions(new FixedValue<>(poolingDimensions)); - } - - public Builder poolingDimensions(ParameterSpace poolingDimensions) { - this.poolingDimensions = poolingDimensions; - return this; - } - - public Builder collapseDimensions(boolean collapseDimensions) { - return collapseDimensions(new FixedValue<>(collapseDimensions)); - } - - public Builder collapseDimensions(ParameterSpace collapseDimensions) { - this.collapseDimensions = collapseDimensions; - return this; - } - - public Builder poolingType(PoolingType poolingType) { - return poolingType(new FixedValue<>(poolingType)); - } - - public Builder poolingType(ParameterSpace poolingType) { - this.poolingType = poolingType; - return this; - } - - public Builder pNorm(int pNorm) { - return pNorm(new FixedValue<>(pNorm)); - } - - public Builder pNorm(ParameterSpace pNorm) { - this.pNorm = pNorm; - return this; - } - - public GlobalPoolingLayerSpace build() { - return new GlobalPoolingLayerSpace(this); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/GravesBidirectionalLSTMLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/GravesBidirectionalLSTMLayerSpace.java deleted file mode 100644 index e42deacbe..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/GravesBidirectionalLSTMLayerSpace.java +++ /dev/null @@ -1,97 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.layers.GravesBidirectionalLSTM; - -import java.util.List; - -/** - * Layer space for Bidirectional LSTM layers - * - * @author Alex Black - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PRIVATE) //For Jackson JSON/YAML deserialization -public class GravesBidirectionalLSTMLayerSpace extends FeedForwardLayerSpace { - - private ParameterSpace forgetGateBiasInit; - - private GravesBidirectionalLSTMLayerSpace(Builder builder) { - super(builder); - this.forgetGateBiasInit = builder.forgetGateBiasInit; - - List l = collectLeaves(); - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - - @Override - public GravesBidirectionalLSTM getValue(double[] values) { - GravesBidirectionalLSTM.Builder b = new GravesBidirectionalLSTM.Builder(); - setLayerOptionsBuilder(b, values); - return b.build(); - } - - protected void setLayerOptionsBuilder(GravesBidirectionalLSTM.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - if (forgetGateBiasInit != null) - builder.forgetGateBiasInit(forgetGateBiasInit.getValue(values)); - } - - @Override - public String toString() { - return toString(", "); - } - - @Override - public String toString(String delim) { - StringBuilder sb = new StringBuilder("GravesBidirectionalLSTMLayerSpace("); - if (forgetGateBiasInit != null) - sb.append("forgetGateBiasInit: ").append(forgetGateBiasInit).append(delim); - sb.append(super.toString(delim)).append(")"); - return sb.toString(); - } - - public static class Builder extends FeedForwardLayerSpace.Builder { - - private ParameterSpace forgetGateBiasInit; - - public Builder forgetGateBiasInit(double forgetGateBiasInit) { - return forgetGateBiasInit(new FixedValue<>(forgetGateBiasInit)); - } - - public Builder forgetGateBiasInit(ParameterSpace forgetGateBiasInit) { - this.forgetGateBiasInit = forgetGateBiasInit; - return this; - } - - @Override - @SuppressWarnings("unchecked") - public GravesBidirectionalLSTMLayerSpace build() { - return new GravesBidirectionalLSTMLayerSpace(this); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/GravesLSTMLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/GravesLSTMLayerSpace.java deleted file mode 100644 index 9707836fa..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/GravesLSTMLayerSpace.java +++ /dev/null @@ -1,76 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.layers.GravesLSTM; - -/** - * Layer space for LSTM layers - * - * @author Alex Black - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PRIVATE) //For Jackson JSON/YAML deserialization -public class GravesLSTMLayerSpace extends AbstractLSTMLayerSpace { - - private GravesLSTMLayerSpace(Builder builder) { - super(builder); - - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - - @Override - public GravesLSTM getValue(double[] values) { - GravesLSTM.Builder b = new GravesLSTM.Builder(); - setLayerOptionsBuilder(b, values); - return b.build(); - } - - protected void setLayerOptionsBuilder(GravesLSTM.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - } - - @Override - public String toString() { - return toString(", "); - } - - @Override - public String toString(String delim) { - StringBuilder sb = new StringBuilder("GravesLSTMLayerSpace("); - sb.append(super.toString(delim)).append(")"); - return sb.toString(); - } - - public static class Builder extends AbstractLSTMLayerSpace.Builder { - - @Override - @SuppressWarnings("unchecked") - public GravesLSTMLayerSpace build() { - return new GravesLSTMLayerSpace(this); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/LSTMLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/LSTMLayerSpace.java deleted file mode 100644 index 10e297134..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/LSTMLayerSpace.java +++ /dev/null @@ -1,77 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.layers.GravesLSTM; -import org.deeplearning4j.nn.conf.layers.LSTM; - -/** - * Layer space for LSTM layers - * - * @author Alex Black - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PRIVATE) //For Jackson JSON/YAML deserialization -public class LSTMLayerSpace extends AbstractLSTMLayerSpace { - - private LSTMLayerSpace(Builder builder) { - super(builder); - - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - - @Override - public LSTM getValue(double[] values) { - LSTM.Builder b = new LSTM.Builder(); - setLayerOptionsBuilder(b, values); - return b.build(); - } - - protected void setLayerOptionsBuilder(LSTM.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - } - - @Override - public String toString() { - return toString(", "); - } - - @Override - public String toString(String delim) { - StringBuilder sb = new StringBuilder("LSTMLayerSpace("); - sb.append(super.toString(delim)).append(")"); - return sb.toString(); - } - - public static class Builder extends AbstractLSTMLayerSpace.Builder { - - @Override - @SuppressWarnings("unchecked") - public LSTMLayerSpace build() { - return new LSTMLayerSpace(this); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/LayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/LayerSpace.java deleted file mode 100644 index eb77196d2..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/LayerSpace.java +++ /dev/null @@ -1,138 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.dropout.DropoutSpace; -import org.deeplearning4j.arbiter.optimize.api.AbstractParameterSpace; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.nn.conf.dropout.IDropout; -import org.deeplearning4j.nn.conf.layers.Layer; -import com.fasterxml.jackson.annotation.JsonInclude; - -import java.util.ArrayList; -import java.util.LinkedList; -import java.util.List; -import java.util.Map; - -/** - * LayerSpace contains common Layer hyperparameters; should match {@link Layer} in terms of features - * - * @author Alex Black - */ -@JsonInclude(JsonInclude.Include.NON_NULL) -@Data -@EqualsAndHashCode(callSuper = false) -@NoArgsConstructor(access = AccessLevel.PROTECTED) //For Jackson JSON/YAML deserialization -public abstract class LayerSpace extends AbstractParameterSpace { - protected ParameterSpace dropOut; - protected int numParameters; - - protected LayerSpace(Builder builder) { - this.dropOut = builder.dropOut; - } - - @Override - public List collectLeaves() { - //To avoid manually coding EVERY parameter, in every layer: - // Do a depth-first search of nested spaces - LinkedList stack = new LinkedList<>(); - stack.add(this); - - List out = new ArrayList<>(); - while (!stack.isEmpty()) { - ParameterSpace next = stack.removeLast(); - if (next.isLeaf()) { - out.add(next); - } else { - Map m = next.getNestedSpaces(); - ParameterSpace[] arr = m.values().toArray(new ParameterSpace[m.size()]); - for (int i = arr.length - 1; i >= 0; i--) { - stack.add(arr[i]); - } - } - } - - return out; - } - - @Override - public int numParameters() { - return numParameters; - } - - @Override - public boolean isLeaf() { - return false; - } - - @Override - public void setIndices(int... indices) { - throw new UnsupportedOperationException("Cannot set indices for non-leaf parameter space"); - } - - - protected void setLayerOptionsBuilder(Layer.Builder builder, double[] values) { - if (dropOut != null) - builder.dropOut(dropOut.getValue(values)); - } - - - @Override - public String toString() { - return toString(", "); - } - - protected String toString(String delim) { - StringBuilder sb = new StringBuilder(); - if (dropOut != null) - sb.append("dropOut: ").append(dropOut).append(delim); - String s = sb.toString(); - - if (s.endsWith(delim)) { - //Remove final delimiter - int last = s.lastIndexOf(delim); - return s.substring(0, last); - } else - return s; - } - - @SuppressWarnings("unchecked") - public abstract static class Builder { - protected ParameterSpace dropOut; - - public T dropOut(double dropOut) { - return dropOut(new FixedValue<>(dropOut)); - } - - public T dropOut(ParameterSpace dropOut) { - return iDropOut(new DropoutSpace(dropOut)); - } - - public T iDropOut(ParameterSpace dropOut){ - this.dropOut = dropOut; - return (T) this; - } - - public abstract E build(); - } - -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/LocalResponseNormalizationLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/LocalResponseNormalizationLayerSpace.java deleted file mode 100644 index eeeb5837f..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/LocalResponseNormalizationLayerSpace.java +++ /dev/null @@ -1,119 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.layers.LocalResponseNormalization; - -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PRIVATE) //For Jackson JSON/YAML deserialization -public class LocalResponseNormalizationLayerSpace extends LayerSpace { - - private ParameterSpace n; - private ParameterSpace k; - private ParameterSpace alpha; - private ParameterSpace beta; - - - private LocalResponseNormalizationLayerSpace(Builder builder) { - super(builder); - this.n = builder.n; - this.k = builder.k; - this.alpha = builder.alpha; - this.beta = builder.beta; - - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - @Override - public LocalResponseNormalization getValue(double[] values) { - LocalResponseNormalization.Builder b = new LocalResponseNormalization.Builder(); - setLayerOptionsBuilder(b, values); - return b.build(); - } - - protected void setLayerOptionsBuilder(LocalResponseNormalization.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - if (n != null) - builder.n(n.getValue(values)); - if (k != null) - builder.k(k.getValue(values)); - if (alpha != null) - builder.alpha(alpha.getValue(values)); - if (beta != null) - builder.beta(beta.getValue(values)); - } - - - public static class Builder extends LayerSpace.Builder { - - private ParameterSpace n; - private ParameterSpace k; - private ParameterSpace alpha; - private ParameterSpace beta; - - - public Builder n(double n) { - return n(new FixedValue<>(n)); - } - - public Builder n(ParameterSpace n) { - this.n = n; - return this; - } - - public Builder k(double k) { - return k(new FixedValue<>(k)); - } - - public Builder k(ParameterSpace k) { - this.k = k; - return this; - } - - public Builder alpha(double alpha) { - return alpha(new FixedValue<>(alpha)); - } - - public Builder alpha(ParameterSpace alpha) { - this.alpha = alpha; - return this; - } - - public Builder beta(double beta) { - return beta(new FixedValue<>(beta)); - } - - public Builder beta(ParameterSpace beta) { - this.beta = beta; - return this; - } - - public LocalResponseNormalizationLayerSpace build() { - return new LocalResponseNormalizationLayerSpace(this); - } - - } - -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/LossLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/LossLayerSpace.java deleted file mode 100644 index fc0b8c4d1..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/LossLayerSpace.java +++ /dev/null @@ -1,105 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.adapter.ActivationParameterSpaceAdapter; -import org.deeplearning4j.arbiter.adapter.LossFunctionParameterSpaceAdapter; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.layers.LossLayer; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.activations.IActivation; -import org.nd4j.linalg.lossfunctions.ILossFunction; -import org.nd4j.linalg.lossfunctions.LossFunctions; - -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PROTECTED) //For Jackson JSON/YAML deserialization -public class LossLayerSpace extends LayerSpace { - - private ParameterSpace activationFunction; - protected ParameterSpace lossFunction; - - public LossLayerSpace(Builder builder){ - super(builder); - this.activationFunction = builder.activationFunction; - this.lossFunction = builder.lossFunction; - - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - @Override - public LossLayer getValue(double[] parameterValues) { - LossLayer.Builder b = new LossLayer.Builder(); - if(activationFunction != null) - b.activation(activationFunction.getValue(parameterValues)); - if(lossFunction != null) - b.lossFunction(lossFunction.getValue(parameterValues)); - return b.build(); - } - - - public static class Builder extends LayerSpace.Builder{ - - private ParameterSpace activationFunction; - protected ParameterSpace lossFunction; - - public Builder lossFunction(LossFunctions.LossFunction lossFunction) { - return lossFunction(new FixedValue<>(lossFunction)); - } - - public Builder lossFunction(ParameterSpace lossFunction) { - return iLossFunction(new LossFunctionParameterSpaceAdapter(lossFunction)); - } - - public Builder iLossFunction(ILossFunction lossFunction) { - return iLossFunction(new FixedValue<>(lossFunction)); - } - - public Builder iLossFunction(ParameterSpace lossFunction) { - this.lossFunction = lossFunction; - return this; - } - - public Builder activation(Activation activation) { - return activation(new FixedValue<>(activation)); - } - - public Builder activation(IActivation iActivation) { - return activationFn(new FixedValue<>(iActivation)); - } - - public Builder activation(ParameterSpace activationFunction) { - return activationFn(new ActivationParameterSpaceAdapter(activationFunction)); - } - - public Builder activationFn(ParameterSpace activationFunction) { - this.activationFunction = activationFunction; - return this; - } - - @Override - public LossLayerSpace build() { - return new LossLayerSpace(this); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/OCNNLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/OCNNLayerSpace.java deleted file mode 100644 index d4fc9553b..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/OCNNLayerSpace.java +++ /dev/null @@ -1,153 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.ocnn.OCNNOutputLayer; - - -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PRIVATE) //For Jackson JSON/YAML deserialization -public class OCNNLayerSpace extends BaseOutputLayerSpace { - - - protected ParameterSpace nuSpace; - protected ParameterSpace initialRValue; - protected ParameterSpace hiddenLayerSize; - protected ParameterSpace windowSize; - protected ParameterSpace configureR; - - private OCNNLayerSpace(Builder builder) { - super(builder); - - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - this.nuSpace = builder.nuSpace; - this.initialRValue = builder.initialRValue; - this.hiddenLayerSize = builder.hiddenLayerSize; - this.configureR = builder.configureR; - } - - - @Override - public OCNNOutputLayer getValue(double[] parameterValues) { - OCNNOutputLayer.Builder o = new OCNNOutputLayer.Builder(); - setLayerOptionsBuilder(o, parameterValues); - return o.build(); - } - - protected void setLayerOptionsBuilder(OCNNOutputLayer.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - builder.nu(nuSpace.getValue(values)); - builder.hiddenLayerSize(hiddenLayerSize.getValue(values)); - builder.initialRValue(initialRValue.getValue(values)); - builder.configureR(configureR.getValue(values)); - builder.windowSize(windowSize.getValue(values)); - } - - - public static class Builder extends BaseOutputLayerSpace.Builder { - protected ParameterSpace nuSpace; - protected ParameterSpace initialRValue; - protected ParameterSpace hiddenLayerSize; - protected ParameterSpace windowSize; - protected ParameterSpace configureR; - - public Builder nu(ParameterSpace nuSpace) { - this.nuSpace = nuSpace; - return this; - } - - /** - * Use hiddenLayerSize instead - * @param numHiddenSpace - * @return - */ - @Deprecated - public Builder numHidden(ParameterSpace numHiddenSpace) { - return hiddenLayerSize(numHiddenSpace); - } - - /** - * Use hiddenLayerSize instead - * @param numHidden - * @return - */ - @Deprecated - public Builder numHidden(int numHidden) { - return hiddenLayerSize(numHidden); - } - - public Builder hiddenLayerSize(ParameterSpace hiddenLayerSize) { - this.hiddenLayerSize = hiddenLayerSize; - return this; - } - - public Builder hiddenLayerSize(int hiddenLayerSize) { - this.hiddenLayerSize = new FixedValue<>(hiddenLayerSize); - return this; - } - - public Builder nu(double nu) { - this.nuSpace = new FixedValue<>(nu); - return this; - } - - public Builder initialRValue(double initialRValue) { - this.initialRValue = new FixedValue<>(initialRValue); - return this; - } - - public Builder initialRValue(ParameterSpace initialRValue) { - this.initialRValue = initialRValue; - return this; - } - - public Builder windowSize(int windowSize) { - this.windowSize = new FixedValue<>(windowSize); - return this; - } - - public Builder windowSize(ParameterSpace windowSize) { - this.windowSize = windowSize; - return this; - } - - public Builder configureR(boolean configureR) { - this.configureR = new FixedValue<>(configureR); - return this; - } - - public Builder configureR(ParameterSpace configureR) { - this.configureR = configureR; - return this; - } - - - @Override - @SuppressWarnings("unchecked") - public OCNNLayerSpace build() { - return new OCNNLayerSpace(this); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/OutputLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/OutputLayerSpace.java deleted file mode 100644 index 5e6479fce..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/OutputLayerSpace.java +++ /dev/null @@ -1,71 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.layers.OutputLayer; - -/** - * Layer hyperparameter configuration space for output layers - * - * @author Alex Black - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PRIVATE) //For Jackson JSON/YAML deserialization -public class OutputLayerSpace extends BaseOutputLayerSpace { - - private OutputLayerSpace(Builder builder) { - super(builder); - - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - @Override - public OutputLayer getValue(double[] values) { - OutputLayer.Builder o = new OutputLayer.Builder(); - setLayerOptionsBuilder(o, values); - return o.build(); - } - - protected void setLayerOptionsBuilder(OutputLayer.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - } - - public static class Builder extends BaseOutputLayerSpace.Builder { - - @Override - @SuppressWarnings("unchecked") - public OutputLayerSpace build() { - return new OutputLayerSpace(this); - } - } - - @Override - public String toString() { - return toString(", "); - } - - @Override - public String toString(String delim) { - return "OutputLayerSpace(" + super.toString(delim) + ")"; - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/RnnOutputLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/RnnOutputLayerSpace.java deleted file mode 100644 index 4fba80d81..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/RnnOutputLayerSpace.java +++ /dev/null @@ -1,71 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.layers.RnnOutputLayer; - -/** - * Layer hyperparametor configuration space for RnnOutputLayer - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PRIVATE) //For Jackson JSON/YAML deserialization -public class RnnOutputLayerSpace extends BaseOutputLayerSpace { - - private RnnOutputLayerSpace(Builder builder) { - super(builder); - - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - @Override - public RnnOutputLayer getValue(double[] values) { - RnnOutputLayer.Builder b = new RnnOutputLayer.Builder(); - setLayerOptionsBuilder(b, values); - return b.build(); - } - - protected void setLayerOptionsBuilder(RnnOutputLayer.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - } - - @Override - public String toString() { - return toString(", "); - } - - @Override - public String toString(String delim) { - return "RnnOutputLayerSpace(" + super.toString(delim) + ")"; - } - - public static class Builder extends BaseOutputLayerSpace.Builder { - - @Override - @SuppressWarnings("unchecked") - public RnnOutputLayerSpace build() { - return new RnnOutputLayerSpace(this); - } - } - - -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/SeparableConvolution2DLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/SeparableConvolution2DLayerSpace.java deleted file mode 100644 index 64a0d26a6..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/SeparableConvolution2DLayerSpace.java +++ /dev/null @@ -1,101 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.nn.api.layers.LayerConstraint; -import org.deeplearning4j.nn.conf.layers.SeparableConvolution2D; - -import java.util.Arrays; -import java.util.List; - -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PROTECTED) //For Jackson JSON/YAML deserialization -public class SeparableConvolution2DLayerSpace extends BaseConvolutionLayerSpace { - - private ParameterSpace depthMultiplier; - protected ParameterSpace> pointWiseConstraints; - - protected SeparableConvolution2DLayerSpace(Builder builder){ - super(builder); - this.depthMultiplier = builder.depthMultiplier; - this.pointWiseConstraints = builder.pointWiseConstraints; - } - - @Override - public SeparableConvolution2D getValue(double[] parameterValues) { - SeparableConvolution2D.Builder b = new SeparableConvolution2D.Builder(); - setLayerOptionsBuilder(b, parameterValues); - return b.build(); - } - - protected void setLayerOptionsBuilder(SeparableConvolution2D.Builder builder, double[] values){ - super.setLayerOptionsBuilder(builder, values); - if (kernelSize != null) - builder.kernelSize(kernelSize.getValue(values)); - if (stride != null) - builder.stride(stride.getValue(values)); - if (padding != null) - builder.padding(padding.getValue(values)); - if (convolutionMode != null) - builder.convolutionMode(convolutionMode.getValue(values)); - if (hasBias != null) - builder.hasBias(hasBias.getValue(values)); - if (depthMultiplier != null) - builder.depthMultiplier(depthMultiplier.getValue(values)); - if (pointWiseConstraints != null){ - List c = pointWiseConstraints.getValue(values); - if(c != null){ - builder.constrainPointWise(c.toArray(new LayerConstraint[c.size()])); - } - } - } - - - public static class Builder extends BaseConvolutionLayerSpace.Builder{ - private ParameterSpace depthMultiplier; - protected ParameterSpace> pointWiseConstraints; - - public Builder constrainPointWise(LayerConstraint... constraints){ - return constrainPointWise(new FixedValue>(Arrays.asList(constraints))); - } - - public Builder constrainPointWise(ParameterSpace> constraints){ - this.pointWiseConstraints = constraints; - return this; - } - - public Builder depthMultiplier(int depthMultiplier){ - return depthMultiplier(new FixedValue<>(depthMultiplier)); - } - - public Builder depthMultiplier(ParameterSpace depthMultiplier){ - this.depthMultiplier = depthMultiplier; - return this; - } - - public SeparableConvolution2DLayerSpace build(){ - return new SeparableConvolution2DLayerSpace(this); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/SubsamplingLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/SubsamplingLayerSpace.java deleted file mode 100644 index 5f1e32dab..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/SubsamplingLayerSpace.java +++ /dev/null @@ -1,208 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.ConvolutionMode; -import org.deeplearning4j.nn.conf.layers.SubsamplingLayer; - -/** - * Layer hyperparameter configuration space for subsampling layers - * - * @author Alex Black - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PRIVATE) //For Jackson JSON/YAML deserialization -public class SubsamplingLayerSpace extends LayerSpace { - - protected ParameterSpace convolutionMode; - protected ParameterSpace poolingType; - protected ParameterSpace dilation; - protected ParameterSpace kernelSize; - protected ParameterSpace stride; - protected ParameterSpace padding; - protected ParameterSpace pnorm; - protected ParameterSpace eps; - - private SubsamplingLayerSpace(Builder builder) { - super(builder); - this.convolutionMode = builder.convolutionMode; - this.poolingType = builder.poolingType; - this.kernelSize = builder.kernelSize; - this.dilation = builder.dilation; - this.stride = builder.stride; - this.padding = builder.padding; - this.pnorm = builder.pnorm; - this.eps = builder.eps; - - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - @Override - public SubsamplingLayer getValue(double[] values) { - SubsamplingLayer.Builder b = new SubsamplingLayer.Builder(); - setLayerOptionsBuilder(b, values); - return b.build(); - } - - protected void setLayerOptionsBuilder(SubsamplingLayer.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - if (convolutionMode != null) - builder.convolutionMode(convolutionMode.getValue(values)); - if (poolingType != null) - builder.poolingType(poolingType.getValue(values)); - if (dilation !=null) - builder.dilation(dilation.getValue(values)); - if (kernelSize != null) - builder.kernelSize(kernelSize.getValue(values)); - if (stride != null) - builder.stride(stride.getValue(values)); - if (padding != null) - builder.padding(padding.getValue(values)); - if(pnorm != null) - builder.pnorm(pnorm.getValue(values)); - if(eps != null) - builder.eps(eps.getValue(values)); - } - - @Override - public String toString() { - return toString(", "); - } - - @Override - public String toString(String delim) { - StringBuilder sb = new StringBuilder("SubsamplingLayerSpace("); - if (convolutionMode != null) - sb.append("convolutionMode: ").append(convolutionMode).append(delim); - if (poolingType != null) - sb.append("poolingType: ").append(poolingType).append(delim); - if (dilation != null) - sb.append("dilation: ").append(dilation).append(delim); - if (kernelSize != null) - sb.append("kernelSize: ").append(kernelSize).append(delim); - if (stride != null) - sb.append("stride: ").append(stride).append(delim); - if (padding != null) - sb.append("padding: ").append(padding).append(delim); - if (pnorm != null) - sb.append("pnorm: ").append(pnorm).append(delim); - if (eps != null) - sb.append("eps: ").append(eps).append(delim); - sb.append(super.toString(delim)).append(")"); - return sb.toString(); - } - - - public static class Builder extends FeedForwardLayerSpace.Builder { - - protected ParameterSpace convolutionMode; - protected ParameterSpace poolingType; - protected ParameterSpace dilation; - protected ParameterSpace kernelSize; - protected ParameterSpace stride; - protected ParameterSpace padding; - protected ParameterSpace pnorm; - protected ParameterSpace eps; - - public Builder convolutionMode(ConvolutionMode convolutionMode){ - return convolutionMode(new FixedValue<>(convolutionMode)); - } - - public Builder convolutionMode(ParameterSpace convolutionMode){ - this.convolutionMode = convolutionMode; - return this; - } - - public Builder poolingType(SubsamplingLayer.PoolingType poolingType) { - return poolingType(new FixedValue<>(poolingType)); - } - - public Builder poolingType(ParameterSpace poolingType) { - this.poolingType = poolingType; - return this; - } - - public Builder dilation(int... dilation) { - return dilation(new FixedValue<>(dilation)); - } - - public Builder dilation(ParameterSpace dilation) { - this.dilation = dilation; - return this; - } - - public Builder kernelSize(int... kernelSize) { - return kernelSize(new FixedValue<>(kernelSize)); - } - - public Builder kernelSize(ParameterSpace kernelSize) { - this.kernelSize = kernelSize; - return this; - } - - public Builder stride(int... stride) { - return stride(new FixedValue(stride)); - } - - public Builder stride(ParameterSpace stride) { - this.stride = stride; - return this; - } - - public Builder padding(int... padding) { - return padding(new FixedValue(padding)); - } - - public Builder padding(ParameterSpace padding) { - this.padding = padding; - return this; - } - - public Builder pnorm(int pnorm){ - return pnorm(new FixedValue<>(pnorm)); - } - - public Builder pnorm(ParameterSpace pnorm){ - this.pnorm = pnorm; - return this; - } - - public Builder eps(double eps){ - return eps(new FixedValue<>(eps)); - } - - public Builder eps(ParameterSpace eps){ - this.eps = eps; - return this; - } - - @SuppressWarnings("unchecked") - public SubsamplingLayerSpace build() { - return new SubsamplingLayerSpace(this); - } - - } - -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/VariationalAutoencoderLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/VariationalAutoencoderLayerSpace.java deleted file mode 100644 index 2138ea8ec..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/VariationalAutoencoderLayerSpace.java +++ /dev/null @@ -1,182 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.layers.variational.LossFunctionWrapper; -import org.deeplearning4j.nn.conf.layers.variational.ReconstructionDistribution; -import org.deeplearning4j.nn.conf.layers.variational.VariationalAutoencoder; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.activations.IActivation; -import org.nd4j.linalg.lossfunctions.ILossFunction; -import org.nd4j.linalg.lossfunctions.LossFunctions; - -/** - * Layer space for {@link VariationalAutoencoder} - * - * @author Alex Black - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PRIVATE) //For Jackson JSON/YAML deserialization -public class VariationalAutoencoderLayerSpace extends BasePretrainNetworkLayerSpace { - - private ParameterSpace encoderLayerSizes; - private ParameterSpace decoderLayerSizes; - private ParameterSpace outputDistribution; - private ParameterSpace pzxActivationFn; - private ParameterSpace numSamples; - - protected VariationalAutoencoderLayerSpace(Builder builder) { - super(builder); - - this.encoderLayerSizes = builder.encoderLayerSizes; - this.decoderLayerSizes = builder.decoderLayerSizes; - this.outputDistribution = builder.outputDistribution; - this.pzxActivationFn = builder.pzxActivationFn; - this.numSamples = builder.numSamples; - - this.numParameters = LeafUtils.countUniqueParameters(collectLeaves()); - } - - @Override - public VariationalAutoencoder getValue(double[] parameterValues) { - VariationalAutoencoder.Builder b = new VariationalAutoencoder.Builder(); - setLayerOptionsBuilder(b, parameterValues); - return b.build(); - } - - protected void setLayerOptionsBuilder(VariationalAutoencoder.Builder builder, double[] values) { - super.setLayerOptionsBuilder(builder, values); - if (encoderLayerSizes != null) - builder.encoderLayerSizes(encoderLayerSizes.getValue(values)); - if (decoderLayerSizes != null) - builder.decoderLayerSizes(decoderLayerSizes.getValue(values)); - if (outputDistribution != null) - builder.reconstructionDistribution(outputDistribution.getValue(values)); - if (pzxActivationFn != null) - builder.pzxActivationFn(pzxActivationFn.getValue(values)); - if (numSamples != null) - builder.numSamples(numSamples.getValue(values)); - } - - @Override - public String toString() { - return toString(", "); - } - - @Override - public String toString(String delim) { - StringBuilder sb = new StringBuilder("VariationalAutoencoderLayerSpace("); - if (encoderLayerSizes != null) - sb.append("encoderLayerSizes: ").append(encoderLayerSizes).append(delim); - if (decoderLayerSizes != null) - sb.append("decoderLayerSizes: ").append(decoderLayerSizes).append(delim); - if (outputDistribution != null) - sb.append("reconstructionDistribution: ").append(outputDistribution).append(delim); - if (pzxActivationFn != null) - sb.append("pzxActivationFn: ").append(pzxActivationFn).append(delim); - if (numSamples != null) - sb.append("numSamples: ").append(numSamples).append(delim); - sb.append(super.toString(delim)).append(")"); - return sb.toString(); - } - - public static class Builder extends BasePretrainNetworkLayerSpace.Builder { - - private ParameterSpace encoderLayerSizes; - private ParameterSpace decoderLayerSizes; - private ParameterSpace outputDistribution; - private ParameterSpace pzxActivationFn; - private ParameterSpace numSamples; - - - public Builder encoderLayerSizes(int... encoderLayerSizes) { - return encoderLayerSizes(new FixedValue<>(encoderLayerSizes)); - } - - public Builder encoderLayerSizes(ParameterSpace encoderLayerSizes) { - this.encoderLayerSizes = encoderLayerSizes; - return this; - } - - public Builder decoderLayerSizes(int... decoderLayerSizes) { - return decoderLayerSizes(new FixedValue<>(decoderLayerSizes)); - } - - public Builder decoderLayerSizes(ParameterSpace decoderLayerSizes) { - this.decoderLayerSizes = decoderLayerSizes; - return this; - } - - public Builder reconstructionDistribution(ReconstructionDistribution distribution) { - return reconstructionDistribution(new FixedValue<>(distribution)); - } - - public Builder reconstructionDistribution(ParameterSpace distribution) { - this.outputDistribution = distribution; - return this; - } - - public Builder lossFunction(IActivation outputActivationFn, LossFunctions.LossFunction lossFunction) { - return lossFunction(outputActivationFn, lossFunction.getILossFunction()); - } - - public Builder lossFunction(Activation outputActivationFn, LossFunctions.LossFunction lossFunction) { - return lossFunction(outputActivationFn.getActivationFunction(), lossFunction.getILossFunction()); - } - - public Builder lossFunction(IActivation outputActivationFn, ILossFunction lossFunction) { - return reconstructionDistribution(new LossFunctionWrapper(outputActivationFn, lossFunction)); - } - - public Builder pzxActivationFn(IActivation activationFunction) { - return pzxActivationFn(new FixedValue<>(activationFunction)); - } - - public Builder pzxActivationFn(ParameterSpace activationFunction) { - this.pzxActivationFn = activationFunction; - return this; - } - - public Builder pzxActivationFunction(Activation activation) { - return pzxActivationFn(activation.getActivationFunction()); - } - - public Builder numSamples(int numSamples) { - return numSamples(new FixedValue<>(numSamples)); - } - - public Builder numSamples(ParameterSpace numSamples) { - this.numSamples = numSamples; - return this; - } - - - @Override - public E build() { - return (E) new VariationalAutoencoderLayerSpace(this); - } - - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/fixed/FixedLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/fixed/FixedLayerSpace.java deleted file mode 100644 index fb1afc299..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/layers/fixed/FixedLayerSpace.java +++ /dev/null @@ -1,71 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.layers.fixed; - -import lombok.AllArgsConstructor; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.layers.LayerSpace; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.nn.conf.layers.Layer; - -import java.util.Collections; -import java.util.List; - -/** - * A layer space that wraps a DL4J layer, without any optimizable hyperparameters - * - * @param Type of layer - * - * @author Alex Black - */ -@AllArgsConstructor -@NoArgsConstructor -@Data -@EqualsAndHashCode(callSuper = false) -public class FixedLayerSpace extends LayerSpace { - - protected T layer; - - @Override - public T getValue(double[] parameterValues) { - return (T)layer.clone(); - } - - @Override - public int numParameters() { - return 0; - } - - @Override - public boolean isLeaf() { - return true; - } - - @Override - public void setIndices(int[] idxs){ - if(idxs != null && idxs.length > 0){ - throw new IllegalStateException("Cannot set indices: no parameters"); - } - } - - @Override - public List collectLeaves() { - return Collections.singletonList(this); - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/listener/DL4JArbiterStatusReportingListener.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/listener/DL4JArbiterStatusReportingListener.java deleted file mode 100644 index 0c89984c9..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/listener/DL4JArbiterStatusReportingListener.java +++ /dev/null @@ -1,49 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.listener; - -import lombok.AllArgsConstructor; -import org.deeplearning4j.arbiter.optimize.runner.CandidateInfo; -import org.deeplearning4j.arbiter.optimize.runner.listener.StatusListener; -import org.deeplearning4j.nn.api.Model; -import org.deeplearning4j.optimize.api.BaseTrainingListener; -import org.deeplearning4j.optimize.api.IterationListener; - -import java.util.List; - -/** - * A simple DL4J Iteration listener that calls Arbiter's status listeners - * - * @author Alex Black - */ -@AllArgsConstructor -public class DL4JArbiterStatusReportingListener extends BaseTrainingListener { - - private List statusListeners; - private CandidateInfo candidateInfo; - - @Override - public void iterationDone(Model model, int iteration, int epoch) { - if (statusListeners == null) { - return; - } - - for (StatusListener sl : statusListeners) { - sl.onCandidateIteration(candidateInfo, model, iteration); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/saver/local/FileModelSaver.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/saver/local/FileModelSaver.java deleted file mode 100644 index 167f1f9d1..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/saver/local/FileModelSaver.java +++ /dev/null @@ -1,147 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.saver.local; - -import lombok.AllArgsConstructor; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import lombok.NonNull; -import lombok.extern.slf4j.Slf4j; -import org.apache.commons.io.FileUtils; -import org.apache.commons.io.FilenameUtils; -import org.deeplearning4j.arbiter.DL4JConfiguration; -import org.deeplearning4j.arbiter.GraphConfiguration; -import org.deeplearning4j.arbiter.optimize.api.OptimizationResult; -import org.deeplearning4j.arbiter.optimize.api.saving.ResultReference; -import org.deeplearning4j.arbiter.optimize.api.saving.ResultSaver; -import org.deeplearning4j.earlystopping.EarlyStoppingConfiguration; -import org.deeplearning4j.nn.api.Model; -import org.deeplearning4j.nn.graph.ComputationGraph; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.deeplearning4j.util.ModelSerializer; -import com.fasterxml.jackson.annotation.JsonCreator; -import com.fasterxml.jackson.annotation.JsonProperty; - -import java.io.*; -import java.util.Arrays; -import java.util.Collections; -import java.util.List; - -/** - * Basic MultiLayerNetwork saver. Saves config, parameters and score to: baseDir/0/, baseDir/1/, etc - * where index is given by OptimizationResult.getIndex() - * - * @author Alex Black - */ -@Slf4j -@NoArgsConstructor -@AllArgsConstructor -@EqualsAndHashCode -public class FileModelSaver implements ResultSaver { - @JsonProperty - private String path; - private File fPath; - - @JsonCreator - public FileModelSaver(@NonNull String path) { - this(new File(path)); - } - - public FileModelSaver(@NonNull File file){ - this.path = file.getPath(); - this.fPath = file; - - if(!fPath.exists()){ - fPath.mkdirs(); - } else if (!fPath.isDirectory()) { - throw new IllegalArgumentException("Invalid path: exists and is not directory. " + path); - } - - log.info("FileModelSaver saving networks to local directory: {}", path); - } - - @Override - public ResultReference saveModel(OptimizationResult result, Object modelResult) throws IOException { - String dir = new File(path, result.getIndex() + "/").getAbsolutePath(); - - File f = new File(dir); - f.mkdir(); - - File modelFile = new File(FilenameUtils.concat(dir, "model.bin")); - File scoreFile = new File(FilenameUtils.concat(dir, "score.txt")); - File additionalResultsFile = new File(FilenameUtils.concat(dir, "additionalResults.bin")); - File esConfigFile = new File(FilenameUtils.concat(dir, "earlyStoppingConfig.bin")); - File numEpochsFile = new File(FilenameUtils.concat(dir, "numEpochs.txt")); - - FileUtils.writeStringToFile(scoreFile, String.valueOf(result.getScore())); - - Model m = (Model) modelResult; - ModelSerializer.writeModel(m, modelFile, true); - - - Object additionalResults = result.getModelSpecificResults(); - if (additionalResults != null && additionalResults instanceof Serializable) { - try (ObjectOutputStream oos = new ObjectOutputStream(new FileOutputStream(additionalResultsFile))) { - oos.writeObject(additionalResults); - } - } - - //Write early stopping configuration (if present) to file: - int nEpochs; - EarlyStoppingConfiguration esc; - if (result.getCandidate().getValue() instanceof DL4JConfiguration) { - DL4JConfiguration c = ((DL4JConfiguration) result.getCandidate().getValue()); - esc = c.getEarlyStoppingConfiguration(); - nEpochs = c.getNumEpochs(); - } else { - GraphConfiguration c = ((GraphConfiguration) result.getCandidate().getValue()); - esc = c.getEarlyStoppingConfiguration(); - nEpochs = c.getNumEpochs(); - } - - - if (esc != null) { - try (ObjectOutputStream oos = new ObjectOutputStream(new FileOutputStream(esConfigFile))) { - oos.writeObject(esc); - } - } else { - FileUtils.writeStringToFile(numEpochsFile, String.valueOf(nEpochs)); - } - - log.debug("Deeplearning4j model result (id={}, score={}) saved to directory: {}", result.getIndex(), - result.getScore(), dir); - - boolean isGraph = m instanceof ComputationGraph; - return new LocalFileNetResultReference(result.getIndex(), dir, isGraph, modelFile, scoreFile, - additionalResultsFile, esConfigFile, numEpochsFile, result.getCandidate()); - } - - @Override - public List> getSupportedCandidateTypes() { - return Collections.>singletonList(Object.class); - } - - @Override - public List> getSupportedModelTypes() { - return Arrays.>asList(MultiLayerNetwork.class, ComputationGraph.class); - } - - @Override - public String toString() { - return "FileModelSaver(path=" + path + ")"; - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/saver/local/LocalFileNetResultReference.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/saver/local/LocalFileNetResultReference.java deleted file mode 100644 index db46e011e..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/saver/local/LocalFileNetResultReference.java +++ /dev/null @@ -1,103 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.saver.local; - -import lombok.AllArgsConstructor; -import org.apache.commons.io.FileUtils; -import org.deeplearning4j.arbiter.DL4JConfiguration; -import org.deeplearning4j.arbiter.optimize.api.Candidate; -import org.deeplearning4j.arbiter.optimize.api.OptimizationResult; -import org.deeplearning4j.arbiter.optimize.api.saving.ResultReference; -import org.deeplearning4j.earlystopping.EarlyStoppingConfiguration; -import org.deeplearning4j.nn.api.Model; -import org.deeplearning4j.util.ModelSerializer; - -import java.io.File; -import java.io.FileInputStream; -import java.io.IOException; -import java.io.ObjectInputStream; - -/** - * Result reference for MultiLayerNetworks and ComputationGraphs saved to local file system - */ -@AllArgsConstructor -public class LocalFileNetResultReference implements ResultReference { - - private int index; - private String dir; - private boolean isGraph; - private File modelFile; - private File scoreFile; - private File additionalResultsFile; - private File esConfigFile; - private File numEpochsFile; - private Candidate candidate; - - @Override - public OptimizationResult getResult() throws IOException { - - - String scoreStr = FileUtils.readFileToString(scoreFile); - //TODO: properly parsing. Probably want to store additional info other than just score... - double d = Double.parseDouble(scoreStr); - - EarlyStoppingConfiguration earlyStoppingConfiguration = null; - if (esConfigFile != null && esConfigFile.exists()) { - try (ObjectInputStream ois = new ObjectInputStream(new FileInputStream(esConfigFile))) { - earlyStoppingConfiguration = (EarlyStoppingConfiguration) ois.readObject(); - } catch (ClassNotFoundException e) { - throw new RuntimeException("Error loading early stopping configuration", e); - } - } - int nEpochs = 1; - if (numEpochsFile != null && numEpochsFile.exists()) { - String numEpochs = FileUtils.readFileToString(numEpochsFile); - nEpochs = Integer.parseInt(numEpochs); - } - - - - Object additionalResults; - if (additionalResultsFile.exists()) { - try (ObjectInputStream ois = new ObjectInputStream(new FileInputStream(additionalResultsFile))) { - additionalResults = ois.readObject(); - } catch (ClassNotFoundException e) { - throw new RuntimeException("Error loading additional results", e); - } - } else { - additionalResults = null; - } - - return new OptimizationResult(candidate, d, index, additionalResults, null, this); - } - - @Override - public Object getResultModel() throws IOException { - Model m; - if (isGraph) { - m = ModelSerializer.restoreComputationGraph(modelFile, false); - } else { - m = ModelSerializer.restoreMultiLayerNetwork(modelFile, false); - } - return m; - } - - @Override - public String toString() { - return "LocalFileNetResultReference(" + dir + ")"; - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/RegressionValue.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/RegressionValue.java deleted file mode 100644 index 304750dc8..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/RegressionValue.java +++ /dev/null @@ -1,32 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.scoring; - -/** - * Enumeration used to select the type of regression statistics to optimize on, with the various regression score functions - * - MSE: mean squared error
- * - MAE: mean absolute error
- * - RMSE: root mean squared error
- * - RSE: relative squared error
- * - CorrCoeff: correlation coefficient
- * - * @deprecated Use {@link org.deeplearning4j.eval.RegressionEvaluation.Metric} - */ -@Deprecated -public enum RegressionValue { - MSE, MAE, RMSE, RSE, CorrCoeff -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/ScoreFunctions.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/ScoreFunctions.java deleted file mode 100644 index f9e57a597..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/ScoreFunctions.java +++ /dev/null @@ -1,66 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.scoring; - - -import org.deeplearning4j.arbiter.optimize.api.score.ScoreFunction; -import org.deeplearning4j.arbiter.scoring.impl.TestSetAccuracyScoreFunction; -import org.deeplearning4j.arbiter.scoring.impl.TestSetF1ScoreFunction; -import org.deeplearning4j.arbiter.scoring.impl.TestSetLossScoreFunction; -import org.deeplearning4j.arbiter.scoring.impl.TestSetRegressionScoreFunction; - -/** - * ScoreFunctions provides static methods for getting score functions for DL4J MultiLayerNetwork and ComputationGraph - * - * @author Alex Black - */ -public class ScoreFunctions { - - private ScoreFunctions() {} - - /** - * Calculate the loss (score/loss function value) on a test set, for a MultiLayerNetwork - * - * @param average Average (divide by number of examples) - */ - public static ScoreFunction testSetLoss(boolean average) { - return new TestSetLossScoreFunction(average); - } - - /** - * Calculate the accuracy on a test set, for a MultiLayerNetwork - */ - public static ScoreFunction testSetAccuracy() { - return new TestSetAccuracyScoreFunction(); - } - - - /** - * Calculate the f1 score on a test set - */ - public static ScoreFunction testSetF1() { - return new TestSetF1ScoreFunction(); - } - - /** - * Calculate a regression value (MSE, MAE etc) on a test set - */ - public static ScoreFunction testSetRegression(RegressionValue regressionValue) { - return new TestSetRegressionScoreFunction(regressionValue); - } - -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/BaseNetScoreFunction.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/BaseNetScoreFunction.java deleted file mode 100644 index 1d38ada7c..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/BaseNetScoreFunction.java +++ /dev/null @@ -1,103 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.scoring.impl; - -import lombok.EqualsAndHashCode; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSource; -import org.deeplearning4j.arbiter.optimize.api.score.ScoreFunction; -import org.deeplearning4j.nn.graph.ComputationGraph; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.DataSetIteratorFactory; -import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator; - -import java.io.IOException; -import java.util.Arrays; -import java.util.List; -import java.util.Map; -import java.util.Properties; - -/** - * Created by Alex on 23/07/2017. - */ -@EqualsAndHashCode -public abstract class BaseNetScoreFunction implements ScoreFunction { - - - @Override - public double score(Object model, DataProvider dataProvider, Map dataParameters) { - Object testData = dataProvider.testData(dataParameters); - return score(model, testData); - } - - @Override - public double score(Object model, Class dataSource, Properties dataSourceProperties) { - DataSource ds; - try{ - ds = dataSource.newInstance(); - if (dataSourceProperties != null) { - ds.configure(dataSourceProperties); - } - } catch (Exception e){ - throw new RuntimeException("Error creating DataSource instance - missing no-arg constructor?", e); - } - return score(model, ds.testData()); - } - - protected double score(Object model, Object testData){ - if (model instanceof MultiLayerNetwork) { - if (testData instanceof DataSetIterator) { - return score((MultiLayerNetwork) model, (DataSetIterator) testData); - } else if(testData instanceof MultiDataSetIterator){ - return score((MultiLayerNetwork) model, (MultiDataSetIterator) testData); - } else if(testData instanceof DataSetIteratorFactory){ - return score((MultiLayerNetwork)model, ((DataSetIteratorFactory)testData).create()); - } else { - throw new RuntimeException("Unknown type of data: " + testData.getClass()); - } - } else { - if (testData instanceof DataSetIterator) { - return score((ComputationGraph) model, (DataSetIterator) testData); - } else if(testData instanceof DataSetIteratorFactory){ - return score((ComputationGraph) model, ((DataSetIteratorFactory)testData).create()); - } else if(testData instanceof MultiDataSetIterator) { - return score((ComputationGraph) model, (MultiDataSetIterator) testData); - } else { - throw new RuntimeException("Unknown type of data: " + testData.getClass()); - } - } - } - - @Override - public List> getSupportedModelTypes() { - return Arrays.>asList(MultiLayerNetwork.class, ComputationGraph.class); - } - - @Override - public List> getSupportedDataTypes() { - return Arrays.>asList(DataSetIterator.class, MultiDataSetIterator.class); - } - - public abstract double score(MultiLayerNetwork net, DataSetIterator iterator); - - public abstract double score(MultiLayerNetwork net, MultiDataSetIterator iterator); - - public abstract double score(ComputationGraph graph, DataSetIterator iterator); - - public abstract double score(ComputationGraph graph, MultiDataSetIterator iterator); -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/EvaluationScoreFunction.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/EvaluationScoreFunction.java deleted file mode 100644 index 7e71425d5..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/EvaluationScoreFunction.java +++ /dev/null @@ -1,86 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.scoring.impl; - -import lombok.*; -import org.deeplearning4j.datasets.iterator.MultiDataSetWrapperIterator; -import org.deeplearning4j.nn.graph.ComputationGraph; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.nd4j.evaluation.classification.Evaluation; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator; - -/** - * Score function that calculates an evaluation {@link Evaluation.Metric} on the test set for a - * {@link MultiLayerNetwork} or {@link ComputationGraph} - * - * @author Alex Black - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PROTECTED) //JSON -public class EvaluationScoreFunction extends BaseNetScoreFunction { - - protected Evaluation.Metric metric; - - /** - * @param metric Evaluation metric to calculate - */ - public EvaluationScoreFunction(@NonNull org.deeplearning4j.eval.Evaluation.Metric metric) { - this(metric.toNd4j()); - } - - /** - * @param metric Evaluation metric to calculate - */ - public EvaluationScoreFunction(@NonNull Evaluation.Metric metric) { - this.metric = metric; - } - - @Override - public String toString() { - return "EvaluationScoreFunction(metric=" + metric + ")"; - } - - @Override - public double score(MultiLayerNetwork net, DataSetIterator iterator) { - Evaluation e = net.evaluate(iterator); - return e.scoreForMetric(metric); - } - - @Override - public double score(MultiLayerNetwork net, MultiDataSetIterator iterator) { - return score(net, new MultiDataSetWrapperIterator(iterator)); - } - - @Override - public double score(ComputationGraph graph, DataSetIterator iterator) { - Evaluation e = graph.evaluate(iterator); - return e.scoreForMetric(metric); - } - - @Override - public double score(ComputationGraph graph, MultiDataSetIterator iterator) { - Evaluation e = graph.evaluate(iterator); - return e.scoreForMetric(metric); - } - - @Override - public boolean minimize() { - return false; //Want to maximize all evaluation metrics: Accuracy, F1, precision, recall, g-measure, mcc - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/ROCScoreFunction.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/ROCScoreFunction.java deleted file mode 100644 index 9203963e3..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/ROCScoreFunction.java +++ /dev/null @@ -1,122 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.scoring.impl; - -import lombok.*; -import org.deeplearning4j.datasets.iterator.MultiDataSetWrapperIterator; -import org.deeplearning4j.nn.graph.ComputationGraph; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.nd4j.evaluation.classification.ROC; -import org.nd4j.evaluation.classification.ROCBinary; -import org.nd4j.evaluation.classification.ROCMultiClass; -import org.nd4j.linalg.dataset.adapter.MultiDataSetIteratorAdapter; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator; - -/** - * Score function that calculates AUC (area under ROC curve) or AUPRC (area under precision/recall curve) on a test set - * for a {@link MultiLayerNetwork} or {@link ComputationGraph} - * - * @author Alex Black - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PROTECTED) //JSON -public class ROCScoreFunction extends BaseNetScoreFunction { - - /** - * Type of ROC evaluation to perform:
- * ROC: use {@link ROC} to perform evaluation (single output binary classification)
- * BINARY: use {@link ROCBinary} to perform evaluation (multi-output/multi-task binary classification)
- * MULTICLASS: use {@link ROCMultiClass} to perform evaluation (1 vs. all multi-class classification) - * - */ - public enum ROCType {ROC, BINARY, MULTICLASS} - - /** - * Metric to calculate.
- * AUC: Area under ROC curve
- * AUPRC: Area under precision/recall curve - */ - public enum Metric {AUC, AUPRC}; - - protected ROCType type; - protected Metric metric; - - /** - * @param type ROC type to use for evaluation - * @param metric Evaluation metric to calculate - */ - public ROCScoreFunction(@NonNull ROCType type, @NonNull Metric metric) { - this.type = type; - this.metric = metric; - } - - @Override - public String toString() { - return "ROCScoreFunction(type=" + type + ",metric=" + metric + ")"; - } - - @Override - public double score(MultiLayerNetwork net, DataSetIterator iterator) { - switch (type){ - case ROC: - ROC r = net.evaluateROC(iterator); - return metric == Metric.AUC ? r.calculateAUC() : r.calculateAUCPR(); - case BINARY: - ROCBinary r2 = net.doEvaluation(iterator, new ROCBinary())[0]; - return metric == Metric.AUC ? r2.calculateAverageAuc() : r2.calculateAverageAUCPR(); - case MULTICLASS: - ROCMultiClass r3 = net.evaluateROCMultiClass(iterator); - return metric == Metric.AUC ? r3.calculateAverageAUC() : r3.calculateAverageAUCPR(); - default: - throw new RuntimeException("Unknown type: " + type); - } - } - - @Override - public double score(MultiLayerNetwork net, MultiDataSetIterator iterator) { - return score(net, new MultiDataSetWrapperIterator(iterator)); - } - - @Override - public double score(ComputationGraph graph, DataSetIterator iterator) { - return score(graph, new MultiDataSetIteratorAdapter(iterator)); - } - - @Override - public double score(ComputationGraph net, MultiDataSetIterator iterator) { - switch (type){ - case ROC: - ROC r = net.evaluateROC(iterator); - return metric == Metric.AUC ? r.calculateAUC() : r.calculateAUCPR(); - case BINARY: - ROCBinary r2 = net.doEvaluation(iterator, new ROCBinary())[0]; - return metric == Metric.AUC ? r2.calculateAverageAuc() : r2.calculateAverageAUCPR(); - case MULTICLASS: - ROCMultiClass r3 = net.evaluateROCMultiClass(iterator, 0); - return metric == Metric.AUC ? r3.calculateAverageAUC() : r3.calculateAverageAUCPR(); - default: - throw new RuntimeException("Unknown type: " + type); - } - } - - @Override - public boolean minimize() { - return false; //Want to maximize all evaluation metrics: Accuracy, F1, precision, recall, g-measure, mcc - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/RegressionScoreFunction.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/RegressionScoreFunction.java deleted file mode 100644 index 51fcd9898..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/RegressionScoreFunction.java +++ /dev/null @@ -1,92 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.scoring.impl; - -import lombok.*; -import org.deeplearning4j.datasets.iterator.MultiDataSetWrapperIterator; -import org.deeplearning4j.nn.graph.ComputationGraph; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.nd4j.evaluation.regression.RegressionEvaluation; -import org.nd4j.evaluation.regression.RegressionEvaluation.Metric; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator; - -/** - * Score function for regression (including multi-label regression) for a MultiLayerNetwork or ComputationGraph - * on a test set. Supports all regression metrics: {@link Metric} - * - * @author Alex Black - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PROTECTED) //For JSON -public class RegressionScoreFunction extends BaseNetScoreFunction { - - protected Metric metric; - - public RegressionScoreFunction(@NonNull org.deeplearning4j.eval.RegressionEvaluation.Metric metric) { - this(metric.toNd4j()); - } - - public RegressionScoreFunction(@NonNull Metric metric) { - this.metric = metric; - } - - @Override - public boolean minimize() { - switch (metric) { - case MSE: - case MAE: - case RMSE: - case RSE: - return true; - case PC: - case R2: - return false; - default: - throw new IllegalStateException("Unknown metric: " + metric); - } - } - - @Override - public String toString() { - return "RegressionScoreFunction(metric=" + metric + ")"; - } - - @Override - public double score(MultiLayerNetwork net, DataSetIterator iterator) { - RegressionEvaluation e = net.evaluateRegression(iterator); - return e.scoreForMetric(metric); - } - - @Override - public double score(MultiLayerNetwork net, MultiDataSetIterator iterator) { - return score(net, new MultiDataSetWrapperIterator(iterator)); - } - - @Override - public double score(ComputationGraph graph, DataSetIterator iterator) { - RegressionEvaluation e = graph.evaluateRegression(iterator); - return e.scoreForMetric(metric); - } - - @Override - public double score(ComputationGraph graph, MultiDataSetIterator iterator) { - RegressionEvaluation e = graph.evaluateRegression(iterator); - return e.scoreForMetric(metric); - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/TestSetAccuracyScoreFunction.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/TestSetAccuracyScoreFunction.java deleted file mode 100644 index 34b051663..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/TestSetAccuracyScoreFunction.java +++ /dev/null @@ -1,72 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.scoring.impl; - -import lombok.Data; -import lombok.EqualsAndHashCode; -import org.deeplearning4j.eval.Evaluation; -import org.deeplearning4j.nn.graph.ComputationGraph; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator; - -/** - * Score function that calculates the accuracy on a - * test set for a {@link MultiLayerNetwork} or {@link ComputationGraph} - * - * @author Alex Black - * @deprecated Use {@link EvaluationScoreFunction} - */ -@Data -@EqualsAndHashCode(callSuper = true) -@Deprecated -public class TestSetAccuracyScoreFunction extends BaseNetScoreFunction { - - - @Override - public String toString() { - return "TestSetAccuracyScoreFunction()"; - } - - @Override - public double score(MultiLayerNetwork net, DataSetIterator iterator) { - Evaluation e = net.evaluate(iterator); - return e.accuracy(); - } - - @Override - public double score(MultiLayerNetwork net, MultiDataSetIterator iterator) { - throw new UnsupportedOperationException("Cannot evaluate MultiLayerNetwork on MultiDataSetIterator"); - } - - @Override - public double score(ComputationGraph graph, DataSetIterator iterator) { - Evaluation e = graph.evaluate(iterator); - return e.accuracy(); - } - - @Override - public double score(ComputationGraph graph, MultiDataSetIterator iterator) { - Evaluation e = graph.evaluate(iterator); - return e.accuracy(); - } - - @Override - public boolean minimize() { - return false; - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/TestSetF1ScoreFunction.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/TestSetF1ScoreFunction.java deleted file mode 100644 index 24516a1d7..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/TestSetF1ScoreFunction.java +++ /dev/null @@ -1,72 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.scoring.impl; - -import lombok.Data; -import lombok.EqualsAndHashCode; -import org.deeplearning4j.eval.Evaluation; -import org.deeplearning4j.nn.graph.ComputationGraph; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator; - -/** - * Score function that calculates the F1 score - * on a test set for a {@link MultiLayerNetwork} or {@link ComputationGraph} - * - * @author Alex Black - * @deprecated Use {@link EvaluationScoreFunction} - */ -@Data -@EqualsAndHashCode(callSuper = true) -@Deprecated -public class TestSetF1ScoreFunction extends BaseNetScoreFunction { - - @Override - public boolean minimize() { - return false; //false -> maximize - } - - - @Override - public String toString() { - return "TestSetF1ScoreFunction"; - } - - @Override - public double score(MultiLayerNetwork net, DataSetIterator iterator) { - Evaluation e = net.evaluate(iterator); - return e.f1(); - } - - @Override - public double score(MultiLayerNetwork net, MultiDataSetIterator iterator) { - throw new UnsupportedOperationException("Cannot evaluate MultiLayerNetwork on MultiDataSetIterator"); - } - - @Override - public double score(ComputationGraph graph, DataSetIterator iterator) { - Evaluation e = graph.evaluate(iterator); - return e.f1(); - } - - @Override - public double score(ComputationGraph graph, MultiDataSetIterator iterator) { - Evaluation e = graph.evaluate(iterator); - return e.f1(); - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/TestSetLossScoreFunction.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/TestSetLossScoreFunction.java deleted file mode 100644 index f44df800e..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/TestSetLossScoreFunction.java +++ /dev/null @@ -1,78 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.scoring.impl; - -import lombok.Data; -import lombok.EqualsAndHashCode; -import org.deeplearning4j.arbiter.scoring.util.ScoreUtil; -import org.deeplearning4j.nn.graph.ComputationGraph; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** - * Score function that calculates the test set loss - * on a test set for a {@link MultiLayerNetwork} or {@link ComputationGraph} - * - * @author Alex Black - */ -@Data -@EqualsAndHashCode(callSuper = false) -public class TestSetLossScoreFunction extends BaseNetScoreFunction { - @JsonProperty - private final boolean average; - - public TestSetLossScoreFunction() { - this(true); - } - - public TestSetLossScoreFunction(boolean average) { - this.average = average; - } - - - @Override - public boolean minimize() { - return true; - } - - @Override - public String toString() { - return "TestSetLossScoreFunction()"; - } - - @Override - public double score(MultiLayerNetwork net, DataSetIterator iterator) { - return ScoreUtil.score(net, iterator, average); - } - - @Override - public double score(MultiLayerNetwork net, MultiDataSetIterator iterator) { - throw new UnsupportedOperationException("Cannot evaluate MultiLayerNetwork on MultiDataSetIterator"); - } - - @Override - public double score(ComputationGraph graph, DataSetIterator iterator) { - return ScoreUtil.score(graph, iterator, average); - } - - @Override - public double score(ComputationGraph graph, MultiDataSetIterator iterator) { - return ScoreUtil.score(graph, iterator, average); - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/TestSetRegressionScoreFunction.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/TestSetRegressionScoreFunction.java deleted file mode 100644 index 0a27cea4e..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/impl/TestSetRegressionScoreFunction.java +++ /dev/null @@ -1,85 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.scoring.impl; - -import lombok.AccessLevel; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; -import org.deeplearning4j.arbiter.scoring.RegressionValue; -import org.deeplearning4j.arbiter.scoring.util.ScoreUtil; -import org.deeplearning4j.eval.RegressionEvaluation; -import org.deeplearning4j.nn.graph.ComputationGraph; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator; - -/** - * Score function for regression (including multi-label regression) for a MultiLayerNetwork or ComputationGraph - * on a test set - * - * @author Alex Black - * @deprecated Use {@link RegressionScoreFunction} - */ -@Data -@EqualsAndHashCode(callSuper = true) -@NoArgsConstructor(access = AccessLevel.PROTECTED) //For JSON -@Deprecated -public class TestSetRegressionScoreFunction extends BaseNetScoreFunction { - private RegressionValue regressionValue; - - /** - * @param regressionValue The type of evaluation to do: MSE, MAE, RMSE, etc - */ - public TestSetRegressionScoreFunction(RegressionValue regressionValue) { - this.regressionValue = regressionValue; - } - - - @Override - public boolean minimize() { - return regressionValue != RegressionValue.CorrCoeff; //Maximize correlation coefficient, minimize the remaining ones - } - - @Override - public String toString() { - return "TestSetRegressionScoreFunction(type=" + regressionValue + ")"; - } - - @Override - public double score(MultiLayerNetwork net, DataSetIterator iterator) { - RegressionEvaluation e = net.evaluateRegression(iterator); - return ScoreUtil.getScoreFromRegressionEval(e, regressionValue); - } - - @Override - public double score(MultiLayerNetwork net, MultiDataSetIterator iterator) { - throw new UnsupportedOperationException("Cannot evaluate MultiLayerNetwork on MultiDataSetIterator"); - } - - @Override - public double score(ComputationGraph graph, DataSetIterator iterator) { - RegressionEvaluation e = graph.evaluateRegression(iterator); - return ScoreUtil.getScoreFromRegressionEval(e, regressionValue); - } - - @Override - public double score(ComputationGraph graph, MultiDataSetIterator iterator) { - RegressionEvaluation e = graph.evaluateRegression(iterator); - return ScoreUtil.getScoreFromRegressionEval(e, regressionValue); - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/util/ScoreUtil.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/util/ScoreUtil.java deleted file mode 100644 index 303defe35..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/scoring/util/ScoreUtil.java +++ /dev/null @@ -1,328 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.scoring.util; - -import org.deeplearning4j.arbiter.scoring.RegressionValue; -import org.deeplearning4j.eval.Evaluation; -import org.deeplearning4j.eval.RegressionEvaluation; -import org.deeplearning4j.nn.graph.ComputationGraph; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.nd4j.linalg.api.ndarray.INDArray; -import org.nd4j.linalg.dataset.DataSet; -import org.nd4j.linalg.dataset.adapter.MultiDataSetIteratorAdapter; -import org.nd4j.linalg.dataset.api.MultiDataSet; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.DataSetIteratorFactory; -import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIteratorFactory; - - - -/** - * Various utilities for functions used in arbiter. - * - * @author Adam Gibson - */ -public class ScoreUtil { - - - - /** - * Get a {@link DataSetIterator} - * from the given object whether it's a {@link DataSetIterator} - * or {@link DataSetIteratorFactory}, any other type will throw - * an {@link IllegalArgumentException} - * @param o the object to get the iterator from - * @return the datasetiterator from the given objects - */ - public static MultiDataSetIterator getMultiIterator(Object o) { - if (o instanceof MultiDataSetIterator) { - return (MultiDataSetIterator) o; - } else if (o instanceof MultiDataSetIteratorFactory) { - MultiDataSetIteratorFactory factory = (MultiDataSetIteratorFactory) o; - return factory.create(); - } else if( o instanceof DataSetIterator ){ - return new MultiDataSetIteratorAdapter((DataSetIterator)o); - } else if( o instanceof DataSetIteratorFactory ){ - return new MultiDataSetIteratorAdapter(((DataSetIteratorFactory)o).create()); - } - - throw new IllegalArgumentException("Type must either be DataSetIterator or DataSetIteratorFactory"); - } - - - /** - * Get a {@link DataSetIterator} - * from the given object whether it's a {@link DataSetIterator} - * or {@link DataSetIteratorFactory}, any other type will throw - * an {@link IllegalArgumentException} - * @param o the object to get the iterator from - * @return the datasetiterator from the given objects - */ - public static DataSetIterator getIterator(Object o) { - if (o instanceof DataSetIterator) - return (DataSetIterator) o; - else if (o instanceof DataSetIteratorFactory) { - DataSetIteratorFactory factory = (DataSetIteratorFactory) o; - return factory.create(); - } - - throw new IllegalArgumentException("Type must either be DataSetIterator or DataSetIteratorFactory"); - } - - /** - * - * @param model - * @param testData - * @return - */ - public static Evaluation getEvaluation(MultiLayerNetwork model, DataSetIterator testData) { - return model.evaluate(testData); - } - - /** - * Get the evaluation - * for the given model and test dataset - * @param model the model to get the evaluation from - * @param testData the test data to do the evaluation on - * @return the evaluation object with accumulated statistics - * for the current test data - */ - public static Evaluation getEvaluation(ComputationGraph model, MultiDataSetIterator testData) { - if (model.getNumOutputArrays() != 1) - throw new IllegalStateException("GraphSetSetAccuracyScoreFunction cannot be " - + "applied to ComputationGraphs with more than one output. NumOutputs = " - + model.getNumOutputArrays()); - - return model.evaluate(testData); - } - - - /** - * Get the evaluation - * for the given model and test dataset - * @param model the model to get the evaluation from - * @param testData the test data to do the evaluation on - * @return the evaluation object with accumulated statistics - * for the current test data - */ - public static Evaluation getEvaluation(ComputationGraph model, DataSetIterator testData) { - if (model.getNumOutputArrays() != 1) - throw new IllegalStateException("GraphSetSetAccuracyScoreFunctionDataSet cannot be " - + "applied to ComputationGraphs with more than one output. NumOutputs = " - + model.getNumOutputArrays()); - - return model.evaluate(testData); - } - - - - /** - * Score based on the loss function - * @param model the model to score with - * @param testData the test data to score - * @param average whether to average the score - * for the whole batch or not - * @return the score for the given test set - */ - public static double score(ComputationGraph model, MultiDataSetIterator testData, boolean average) { - //TODO: do this properly taking into account division by N, L1/L2 etc - double sumScore = 0.0; - int totalExamples = 0; - while (testData.hasNext()) { - MultiDataSet ds = testData.next(); - long numExamples = ds.getFeatures(0).size(0); - sumScore += numExamples * model.score(ds); - totalExamples += numExamples; - } - - if (!average) - return sumScore; - return sumScore / totalExamples; - } - - /** - * Score based on the loss function - * @param model the model to score with - * @param testData the test data to score - * @param average whether to average the score - * for the whole batch or not - * @return the score for the given test set - */ - public static double score(ComputationGraph model, DataSetIterator testData, boolean average) { - //TODO: do this properly taking into account division by N, L1/L2 etc - double sumScore = 0.0; - int totalExamples = 0; - while (testData.hasNext()) { - DataSet ds = testData.next(); - int numExamples = ds.numExamples(); - - sumScore += numExamples * model.score(ds); - totalExamples += numExamples; - } - - if (!average) - return sumScore; - return sumScore / totalExamples; - } - - - /** - * - * @param model - * @param testSet - * @param regressionValue - * @return - */ - public static double score(ComputationGraph model, MultiDataSetIterator testSet, RegressionValue regressionValue) { - int nOutputs = model.getNumOutputArrays(); - - RegressionEvaluation[] evaluations = new RegressionEvaluation[nOutputs]; - for (int i = 0; i < evaluations.length; i++) - evaluations[i] = new RegressionEvaluation(); - - while (testSet.hasNext()) { - MultiDataSet next = testSet.next(); - INDArray[] labels = next.getLabels(); - - if (next.hasMaskArrays()) { - INDArray[] fMasks = next.getFeaturesMaskArrays(); - INDArray[] lMasks = next.getLabelsMaskArrays(); - - model.setLayerMaskArrays(fMasks, lMasks); - - INDArray[] outputs = model.output(false, next.getFeatures()); - for (int i = 0; i < evaluations.length; i++) { - if (lMasks != null && lMasks[i] != null) { - evaluations[i].evalTimeSeries(labels[i], outputs[i], lMasks[i]); - } else { - evaluations[i].evalTimeSeries(labels[i], outputs[i]); - } - } - - model.clearLayerMaskArrays(); - } else { - INDArray[] outputs = model.output(false, next.getFeatures()); - for (int i = 0; i < evaluations.length; i++) { - if (labels[i].rank() == 3) { - evaluations[i].evalTimeSeries(labels[i], outputs[i]); - } else { - evaluations[i].eval(labels[i], outputs[i]); - } - } - } - } - - double sum = 0.0; - int totalColumns = 0; - for (int i = 0; i < evaluations.length; i++) { - int nColumns = evaluations[i].numColumns(); - totalColumns += nColumns; - sum += getScoreFromRegressionEval(evaluations[i], regressionValue); - } - if (regressionValue == RegressionValue.CorrCoeff) - sum /= totalColumns; - - return sum; - } - - - /** - * Run a {@link RegressionEvaluation} - * over a {@link DataSetIterator} - * @param model the model to use - * @param testSet the test set iterator - * @param regressionValue the regression type to use - * @return - */ - public static double score(ComputationGraph model, DataSetIterator testSet, RegressionValue regressionValue) { - RegressionEvaluation evaluation = model.evaluateRegression(testSet); - return getScoreFromRegressionEval(evaluation, regressionValue); - } - - - /** - * Score the given test data - * with the given multi layer network - * @param model model to use - * @param testData the test data to test with - * @param average whether to average the score or not - * @return the score for the given test data given the model - */ - public static double score(MultiLayerNetwork model, DataSetIterator testData, boolean average) { - //TODO: do this properly taking into account division by N, L1/L2 etc - double sumScore = 0.0; - int totalExamples = 0; - while (testData.hasNext()) { - DataSet ds = testData.next(); - int numExamples = ds.numExamples(); - - sumScore += numExamples * model.score(ds); - totalExamples += numExamples; - } - - if (!average) - return sumScore; - return sumScore / totalExamples; - } - - - /** - * Score the given multi layer network - * @param model the model to score - * @param testSet the test set - * @param regressionValue the regression function to use - * @return the score from the given test set - */ - public static double score(MultiLayerNetwork model, DataSetIterator testSet, RegressionValue regressionValue) { - RegressionEvaluation eval = model.evaluateRegression(testSet); - return getScoreFromRegressionEval(eval, regressionValue); - } - - - @Deprecated - public static double getScoreFromRegressionEval(RegressionEvaluation eval, RegressionValue regressionValue) { - double sum = 0.0; - int nColumns = eval.numColumns(); - switch (regressionValue) { - case MSE: - for (int i = 0; i < nColumns; i++) - sum += eval.meanSquaredError(i); - break; - case MAE: - for (int i = 0; i < nColumns; i++) - sum += eval.meanAbsoluteError(i); - break; - case RMSE: - for (int i = 0; i < nColumns; i++) - sum += eval.rootMeanSquaredError(i); - break; - case RSE: - for (int i = 0; i < nColumns; i++) - sum += eval.relativeSquaredError(i); - break; - case CorrCoeff: - for (int i = 0; i < nColumns; i++) - sum += eval.correlationR2(i); - sum /= nColumns; - break; - } - - return sum; - } - -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/task/ComputationGraphTaskCreator.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/task/ComputationGraphTaskCreator.java deleted file mode 100644 index 53a9fe0aa..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/task/ComputationGraphTaskCreator.java +++ /dev/null @@ -1,267 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.task; - -import lombok.AllArgsConstructor; -import lombok.Getter; -import lombok.NoArgsConstructor; -import lombok.Setter; -import lombok.extern.slf4j.Slf4j; -import org.apache.commons.lang3.exception.ExceptionUtils; -import org.deeplearning4j.arbiter.GraphConfiguration; -import org.deeplearning4j.arbiter.listener.DL4JArbiterStatusReportingListener; -import org.deeplearning4j.arbiter.optimize.api.Candidate; -import org.deeplearning4j.arbiter.optimize.api.OptimizationResult; -import org.deeplearning4j.arbiter.optimize.api.TaskCreator; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSource; -import org.deeplearning4j.arbiter.optimize.api.evaluation.ModelEvaluator; -import org.deeplearning4j.arbiter.optimize.api.saving.ResultReference; -import org.deeplearning4j.arbiter.optimize.api.saving.ResultSaver; -import org.deeplearning4j.arbiter.optimize.api.score.ScoreFunction; -import org.deeplearning4j.arbiter.optimize.runner.CandidateInfo; -import org.deeplearning4j.arbiter.optimize.runner.CandidateStatus; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.listener.StatusListener; -import org.deeplearning4j.arbiter.scoring.util.ScoreUtil; -import org.deeplearning4j.earlystopping.EarlyStoppingConfiguration; -import org.deeplearning4j.earlystopping.EarlyStoppingResult; -import org.deeplearning4j.earlystopping.trainer.EarlyStoppingGraphTrainer; -import org.deeplearning4j.nn.graph.ComputationGraph; -import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator; -import org.nd4j.linalg.factory.Nd4j; - -import java.io.IOException; -import java.util.List; -import java.util.Properties; -import java.util.concurrent.Callable; - -/** - * Task creator for ComputationGraph - * - * @author Alex Black - */ -@AllArgsConstructor -@NoArgsConstructor -@Slf4j -public class ComputationGraphTaskCreator implements TaskCreator { - - private ModelEvaluator modelEvaluator; - @Getter - @Setter - private TaskListener taskListener; - - public ComputationGraphTaskCreator(ModelEvaluator modelEvaluator){ - this(modelEvaluator, null); - } - - @Override - public Callable create(Candidate candidate, DataProvider dataProvider, - ScoreFunction scoreFunction, List statusListener, - IOptimizationRunner runner) { - - return new GraphLearningTask(candidate, dataProvider, scoreFunction, modelEvaluator, statusListener, - taskListener, runner); - } - - @Override - public Callable create(Candidate candidate, Class dataSource, Properties dataSourceProperties, - ScoreFunction scoreFunction, List statusListeners, IOptimizationRunner runner) { - return new GraphLearningTask(candidate, dataSource, dataSourceProperties, scoreFunction, modelEvaluator, statusListeners, - taskListener, runner); - } - - @AllArgsConstructor - private static class GraphLearningTask implements Callable { - - private Candidate candidate; - private DataProvider dataProvider; - private Class dataSource; - private Properties dataSourceProperties; - private ScoreFunction scoreFunction; - private ModelEvaluator modelEvaluator; - private List listeners; - private TaskListener taskListener; - private IOptimizationRunner runner; - - private long startTime; - - public GraphLearningTask(Candidate candidate, DataProvider dataProvider, ScoreFunction scoreFunction, - ModelEvaluator modelEvaluator, List listeners, - TaskListener taskListener, IOptimizationRunner runner) { - this.candidate = candidate; - this.dataProvider = dataProvider; - this.scoreFunction = scoreFunction; - this.modelEvaluator = modelEvaluator; - this.listeners = listeners; - this.taskListener = taskListener; - this.runner = runner; - } - - public GraphLearningTask(Candidate candidate, Class dataSource, Properties dataSourceProperties, - ScoreFunction scoreFunction, ModelEvaluator modelEvaluator, List listeners, - TaskListener taskListener, IOptimizationRunner runner) { - this.candidate = candidate; - this.dataSource = dataSource; - this.dataSourceProperties = dataSourceProperties; - this.scoreFunction = scoreFunction; - this.modelEvaluator = modelEvaluator; - this.listeners = listeners; - this.taskListener = taskListener; - this.runner = runner; - } - - - @Override - public OptimizationResult call() throws Exception { - - try { - OptimizationResult result = callHelper(); - if(listeners != null && !listeners.isEmpty()){ - CandidateInfo ci = new CandidateInfo(candidate.getIndex(), CandidateStatus.Complete, result.getScore(), - startTime, startTime, System.currentTimeMillis(), candidate.getFlatParameters(), null); - for(StatusListener sl : listeners){ - try{ - sl.onCandidateStatusChange(ci, runner, result); - } catch (Exception e){ - log.error("Error in status listener for candidate {}", candidate.getIndex(), e); - } - } - } - return result; - } catch (Throwable e) { - String stackTrace = ExceptionUtils.getStackTrace(e); - log.warn("Execution failed for task {}", candidate.getIndex(), e); - - CandidateInfo ci = new CandidateInfo(candidate.getIndex(), CandidateStatus.Failed, null, startTime, - null, null, candidate.getFlatParameters(), stackTrace); - return new OptimizationResult(candidate, null, candidate.getIndex(), null, ci, null); - } finally { - //Destroy workspaces to free memory - Nd4j.getWorkspaceManager().destroyAllWorkspacesForCurrentThread(); - System.gc(); - try { - //Sleep for a few seconds - workspace destruction and memory deallocation happens quickly but doesn't - // happen instantly; if we didn't have this, we may run into a situation where the next thread/task - // tries to allocate before WS memory is fully deallocated, resulting in an OOM in memory constrained - // environments - Thread.sleep(2000L); - } catch (Exception e){ } - } - } - - private OptimizationResult callHelper() throws Exception { - startTime = System.currentTimeMillis(); - CandidateInfo ci = new CandidateInfo(candidate.getIndex(), CandidateStatus.Running, null, startTime, startTime, - null, candidate.getFlatParameters(), null); - - //Create network - ComputationGraph net = new ComputationGraph(((GraphConfiguration) candidate.getValue()).getConfiguration()); - net.init(); - - if(taskListener != null){ - net = taskListener.preProcess(net, candidate); - } - - if (listeners != null) { - net.addListeners(new DL4JArbiterStatusReportingListener(listeners, ci)); - } - - //For DataSetIterator: wraps in a MultiDataSetIterator, hence method can be used for both - MultiDataSetIterator iterator; - if(dataSource != null){ - try { - DataSource dsInstance = dataSource.newInstance(); - if (dataSourceProperties != null) - dsInstance.configure(dataSourceProperties); - iterator = ScoreUtil.getMultiIterator(dsInstance.trainData()); - } catch (Exception e){ - throw new RuntimeException("Error instantiating instance of DataSource for class " + dataSource.getName() + - " - no zero-arg constructor?",e); - } - } else { - iterator = ScoreUtil.getMultiIterator(dataProvider.trainData(candidate.getDataParameters())); - } - - - EarlyStoppingConfiguration esConfig = - ((GraphConfiguration) candidate.getValue()).getEarlyStoppingConfiguration(); - EarlyStoppingResult esResult = null; - if (esConfig != null) { - EarlyStoppingGraphTrainer trainer = new EarlyStoppingGraphTrainer(esConfig, net, iterator, null); - esResult = trainer.fit(); - net = esResult.getBestModel(); //Can return null if failed OR if - - switch (esResult.getTerminationReason()) { - case Error: - ci.setCandidateStatus(CandidateStatus.Failed); - ci.setExceptionStackTrace(esResult.getTerminationDetails()); - break; - case IterationTerminationCondition: - case EpochTerminationCondition: - ci.setCandidateStatus(CandidateStatus.Complete); - break; - } - - } else { - //Fixed number of epochs - int nEpochs = ((GraphConfiguration) candidate.getValue()).getNumEpochs(); - for (int i = 0; i < nEpochs; i++) { - net.fit(iterator); - } - ci.setCandidateStatus(CandidateStatus.Complete); - } - Nd4j.getExecutioner().commit(); - - Object additionalEvaluation = null; - if (esConfig != null && esResult.getTerminationReason() != EarlyStoppingResult.TerminationReason.Error) { - additionalEvaluation = - (modelEvaluator != null ? modelEvaluator.evaluateModel(net, dataProvider) : null); - } - - Double score = null; - if (net != null) { - if(dataSource != null){ - score = scoreFunction.score(net, dataSource, dataSourceProperties); - } else { - score = scoreFunction.score(net, dataProvider, candidate.getDataParameters()); - } - ci.setScore(score); - } - - if(taskListener != null){ - taskListener.postProcess(net, candidate); - } - - OptimizationResult result = new OptimizationResult(candidate, score, candidate.getIndex(), additionalEvaluation, ci, null); - - //Save the model: - ResultSaver saver = runner.getConfiguration().getResultSaver(); - ResultReference resultReference = null; - if (saver != null) { - try { - resultReference = saver.saveModel(result, net); - } catch (IOException e) { - //TODO: Do we want ta warn or fail on IOException? - log.warn("Error saving model (id={}): IOException thrown. ", result.getIndex(), e); - } - } - result.setResultReference(resultReference); - return result; - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/task/MultiLayerNetworkTaskCreator.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/task/MultiLayerNetworkTaskCreator.java deleted file mode 100644 index 5c2fb0703..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/task/MultiLayerNetworkTaskCreator.java +++ /dev/null @@ -1,265 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.task; - -import lombok.AllArgsConstructor; -import lombok.Getter; -import lombok.NoArgsConstructor; -import lombok.Setter; -import lombok.extern.slf4j.Slf4j; -import org.apache.commons.lang3.exception.ExceptionUtils; -import org.deeplearning4j.arbiter.DL4JConfiguration; -import org.deeplearning4j.arbiter.listener.DL4JArbiterStatusReportingListener; -import org.deeplearning4j.arbiter.optimize.api.Candidate; -import org.deeplearning4j.arbiter.optimize.api.OptimizationResult; -import org.deeplearning4j.arbiter.optimize.api.TaskCreator; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSource; -import org.deeplearning4j.arbiter.optimize.api.evaluation.ModelEvaluator; -import org.deeplearning4j.arbiter.optimize.api.saving.ResultReference; -import org.deeplearning4j.arbiter.optimize.api.saving.ResultSaver; -import org.deeplearning4j.arbiter.optimize.api.score.ScoreFunction; -import org.deeplearning4j.arbiter.optimize.runner.CandidateInfo; -import org.deeplearning4j.arbiter.optimize.runner.CandidateStatus; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.listener.StatusListener; -import org.deeplearning4j.arbiter.scoring.util.ScoreUtil; -import org.deeplearning4j.earlystopping.EarlyStoppingConfiguration; -import org.deeplearning4j.earlystopping.EarlyStoppingResult; -import org.deeplearning4j.earlystopping.trainer.EarlyStoppingTrainer; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.factory.Nd4j; - -import java.io.IOException; -import java.util.List; -import java.util.Properties; -import java.util.concurrent.Callable; - -/** - * Task creator for MultiLayerNetworks - * - * @author Alex Black - */ -@AllArgsConstructor -@NoArgsConstructor -@Slf4j -public class MultiLayerNetworkTaskCreator implements TaskCreator { - - private ModelEvaluator modelEvaluator; - @Getter - @Setter - private TaskListener taskListener; - - public MultiLayerNetworkTaskCreator(ModelEvaluator modelEvaluator){ - this(modelEvaluator, null); - } - - @Override - public Callable create(Candidate candidate, DataProvider dataProvider, - ScoreFunction scoreFunction, List statusListeners, - IOptimizationRunner runner) { - - return new DL4JLearningTask(candidate, dataProvider, scoreFunction, modelEvaluator, statusListeners, taskListener, runner); - } - - @Override - public Callable create(Candidate candidate, Class dataSource, Properties dataSourceProperties, - ScoreFunction scoreFunction, List statusListeners, IOptimizationRunner runner) { - return new DL4JLearningTask(candidate, dataSource, dataSourceProperties, scoreFunction, modelEvaluator, statusListeners, taskListener, runner); - } - - - private static class DL4JLearningTask implements Callable { - - private Candidate candidate; - private DataProvider dataProvider; - private Class dataSource; - private Properties dataSourceProperties; - private ScoreFunction scoreFunction; - private ModelEvaluator modelEvaluator; - private List listeners; - private TaskListener taskListener; - private IOptimizationRunner runner; - - private long startTime; - - public DL4JLearningTask(Candidate candidate, DataProvider dataProvider, ScoreFunction scoreFunction, - ModelEvaluator modelEvaluator, List listeners, TaskListener taskListener, - IOptimizationRunner runner) { - this.candidate = candidate; - this.dataProvider = dataProvider; - this.scoreFunction = scoreFunction; - this.modelEvaluator = modelEvaluator; - this.listeners = listeners; - this.taskListener = taskListener; - this.runner = runner; - } - - public DL4JLearningTask(Candidate candidate, Class dataSource, Properties dataSourceProperties, - ScoreFunction scoreFunction, ModelEvaluator modelEvaluator, List listeners, TaskListener taskListener, - IOptimizationRunner runner) { - this.candidate = candidate; - this.dataSource = dataSource; - this.dataSourceProperties = dataSourceProperties; - this.scoreFunction = scoreFunction; - this.modelEvaluator = modelEvaluator; - this.listeners = listeners; - this.taskListener = taskListener; - this.runner = runner; - } - - - @Override - public OptimizationResult call() { - - try { - OptimizationResult result = callHelper(); - if(listeners != null && !listeners.isEmpty()){ - CandidateInfo ci = new CandidateInfo(candidate.getIndex(), CandidateStatus.Complete, result.getScore(), - startTime, startTime, System.currentTimeMillis(), candidate.getFlatParameters(), null); - for(StatusListener sl : listeners){ - try{ - sl.onCandidateStatusChange(ci, runner, result); - } catch (Exception e){ - log.error("Error in status listener for candidate {}", candidate.getIndex(), e); - } - } - } - return result; - } catch (Throwable e) { - String stackTrace = ExceptionUtils.getStackTrace(e); - log.warn( "Execution failed for task {}", candidate.getIndex(), e ); - - CandidateInfo ci = new CandidateInfo(candidate.getIndex(), CandidateStatus.Failed, null, startTime, - null, null, candidate.getFlatParameters(), stackTrace); - return new OptimizationResult(candidate, null, candidate.getIndex(), null, ci, null); - } finally { - //Destroy workspaces to free memory - Nd4j.getWorkspaceManager().destroyAllWorkspacesForCurrentThread(); - System.gc(); - try { - //Sleep for a few seconds - workspace destruction and memory deallocation happens quickly but doesn't - // happen instantly; if we didn't have this, we may run into a situation where the next thread/task - // tries to allocate before WS memory is fully deallocated, resulting in an OOM in memory constrained - // environments - Thread.sleep(2000L); - } catch (Exception e){ } - } - } - - private OptimizationResult callHelper() { - startTime = System.currentTimeMillis(); - CandidateInfo ci = new CandidateInfo(candidate.getIndex(), CandidateStatus.Running, null, - startTime, startTime, null, candidate.getFlatParameters(), null); - - //Create network - MultiLayerNetwork net = new MultiLayerNetwork( - ((DL4JConfiguration) candidate.getValue()).getMultiLayerConfiguration()); - net.init(); - - if(taskListener != null){ - net = taskListener.preProcess(net, candidate); - } - - if (listeners != null) { - net.addListeners(new DL4JArbiterStatusReportingListener(listeners, ci)); - } - - //Early stopping or fixed number of epochs: - DataSetIterator dataSetIterator; - if(dataSource != null){ - DataSource dsInstance; - try{ - dsInstance = dataSource.newInstance(); - } catch (Exception e){ - throw new RuntimeException("Error instantiating instance of DataSource for class " + dataSource.getName() + - " - no zero-arg constructor?",e); - } - if(dataSourceProperties != null) - dsInstance.configure(dataSourceProperties); - dataSetIterator = ScoreUtil.getIterator(dsInstance.trainData()); - } else { - dataSetIterator = ScoreUtil.getIterator(dataProvider.trainData(candidate.getDataParameters())); - } - - - EarlyStoppingConfiguration esConfig = - ((DL4JConfiguration) candidate.getValue()).getEarlyStoppingConfiguration(); - EarlyStoppingResult esResult = null; - if (esConfig != null) { - EarlyStoppingTrainer trainer = new EarlyStoppingTrainer(esConfig, net, dataSetIterator, null); - esResult = trainer.fit(); - net = esResult.getBestModel(); //Can return null if failed OR if - - switch (esResult.getTerminationReason()) { - case Error: - ci.setCandidateStatus(CandidateStatus.Failed); - ci.setExceptionStackTrace(esResult.getTerminationDetails()); - break; - case IterationTerminationCondition: - case EpochTerminationCondition: - ci.setCandidateStatus(CandidateStatus.Complete); - break; - } - - } else { - //Fixed number of epochs - int nEpochs = ((DL4JConfiguration) candidate.getValue()).getNumEpochs(); - for (int i = 0; i < nEpochs; i++) { - net.fit(dataSetIterator); - } - ci.setCandidateStatus(CandidateStatus.Complete); - } - - Object additionalEvaluation = null; - if (esConfig != null && esResult.getTerminationReason() != EarlyStoppingResult.TerminationReason.Error) { - additionalEvaluation = - (modelEvaluator != null ? modelEvaluator.evaluateModel(net, dataProvider) : null); - } - - Double score = null; - if (net != null) { - if(dataSource != null){ - score = scoreFunction.score(net, dataSource, dataSourceProperties); - } else { - score = scoreFunction.score(net, dataProvider, candidate.getDataParameters()); - } - ci.setScore(score); - } - - if(taskListener != null){ - taskListener.postProcess(net, candidate); - } - - OptimizationResult result = new OptimizationResult(candidate, score, candidate.getIndex(), additionalEvaluation, ci, null); - //Save the model: - ResultSaver saver = runner.getConfiguration().getResultSaver(); - ResultReference resultReference = null; - if (saver != null) { - try { - resultReference = saver.saveModel(result, net); - } catch (IOException e) { - //TODO: Do we want ta warn or fail on IOException? - log.warn("Error saving model (id={}): IOException thrown. ", result.getIndex(), e); - } - } - result.setResultReference(resultReference); - return result; - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/task/TaskListener.java b/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/task/TaskListener.java deleted file mode 100644 index ecf262548..000000000 --- a/arbiter/arbiter-deeplearning4j/src/main/java/org/deeplearning4j/arbiter/task/TaskListener.java +++ /dev/null @@ -1,49 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.task; - -import org.deeplearning4j.arbiter.optimize.api.Candidate; -import org.deeplearning4j.nn.api.Model; - -import java.io.Serializable; - -/** - * TaskListener: can be used to preprocess and post process a model (MultiLayerNetwork or ComputationGraph) before/after - * training, in a {@link MultiLayerNetworkTaskCreator} or {@link ComputationGraphTaskCreator} - * - * @author Alex Black - */ -public interface TaskListener extends Serializable { - - /** - * Preprocess the model, before any training has taken place. - *
- * Can be used to (for example) set listeners on a model before training starts - * @param model Model to preprocess - * @param candidate Candidate information, for the current model - * @return The updated model (usually the same one as the input, perhaps with modifications) - */ - T preProcess(T model, Candidate candidate); - - /** - * Post process the model, after any training has taken place - * @param model Model to postprocess - * @param candidate Candidate information, for the current model - */ - void postProcess(Model model, Candidate candidate); - -} diff --git a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/AssertTestsExtendBaseClass.java b/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/AssertTestsExtendBaseClass.java deleted file mode 100644 index 06e00219f..000000000 --- a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/AssertTestsExtendBaseClass.java +++ /dev/null @@ -1,50 +0,0 @@ -/* ****************************************************************************** - * Copyright (c) 2020 Konduit K.K. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ -package org.deeplearning4j.arbiter; - -import lombok.extern.slf4j.Slf4j; -import org.deeplearning4j.BaseDL4JTest; -import org.nd4j.common.tests.AbstractAssertTestsClass; - -import java.util.*; - -/** - * This class checks that all test classes (i.e., anything with one or more methods annotated with @Test) - * extends BaseDl4jTest - either directly or indirectly. - * Other than a small set of exceptions, all tests must extend this - * - * @author Alex Black - */ - -@Slf4j -public class AssertTestsExtendBaseClass extends AbstractAssertTestsClass { - - @Override - protected Set> getExclusions() { - //Set of classes that are exclusions to the rule (either run manually or have their own logging + timeouts) - return new HashSet<>(); - } - - @Override - protected String getPackageName() { - return "org.deeplearning4j.arbiter"; - } - - @Override - protected Class getBaseClass() { - return BaseDL4JTest.class; - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/TestUtils.java b/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/TestUtils.java deleted file mode 100644 index ea5e0eddd..000000000 --- a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/TestUtils.java +++ /dev/null @@ -1,243 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter; - -import org.apache.commons.compress.utils.IOUtils; -import org.deeplearning4j.nn.conf.ComputationGraphConfiguration; -import org.deeplearning4j.nn.conf.MultiLayerConfiguration; -import org.deeplearning4j.nn.conf.layers.BaseLayer; -import org.deeplearning4j.nn.conf.layers.samediff.AbstractSameDiffLayer; -import org.deeplearning4j.nn.graph.ComputationGraph; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.deeplearning4j.util.ModelSerializer; -import org.nd4j.linalg.api.ndarray.INDArray; -import org.nd4j.linalg.api.ops.random.impl.BernoulliDistribution; -import org.nd4j.linalg.factory.Nd4j; -import org.nd4j.linalg.learning.regularization.L1Regularization; -import org.nd4j.linalg.learning.regularization.L2Regularization; -import org.nd4j.linalg.learning.regularization.Regularization; -import org.nd4j.linalg.learning.regularization.WeightDecay; - -import java.io.*; -import java.util.List; -import java.util.Random; - -import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.junit.jupiter.api.Assertions.assertNotNull; - -public class TestUtils { - - public static MultiLayerNetwork testModelSerialization(MultiLayerNetwork net){ - - MultiLayerNetwork restored; - try { - ByteArrayOutputStream baos = new ByteArrayOutputStream(); - ModelSerializer.writeModel(net, baos, true); - byte[] bytes = baos.toByteArray(); - - ByteArrayInputStream bais = new ByteArrayInputStream(bytes); - restored = ModelSerializer.restoreMultiLayerNetwork(bais, true); - - assertEquals(net.getLayerWiseConfigurations(), restored.getLayerWiseConfigurations()); - assertEquals(net.params(), restored.params()); - } catch (IOException e){ - //Should never happen - throw new RuntimeException(e); - } - - //Also check the MultiLayerConfiguration is serializable (required by Spark etc) - MultiLayerConfiguration conf = net.getLayerWiseConfigurations(); - serializeDeserializeJava(conf); - - return restored; - } - - public static ComputationGraph testModelSerialization(ComputationGraph net){ - - ComputationGraph restored; - try { - ByteArrayOutputStream baos = new ByteArrayOutputStream(); - ModelSerializer.writeModel(net, baos, true); - byte[] bytes = baos.toByteArray(); - - ByteArrayInputStream bais = new ByteArrayInputStream(bytes); - restored = ModelSerializer.restoreComputationGraph(bais, true); - - assertEquals(net.getConfiguration(), restored.getConfiguration()); - assertEquals(net.params(), restored.params()); - } catch (IOException e){ - //Should never happen - throw new RuntimeException(e); - } - - //Also check the ComputationGraphConfiguration is serializable (required by Spark etc) - ComputationGraphConfiguration conf = net.getConfiguration(); - serializeDeserializeJava(conf); - - return restored; - } - - private static T serializeDeserializeJava(T object){ - byte[] bytes; - try(ByteArrayOutputStream baos = new ByteArrayOutputStream(); ObjectOutputStream oos = new ObjectOutputStream(baos)){ - oos.writeObject(object); - oos.close(); - bytes = baos.toByteArray(); - } catch (IOException e){ - //Should never happen - throw new RuntimeException(e); - } - - T out; - try(ObjectInputStream ois = new ObjectInputStream(new ByteArrayInputStream(bytes))){ - out = (T)ois.readObject(); - } catch (IOException | ClassNotFoundException e){ - throw new RuntimeException(e); - } - - assertEquals(object, out); - return out; - } - - public static INDArray randomOneHot(long examples, long nOut){ - return randomOneHot(examples, nOut, new Random(12345)); - } - - public static INDArray randomOneHot(long examples, long nOut, long rngSeed){ - return randomOneHot(examples, nOut, new Random(rngSeed)); - } - - public static INDArray randomOneHot(long examples, long nOut, Random rng){ - INDArray arr = Nd4j.create(examples, nOut); - for( int i=0; i l){ - for(Regularization r : l){ - if(r instanceof L1Regularization){ - return (L1Regularization) r; - } - } - return null; - } - - public static L2Regularization getL2Reg(BaseLayer baseLayer){ - return getL2Reg(baseLayer.getRegularization()); - } - - public static L2Regularization getL2Reg(List l){ - for(Regularization r : l){ - if(r instanceof L2Regularization){ - return (L2Regularization) r; - } - } - return null; - } - - public static WeightDecay getWeightDecayReg(BaseLayer bl){ - return getWeightDecayReg(bl.getRegularization()); - } - - public static WeightDecay getWeightDecayReg(List l){ - for(Regularization r : l){ - if(r instanceof WeightDecay){ - return (WeightDecay) r; - } - } - return null; - } - - public static double getL1(BaseLayer layer) { - List l = layer.getRegularization(); - return getL1(l); - } - - public static double getL1(List l){ - L1Regularization l1Reg = null; - for(Regularization reg : l){ - if(reg instanceof L1Regularization) - l1Reg = (L1Regularization) reg; - } - assertNotNull(l1Reg); - return l1Reg.getL1().valueAt(0,0); - } - - public static double getL2(BaseLayer layer) { - List l = layer.getRegularization(); - return getL2(l); - } - - public static double getL2(List l){ - L2Regularization l2Reg = null; - for(Regularization reg : l){ - if(reg instanceof L2Regularization) - l2Reg = (L2Regularization) reg; - } - assertNotNull(l2Reg); - return l2Reg.getL2().valueAt(0,0); - } - - public static double getL1(AbstractSameDiffLayer layer){ - return getL1(layer.getRegularization()); - } - - public static double getL2(AbstractSameDiffLayer layer){ - return getL2(layer.getRegularization()); - } - - public static double getWeightDecay(BaseLayer layer) { - return getWeightDecayReg(layer.getRegularization()).getCoeff().valueAt(0,0); - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/computationgraph/TestComputationGraphSpace.java b/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/computationgraph/TestComputationGraphSpace.java deleted file mode 100644 index b34280911..000000000 --- a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/computationgraph/TestComputationGraphSpace.java +++ /dev/null @@ -1,168 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.computationgraph; - -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.ComputationGraphSpace; -import org.deeplearning4j.arbiter.TestUtils; -import org.deeplearning4j.arbiter.conf.updater.SgdSpace; -import org.deeplearning4j.arbiter.layers.DenseLayerSpace; -import org.deeplearning4j.arbiter.layers.OutputLayerSpace; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.continuous.ContinuousParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.discrete.DiscreteParameterSpace; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.nn.conf.ComputationGraphConfiguration; -import org.deeplearning4j.nn.conf.NeuralNetConfiguration; -import org.deeplearning4j.nn.conf.graph.LayerVertex; -import org.deeplearning4j.nn.conf.inputs.InputType; -import org.deeplearning4j.nn.conf.layers.BaseLayer; -import org.deeplearning4j.nn.conf.layers.DenseLayer; -import org.deeplearning4j.nn.conf.layers.OutputLayer; -import org.junit.jupiter.api.Test; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.activations.IActivation; -import org.nd4j.linalg.learning.config.Sgd; -import org.nd4j.linalg.lossfunctions.LossFunctions.LossFunction; - -import java.util.List; -import java.util.Random; - -import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.junit.jupiter.api.Assertions.assertTrue; - -public class TestComputationGraphSpace extends BaseDL4JTest { - - @Test - public void testBasic() { - - ComputationGraphConfiguration expected = new NeuralNetConfiguration.Builder() - .updater(new Sgd(0.005)) - .seed(12345) - .graphBuilder().addInputs("in") - .addLayer("0", new DenseLayer.Builder().nIn(10).nOut(10).build(), "in") - .addLayer("1", new DenseLayer.Builder().nIn(10).nOut(10).build(), "0").addLayer("2", - new OutputLayer.Builder().lossFunction(LossFunction.MCXENT) - .activation(Activation.SOFTMAX) - .nIn(10).nOut(5) - .build(), - "1") - .setOutputs("2").build(); - - ComputationGraphSpace cgs = new ComputationGraphSpace.Builder() - .updater(new Sgd(0.005)) - .seed(12345).addInputs("in") - .addLayer("0", new DenseLayerSpace.Builder().nIn(10).nOut(10).build(), "in") - .addLayer("1", new DenseLayerSpace.Builder().nIn(10).nOut(10).build(), "0") - .addLayer("2", new OutputLayerSpace.Builder().lossFunction(LossFunction.MCXENT).activation(Activation.SOFTMAX).nIn(10).nOut(5) - .build(), "1") - .setOutputs("2").setInputTypes(InputType.feedForward(10)) - .build(); - - int nParams = cgs.numParameters(); - assertEquals(0, nParams); - - ComputationGraphConfiguration conf = cgs.getValue(new double[0]).getConfiguration(); - - assertEquals(expected, conf); - } - - @Test - public void testBasic2() { - - ComputationGraphSpace mls = new ComputationGraphSpace.Builder() - .updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.1))) - .l2(new ContinuousParameterSpace(0.2, 0.5)) - .addInputs("in").addLayer("0", - new DenseLayerSpace.Builder().nIn(10).nOut(10) - .activation(new DiscreteParameterSpace<>(Activation.RELU, - Activation.TANH)) - .build(), - "in") - .addLayer("1", new OutputLayerSpace.Builder().nIn(10).nOut(10).activation(Activation.SOFTMAX) - .build(), "0") - .setOutputs("1").setInputTypes(InputType.feedForward(10)).build(); - - int nParams = mls.numParameters(); - assertEquals(3, nParams); - - //Assign numbers to each leaf ParameterSpace object (normally done by candidate generator) - List noDuplicatesList = LeafUtils.getUniqueObjects(mls.collectLeaves()); - - //Second: assign each a number - int c = 0; - for (ParameterSpace ps : noDuplicatesList) { - int np = ps.numParameters(); - if (np == 1) { - ps.setIndices(c++); - } else { - int[] values = new int[np]; - for (int j = 0; j < np; j++) - values[c++] = j; - ps.setIndices(values); - } - } - - int reluCount = 0; - int tanhCount = 0; - - Random r = new Random(12345); - - for (int i = 0; i < 50; i++) { - - double[] rvs = new double[nParams]; - for (int j = 0; j < rvs.length; j++) - rvs[j] = r.nextDouble(); - - - ComputationGraphConfiguration conf = mls.getValue(rvs).getConfiguration(); - - int nLayers = conf.getVertexInputs().size(); - assertEquals(2, nLayers); - - for (int j = 0; j < nLayers; j++) { - NeuralNetConfiguration layerConf = - ((LayerVertex) conf.getVertices().get(String.valueOf(j))).getLayerConf(); - - double lr = ((Sgd)((BaseLayer) layerConf.getLayer()).getIUpdater()).getLearningRate(); - assertTrue(lr >= 0.0001 && lr <= 0.1); - double l2 = TestUtils.getL2(((BaseLayer) layerConf.getLayer())); - assertTrue(l2 >= 0.2 && l2 <= 0.5); - - if (j == nLayers - 1) { //Output layer - assertEquals(Activation.SOFTMAX.getActivationFunction(), - ((BaseLayer) layerConf.getLayer()).getActivationFn()); - } else { - IActivation actFn = ((BaseLayer) layerConf.getLayer()).getActivationFn(); - assertTrue(Activation.RELU.getActivationFunction().equals(actFn) || - Activation.TANH.getActivationFunction().equals(actFn)); - if (Activation.RELU.getActivationFunction().equals(actFn)) - reluCount++; - else - tanhCount++; - } - } - } - -// System.out.println("ReLU vs. Tanh: " + reluCount + "\t" + tanhCount); - assertTrue(reluCount > 0); - assertTrue(tanhCount > 0); - - } - - -} diff --git a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/computationgraph/TestGraphLocalExecution.java b/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/computationgraph/TestGraphLocalExecution.java deleted file mode 100644 index e9b8a7f73..000000000 --- a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/computationgraph/TestGraphLocalExecution.java +++ /dev/null @@ -1,373 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.computationgraph; - -import lombok.extern.slf4j.Slf4j; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.ComputationGraphSpace; -import org.deeplearning4j.arbiter.conf.updater.AdamSpace; -import org.deeplearning4j.arbiter.conf.updater.SgdSpace; -import org.deeplearning4j.arbiter.evaluator.multilayer.ClassificationEvaluator; -import org.deeplearning4j.arbiter.layers.DenseLayerSpace; -import org.deeplearning4j.arbiter.layers.OutputLayerSpace; -import org.deeplearning4j.arbiter.multilayernetwork.TestDL4JLocalExecution; -import org.deeplearning4j.arbiter.optimize.api.CandidateGenerator; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSetIteratorFactoryProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSource; -import org.deeplearning4j.arbiter.optimize.api.saving.ResultReference; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxCandidatesCondition; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxTimeCondition; -import org.deeplearning4j.arbiter.optimize.generator.RandomSearchGenerator; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; -import org.deeplearning4j.arbiter.optimize.parameter.continuous.ContinuousParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.discrete.DiscreteParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.integer.IntegerParameterSpace; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.LocalOptimizationRunner; -import org.deeplearning4j.arbiter.saver.local.FileModelSaver; -import org.deeplearning4j.arbiter.scoring.ScoreFunctions; -import org.deeplearning4j.arbiter.scoring.impl.TestSetLossScoreFunction; -import org.deeplearning4j.arbiter.task.ComputationGraphTaskCreator; -import org.deeplearning4j.arbiter.util.TestDataFactoryProviderMnist; -import org.deeplearning4j.datasets.iterator.MultipleEpochsIterator; -import org.deeplearning4j.datasets.iterator.impl.MnistDataSetIterator; -import org.deeplearning4j.earlystopping.EarlyStoppingConfiguration; -import org.deeplearning4j.earlystopping.saver.InMemoryModelSaver; -import org.deeplearning4j.earlystopping.scorecalc.DataSetLossCalculatorCG; -import org.deeplearning4j.earlystopping.scorecalc.ScoreCalculator; -import org.deeplearning4j.earlystopping.termination.MaxEpochsTerminationCondition; -import org.deeplearning4j.nn.api.OptimizationAlgorithm; -import org.deeplearning4j.nn.conf.inputs.InputType; -import org.deeplearning4j.nn.graph.ComputationGraph; -import org.junit.jupiter.api.BeforeAll; -import org.junit.jupiter.api.Test; -import org.junit.jupiter.api.io.TempDir; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.api.buffer.DataType; -import org.nd4j.linalg.dataset.adapter.MultiDataSetIteratorAdapter; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator; -import org.nd4j.linalg.factory.Nd4j; -import org.nd4j.common.function.Supplier; -import org.nd4j.linalg.lossfunctions.LossFunctions; -import com.fasterxml.jackson.annotation.JsonProperty; - -import java.io.File; -import java.io.IOException; -import java.io.Serializable; -import java.util.HashMap; -import java.util.List; -import java.util.Map; -import java.util.Properties; -import java.util.concurrent.TimeUnit; - -import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.junit.jupiter.api.Assertions.assertTrue; - -@Slf4j -public class TestGraphLocalExecution extends BaseDL4JTest { - - @TempDir - public File testDir; - - @BeforeAll - public static void before(){ - Nd4j.setDefaultDataTypes(DataType.FLOAT, DataType.FLOAT); - } - - @Override - public long getTimeoutMilliseconds() { - return 120_000L; - } - - @Test - public void testLocalExecutionDataSources() throws Exception { - - for( int dataApproach = 0; dataApproach<3; dataApproach++ ) { - log.info("////////////////// Starting Test: {} ///////////////////", dataApproach); - - //Define: network config (hyperparameter space) - ComputationGraphSpace mls = new ComputationGraphSpace.Builder() - .optimizationAlgo(OptimizationAlgorithm.STOCHASTIC_GRADIENT_DESCENT) - .updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.1))) - .l2(new ContinuousParameterSpace(0.0001, 0.01)) - .addInputs("in") - .addLayer("0", - new DenseLayerSpace.Builder().nIn(784).nOut(new IntegerParameterSpace(10, 20)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, - Activation.TANH)) - .build(), "in") //1-2 identical layers (except nIn) - .addLayer("1", new OutputLayerSpace.Builder().nOut(10).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build(), "0") - .setOutputs("1") - .setInputTypes(InputType.feedForward(784)) - .numEpochs(3).build(); - - DataProvider dp = null; - Class ds = null; - Properties dsP = null; - CandidateGenerator candidateGenerator; - - if(dataApproach == 0){ - ds = TestDL4JLocalExecution.MnistDataSource.class; - dsP = new Properties(); - dsP.setProperty("minibatch", "2"); - candidateGenerator = new RandomSearchGenerator(mls); - } else if(dataApproach == 1) { - //DataProvider approach - dp = new TestDL4JLocalExecution.MnistDataProvider(); - candidateGenerator = new RandomSearchGenerator(mls); - } else { - //Factory approach - Map commands = new HashMap<>(); - commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY, TestDataFactoryProviderMnist.class.getCanonicalName()); - - candidateGenerator = new RandomSearchGenerator(mls, commands); - dp = new DataSetIteratorFactoryProvider(); - } - - File f = testDir; - File modelSave = new File(f, "modelSaveDir"); - - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator) - .dataProvider(dp) - .dataSource(ds, dsP) - .modelSaver(new FileModelSaver(modelSave)) - .scoreFunction(new TestSetLossScoreFunction()) - .terminationConditions(new MaxTimeCondition(20, TimeUnit.SECONDS), - new MaxCandidatesCondition(3)) - .build(); - - IOptimizationRunner runner = new LocalOptimizationRunner(configuration,new ComputationGraphTaskCreator(new ClassificationEvaluator())); - - runner.execute(); - - List results = runner.getResults(); - assertTrue(results.size() > 0); - -// System.out.println("----- COMPLETE - " + results.size() + " results -----"); - } - } - - - @Test - public void testLocalExecution() throws Exception { - Map commands = new HashMap<>(); - commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY, TestDataFactoryProviderMnist.class.getCanonicalName()); - - //Define: network config (hyperparameter space) - ComputationGraphSpace mls = new ComputationGraphSpace.Builder() - .optimizationAlgo(OptimizationAlgorithm.STOCHASTIC_GRADIENT_DESCENT) - .updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.1))) - .l2(new ContinuousParameterSpace(0.0001, 0.01)).addInputs("in") - .setInputTypes(InputType.feedForward(4)) - .addLayer("layer0", - new DenseLayerSpace.Builder().nIn(784).nOut(new IntegerParameterSpace(2, 10)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, Activation.TANH)) - .build(), - "in") - .addLayer("out", new OutputLayerSpace.Builder().nOut(10).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build(), "layer0") - .setOutputs("out").numEpochs(3).build(); - - //Define configuration: - CandidateGenerator candidateGenerator = new RandomSearchGenerator(mls, commands); - DataProvider dataProvider = new DataSetIteratorFactoryProvider(); - - String modelSavePath = new File(System.getProperty("java.io.tmpdir"), "ArbiterDL4JTest\\").getAbsolutePath(); - - File f = new File(modelSavePath); - if (f.exists()) - f.delete(); - f.mkdir(); - f.deleteOnExit(); - if (!f.exists()) - throw new RuntimeException(); - - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).dataProvider(dataProvider) - .modelSaver(new FileModelSaver(modelSavePath)).scoreFunction(ScoreFunctions.testSetLoss(true)) - .terminationConditions(new MaxTimeCondition(30, TimeUnit.SECONDS), - new MaxCandidatesCondition(3)) - .build(); - - IOptimizationRunner runner = new LocalOptimizationRunner(configuration, - new ComputationGraphTaskCreator(new ClassificationEvaluator())); - - runner.execute(); - - assertEquals(0, runner.numCandidatesFailed()); - assertTrue(runner.numCandidatesCompleted() > 0); - } - - @Test - public void testLocalExecutionMDS() throws Exception { - //Define: network config (hyperparameter space) - ComputationGraphSpace mls = new ComputationGraphSpace.Builder() - .optimizationAlgo(OptimizationAlgorithm.STOCHASTIC_GRADIENT_DESCENT) - .updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.1))) - .l2(new ContinuousParameterSpace(0.0001, 0.01)).addInputs("in") - .setInputTypes(InputType.feedForward(784)) - .addLayer("layer0", - new DenseLayerSpace.Builder().nIn(784).nOut(new IntegerParameterSpace(2, 10)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, Activation.TANH)) - .build(), - "in") - .addLayer("out", new OutputLayerSpace.Builder().nOut(10).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build(), "layer0") - .setOutputs("out").numEpochs(3).build(); - - //Define configuration: - CandidateGenerator candidateGenerator = new RandomSearchGenerator(mls, null); - - String modelSavePath = new File(System.getProperty("java.io.tmpdir"), "ArbiterDL4JTest\\").getAbsolutePath(); - - File f = new File(modelSavePath); - if (f.exists()) - f.delete(); - f.mkdir(); - f.deleteOnExit(); - if (!f.exists()) - throw new RuntimeException(); - - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator) - .dataProvider(new TestMdsDataProvider(1, 32)) - .modelSaver(new FileModelSaver(modelSavePath)).scoreFunction(ScoreFunctions.testSetLoss(true)) - .terminationConditions(new MaxTimeCondition(30, TimeUnit.SECONDS), - new MaxCandidatesCondition(3)) - .scoreFunction(ScoreFunctions.testSetAccuracy()) - .build(); - - IOptimizationRunner runner = new LocalOptimizationRunner(configuration, new ComputationGraphTaskCreator()); - - runner.execute(); - - assertEquals(0, runner.numCandidatesFailed()); - assertTrue(runner.numCandidatesCompleted() > 0); - } - - public static class TestMdsDataProvider implements DataProvider { - private int numEpochs; - private int batchSize; - - public TestMdsDataProvider(@JsonProperty("numEpochs") int numEpochs, @JsonProperty("batchSize") int batchSize) { - this.numEpochs = numEpochs; - this.batchSize = batchSize; - } - - private TestMdsDataProvider() { - } - - - @Override - public Object trainData(Map dataParameters) { - try { - DataSetIterator underlying = new MnistDataSetIterator(batchSize, Math.min(60000, 3 * batchSize), false, true, true, 12345); - return new MultiDataSetIteratorAdapter(new MultipleEpochsIterator(numEpochs, underlying)); - } catch (IOException e) { - throw new RuntimeException(e); - } - } - - @Override - public Object testData(Map dataParameters) { - try { - DataSetIterator underlying = new MnistDataSetIterator(batchSize, Math.min(10000, 2 * batchSize), false, false, false, 12345); - return new MultiDataSetIteratorAdapter(underlying); - } catch (IOException e) { - throw new RuntimeException(e); - } - } - - @Override - public Class getDataType() { - return MultiDataSetIterator.class; - } - } - - @Test - public void testLocalExecutionEarlyStopping() throws Exception { - EarlyStoppingConfiguration esConf = new EarlyStoppingConfiguration.Builder() - .epochTerminationConditions(new MaxEpochsTerminationCondition(2)) - .scoreCalculator(new ScoreProvider()) - .modelSaver(new InMemoryModelSaver()).build(); - Map commands = new HashMap<>(); - commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY, TestDataFactoryProviderMnist.class.getCanonicalName()); - - //Define: network config (hyperparameter space) - ComputationGraphSpace cgs = new ComputationGraphSpace.Builder() - .optimizationAlgo(OptimizationAlgorithm.STOCHASTIC_GRADIENT_DESCENT) - .updater(new AdamSpace(new ContinuousParameterSpace(0.0001, 0.1))) - .l2(new ContinuousParameterSpace(0.0001, 0.01)).addInputs("in") - .setInputTypes(InputType.feedForward(784)) - .addLayer("first", - new DenseLayerSpace.Builder().nIn(784).nOut(new IntegerParameterSpace(2, 10)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, - Activation.TANH)) - .build(), - "in") //1-2 identical layers (except nIn) - .addLayer("out", new OutputLayerSpace.Builder().nOut(10).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build(), "first") - .setOutputs("out").earlyStoppingConfiguration(esConf).build(); - - //Define configuration: - - CandidateGenerator candidateGenerator = new RandomSearchGenerator(cgs, commands); - DataProvider dataProvider = new DataSetIteratorFactoryProvider(); - - - String modelSavePath = new File(System.getProperty("java.io.tmpdir"), "ArbiterDL4JTest2CG\\").getAbsolutePath(); - - File f = new File(modelSavePath); - if (f.exists()) - f.delete(); - f.mkdir(); - f.deleteOnExit(); - if (!f.exists()) - throw new RuntimeException(); - - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator) - .dataProvider(dataProvider) - .scoreFunction(ScoreFunctions.testSetF1()) - .modelSaver(new FileModelSaver(modelSavePath)) - .terminationConditions(new MaxTimeCondition(15, TimeUnit.SECONDS), - new MaxCandidatesCondition(3)) - .build(); - - - IOptimizationRunner runner = new LocalOptimizationRunner(configuration, new ComputationGraphTaskCreator()); - runner.execute(); - - assertEquals(0, runner.numCandidatesFailed()); - assertTrue(runner.numCandidatesCompleted() > 0); - } - - private static class ScoreProvider implements Supplier, Serializable { - @Override - public ScoreCalculator get() { - try { - return new DataSetLossCalculatorCG(new MnistDataSetIterator(4, 8), true); - } catch (Exception e){ - throw new RuntimeException(e); - } - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/computationgraph/TestGraphLocalExecutionGenetic.java b/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/computationgraph/TestGraphLocalExecutionGenetic.java deleted file mode 100644 index 05815a020..000000000 --- a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/computationgraph/TestGraphLocalExecutionGenetic.java +++ /dev/null @@ -1,212 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.computationgraph; - -import lombok.extern.slf4j.Slf4j; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.ComputationGraphSpace; -import org.deeplearning4j.arbiter.conf.updater.SgdSpace; -import org.deeplearning4j.arbiter.evaluator.multilayer.ClassificationEvaluator; -import org.deeplearning4j.arbiter.layers.DenseLayerSpace; -import org.deeplearning4j.arbiter.layers.OutputLayerSpace; -import org.deeplearning4j.arbiter.multilayernetwork.TestDL4JLocalExecution; -import org.deeplearning4j.arbiter.optimize.api.CandidateGenerator; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSetIteratorFactoryProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSource; -import org.deeplearning4j.arbiter.optimize.api.saving.ResultReference; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxCandidatesCondition; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxTimeCondition; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; -import org.deeplearning4j.arbiter.optimize.generator.GeneticSearchCandidateGenerator; -import org.deeplearning4j.arbiter.optimize.generator.genetic.population.PopulationModel; -import org.deeplearning4j.arbiter.optimize.parameter.continuous.ContinuousParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.discrete.DiscreteParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.integer.IntegerParameterSpace; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.LocalOptimizationRunner; -import org.deeplearning4j.arbiter.saver.local.FileModelSaver; -import org.deeplearning4j.arbiter.scoring.impl.TestSetLossScoreFunction; -import org.deeplearning4j.arbiter.task.ComputationGraphTaskCreator; -import org.deeplearning4j.arbiter.util.TestDataFactoryProviderMnist; -import org.deeplearning4j.datasets.iterator.MultipleEpochsIterator; -import org.deeplearning4j.datasets.iterator.impl.MnistDataSetIterator; -import org.deeplearning4j.earlystopping.scorecalc.DataSetLossCalculatorCG; -import org.deeplearning4j.earlystopping.scorecalc.ScoreCalculator; -import org.deeplearning4j.nn.api.OptimizationAlgorithm; -import org.deeplearning4j.nn.conf.inputs.InputType; -import org.junit.jupiter.api.Test; -import org.junit.jupiter.api.io.TempDir; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.dataset.adapter.MultiDataSetIteratorAdapter; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator; -import org.nd4j.common.function.Supplier; -import org.nd4j.linalg.lossfunctions.LossFunctions; -import com.fasterxml.jackson.annotation.JsonProperty; - -import java.io.File; -import java.io.IOException; -import java.io.Serializable; -import java.util.HashMap; -import java.util.List; -import java.util.Map; -import java.util.Properties; -import java.util.concurrent.TimeUnit; - -import static org.junit.jupiter.api.Assertions.assertTrue; - -@Slf4j -public class TestGraphLocalExecutionGenetic extends BaseDL4JTest { - - @TempDir - public File testDir; - - @Override - public long getTimeoutMilliseconds() { - return 120_000L; - } - - @Test - public void testLocalExecutionDataSources() throws Exception { - for (int dataApproach = 0; dataApproach < 3; dataApproach++) { - log.info("////////////////// Starting Test: {} ///////////////////", dataApproach); - - //Define: network config (hyperparameter space) - ComputationGraphSpace mls = new ComputationGraphSpace.Builder() - .optimizationAlgo(OptimizationAlgorithm.STOCHASTIC_GRADIENT_DESCENT) - .updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.1))) - .l2(new ContinuousParameterSpace(0.0001, 0.01)) - .addInputs("in") - .addLayer("0", - new DenseLayerSpace.Builder().nIn(784).nOut(new IntegerParameterSpace(5, 32)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, Activation.TANH, Activation.LEAKYRELU)) - .build(), "in") //1-2 identical layers (except nIn) - .addLayer("1", new OutputLayerSpace.Builder().nOut(10).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build(), "0") - .setOutputs("1") - .setInputTypes(InputType.feedForward(784)) - .numEpochs(3).build(); - - DataProvider dp = null; - Class ds = null; - Properties dsP = null; - CandidateGenerator candidateGenerator; - - TestSetLossScoreFunction scoreFunction = new TestSetLossScoreFunction(); - - if (dataApproach == 0) { - ds = TestDL4JLocalExecution.MnistDataSource.class; - dsP = new Properties(); - dsP.setProperty("minibatch", "2"); - - candidateGenerator = new GeneticSearchCandidateGenerator.Builder(mls, scoreFunction) - .populationModel(new PopulationModel.Builder().populationSize(5).build()) - .build(); - } else if (dataApproach == 1) { - //DataProvider approach - dp = new TestDL4JLocalExecution.MnistDataProvider(); - - candidateGenerator = new GeneticSearchCandidateGenerator.Builder(mls, scoreFunction) - .populationModel(new PopulationModel.Builder().populationSize(5).build()) - .build(); - } else { - //Factory approach - Map commands = new HashMap<>(); - commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY, TestDataFactoryProviderMnist.class.getCanonicalName()); - - candidateGenerator = new GeneticSearchCandidateGenerator.Builder(mls, scoreFunction) - .dataParameters(commands) - .populationModel(new PopulationModel.Builder().populationSize(5).build()) - .build(); - dp = new DataSetIteratorFactoryProvider(); - } - - File f = testDir; - File modelSave = new File(f, "modelSaveDir"); - - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator) - .dataProvider(dp) - .dataSource(ds, dsP) - .modelSaver(new FileModelSaver(modelSave)) - .scoreFunction(new TestSetLossScoreFunction()) - .terminationConditions(new MaxTimeCondition(20, TimeUnit.SECONDS), - new MaxCandidatesCondition(3)) - .build(); - - IOptimizationRunner runner = new LocalOptimizationRunner(configuration, new ComputationGraphTaskCreator(new ClassificationEvaluator())); - - runner.execute(); - - List results = runner.getResults(); - assertTrue(results.size() > 0); - -// System.out.println("----- COMPLETE - " + results.size() + " results -----"); - } - } - - public static class TestMdsDataProvider implements DataProvider { - private int numEpochs; - private int batchSize; - - public TestMdsDataProvider(@JsonProperty("numEpochs") int numEpochs, @JsonProperty("batchSize") int batchSize) { - this.numEpochs = numEpochs; - this.batchSize = batchSize; - } - - private TestMdsDataProvider() { - } - - - @Override - public Object trainData(Map dataParameters) { - try { - DataSetIterator underlying = new MnistDataSetIterator(batchSize, Math.min(60000, 10 * batchSize), false, true, true, 12345); - return new MultiDataSetIteratorAdapter(new MultipleEpochsIterator(numEpochs, underlying)); - } catch (IOException e) { - throw new RuntimeException(e); - } - } - - @Override - public Object testData(Map dataParameters) { - try { - DataSetIterator underlying = new MnistDataSetIterator(batchSize, Math.min(10000, 5 * batchSize), false, false, false, 12345); - return new MultiDataSetIteratorAdapter(underlying); - } catch (IOException e) { - throw new RuntimeException(e); - } - } - - @Override - public Class getDataType() { - return MultiDataSetIterator.class; - } - } - - private static class ScoreProvider implements Supplier, Serializable { - @Override - public ScoreCalculator get() { - try { - return new DataSetLossCalculatorCG(new MnistDataSetIterator(128, 1280), true); - } catch (Exception e){ - throw new RuntimeException(e); - } - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/json/TestJson.java b/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/json/TestJson.java deleted file mode 100644 index f4d539089..000000000 --- a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/json/TestJson.java +++ /dev/null @@ -1,268 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.json; - -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.ComputationGraphSpace; -import org.deeplearning4j.arbiter.MultiLayerSpace; -import org.deeplearning4j.arbiter.conf.updater.AdaMaxSpace; -import org.deeplearning4j.arbiter.conf.updater.AdamSpace; -import org.deeplearning4j.arbiter.conf.updater.SgdSpace; -import org.deeplearning4j.arbiter.layers.DenseLayerSpace; -import org.deeplearning4j.arbiter.layers.OutputLayerSpace; -import org.deeplearning4j.arbiter.multilayernetwork.MnistDataSetIteratorFactory; -import org.deeplearning4j.arbiter.optimize.api.CandidateGenerator; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSetIteratorFactoryProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSource; -import org.deeplearning4j.arbiter.optimize.api.score.ScoreFunction; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxCandidatesCondition; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxTimeCondition; -import org.deeplearning4j.arbiter.optimize.generator.RandomSearchGenerator; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; -import org.deeplearning4j.arbiter.optimize.parameter.continuous.ContinuousParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.discrete.DiscreteParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.integer.IntegerParameterSpace; -import org.deeplearning4j.arbiter.optimize.serde.jackson.JsonMapper; -import org.deeplearning4j.arbiter.scoring.RegressionValue; -import org.deeplearning4j.arbiter.scoring.ScoreFunctions; -import org.deeplearning4j.arbiter.scoring.impl.TestSetLossScoreFunction; -import org.deeplearning4j.arbiter.util.TestDataFactoryProviderMnist; -import org.deeplearning4j.datasets.iterator.impl.IrisDataSetIterator; -import org.deeplearning4j.datasets.iterator.impl.MnistDataSetIterator; -import org.deeplearning4j.earlystopping.EarlyStoppingConfiguration; -import org.deeplearning4j.earlystopping.saver.InMemoryModelSaver; -import org.deeplearning4j.earlystopping.scorecalc.ClassificationScoreCalculator; -import org.deeplearning4j.earlystopping.scorecalc.DataSetLossCalculatorCG; -import org.deeplearning4j.earlystopping.scorecalc.base.BaseIEvaluationScoreCalculator; -import org.deeplearning4j.earlystopping.termination.MaxEpochsTerminationCondition; -import org.deeplearning4j.eval.Evaluation; -import org.deeplearning4j.eval.IEvaluation; -import org.deeplearning4j.nn.api.OptimizationAlgorithm; -import org.deeplearning4j.nn.conf.inputs.InputType; -import org.deeplearning4j.nn.graph.ComputationGraph; -import org.junit.jupiter.api.Test; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.lossfunctions.LossFunctions; - -import java.util.HashMap; -import java.util.Map; -import java.util.Properties; -import java.util.concurrent.TimeUnit; - -import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.junit.jupiter.api.Assertions.assertNotNull; - -/** - * Created by Alex on 14/02/2017. - */ -public class TestJson extends BaseDL4JTest { - - @Test - public void testMultiLayerSpaceJson() { - MultiLayerSpace mls = new MultiLayerSpace.Builder() - .optimizationAlgo(OptimizationAlgorithm.STOCHASTIC_GRADIENT_DESCENT) - .updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.2))) - .l2(new ContinuousParameterSpace(0.0001, 0.05)) - .addLayer(new DenseLayerSpace.Builder().nIn(1).nOut(new IntegerParameterSpace(5, 30)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, Activation.SOFTPLUS, - Activation.LEAKYRELU)) - .build(), new IntegerParameterSpace(1, 2), true) //1-2 identical layers - .addLayer(new DenseLayerSpace.Builder().nIn(4).nOut(new IntegerParameterSpace(2, 10)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, Activation.TANH)) - .build(), new IntegerParameterSpace(0, 1), true) //0 to 1 layers - .addLayer(new OutputLayerSpace.Builder().nOut(10).activation(Activation.SOFTMAX) - .iLossFunction(LossFunctions.LossFunction.MCXENT.getILossFunction()).build()) - .setInputType(InputType.convolutional(28, 28, 1)).build(); - - String asJson = mls.toJson(); - // System.out.println(asJson); - - MultiLayerSpace fromJson = MultiLayerSpace.fromJson(asJson); - - assertEquals(mls, fromJson); - } - - - - @Test - public void testOptimizationFromJson() { - EarlyStoppingConfiguration esConf = - new EarlyStoppingConfiguration.Builder() - .epochTerminationConditions(new MaxEpochsTerminationCondition(100)) - .scoreCalculator(new DataSetLossCalculatorCG(new IrisDataSetIterator(150, 150), - true)) - .modelSaver(new InMemoryModelSaver()).build(); - - //Define: network config (hyperparameter space) - ComputationGraphSpace cgs = new ComputationGraphSpace.Builder() - .optimizationAlgo(OptimizationAlgorithm.STOCHASTIC_GRADIENT_DESCENT) - .updater(new AdaMaxSpace(new ContinuousParameterSpace(0.0001, 0.1))) - .l2(new ContinuousParameterSpace(0.0001, 0.01)).addInputs("in") - .setInputTypes(InputType.feedForward(4)) - .addLayer("first", - new DenseLayerSpace.Builder().nIn(4).nOut(new IntegerParameterSpace(2, 10)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, - Activation.TANH)) - .build(), - "in") //1-2 identical layers (except nIn) - .addLayer("out", new OutputLayerSpace.Builder().nOut(3).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build(), "first") - .setOutputs("out").earlyStoppingConfiguration(esConf).build(); - - //Define configuration: - Map commands = new HashMap<>(); - commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY, TestDataFactoryProviderMnist.class.getCanonicalName()); - - CandidateGenerator candidateGenerator = new RandomSearchGenerator(cgs, commands); - DataProvider dataProvider = new DataSetIteratorFactoryProvider(); - - - OptimizationConfiguration configuration = - new OptimizationConfiguration.Builder().candidateGenerator(candidateGenerator) - .dataProvider(dataProvider).scoreFunction(new TestSetLossScoreFunction()) - .terminationConditions(new MaxTimeCondition(2, TimeUnit.MINUTES), - new MaxCandidatesCondition(100)) - .build(); - - String json = configuration.toJson(); - OptimizationConfiguration loadConf = OptimizationConfiguration.fromJson(json); - assertEquals(configuration, loadConf); - } - - @Test - public void testOptimizationFromJsonDataSource() { - for(boolean withProperties : new boolean[]{false, true}) { - //Define: network config (hyperparameter space) - ComputationGraphSpace cgs = new ComputationGraphSpace.Builder() - .optimizationAlgo(OptimizationAlgorithm.STOCHASTIC_GRADIENT_DESCENT) - .updater(new AdaMaxSpace(new ContinuousParameterSpace(0.0001, 0.1))) - .l2(new ContinuousParameterSpace(0.0001, 0.01)).addInputs("in") - .setInputTypes(InputType.feedForward(4)) - .addLayer("first", - new DenseLayerSpace.Builder().nIn(4).nOut(new IntegerParameterSpace(2, 10)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, - Activation.TANH)) - .build(), - "in") //1-2 identical layers (except nIn) - .addLayer("out", new OutputLayerSpace.Builder().nOut(3).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build(), "first") - .setOutputs("out").build(); - - //Define configuration: - Map commands = new HashMap<>(); - commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY, TestDataFactoryProviderMnist.class.getCanonicalName()); - - CandidateGenerator candidateGenerator = new RandomSearchGenerator(cgs, commands); - - Properties p = new Properties(); - p.setProperty("minibatch", "16"); - - OptimizationConfiguration configuration = - new OptimizationConfiguration.Builder().candidateGenerator(candidateGenerator) - .dataSource(MnistDataSource.class, (withProperties ? p : null)) - .scoreFunction(new TestSetLossScoreFunction()) - .terminationConditions(new MaxTimeCondition(2, TimeUnit.MINUTES), - new MaxCandidatesCondition(100)) - .build(); - - String json = configuration.toJson(); - OptimizationConfiguration loadConf = OptimizationConfiguration.fromJson(json); - assertEquals(configuration, loadConf); - assertNotNull(loadConf.getDataSource()); - if(withProperties){ - assertNotNull(loadConf.getDataSourceProperties()); - } - } - } - - @Test - public void testComputationGraphSpaceJson() { - ParameterSpace p = new IntegerParameterSpace(10, 100); - ComputationGraphSpace cgs = - new ComputationGraphSpace.Builder() - .updater(new AdamSpace(new DiscreteParameterSpace<>(0.1, 0.5, 1.0))) - .seed(12345).addInputs("in") - .addLayer("0", new DenseLayerSpace.Builder() - .nIn(new IntegerParameterSpace(1, 100)).nOut(p).build(), "in") - .addLayer("1", new DenseLayerSpace.Builder().nIn(p).nOut(10).build(), "0") - .addLayer("2", new OutputLayerSpace.Builder().iLossFunction( - LossFunctions.LossFunction.MCXENT.getILossFunction()).nIn(10) - .nOut(5).build(), "1") - .setOutputs("2").build(); - - String asJson = cgs.toJson(); - ComputationGraphSpace fromJson = ComputationGraphSpace.fromJson(asJson); - - assertEquals(cgs, fromJson); - } - - @Test - public void testScoreFunctionJson() throws Exception { - - ScoreFunction[] scoreFunctions = new ScoreFunction[]{ - ScoreFunctions.testSetAccuracy(), ScoreFunctions.testSetF1(), - ScoreFunctions.testSetLoss(true), ScoreFunctions.testSetRegression(RegressionValue.MAE), - ScoreFunctions.testSetRegression(RegressionValue.RMSE)}; - - for(ScoreFunction sc : scoreFunctions){ - String json = JsonMapper.getMapper().writeValueAsString(sc); - ScoreFunction fromJson = JsonMapper.getMapper().readValue(json, ScoreFunction.class); - - assertEquals(sc, fromJson); - } - } - - - public static class MnistDataSource implements DataSource { - private int minibatch; - - public MnistDataSource(){ - - } - - @Override - public void configure(Properties properties) { - this.minibatch = Integer.parseInt(properties.getProperty("minibatch", "16")); - } - - @Override - public Object trainData() { - try { - return new MnistDataSetIterator(minibatch, true, 12345); - } catch (Exception e){ - throw new RuntimeException(e); - } - } - - @Override - public Object testData() { - try { - return new MnistDataSetIterator(minibatch, true, 12345); - } catch (Exception e){ - throw new RuntimeException(e); - } - } - - @Override - public Class getDataType() { - return DataSetIterator.class; - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/MNISTOptimizationTest.java b/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/MNISTOptimizationTest.java deleted file mode 100644 index ea754990a..000000000 --- a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/MNISTOptimizationTest.java +++ /dev/null @@ -1,166 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.multilayernetwork; - -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.MultiLayerSpace; -import org.deeplearning4j.arbiter.conf.updater.SgdSpace; -import org.deeplearning4j.arbiter.layers.ConvolutionLayerSpace; -import org.deeplearning4j.arbiter.layers.DenseLayerSpace; -import org.deeplearning4j.arbiter.layers.OutputLayerSpace; -import org.deeplearning4j.arbiter.optimize.api.CandidateGenerator; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSetIteratorFactoryProvider; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxCandidatesCondition; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxTimeCondition; -import org.deeplearning4j.arbiter.optimize.generator.RandomSearchGenerator; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; -import org.deeplearning4j.arbiter.optimize.parameter.continuous.ContinuousParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.discrete.DiscreteParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.integer.IntegerParameterSpace; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.LocalOptimizationRunner; -import org.deeplearning4j.arbiter.saver.local.FileModelSaver; -import org.deeplearning4j.arbiter.scoring.impl.TestSetLossScoreFunction; -import org.deeplearning4j.arbiter.task.MultiLayerNetworkTaskCreator; -import org.deeplearning4j.arbiter.util.TestDataFactoryProviderMnist; -import org.deeplearning4j.datasets.iterator.impl.MnistDataSetIterator; -import org.deeplearning4j.earlystopping.EarlyStoppingConfiguration; -import org.deeplearning4j.earlystopping.saver.InMemoryModelSaver; -import org.deeplearning4j.earlystopping.scorecalc.DataSetLossCalculator; -import org.deeplearning4j.earlystopping.termination.MaxEpochsTerminationCondition; -import org.deeplearning4j.earlystopping.termination.MaxScoreIterationTerminationCondition; -import org.deeplearning4j.earlystopping.termination.MaxTimeIterationTerminationCondition; -import org.deeplearning4j.nn.api.OptimizationAlgorithm; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.lossfunctions.LossFunctions; - -import java.io.File; -import java.util.HashMap; -import java.util.Map; -import java.util.concurrent.TimeUnit; - -// import org.deeplearning4j.arbiter.optimize.ui.ArbiterUIServer; -// import org.deeplearning4j.arbiter.optimize.ui.listener.UIOptimizationRunnerStatusListener; - -/** Not strictly a unit test. Rather: part example, part debugging on MNIST */ -public class MNISTOptimizationTest extends BaseDL4JTest { - - public static void main(String[] args) throws Exception { - EarlyStoppingConfiguration esConf = - new EarlyStoppingConfiguration.Builder() - .epochTerminationConditions(new MaxEpochsTerminationCondition(3)) - .iterationTerminationConditions( - new MaxTimeIterationTerminationCondition(5, TimeUnit.MINUTES), - new MaxScoreIterationTerminationCondition(4.6) //Random score: -log_e(0.1) ~= 2.3 - ).scoreCalculator(new DataSetLossCalculator(new MnistDataSetIterator(64, 2000, false, false, true, 123), true)).modelSaver(new InMemoryModelSaver()).build(); - - //Define: network config (hyperparameter space) - MultiLayerSpace mls = new MultiLayerSpace.Builder() - .optimizationAlgo(OptimizationAlgorithm.STOCHASTIC_GRADIENT_DESCENT) - .updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.2))) - .l2(new ContinuousParameterSpace(0.0001, 0.05)) - .addLayer( - new ConvolutionLayerSpace.Builder().nIn(1) - .nOut(new IntegerParameterSpace(5, 30)) - .kernelSize(new DiscreteParameterSpace<>(new int[] {3, 3}, - new int[] {4, 4}, new int[] {5, 5})) - .stride(new DiscreteParameterSpace<>(new int[] {1, 1}, - new int[] {2, 2})) - .activation(new DiscreteParameterSpace<>(Activation.RELU, - Activation.SOFTPLUS, Activation.LEAKYRELU)) - .build(), - new IntegerParameterSpace(1, 2)) //1-2 identical layers - .addLayer(new DenseLayerSpace.Builder().nIn(4).nOut(new IntegerParameterSpace(2, 10)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, Activation.TANH)) - .build(), new IntegerParameterSpace(0, 1)) //0 to 1 layers - .addLayer(new OutputLayerSpace.Builder().nOut(10).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build()) - .earlyStoppingConfiguration(esConf).build(); - Map commands = new HashMap<>(); - commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY, TestDataFactoryProviderMnist.class.getCanonicalName()); - - //Define configuration: - CandidateGenerator candidateGenerator = new RandomSearchGenerator(mls, commands); - DataProvider dataProvider = new MnistDataSetProvider(); - - - String modelSavePath = new File(System.getProperty("java.io.tmpdir"), "ArbiterMNISTSmall\\").getAbsolutePath(); - - File f = new File(modelSavePath); - if (f.exists()) - f.delete(); - f.mkdir(); - if (!f.exists()) - throw new RuntimeException(); - - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator) - .dataProvider(dataProvider) - .modelSaver(new FileModelSaver(modelSavePath)).scoreFunction(new TestSetLossScoreFunction(true)) - .terminationConditions(new MaxTimeCondition(120, TimeUnit.MINUTES), - new MaxCandidatesCondition(100)) - .build(); - - IOptimizationRunner runner = new LocalOptimizationRunner(configuration, new MultiLayerNetworkTaskCreator()); - - // ArbiterUIServer server = ArbiterUIServer.getInstance(); - // runner.addListeners(new UIOptimizationRunnerStatusListener(server)); - - runner.execute(); - - - System.out.println("----- COMPLETE -----"); - } - - - private static class MnistDataSetProvider implements DataProvider { - - @Override - public DataSetIterator trainData(Map dataParameters) { - try { - if (dataParameters == null || dataParameters.isEmpty()) { - return new MnistDataSetIterator(64, 10000, false, true, true, 123); - } - if (dataParameters.containsKey("batchsize")) { - int b = (Integer) dataParameters.get("batchsize"); - return new MnistDataSetIterator(b, 10000, false, true, true, 123); - } - return new MnistDataSetIterator(64, 10000, false, true, true, 123); - } catch (Exception e) { - throw new RuntimeException(e); - } - } - - @Override - public DataSetIterator testData(Map dataParameters) { - return trainData(dataParameters); - } - - @Override - public Class getDataType() { - return DataSetIterator.class; - } - - @Override - public String toString() { - return "MnistDataSetProvider()"; - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/MnistDataSetIteratorFactory.java b/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/MnistDataSetIteratorFactory.java deleted file mode 100644 index 55c2643a9..000000000 --- a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/MnistDataSetIteratorFactory.java +++ /dev/null @@ -1,42 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.multilayernetwork; - -import lombok.Data; -import org.deeplearning4j.datasets.iterator.impl.MnistDataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.DataSetIteratorFactory; - -import java.io.IOException; - -/** - * Created by agibsonccc on 3/13/17. - */ -@Data -public class MnistDataSetIteratorFactory implements DataSetIteratorFactory { - /** - * @return - */ - @Override - public DataSetIterator create() { - try { - return new MnistDataSetIterator(1000, 1000); - } catch (IOException e) { - throw new RuntimeException(e); - } - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestDL4JLocalExecution.java b/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestDL4JLocalExecution.java deleted file mode 100644 index aee1d022c..000000000 --- a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestDL4JLocalExecution.java +++ /dev/null @@ -1,381 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.multilayernetwork; - -import lombok.extern.slf4j.Slf4j; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.MultiLayerSpace; -import org.deeplearning4j.arbiter.conf.updater.SgdSpace; -import org.deeplearning4j.arbiter.evaluator.multilayer.ClassificationEvaluator; -import org.deeplearning4j.arbiter.layers.DenseLayerSpace; -import org.deeplearning4j.arbiter.layers.OCNNLayerSpace; -import org.deeplearning4j.arbiter.layers.OutputLayerSpace; -import org.deeplearning4j.arbiter.optimize.api.Candidate; -import org.deeplearning4j.arbiter.optimize.api.CandidateGenerator; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSetIteratorFactoryProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSource; -import org.deeplearning4j.arbiter.optimize.api.saving.ResultReference; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxCandidatesCondition; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxTimeCondition; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; -import org.deeplearning4j.arbiter.optimize.generator.GridSearchCandidateGenerator; -import org.deeplearning4j.arbiter.optimize.generator.RandomSearchGenerator; -import org.deeplearning4j.arbiter.optimize.parameter.continuous.ContinuousParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.discrete.DiscreteParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.integer.IntegerParameterSpace; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.LocalOptimizationRunner; -import org.deeplearning4j.arbiter.saver.local.FileModelSaver; -import org.deeplearning4j.arbiter.scoring.impl.TestSetLossScoreFunction; -import org.deeplearning4j.arbiter.task.MultiLayerNetworkTaskCreator; -import org.deeplearning4j.arbiter.util.TestDataFactoryProviderMnist; -import org.deeplearning4j.datasets.iterator.EarlyTerminationDataSetIterator; -import org.deeplearning4j.datasets.iterator.impl.IrisDataSetIterator; -import org.deeplearning4j.datasets.iterator.impl.MnistDataSetIterator; -import org.deeplearning4j.earlystopping.EarlyStoppingConfiguration; -import org.deeplearning4j.earlystopping.saver.InMemoryModelSaver; -import org.deeplearning4j.earlystopping.scorecalc.DataSetLossCalculator; -import org.deeplearning4j.earlystopping.termination.MaxEpochsTerminationCondition; -import org.deeplearning4j.nn.api.OptimizationAlgorithm; -import org.deeplearning4j.nn.conf.inputs.InputType; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.junit.jupiter.api.BeforeAll; -import org.junit.jupiter.api.Test; -import org.junit.jupiter.api.io.TempDir; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.api.buffer.DataType; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.factory.Nd4j; -import org.nd4j.linalg.lossfunctions.LossFunctions; - -import java.io.File; -import java.util.HashMap; -import java.util.List; -import java.util.Map; -import java.util.Properties; -import java.util.concurrent.TimeUnit; - -import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.junit.jupiter.api.Assertions.assertTrue; - -@Slf4j -public class TestDL4JLocalExecution extends BaseDL4JTest { - - @TempDir - public File testDir; - - @BeforeAll - public static void before(){ - Nd4j.setDefaultDataTypes(DataType.FLOAT, DataType.FLOAT); - } - - @Test - public void testLocalExecution() throws Exception { - - for( int dataApproach = 0; dataApproach<3; dataApproach++ ) { - log.info("////////////////// Starting Test: {} ///////////////////", dataApproach); - - //Define: network config (hyperparameter space) - MultiLayerSpace mls = new MultiLayerSpace.Builder() - .optimizationAlgo(OptimizationAlgorithm.STOCHASTIC_GRADIENT_DESCENT) - .updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.1))) - .l2(new ContinuousParameterSpace(0.0001, 0.01)) - .addLayer( - new DenseLayerSpace.Builder().nIn(784).nOut(new IntegerParameterSpace(10, 20)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, - Activation.TANH)) - .build()) //1-2 identical layers (except nIn) - .addLayer(new OutputLayerSpace.Builder().nOut(10).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build()) - .numEpochs(3).build(); - - DataProvider dp = null; - Class ds = null; - Properties dsP = null; - CandidateGenerator candidateGenerator; - - if(dataApproach == 0){ - ds = MnistDataSource.class; - dsP = new Properties(); - dsP.setProperty("minibatch", "2"); - candidateGenerator = new RandomSearchGenerator(mls); - } else if(dataApproach == 1) { - //DataProvider approach - dp = new MnistDataProvider(); - candidateGenerator = new RandomSearchGenerator(mls); - } else { - //Factory approach - Map commands = new HashMap<>(); - commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY, TestDataFactoryProviderMnist.class.getCanonicalName()); - - candidateGenerator = new RandomSearchGenerator(mls, commands); - dp = new DataSetIteratorFactoryProvider(); - } - - File f = testDir; - File modelSave = new File(f, "modelSaveDir"); - - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator) - .dataProvider(dp) - .dataSource(ds, dsP) - .modelSaver(new FileModelSaver(modelSave)) - .scoreFunction(new TestSetLossScoreFunction()) - .terminationConditions(new MaxTimeCondition(5, TimeUnit.SECONDS), - new MaxCandidatesCondition(5)) - .build(); - - IOptimizationRunner runner = new LocalOptimizationRunner(configuration, - new MultiLayerNetworkTaskCreator(new ClassificationEvaluator())); - - runner.execute(); - - List results = runner.getResults(); - assertTrue(results.size() > 0); - - System.out.println("----- COMPLETE - " + results.size() + " results -----"); - } - } - - public static class MnistDataSource implements DataSource { - private int minibatch; - - public MnistDataSource(){ - - } - - @Override - public void configure(Properties properties) { - this.minibatch = Integer.parseInt(properties.getProperty("minibatch", "16")); - } - - @Override - public Object trainData() { - try { - return new EarlyTerminationDataSetIterator(new MnistDataSetIterator(minibatch, true, 12345), 3); - } catch (Exception e){ - throw new RuntimeException(e); - } - } - - @Override - public Object testData() { - try { - return new EarlyTerminationDataSetIterator(new MnistDataSetIterator(minibatch, true, 12345), 3); - } catch (Exception e){ - throw new RuntimeException(e); - } - } - - @Override - public Class getDataType() { - return DataSetIterator.class; - } - } - - public static class MnistDataProvider implements DataProvider { - private int minibatch = 8; - - @Override - public Object trainData(Map dataParameters) { - try { - return new EarlyTerminationDataSetIterator(new MnistDataSetIterator(minibatch, true, 12345), 3); - } catch (Exception e){ - throw new RuntimeException(e); - } - } - - @Override - public Object testData(Map dataParameters) { - try { - return new EarlyTerminationDataSetIterator(new MnistDataSetIterator(minibatch, true, 12345), 3); - } catch (Exception e){ - throw new RuntimeException(e); - } - } - - @Override - public Class getDataType() { - return DataSetIterator.class; - } - } - - @Test - //@org.junit.Ignore - public void testLocalExecutionGridSearch() throws Exception { - - //Define: network config (hyperparameter space) - MultiLayerSpace mls = new MultiLayerSpace.Builder() - .optimizationAlgo(OptimizationAlgorithm.STOCHASTIC_GRADIENT_DESCENT) - .updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.2))) - .l2(new ContinuousParameterSpace(0.0001, 0.01)) - .addLayer( - new DenseLayerSpace.Builder().nIn(4).nOut(new IntegerParameterSpace(2, 10)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, - Activation.TANH)) - .build(), - new IntegerParameterSpace(1, 2)) //1-2 identical layers (except nIn) - .addLayer(new OutputLayerSpace.Builder().nOut(3).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build()) - .numEpochs(3).build(); - Map commands = new HashMap<>(); - commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY, TestDataFactoryProviderMnist.class.getCanonicalName()); - - CandidateGenerator candidateGenerator = new GridSearchCandidateGenerator(mls, 5, - GridSearchCandidateGenerator.Mode.Sequential, commands); - DataProvider dataProvider = new DataSetIteratorFactoryProvider(); - - String modelSavePath = new File(System.getProperty("java.io.tmpdir"), "ArbiterDL4JTest/").getAbsolutePath(); - - File f = new File(modelSavePath); - if (f.exists()) - f.delete(); - f.mkdir(); - f.deleteOnExit(); - if (!f.exists()) - throw new RuntimeException(); - - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).dataProvider(dataProvider) - .modelSaver(new FileModelSaver(modelSavePath)).scoreFunction(new TestSetLossScoreFunction()) - .terminationConditions(new MaxTimeCondition(2, TimeUnit.MINUTES), - new MaxCandidatesCondition(100)) - .build(); - - IOptimizationRunner runner = new LocalOptimizationRunner(configuration, - new MultiLayerNetworkTaskCreator(new ClassificationEvaluator())); - - runner.execute(); - - System.out.println("----- COMPLETE -----"); - } - - @Test - //@Ignore - public void testLocalExecutionEarlyStopping() throws Exception { - EarlyStoppingConfiguration esConf = new EarlyStoppingConfiguration.Builder() - .epochTerminationConditions(new MaxEpochsTerminationCondition(100)) - .scoreCalculator(new DataSetLossCalculator(new IrisDataSetIterator(150, 150), true)) - .modelSaver(new InMemoryModelSaver()).build(); - Map commands = new HashMap<>(); - commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY, TestDataFactoryProviderMnist.class.getCanonicalName()); - - - //Define: network config (hyperparameter space) - MultiLayerSpace mls = new MultiLayerSpace.Builder() - .optimizationAlgo(OptimizationAlgorithm.STOCHASTIC_GRADIENT_DESCENT) - .updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.1))) - .l2(new ContinuousParameterSpace(0.0001, 0.01)) - .addLayer(new DenseLayerSpace.Builder().nIn(4).nOut(new IntegerParameterSpace(2, 10)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, - Activation.TANH)) - .build(), - new IntegerParameterSpace(1, 2)) //1-2 identical layers (except nIn) - .addLayer(new OutputLayerSpace.Builder().nOut(3).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build()) - .earlyStoppingConfiguration(esConf).build(); - - //Define configuration: - - CandidateGenerator candidateGenerator = new RandomSearchGenerator(mls, commands); - DataProvider dataProvider = new DataSetIteratorFactoryProvider(); - - - String modelSavePath = new File(System.getProperty("java.io.tmpdir"), "ArbiterDL4JTest2\\").getAbsolutePath(); - - File f = new File(modelSavePath); - if (f.exists()) - f.delete(); - f.mkdir(); - f.deleteOnExit(); - if (!f.exists()) - throw new RuntimeException(); - - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).dataProvider(dataProvider) - .modelSaver(new FileModelSaver(modelSavePath)).scoreFunction(new TestSetLossScoreFunction()) - .terminationConditions(new MaxTimeCondition(2, TimeUnit.MINUTES), - new MaxCandidatesCondition(100)) - .build(); - - IOptimizationRunner runner = new LocalOptimizationRunner(configuration, - new MultiLayerNetworkTaskCreator(new ClassificationEvaluator())); - - runner.execute(); - System.out.println("----- COMPLETE -----"); - } - - - @Test - public void testOcnn() { - Map commands = new HashMap<>(); - commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY, TestDataFactoryProviderMnist.class.getCanonicalName()); - - - //Define: network config (hyperparameter space) - MultiLayerSpace mls = new MultiLayerSpace.Builder() - .optimizationAlgo(OptimizationAlgorithm.STOCHASTIC_GRADIENT_DESCENT) - .updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.1))) - .l2(new ContinuousParameterSpace(0.0001, 0.01)) - .addLayer( - new DenseLayerSpace.Builder().nOut(new IntegerParameterSpace(250, 500)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, - Activation.TANH)) - .build(), - new IntegerParameterSpace(1, 2)) //1-2 identical layers (except nIn) - .addLayer(new OCNNLayerSpace.Builder().nu(new ContinuousParameterSpace(0.0001, 0.1)) - .numHidden(new DiscreteParameterSpace(784 / 2,784 / 4)) - .activation(Activation.HARDSIGMOID) - .lossFunction(LossFunctions.LossFunction.MCXENT).build()) - .setInputType(InputType.convolutionalFlat(28,28,1)) - .build(); - - //Define configuration: - - CandidateGenerator candidateGenerator = new RandomSearchGenerator(mls, commands); - DataProvider dataProvider = new DataSetIteratorFactoryProvider(); - - - String modelSavePath = new File(System.getProperty("java.io.tmpdir"), "ArbiterDL4JTest3\\").getAbsolutePath(); - - File f = new File(modelSavePath); - if (f.exists()) - f.delete(); - f.mkdir(); - f.deleteOnExit(); - if (!f.exists()) - throw new RuntimeException(); - - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).dataProvider(dataProvider) - .modelSaver(new FileModelSaver(modelSavePath)).scoreFunction(new TestSetLossScoreFunction()) - .terminationConditions(new MaxTimeCondition(2, TimeUnit.MINUTES), - new MaxCandidatesCondition(100)) - .build(); - - - //candidate generation: uncomment execute if you want to run - IOptimizationRunner runner = new LocalOptimizationRunner(configuration, - new MultiLayerNetworkTaskCreator(new ClassificationEvaluator())); - - Candidate candidate = candidateGenerator.getCandidate(); - - // runner.execute(); - System.out.println("----- COMPLETE -----"); - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestErrors.java b/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestErrors.java deleted file mode 100644 index a3d4e3657..000000000 --- a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestErrors.java +++ /dev/null @@ -1,158 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.multilayernetwork; - -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.ComputationGraphSpace; -import org.deeplearning4j.arbiter.MultiLayerSpace; -import org.deeplearning4j.arbiter.layers.DenseLayerSpace; -import org.deeplearning4j.arbiter.layers.OutputLayerSpace; -import org.deeplearning4j.arbiter.optimize.api.CandidateGenerator; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxCandidatesCondition; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; -import org.deeplearning4j.arbiter.optimize.generator.RandomSearchGenerator; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.LocalOptimizationRunner; -import org.deeplearning4j.arbiter.saver.local.FileModelSaver; -import org.deeplearning4j.arbiter.scoring.impl.TestSetLossScoreFunction; -import org.deeplearning4j.arbiter.task.MultiLayerNetworkTaskCreator; -import org.deeplearning4j.arbiter.util.TestDataProviderMnist; -import org.junit.jupiter.api.Test; -import org.junit.jupiter.api.Timeout; -import org.junit.jupiter.api.io.TempDir; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.lossfunctions.LossFunctions; - -import java.io.File; - -@Timeout(20) -public class TestErrors extends BaseDL4JTest { - - @TempDir - public File temp; - - @Test - public void testAllInvalidConfig() throws Exception { - //Invalid config - basically check that this actually terminates - - File f = temp; - MultiLayerSpace mls = new MultiLayerSpace.Builder() - .addLayer(new DenseLayerSpace.Builder().nIn(4).nOut(new FixedValue<>(0)) //INVALID: nOut of 0 - .activation(Activation.TANH) - .build()) - .addLayer(new OutputLayerSpace.Builder().nOut(3).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build()) - .build(); - - CandidateGenerator candidateGenerator = new RandomSearchGenerator(mls); - - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).dataProvider(new TestDataProviderMnist(32, 3)) - .modelSaver(new FileModelSaver(f)).scoreFunction(new TestSetLossScoreFunction(true)) - .terminationConditions( - new MaxCandidatesCondition(5)) - .build(); - - IOptimizationRunner runner = new LocalOptimizationRunner(configuration); - runner.execute(); - } - - - @Test - public void testAllInvalidDataConfigMismatch() throws Exception { - //Valid config - but mismatched with provided data - - File f = temp; - MultiLayerSpace mls = new MultiLayerSpace.Builder() - .addLayer(new DenseLayerSpace.Builder().nIn(4).nOut(10) //INVALID: nOut of 0 - .activation(Activation.TANH) - .build()) - .addLayer(new OutputLayerSpace.Builder().nIn(10).nOut(3).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build()) - .build(); - - CandidateGenerator candidateGenerator = new RandomSearchGenerator(mls); - - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).dataProvider(new TestDataProviderMnist(32, 3)) - .modelSaver(new FileModelSaver(f)).scoreFunction(new TestSetLossScoreFunction(true)) - .terminationConditions( - new MaxCandidatesCondition(5)) - .build(); - - IOptimizationRunner runner = new LocalOptimizationRunner(configuration); - runner.execute(); - } - - - @Test - public void testAllInvalidConfigCG() throws Exception { - //Invalid config - basically check that this actually terminates - - File f = temp; - ComputationGraphSpace mls = new ComputationGraphSpace.Builder() - .addInputs("in") - .layer("0", new DenseLayerSpace.Builder().nIn(4).nOut(new FixedValue<>(0)) //INVALID: nOut of 0 - .activation(Activation.TANH) - .build(), "in") - .layer("1", new OutputLayerSpace.Builder().nOut(3).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build(), "0") - .setOutputs("1") - .build(); - - CandidateGenerator candidateGenerator = new RandomSearchGenerator(mls); - - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).dataProvider(new TestDataProviderMnist(32, 3)) - .modelSaver(new FileModelSaver(f)).scoreFunction(new TestSetLossScoreFunction(true)) - .terminationConditions(new MaxCandidatesCondition(5)) - .build(); - - IOptimizationRunner runner = new LocalOptimizationRunner(configuration); - runner.execute(); - } - - - @Test - public void testAllInvalidDataConfigMismatchCG() throws Exception { - //Valid config - but mismatched with provided data - - File f = temp; - ComputationGraphSpace mls = new ComputationGraphSpace.Builder() - .addInputs("in") - .layer("0", new DenseLayerSpace.Builder().nIn(4).nOut(10) - .activation(Activation.TANH).build(), "in") - .addLayer("1", new OutputLayerSpace.Builder().nIn(10).nOut(3).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build(), "0") - .setOutputs("1") - .build(); - - CandidateGenerator candidateGenerator = new RandomSearchGenerator(mls); - - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).dataProvider(new TestDataProviderMnist(32, 3)) - .modelSaver(new FileModelSaver(f)).scoreFunction(new TestSetLossScoreFunction(true)) - .terminationConditions( - new MaxCandidatesCondition(5)) - .build(); - - IOptimizationRunner runner = new LocalOptimizationRunner(configuration, new MultiLayerNetworkTaskCreator()); - runner.execute(); - } - -} diff --git a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestLayerSpace.java deleted file mode 100644 index 3f25c66db..000000000 --- a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestLayerSpace.java +++ /dev/null @@ -1,314 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.multilayernetwork; - -import org.apache.commons.lang3.ArrayUtils; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.TestUtils; -import org.deeplearning4j.arbiter.conf.updater.SgdSpace; -import org.deeplearning4j.arbiter.layers.*; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.BooleanSpace; -import org.deeplearning4j.arbiter.optimize.parameter.continuous.ContinuousParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.discrete.DiscreteParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.integer.IntegerParameterSpace; -import org.deeplearning4j.nn.api.layers.LayerConstraint; -import org.deeplearning4j.nn.conf.constraint.MaxNormConstraint; -import org.deeplearning4j.nn.conf.constraint.MinMaxNormConstraint; -import org.deeplearning4j.nn.conf.constraint.NonNegativeConstraint; -import org.deeplearning4j.nn.conf.constraint.UnitNormConstraint; -import org.deeplearning4j.nn.conf.layers.*; -import org.junit.jupiter.api.Test; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.activations.IActivation; -import org.nd4j.linalg.learning.config.Sgd; - -import java.util.ArrayList; -import java.util.Collections; -import java.util.List; -import java.util.Random; - -import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.junit.jupiter.api.Assertions.assertTrue; - -public class TestLayerSpace extends BaseDL4JTest { - - @Test - public void testBasic1() { - - DenseLayer expected = new DenseLayer.Builder().nOut(13).activation(Activation.RELU).build(); - - DenseLayerSpace space = new DenseLayerSpace.Builder().nOut(13).activation(Activation.RELU).build(); - - int nParam = space.numParameters(); - assertEquals(0, nParam); - DenseLayer actual = space.getValue(new double[nParam]); - - assertEquals(expected, actual); - } - - @Test - public void testBasic2() { - - Activation[] actFns = new Activation[]{Activation.SOFTSIGN, Activation.RELU, Activation.LEAKYRELU}; - Random r = new Random(12345); - - for (int i = 0; i < 20; i++) { - - new DenseLayer.Builder().build(); - - DenseLayerSpace ls = - new DenseLayerSpace.Builder().nOut(20) - .updater(new SgdSpace(new ContinuousParameterSpace(0.3, 0.4))) - .l2(new ContinuousParameterSpace(0.01, 0.1)) - .activation(new DiscreteParameterSpace<>(actFns)).build(); - - //Set the parameter numbers... - List list = ls.collectLeaves(); - int k = 0; - for (int j = 0; j < list.size(); j++) { - if (list.get(j).numParameters() > 0) { - list.get(j).setIndices(k++); - } - } - - int nParam = ls.numParameters(); - assertEquals(3, nParam); - - double[] d = new double[nParam]; - for (int j = 0; j < d.length; j++) { - d[j] = r.nextDouble(); - } - - DenseLayer l = ls.getValue(d); - - assertEquals(20, l.getNOut()); - double lr = ((Sgd) l.getIUpdater()).getLearningRate(); - double l2 = TestUtils.getL2(l); - IActivation activation = l.getActivationFn(); - -// System.out.println(lr + "\t" + l2 + "\t" + activation); - - assertTrue(lr >= 0.3 && lr <= 0.4); - assertTrue(l2 >= 0.01 && l2 <= 0.1); - assertTrue(containsActivationFunction(actFns, activation)); - } - } - - @Test - public void testBatchNorm() { - BatchNormalizationSpace sp = new BatchNormalizationSpace.Builder().gamma(1.5) - .beta(new ContinuousParameterSpace(2, 3)).lockGammaBeta(true).build(); - - //Set the parameter numbers... - List list = sp.collectLeaves(); - int k = 0; - for (int j = 0; j < list.size(); j++) { - if (list.get(j).numParameters() > 0) { - list.get(j).setIndices(k++); - } - } - - BatchNormalization bn = sp.getValue(new double[]{0.6}); - assertTrue(bn.isLockGammaBeta()); - assertEquals(1.5, bn.getGamma(), 0.0); - assertEquals(0.6 * (3 - 2) + 2, bn.getBeta(), 1e-4); - } - - @Test - public void testBatchNormConstrain() { - - ArrayList> constrainListOptions = new ArrayList>(); - constrainListOptions.add(Collections.singletonList((LayerConstraint) new MaxNormConstraint(0.5, 1))); - constrainListOptions.add(Collections.singletonList((LayerConstraint) new MinMaxNormConstraint(0.3, 0.4, 1.0, 1))); - constrainListOptions.add(Collections.singletonList((LayerConstraint) new NonNegativeConstraint())); - constrainListOptions.add(Collections.singletonList((LayerConstraint) new UnitNormConstraint(1))); - - DiscreteParameterSpace> constrainParamSpace = new DiscreteParameterSpace<>(constrainListOptions); - BatchNormalizationSpace sp = new BatchNormalizationSpace.Builder().gamma(1.5) - .beta(0.6).lockGammaBeta(true).constrainBeta(constrainParamSpace).constrainGamma(new NonNegativeConstraint()).build(); - - BatchNormalization bnExpected = new BatchNormalization.Builder().gamma(1.5) - .beta(0.6).lockGammaBeta(true).constrainBeta(new NonNegativeConstraint()).constrainGamma(new NonNegativeConstraint()).build(); - //Set the parameter numbers... - List list = sp.collectLeaves(); - int k = 0; - for( - int j = 0; j 0) { - list.get(j).setIndices(k++); - } - } - - assertEquals(1,sp.getNumParameters()); - BatchNormalization bn = sp.getValue(new double[]{0.6}); - assertEquals(bnExpected,bn); //0.6 should pick the 3rd value in discrete param space - - //assertEquals(bn.getConstraints().size(),2); This throws an NPE but I believe this is an issue with actual impl of BatchNormalization not arbiter -} - - @Test - public void testActivationLayer() { - Activation[] actFns = new Activation[]{Activation.SOFTSIGN, Activation.RELU, Activation.LEAKYRELU}; - - ActivationLayerSpace als = - new ActivationLayerSpace.Builder().activation(new DiscreteParameterSpace<>(actFns)).build(); - //Set the parameter numbers... - List list = als.collectLeaves(); - for (int j = 0; j < list.size(); j++) { - list.get(j).setIndices(j); - } - - int nParam = als.numParameters(); - assertEquals(1, nParam); - - Random r = new Random(12345); - - for (int i = 0; i < 20; i++) { - - double[] d = new double[nParam]; - for (int j = 0; j < d.length; j++) { - d[j] = r.nextDouble(); - } - - ActivationLayer al = als.getValue(d); - IActivation activation = al.getActivationFn(); - -// System.out.println(activation); - - assertTrue(containsActivationFunction(actFns, activation)); - } - } - - @Test - public void testEmbeddingLayer() { - - Activation[] actFns = new Activation[]{Activation.SOFTSIGN, Activation.RELU, Activation.LEAKYRELU}; - - EmbeddingLayerSpace els = new EmbeddingLayerSpace.Builder().activation(new DiscreteParameterSpace<>(actFns)) - .nIn(10).nOut(new IntegerParameterSpace(10, 20)).build(); - //Set the parameter numbers... - List list = els.collectLeaves(); - int k = 0; - for (int j = 0; j < list.size(); j++) { - if (list.get(j).numParameters() > 0) { - list.get(j).setIndices(k++); - } - } - - int nParam = els.numParameters(); - assertEquals(2, nParam); - - Random r = new Random(12345); - - for (int i = 0; i < 20; i++) { - - double[] d = new double[nParam]; - for (int j = 0; j < d.length; j++) { - d[j] = r.nextDouble(); - } - - EmbeddingLayer el = els.getValue(d); - IActivation activation = el.getActivationFn(); - long nOut = el.getNOut(); - -// System.out.println(activation + "\t" + nOut); - - assertTrue(containsActivationFunction(actFns, activation)); - assertTrue(nOut >= 10 && nOut <= 20); - } - } - - @Test - public void testSimpleConv() { - ConvolutionLayer conv2d = new Convolution2D.Builder().dilation(1,2).kernelSize(2,2).nIn(2).nOut(3).build(); - ConvolutionLayerSpace conv2dSpace = new ConvolutionLayerSpace.Builder().dilation(1,2).kernelSize(2,2).nIn(2).nOut(3).build(); - assertEquals(0,conv2dSpace.getNumParameters()); - assertEquals(conv2d, conv2dSpace.getValue(new double[0])); - - Deconvolution2DLayerSpace deconvd2dls = new Deconvolution2DLayerSpace.Builder().dilation(2,1).nIn(2).nOut(2).hasBias(new BooleanSpace()).build(); - assertEquals(1, deconvd2dls.getNumParameters()); - //Set the parameter numbers... - List list = deconvd2dls.collectLeaves(); - int k = 0; - for( - int j = 0; j 0) { - list.get(j).setIndices(k++); - } - } - Deconvolution2D actual = deconvd2dls.getValue(new double[]{0.9}); - assertTrue(!actual.hasBias()); - assertEquals(ArrayUtils.toString(new int[] {2,1} ),ArrayUtils.toString(actual.getDilation())); - } - - @Test - public void testGravesBidirectionalLayer() { - - Activation[] actFns = new Activation[]{Activation.SOFTSIGN, Activation.RELU, Activation.LEAKYRELU}; - - GravesBidirectionalLSTMLayerSpace ls = - new GravesBidirectionalLSTMLayerSpace.Builder().activation(new DiscreteParameterSpace<>(actFns)) - .forgetGateBiasInit(new ContinuousParameterSpace(0.5, 0.8)).nIn(10) - .nOut(new IntegerParameterSpace(10, 20)).build(); - //Set the parameter numbers... - List list = ls.collectLeaves(); - int k = 0; - for (int j = 0; j < list.size(); j++) { - if (list.get(j).numParameters() > 0) { - list.get(j).setIndices(k++); - } - } - - int nParam = ls.numParameters(); - assertEquals(3, nParam); //Excluding fixed value for nIn - - Random r = new Random(12345); - - for (int i = 0; i < 20; i++) { - - double[] d = new double[nParam]; - for (int j = 0; j < d.length; j++) { - d[j] = r.nextDouble(); - } - - GravesBidirectionalLSTM el = ls.getValue(d); - IActivation activation = el.getActivationFn(); - long nOut = el.getNOut(); - double forgetGate = el.getForgetGateBiasInit(); - -// System.out.println(activation + "\t" + nOut + "\t" + forgetGate); - - assertTrue(containsActivationFunction(actFns, activation)); - assertTrue(nOut >= 10 && nOut <= 20); - assertTrue(forgetGate >= 0.5 && forgetGate <= 0.8); - } - } - - private static boolean containsActivationFunction(Activation[] activationFunctions, - IActivation activationFunction) { - for (Activation af : activationFunctions) { - if (activationFunction.equals(af.getActivationFunction())) - return true; - } - return false; - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestMultiLayerSpace.java b/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestMultiLayerSpace.java deleted file mode 100644 index 784df4628..000000000 --- a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestMultiLayerSpace.java +++ /dev/null @@ -1,819 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.multilayernetwork; - -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.DL4JConfiguration; -import org.deeplearning4j.arbiter.MultiLayerSpace; -import org.deeplearning4j.arbiter.TestUtils; -import org.deeplearning4j.arbiter.conf.updater.AdamSpace; -import org.deeplearning4j.arbiter.conf.updater.NesterovsSpace; -import org.deeplearning4j.arbiter.conf.updater.SgdSpace; -import org.deeplearning4j.arbiter.layers.*; -import org.deeplearning4j.arbiter.optimize.api.Candidate; -import org.deeplearning4j.arbiter.optimize.api.CandidateGenerator; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.saving.ResultSaver; -import org.deeplearning4j.arbiter.optimize.api.score.ScoreFunction; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxCandidatesCondition; -import org.deeplearning4j.arbiter.optimize.api.termination.TerminationCondition; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; -import org.deeplearning4j.arbiter.optimize.generator.GridSearchCandidateGenerator; -import org.deeplearning4j.arbiter.optimize.generator.RandomSearchGenerator; -import org.deeplearning4j.arbiter.optimize.parameter.FixedValue; -import org.deeplearning4j.arbiter.optimize.parameter.continuous.ContinuousParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.discrete.DiscreteParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.integer.IntegerParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.math.MathOp; -import org.deeplearning4j.arbiter.optimize.parameter.math.Op; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.LocalOptimizationRunner; -import org.deeplearning4j.arbiter.saver.local.FileModelSaver; -import org.deeplearning4j.arbiter.scoring.impl.TestSetAccuracyScoreFunction; -import org.deeplearning4j.arbiter.task.MultiLayerNetworkTaskCreator; -import org.deeplearning4j.arbiter.util.LeafUtils; -import org.deeplearning4j.datasets.iterator.ExistingDataSetIterator; -import org.deeplearning4j.nn.conf.ConvolutionMode; -import org.deeplearning4j.nn.conf.MultiLayerConfiguration; -import org.deeplearning4j.nn.conf.NeuralNetConfiguration; -import org.deeplearning4j.nn.conf.constraint.NonNegativeConstraint; -import org.deeplearning4j.nn.conf.constraint.UnitNormConstraint; -import org.deeplearning4j.nn.conf.dropout.Dropout; -import org.deeplearning4j.nn.conf.dropout.IDropout; -import org.deeplearning4j.nn.conf.inputs.InputType; -import org.deeplearning4j.nn.conf.layers.*; -import org.deeplearning4j.nn.conf.layers.variational.BernoulliReconstructionDistribution; -import org.deeplearning4j.nn.conf.layers.variational.GaussianReconstructionDistribution; -import org.deeplearning4j.nn.conf.layers.variational.ReconstructionDistribution; -import org.deeplearning4j.nn.conf.layers.variational.VariationalAutoencoder; -import org.deeplearning4j.nn.layers.recurrent.BidirectionalLayer; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.deeplearning4j.nn.weights.WeightInit; -import org.junit.jupiter.api.BeforeAll; -import org.junit.jupiter.api.Test; -import org.junit.jupiter.api.io.TempDir; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.activations.IActivation; -import org.nd4j.linalg.api.buffer.DataType; -import org.nd4j.linalg.dataset.DataSet; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.factory.Nd4j; -import org.nd4j.linalg.learning.config.Nesterovs; -import org.nd4j.linalg.learning.config.Sgd; -import org.nd4j.linalg.lossfunctions.ILossFunction; -import org.nd4j.linalg.lossfunctions.LossFunctions; -import org.nd4j.linalg.lossfunctions.LossFunctions.LossFunction; -import org.nd4j.linalg.lossfunctions.impl.LossMCXENT; -import org.nd4j.linalg.lossfunctions.impl.LossMSE; -import org.nd4j.common.primitives.Pair; - -import java.io.File; -import java.lang.reflect.Field; -import java.util.*; - -import static org.junit.jupiter.api.Assertions.*; - -public class TestMultiLayerSpace extends BaseDL4JTest { - - @TempDir - public File testDir; - - @BeforeAll - public static void before(){ - Nd4j.setDefaultDataTypes(DataType.FLOAT, DataType.FLOAT); - } - - @Test - public void testBasic() { - - MultiLayerConfiguration expected = - new NeuralNetConfiguration.Builder() - .updater(new Sgd(0.005)).seed(12345).list() - .layer(0, new DenseLayer.Builder().nIn(10).nOut(10).build()) - .layer(1, new DenseLayer.Builder().nIn(10).nOut(10).build()).layer(2, - new OutputLayer.Builder().lossFunction(LossFunction.MCXENT) - .activation(Activation.SOFTMAX).nIn(10).nOut(5).build()) - - .build(); - - MultiLayerSpace mls = - new MultiLayerSpace.Builder() - .updater(new Sgd(0.005)).seed(12345) - .addLayer(new DenseLayerSpace.Builder().nIn(10).nOut(10).build(), - new FixedValue<>(2)) //2 identical layers - .addLayer(new OutputLayerSpace.Builder().lossFunction(LossFunction.MCXENT) - .activation(Activation.SOFTMAX) - .nIn(10).nOut(5).build()).build(); - - int nParams = mls.numParameters(); - assertEquals(0, nParams); - - MultiLayerConfiguration conf = mls.getValue(new double[0]).getMultiLayerConfiguration(); - - assertEquals(expected, conf); - } - - @Test - public void testBasic0() { - MultiLayerConfiguration expected = - new NeuralNetConfiguration.Builder() - .l1Bias(0.4) - .l2Bias(0.5) - .constrainBias(new NonNegativeConstraint()) - .updater(new Sgd(0.005)).seed(12345).list() - .layer(0, new DenseLayer.Builder().l1Bias(0.6).nIn(10).nOut(10).build()) - .layer(1, new DenseLayer.Builder().l2Bias(0.7).constrainBias(new UnitNormConstraint()).nIn(10).nOut(10).build()).layer(2, - new OutputLayer.Builder().lossFunction(LossFunction.MCXENT).activation(Activation.SOFTMAX) - .nIn(10).nOut(5).build()) - .build(); - - MultiLayerSpace mls = - new MultiLayerSpace.Builder() - .l1Bias(0.4) - .l2Bias(0.5) - .constrainBias(new NonNegativeConstraint()) - .updater(new Sgd(0.005)).seed(12345) - .addLayer(new DenseLayerSpace.Builder().l1Bias(new ContinuousParameterSpace(0,1)).nIn(10).nOut(10).build()) - .addLayer(new DenseLayerSpace.Builder().l2Bias(0.7).constrainBias(new UnitNormConstraint()).nIn(10).nOut(10).build()) - .addLayer(new OutputLayerSpace.Builder().lossFunction(LossFunction.MCXENT).activation(Activation.SOFTMAX) - .nIn(10).nOut(5).build()) - .build(); - - int nParams = mls.numParameters(); - assertEquals(1, nParams); - - //Assign numbers to each leaf ParameterSpace object (normally done by candidate generator - manual here for testing) - List noDuplicatesList = LeafUtils.getUniqueObjects(mls.collectLeaves()); - - //Second: assign each a number - int c = 0; - for (ParameterSpace ps : noDuplicatesList) { - int np = ps.numParameters(); - if (np == 1) { - ps.setIndices(c++); - } else { - int[] values = new int[np]; - for (int j = 0; j < np; j++) - values[c++] = j; - ps.setIndices(values); - } - } - MultiLayerConfiguration conf = mls.getValue(new double[] {0.6}).getMultiLayerConfiguration(); - - assertEquals(expected, conf); - } - - @Test - public void testILossFunctionGetsSet() { - ILossFunction lossFunction = new LossMCXENT(Nd4j.create(new float[] {1f, 2f}, new long[]{1,2})); - - MultiLayerConfiguration expected = - new NeuralNetConfiguration.Builder().updater(new Sgd(0.005)).seed(12345).list() - .layer(0, new DenseLayer.Builder().nIn(10).nOut(10).build()) - .layer(1, new DenseLayer.Builder().nIn(10).nOut(10).build()).layer(2, - new OutputLayer.Builder().lossFunction(lossFunction) - .activation(Activation.SOFTMAX).nIn(10).nOut(5).build()) - .build(); - - MultiLayerSpace mls = new MultiLayerSpace.Builder().updater(new Sgd(0.005)).seed(12345) - .addLayer(new DenseLayerSpace.Builder().nIn(10).nOut(10).build(), new FixedValue<>(2)) //2 identical layers - .addLayer(new OutputLayerSpace.Builder().iLossFunction(lossFunction).activation(Activation.SOFTMAX).nIn(10).nOut(5).build()) - .build(); - - int nParams = mls.numParameters(); - assertEquals(0, nParams); - - MultiLayerConfiguration conf = mls.getValue(new double[0]).getMultiLayerConfiguration(); - - assertEquals(expected, conf); - } - - @Test - public void testBasic2() { - - MultiLayerSpace mls = - new MultiLayerSpace.Builder().updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.1))) - .l2(new ContinuousParameterSpace(0.2, 0.5)) - .convolutionMode(ConvolutionMode.Same) - .addLayer(new ConvolutionLayerSpace.Builder().nIn(3).nOut(3).kernelSize(2, 2) - .stride(1, 1).build()) - .addLayer(new DenseLayerSpace.Builder().nIn(10).nOut(10) - .activation(new DiscreteParameterSpace<>(Activation.RELU, - Activation.TANH)) - .build(), new IntegerParameterSpace(1, 3)) //1-3 identical layers - .addLayer(new OutputLayerSpace.Builder().nIn(10).nOut(10) - .activation(Activation.SOFTMAX).build()) - .build(); - - int nParams = mls.numParameters(); - assertEquals(4, nParams); - - //Assign numbers to each leaf ParameterSpace object (normally done by candidate generator - manual here for testing) - List noDuplicatesList = LeafUtils.getUniqueObjects(mls.collectLeaves()); - - //Second: assign each a number - int c = 0; - for (ParameterSpace ps : noDuplicatesList) { - int np = ps.numParameters(); - if (np == 1) { - ps.setIndices(c++); - } else { - int[] values = new int[np]; - for (int j = 0; j < np; j++) - values[c++] = j; - ps.setIndices(values); - } - } - - - int[] nLayerCounts = new int[3]; - int reluCount = 0; - int tanhCount = 0; - - Random r = new Random(12345); - - for (int i = 0; i < 50; i++) { - - double[] rvs = new double[nParams]; - for (int j = 0; j < rvs.length; j++) - rvs[j] = r.nextDouble(); - - - MultiLayerConfiguration conf = mls.getValue(rvs).getMultiLayerConfiguration(); - - int nLayers = conf.getConfs().size(); - assertTrue(nLayers >= 3 && nLayers <= 5); //1 conv + 1-3 dense layers + 1 output layer: 2 to 4 - - int nLayersExOutputLayer = nLayers - 1; - nLayerCounts[nLayersExOutputLayer - 2]++; - - for (int j = 0; j < nLayers; j++) { - NeuralNetConfiguration layerConf = conf.getConf(j); - - double lr = ((Sgd)((BaseLayer) layerConf.getLayer()).getIUpdater()).getLearningRate(); - assertTrue(lr >= 0.0001 && lr <= 0.1); - double l2 = TestUtils.getL2((BaseLayer) layerConf.getLayer()); - assertTrue(l2 >= 0.2 && l2 <= 0.5); - - if (j == nLayers - 1) { //Output layer - assertEquals(Activation.SOFTMAX.getActivationFunction(), ((BaseLayer) layerConf.getLayer()).getActivationFn()); - } else if (j == 0) { - //Conv layer - ConvolutionLayer cl = (ConvolutionLayer) layerConf.getLayer(); - assertEquals(3, cl.getNIn()); - assertEquals(3, cl.getNOut()); - assertEquals(ConvolutionMode.Same, cl.getConvolutionMode()); - } else { - IActivation actFn = ((BaseLayer) layerConf.getLayer()).getActivationFn(); - assertTrue(Activation.RELU.getActivationFunction().equals(actFn) || - Activation.TANH.getActivationFunction().equals(actFn)); - if (Activation.RELU.getActivationFunction().equals(actFn)) - reluCount++; - else - tanhCount++; - } - } - } - - for (int i = 0; i < 3; i++) { - assertTrue(nLayerCounts[i] >= 5); //Expect approx equal (50/3 each), but some variation randomly - } - -// System.out.println("Number of layers: " + Arrays.toString(nLayerCounts)); -// System.out.println("ReLU vs. Tanh: " + reluCount + "\t" + tanhCount); - - } - - @Test - public void testGlobalPoolingBasic() { - - MultiLayerConfiguration expected = new NeuralNetConfiguration.Builder().updater(new Sgd(0.005)).seed(12345).list() - .layer(0, new GravesLSTM.Builder().nIn(10).nOut(10).build()) - .layer(1, new GlobalPoolingLayer.Builder().poolingType(PoolingType.SUM).pnorm(7).build()) - .layer(2, new OutputLayer.Builder().lossFunction(LossFunction.MCXENT).activation(Activation.SOFTMAX).nIn(10).nOut(5).build()) - .build(); - - MultiLayerSpace mls = - new MultiLayerSpace.Builder().updater(new Sgd(0.005)).seed(12345) - .addLayer(new GravesLSTMLayerSpace.Builder().nIn(10).nOut(10).build()) - .addLayer(new GlobalPoolingLayerSpace.Builder().poolingType(PoolingType.SUM) - .pNorm(7).build()) - .addLayer(new OutputLayerSpace.Builder().lossFunction(LossFunction.MCXENT) - .activation(Activation.SOFTMAX) - .nIn(10).nOut(5).build()) - .build(); - - int nParams = mls.numParameters(); - assertEquals(0, nParams); - - MultiLayerConfiguration conf = mls.getValue(new double[0]).getMultiLayerConfiguration(); - - assertEquals(expected, conf); - } - - - @Test - public void testVariationalAutoencoderLayerSpaceBasic() { - MultiLayerSpace mls = - new MultiLayerSpace.Builder() - .updater(new Sgd(0.005)).seed( - 12345) - .addLayer(new VariationalAutoencoderLayerSpace.Builder() - .nIn(new IntegerParameterSpace(50, 75)).nOut(200) - .encoderLayerSizes(234, 567).decoderLayerSizes(123, 456) - .reconstructionDistribution( - new DiscreteParameterSpace( - new GaussianReconstructionDistribution(), - new BernoulliReconstructionDistribution())) - .build()) - .build(); - - int numParams = mls.numParameters(); - - //Assign numbers to each leaf ParameterSpace object (normally done by candidate generator - manual here for testing) - List noDuplicatesList = LeafUtils.getUniqueObjects(mls.collectLeaves()); - - //Second: assign each a number - int c = 0; - for (ParameterSpace ps : noDuplicatesList) { - int np = ps.numParameters(); - if (np == 1) { - ps.setIndices(c++); - } else { - int[] values = new int[np]; - for (int j = 0; j < np; j++) - values[c++] = j; - ps.setIndices(values); - } - } - - double[] zeros = new double[numParams]; - - DL4JConfiguration configuration = mls.getValue(zeros); - - MultiLayerConfiguration conf = configuration.getMultiLayerConfiguration(); - assertEquals(1, conf.getConfs().size()); - - NeuralNetConfiguration nnc = conf.getConf(0); - VariationalAutoencoder vae = (VariationalAutoencoder) nnc.getLayer(); - - assertEquals(50, vae.getNIn()); - assertEquals(200, vae.getNOut()); - - assertArrayEquals(new int[] {234, 567}, vae.getEncoderLayerSizes()); - assertArrayEquals(new int[] {123, 456}, vae.getDecoderLayerSizes()); - - assertTrue(vae.getOutputDistribution() instanceof GaussianReconstructionDistribution); - - - - double[] ones = new double[numParams]; - for (int i = 0; i < ones.length; i++) - ones[i] = 1.0; - - configuration = mls.getValue(ones); - - conf = configuration.getMultiLayerConfiguration(); - assertEquals(1, conf.getConfs().size()); - - nnc = conf.getConf(0); - vae = (VariationalAutoencoder) nnc.getLayer(); - - assertEquals(75, vae.getNIn()); - assertEquals(200, vae.getNOut()); - - assertArrayEquals(new int[] {234, 567}, vae.getEncoderLayerSizes()); - assertArrayEquals(new int[] {123, 456}, vae.getDecoderLayerSizes()); - - assertTrue(vae.getOutputDistribution() instanceof BernoulliReconstructionDistribution); - } - - @Test - public void testInputTypeBasic() throws Exception { - - ParameterSpace layerSizeHyperparam = new IntegerParameterSpace(20, 60); - - MultiLayerSpace hyperparameterSpace = new MultiLayerSpace.Builder().l2(0.0001) - .weightInit(WeightInit.XAVIER).updater(new Nesterovs()) - .addLayer(new ConvolutionLayerSpace.Builder().kernelSize(5, 5).nIn(1).stride(1, 1) - .nOut(layerSizeHyperparam).activation(Activation.IDENTITY).build()) - .addLayer(new SubsamplingLayerSpace.Builder().poolingType(SubsamplingLayer.PoolingType.MAX) - .kernelSize(2, 2).stride(2, 2).build()) - .addLayer(new ConvolutionLayerSpace.Builder().kernelSize(5, 5) - //Note that nIn need not be specified in later layers - .stride(1, 1).nOut(50).activation(Activation.IDENTITY).build()) - .addLayer(new SubsamplingLayerSpace.Builder().poolingType(SubsamplingLayer.PoolingType.MAX) - .kernelSize(2, 2).stride(2, 2).build()) - .addLayer(new DenseLayerSpace.Builder().activation(Activation.RELU).nOut(500).build()) - .addLayer(new OutputLayerSpace.Builder() - .lossFunction(LossFunctions.LossFunction.NEGATIVELOGLIKELIHOOD).nOut(10) - .activation(Activation.SOFTMAX).build()) - .setInputType(InputType.convolutionalFlat(28, 28, 1)).build(); - - - DataProvider dataProvider = new TestDataSetProvider(); - - File f = testDir; - if (f.exists()) - f.delete(); - f.mkdir(); - ResultSaver modelSaver = new FileModelSaver(f.getAbsolutePath()); - - ScoreFunction scoreFunction = new TestSetAccuracyScoreFunction(); - - int maxCandidates = 4; - TerminationCondition[] terminationConditions; - terminationConditions = new TerminationCondition[] {new MaxCandidatesCondition(maxCandidates)}; - - //Given these configuration options, let's put them all together: - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(new RandomSearchGenerator(hyperparameterSpace, null)) - .dataProvider(dataProvider).modelSaver(modelSaver).scoreFunction(scoreFunction) - .terminationConditions(terminationConditions).build(); - - IOptimizationRunner runner = new LocalOptimizationRunner(configuration, new MultiLayerNetworkTaskCreator()); - runner.execute(); - - assertEquals(maxCandidates, runner.getResults().size()); - } - - - @Test - public void testSameRanges() { - - ParameterSpace l1Hyperparam = new ContinuousParameterSpace(0.001, 0.1); - ParameterSpace l2Hyperparam = new ContinuousParameterSpace(0.001, 0.1); - - MultiLayerSpace hyperparameterSpace = - new MultiLayerSpace.Builder().addLayer(new DenseLayerSpace.Builder().nIn(10).nOut(10).build()) - .l1(l1Hyperparam).l2(l2Hyperparam).build(); - - CandidateGenerator c = new RandomSearchGenerator(hyperparameterSpace, null); - - Candidate candidate = c.getCandidate(); - } - - @Test - public void testWeightedLossFunction() { - - MultiLayerConfiguration expected = - new NeuralNetConfiguration.Builder().updater(new Sgd(0.005)).seed(12345).list() - .layer(0, new DenseLayer.Builder().nIn(10).nOut(10).build()) - .layer(1, new DenseLayer.Builder().nIn(10).nOut(10).build()).layer(2, - new OutputLayer.Builder() - .lossFunction(new LossMSE(Nd4j.create( - new double[] {1, 2, 3, 4, 5}, new long[]{1,5}))) - .nIn(10).nOut(5).build()) - .build(); - - MultiLayerSpace mls = - new MultiLayerSpace.Builder().updater(new Sgd(0.005)).seed(12345) - .addLayer(new DenseLayerSpace.Builder().nIn(10).nOut(10).build(), - new FixedValue<>(2)) //2 identical layers - .addLayer(new OutputLayerSpace.Builder() - .iLossFunction(new LossMSE(Nd4j.create(new double[] {1, 2, 3, 4, 5}, new long[]{1,5}))) - .nIn(10).nOut(5).build()) - .build(); - - int nParams = mls.numParameters(); - assertEquals(0, nParams); - - MultiLayerConfiguration conf = mls.getValue(new double[0]).getMultiLayerConfiguration(); - - assertEquals(expected, conf); - - String json = mls.toJson(); - MultiLayerSpace fromJson = MultiLayerSpace.fromJson(json); - - assertEquals(mls, fromJson); - } - - - @Test - public void testBidirectional() throws Exception { - - MultiLayerSpace mls = - new MultiLayerSpace.Builder().updater(new Sgd(0.005)) - .seed(12345) - .layer(new Bidirectional(new LSTMLayerSpace.Builder() - .nIn(10).nOut(10).build())) - .build(); - - DL4JConfiguration conf = mls.getValue(new double[0]); - MultiLayerConfiguration c2 = conf.getMultiLayerConfiguration(); - - MultiLayerNetwork net = new MultiLayerNetwork(c2); - net.init(); - - assertEquals(1, net.getnLayers()); - assertTrue(net.getLayer(0) instanceof BidirectionalLayer); - BidirectionalLayer bl = (BidirectionalLayer)net.getLayer(0); - - Field f = BidirectionalLayer.class.getDeclaredField("fwd"); - Field b = BidirectionalLayer.class.getDeclaredField("bwd"); - f.setAccessible(true); - b.setAccessible(true); - org.deeplearning4j.nn.layers.recurrent.LSTM lstmFwd = (org.deeplearning4j.nn.layers.recurrent.LSTM) f.get(bl); - org.deeplearning4j.nn.layers.recurrent.LSTM lstmBwd = (org.deeplearning4j.nn.layers.recurrent.LSTM) b.get(bl); - - assertEquals(10, ((LSTM)lstmFwd.conf().getLayer()).getNIn()); - assertEquals(10, ((LSTM)lstmFwd.conf().getLayer()).getNOut()); - assertEquals(10, ((LSTM)lstmBwd.conf().getLayer()).getNIn()); - assertEquals(10, ((LSTM)lstmBwd.conf().getLayer()).getNOut()); - } - - - @Test - public void testMathOps() { - - ParameterSpace firstLayerSize = new IntegerParameterSpace(10,30); - ParameterSpace secondLayerSize = new MathOp<>(firstLayerSize, Op.MUL, 3); - ParameterSpace firstLayerLR = new ContinuousParameterSpace(0.01, 0.1); - ParameterSpace secondLayerLR = new MathOp<>(firstLayerLR, Op.ADD, 0.2); - - MultiLayerSpace mls = - new MultiLayerSpace.Builder().updater(new Sgd(0.005)) - .seed(12345) - .layer(new DenseLayerSpace.Builder().nOut(firstLayerSize) - .updater(new AdamSpace(firstLayerLR)) - .build()) - .layer(new OutputLayerSpace.Builder().nOut(secondLayerSize) - .updater(new AdamSpace(secondLayerLR)) - .activation(Activation.SOFTMAX) - .build()) - .setInputType(InputType.feedForward(10)) - .build(); - - int nParams = mls.numParameters(); - assertEquals(2, nParams); - - new RandomSearchGenerator(mls, null); //Initializes the indices - - Random r = new Random(12345); - for( int i=0; i<10; i++ ){ - double[] d = new double[nParams]; - for( int j=0; j dropout = new DiscreteParameterSpace<>(0.0, 0.5); - - MultiLayerSpace mls = - new MultiLayerSpace.Builder().updater(new Sgd(0.005)) - .dropOut(dropout) - .seed(12345) - .layer(new DenseLayerSpace.Builder().nOut(10) - .build()) - .layer(new OutputLayerSpace.Builder().nOut(10).activation(Activation.SOFTMAX) - .build()) - .setInputType(InputType.feedForward(10)) - .build(); - - int nParams = mls.numParameters(); - assertEquals(1, nParams); - - new RandomSearchGenerator(mls, null); //Initializes the indices - - Random r = new Random(12345); - int countNull = 0; - int count05 = 0; - for( int i=0; i<10; i++ ){ - double[] d = new double[nParams]; - for( int j=0; j 0); - assertTrue(count05 > 0); - } - - - private static class TestDataSetProvider implements DataProvider { - - @Override - public Object trainData(Map dataParameters) { - return new ExistingDataSetIterator( - Collections.singletonList(new DataSet(Nd4j.create(1, 1, 28, 28), Nd4j.create(1,10)))); - } - - @Override - public Object testData(Map dataParameters) { - return new ExistingDataSetIterator( - Collections.singletonList(new DataSet(Nd4j.create(1, 1, 28, 28), Nd4j.create(1,10)))); - } - - @Override - public Class getDataType() { - return DataSetIterator.class; - } - } - - - @Test - public void testDropout(){ - - MultiLayerSpace mls = new MultiLayerSpace.Builder().updater(new Sgd(0.005)).seed(12345) - .addLayer(new ConvolutionLayerSpace.Builder().nOut(2) - .dropOut(new ContinuousParameterSpace(0.4,0.6)) - .build()) - .addLayer(new GlobalPoolingLayerSpace.Builder().dropOut(new ContinuousParameterSpace(0.4,0.6)).build()) - .addLayer(new OutputLayerSpace.Builder().activation(Activation.SOFTMAX).nIn(10).nOut(5).build()) - .setInputType(InputType.convolutional(28, 28, 1)) - .build(); - - int nParams = mls.numParameters(); - List l = LeafUtils.getUniqueObjects(mls.collectLeaves()); - int x=0; - for( ParameterSpace p : l){ - int n = p.numParameters(); - int[] arr = new int[n]; - for(int i=0; i l = LeafUtils.getUniqueObjects(mls.collectLeaves()); - int x=0; - for( ParameterSpace p : l){ - int n = p.numParameters(); - int[] arr = new int[n]; - for(int i=0; i learningRateHyperparam = new DiscreteParameterSpace<>(0.003, 0.005, 0.01, 0.05); - ParameterSpace layerSizeHyperparam1 = new DiscreteParameterSpace<>(32, 64, 96, 128); - ParameterSpace layerSizeHyperparam2 = new DiscreteParameterSpace<>(32, 64, 96, 128); - ParameterSpace dropoutHyperparam = new DiscreteParameterSpace<>(0.8, 0.9); - - MultiLayerSpace mls = new MultiLayerSpace.Builder() - .updater(new AdamSpace(learningRateHyperparam)) - .weightInit(WeightInit.XAVIER) - .l2(0.0001) - .addLayer(new DenseLayerSpace.Builder() - .nIn(10) - .nOut(layerSizeHyperparam1) - .build()) - .addLayer(new BatchNormalizationSpace.Builder() - .nOut(layerSizeHyperparam1) - .activation(Activation.RELU) - .build()) - .addLayer(new DropoutLayerSpace.Builder() - .dropOut(dropoutHyperparam) - .build()) - .addLayer(new DenseLayerSpace.Builder() - .nOut(layerSizeHyperparam2) - .build()) - .addLayer(new BatchNormalizationSpace.Builder() - .nOut(layerSizeHyperparam2) - .activation(Activation.RELU) - .build()) - .addLayer(new DropoutLayerSpace.Builder() - .dropOut(dropoutHyperparam) - .build()) - .addLayer(new OutputLayerSpace.Builder() - .nOut(10) - .activation(Activation.SOFTMAX) - .lossFunction(LossFunction.MCXENT) - .build()) - .build(); - - assertEquals(4, mls.getNumParameters()); - - for( int discreteCount : new int[]{1, 5}) { - GridSearchCandidateGenerator generator = new GridSearchCandidateGenerator(mls, discreteCount, GridSearchCandidateGenerator.Mode.Sequential, null); - - int expCandidates = 4 * 4 * 4 * 2; - assertEquals(expCandidates, generator.getTotalNumCandidates()); - - int count = 0; - while (generator.hasMoreCandidates()) { - generator.getCandidate(); - count++; - } - - - assertEquals(expCandidates, count); - } - } - - - @Test - public void testGridCandidateGenerator(){ - ParameterSpace layerSizeParam = new DiscreteParameterSpace<>(32, 48, 64); - ParameterSpace learningRateParam = new DiscreteParameterSpace<>(0.005, 0.007, 0.01); - - MultiLayerSpace hyperParamaterSpace = new MultiLayerSpace.Builder() - .seed(12345) - .biasInit(1) - .l2(1e-4) - .updater(new NesterovsSpace(learningRateParam)) - .addLayer(new DenseLayerSpace.Builder().nIn(10).nOut(layerSizeParam) - .weightInit(WeightInit.XAVIER) - .activation(Activation.RELU) - .build()) - .addLayer(new DenseLayerSpace.Builder().nIn(layerSizeParam).nOut(layerSizeParam) - .weightInit(WeightInit.XAVIER) - .activation(Activation.RELU) - .build()) - .addLayer(new OutputLayerSpace.Builder() - .lossFunction(LossFunctions.LossFunction.MSE) - .weightInit(WeightInit.XAVIER) - .activation(Activation.SOFTMAX) - .nIn(layerSizeParam).nOut(10).build()) - .build(); - - CandidateGenerator candidateGenerator = new GridSearchCandidateGenerator(hyperParamaterSpace, 30, GridSearchCandidateGenerator.Mode.Sequential, null); -// CandidateGenerator candidateGenerator = new RandomSearchGenerator(hyperParamaterSpace); - - Set> expCandidates = new HashSet<>(); - for(Double d : new double[]{0.005, 0.007, 0.01}){ - for(int i : new int[]{32, 48, 64}){ - expCandidates.add(new Pair<>(d, i)); - } - } - - Set> actCandidates = new HashSet<>(); - while(candidateGenerator.hasMoreCandidates()) { - Candidate conf = candidateGenerator.getCandidate(); - MultiLayerConfiguration mlc = conf.getValue().getMultiLayerConfiguration(); - FeedForwardLayer ffl = ((FeedForwardLayer) mlc.getConf(0).getLayer()); -// System.out.println(ffl.getIUpdater() + ", " + ffl.getNOut()); - actCandidates.add(new Pair<>(ffl.getIUpdater().getLearningRate(0,0), (int)ffl.getNOut())); - } - - assertEquals(expCandidates, actCandidates); - } -} diff --git a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestScoreFunctions.java b/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestScoreFunctions.java deleted file mode 100644 index e9c34c947..000000000 --- a/arbiter/arbiter-deeplearning4j/src/test/java/org/deeplearning4j/arbiter/multilayernetwork/TestScoreFunctions.java +++ /dev/null @@ -1,220 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.multilayernetwork; - -import lombok.AllArgsConstructor; -import lombok.extern.slf4j.Slf4j; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.MultiLayerSpace; -import org.deeplearning4j.arbiter.conf.updater.AdamSpace; -import org.deeplearning4j.arbiter.layers.OutputLayerSpace; -import org.deeplearning4j.arbiter.optimize.api.CandidateGenerator; -import org.deeplearning4j.arbiter.optimize.api.OptimizationResult; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.saving.InMemoryResultSaver; -import org.deeplearning4j.arbiter.optimize.api.saving.ResultReference; -import org.deeplearning4j.arbiter.optimize.api.saving.ResultSaver; -import org.deeplearning4j.arbiter.optimize.api.score.ScoreFunction; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxCandidatesCondition; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; -import org.deeplearning4j.arbiter.optimize.generator.RandomSearchGenerator; -import org.deeplearning4j.arbiter.optimize.parameter.continuous.ContinuousParameterSpace; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.LocalOptimizationRunner; -import org.deeplearning4j.arbiter.scoring.impl.ROCScoreFunction; -import org.deeplearning4j.arbiter.task.MultiLayerNetworkTaskCreator; -import org.deeplearning4j.datasets.iterator.impl.MnistDataSetIterator; -import org.deeplearning4j.eval.ROC; -import org.deeplearning4j.eval.ROCBinary; -import org.deeplearning4j.eval.ROCMultiClass; -import org.deeplearning4j.nn.conf.WorkspaceMode; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.deeplearning4j.nn.weights.WeightInit; -import org.junit.jupiter.api.Test; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.api.ndarray.INDArray; -import org.nd4j.linalg.dataset.api.DataSet; -import org.nd4j.linalg.dataset.api.DataSetPreProcessor; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.factory.Nd4j; -import org.nd4j.linalg.lossfunctions.LossFunctions; - -import java.io.IOException; -import java.util.List; -import java.util.Map; - -import static org.junit.jupiter.api.Assertions.assertEquals; - -@Slf4j -public class TestScoreFunctions extends BaseDL4JTest { - - - @Override - public long getTimeoutMilliseconds() { - return 60000L; - } - - @Test - public void testROCScoreFunctions() throws Exception { - - - for (boolean auc : new boolean[]{true, false}) { - for (ROCScoreFunction.ROCType rocType : ROCScoreFunction.ROCType.values()) { - String msg = (auc ? "AUC" : "AUPRC") + " - " + rocType; - log.info("Starting: " + msg); - - ParameterSpace lr = new ContinuousParameterSpace(1e-5, 1e-3); - - int nOut = (rocType == ROCScoreFunction.ROCType.ROC ? 2 : 10); - LossFunctions.LossFunction lf = (rocType == ROCScoreFunction.ROCType.BINARY ? - LossFunctions.LossFunction.XENT : LossFunctions.LossFunction.MCXENT); - Activation a = (rocType == ROCScoreFunction.ROCType.BINARY ? Activation.SIGMOID : Activation.SOFTMAX); - MultiLayerSpace mls = new MultiLayerSpace.Builder() - .trainingWorkspaceMode(WorkspaceMode.NONE) - .inferenceWorkspaceMode(WorkspaceMode.NONE) - .updater(new AdamSpace(lr)) - .weightInit(WeightInit.XAVIER) - .layer(new OutputLayerSpace.Builder().nIn(784).nOut(nOut) - .activation(a) - .lossFunction(lf).build()) - .build(); - - CandidateGenerator cg = new RandomSearchGenerator(mls); - ResultSaver rs = new InMemoryResultSaver(); - ScoreFunction sf = new ROCScoreFunction(rocType, (auc ? ROCScoreFunction.Metric.AUC : ROCScoreFunction.Metric.AUPRC)); - - - OptimizationConfiguration oc = new OptimizationConfiguration.Builder() - .candidateGenerator(cg) - .dataProvider(new DP(rocType)) - .modelSaver(rs) - .scoreFunction(sf) - .terminationConditions(new MaxCandidatesCondition(3)) - .rngSeed(12345) - .build(); - - IOptimizationRunner runner = new LocalOptimizationRunner(oc, new MultiLayerNetworkTaskCreator()); - runner.execute(); - - List list = runner.getResults(); - - for (ResultReference rr : list) { - DataSetIterator testIter = new MnistDataSetIterator(4, 16, false, false, false, 12345); - testIter.setPreProcessor(new PreProc(rocType)); - - OptimizationResult or = rr.getResult(); - MultiLayerNetwork net = (MultiLayerNetwork) or.getResultReference().getResultModel(); - - double expScore; - switch (rocType){ - case ROC: - if(auc){ - expScore = net.doEvaluation(testIter, new ROC())[0].calculateAUC(); - } else { - expScore = net.doEvaluation(testIter, new ROC())[0].calculateAUCPR(); - } - break; - case BINARY: - if(auc){ - expScore = net.doEvaluation(testIter, new ROCBinary())[0].calculateAverageAuc(); - } else { - expScore = net.doEvaluation(testIter, new ROCBinary())[0].calculateAverageAUCPR(); - } - break; - case MULTICLASS: - if(auc){ - expScore = net.doEvaluation(testIter, new ROCMultiClass())[0].calculateAverageAUC(); - } else { - expScore = net.doEvaluation(testIter, new ROCMultiClass())[0].calculateAverageAUCPR(); - } - break; - default: - throw new RuntimeException(); - } - - - DataSetIterator iter = new MnistDataSetIterator(4, 16, false, false, false, 12345); - iter.setPreProcessor(new PreProc(rocType)); - - assertEquals(expScore, or.getScore(), 1e-4, msg); - } - } - } - } - - @AllArgsConstructor - public static class DP implements DataProvider { - - protected ROCScoreFunction.ROCType rocType; - - @Override - public Object trainData(Map dataParameters) { - try { - DataSetIterator iter = new MnistDataSetIterator(4, 16, false, false, false, 12345); - iter.setPreProcessor(new PreProc(rocType)); - return iter; - } catch (IOException e){ - throw new RuntimeException(e); - } - } - - @Override - public Object testData(Map dataParameters) { - try { - DataSetIterator iter = new MnistDataSetIterator(4, 16, false, false, false, 12345); - iter.setPreProcessor(new PreProc(rocType)); - return iter; - } catch (IOException e){ - throw new RuntimeException(e); - } - } - - @Override - public Class getDataType() { - return DataSetIterator.class; - } - } - - @AllArgsConstructor - public static class PreProc implements DataSetPreProcessor { - protected ROCScoreFunction.ROCType rocType; - - @Override - public void preProcess(DataSet toPreProcess) { - switch (rocType){ - case ROC: - //Convert to binary - long mb = toPreProcess.getLabels().size(0); - INDArray argMax = Nd4j.argMax(toPreProcess.getLabels(), 1); - INDArray newLabel = Nd4j.create(mb, 2); - for( int i=0; i dataParameters) { - try { - return new EarlyTerminationDataSetIterator(new MnistDataSetIterator(batchSize, true, 12345), terminationIter); - } catch (Exception e){ - throw new RuntimeException(e); - } - } - - @Override - public Object testData(Map dataParameters) { - try { - return new EarlyTerminationDataSetIterator(new MnistDataSetIterator(batchSize, false, 12345), terminationIter); - } catch (Exception e){ - throw new RuntimeException(e); - } - } - - @Override - public Class getDataType() { - return DataSetIterator.class; - } - - -} diff --git a/arbiter/arbiter-deeplearning4j/src/test/resources/logback.xml b/arbiter/arbiter-deeplearning4j/src/test/resources/logback.xml deleted file mode 100644 index 410bdaae9..000000000 --- a/arbiter/arbiter-deeplearning4j/src/test/resources/logback.xml +++ /dev/null @@ -1,51 +0,0 @@ - - - - - - logs/application.log - - %date - [%level] - from %logger in %thread - %n%message%n%xException%n - - - - - - %logger{15} - %message%n%xException{5} - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/arbiter/arbiter-server/pom.xml b/arbiter/arbiter-server/pom.xml deleted file mode 100644 index c38549354..000000000 --- a/arbiter/arbiter-server/pom.xml +++ /dev/null @@ -1,63 +0,0 @@ - - - - - arbiter - net.brutex.ai - 1.0.0-SNAPSHOT - - 4.0.0 - - arbiter-server - jar - - arbiter-server - - - UTF-8 - - - - - com.beust - jcommander - 1.27 - - - net.brutex.ai - arbiter-deeplearning4j - ${project.version} - - - - net.brutex.ai - deeplearning4j-common-tests - ${project.version} - test - - - - - - test-nd4j-native - - - test-nd4j-cuda-10.2 - - - diff --git a/arbiter/arbiter-server/src/main/java/org/deeplearning4j/arbiter/server/ArbiterCliGenerator.java b/arbiter/arbiter-server/src/main/java/org/deeplearning4j/arbiter/server/ArbiterCliGenerator.java deleted file mode 100644 index af19a81f7..000000000 --- a/arbiter/arbiter-server/src/main/java/org/deeplearning4j/arbiter/server/ArbiterCliGenerator.java +++ /dev/null @@ -1,286 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.server; - -import com.beust.jcommander.JCommander; -import com.beust.jcommander.Parameter; -import com.beust.jcommander.ParameterException; -import org.apache.commons.io.FileUtils; -import org.deeplearning4j.arbiter.ComputationGraphSpace; -import org.deeplearning4j.arbiter.MultiLayerSpace; -import org.deeplearning4j.arbiter.optimize.api.CandidateGenerator; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSetIteratorFactoryProvider; -import org.deeplearning4j.arbiter.optimize.api.score.ScoreFunction; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxCandidatesCondition; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxTimeCondition; -import org.deeplearning4j.arbiter.optimize.api.termination.TerminationCondition; -import org.deeplearning4j.arbiter.optimize.generator.GridSearchCandidateGenerator; -import org.deeplearning4j.arbiter.optimize.generator.RandomSearchGenerator; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; -import org.deeplearning4j.arbiter.saver.local.FileModelSaver; -import org.deeplearning4j.arbiter.scoring.RegressionValue; -import org.deeplearning4j.arbiter.scoring.ScoreFunctions; - -import java.io.File; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; -import java.util.concurrent.TimeUnit; - -/** - * Generate an {@link OptimizationConfiguration} - * via the command line interface. - * You can then use this configuration json file from - * {@link ArbiterCliRunner} - * - * @author Adam Gibson - */ -public class ArbiterCliGenerator { - @Parameter(names = {"--searchSpacePath"}) - private String searchSpacePath = null; - @Parameter(names = {"--candidateType"},required = true) - private String candidateType = null; - @Parameter(names = {"--discretizationCount"}) - private int discretizationCount = 5; - @Parameter(names = {"--gridSearchOrder"}) - private String gridSearchOrder = null; - @Parameter(names = {"--neuralNetType"},required = true) - private String neuralNetType = null; - @Parameter(names = {"--dataSetIteratorClass"},required = true) - private String dataSetIteratorClass = null; - @Parameter(names = {"--modelOutputPath"},required = true) - private String modelOutputPath = null; - @Parameter(names = {"--score"},required = true) - private String score = null; - @Parameter(names = {"--problemType"},required = true) - private String problemType = CLASSIFICIATION; - @Parameter(names = {"--configSavePath"},required = true) - private String configSavePath = null; - - @Parameter(names = {"--duration"},description = "The number of minutes to run for. Default is -1 which means run till convergence.") - private long duration = -1; - @Parameter(names = {"--numCandidates"},description = "The number of candidates to generate. Default is 1.") - private int numCandidates = 1; - - public final static String REGRESSION_MULTI = "regression"; - public final static String REGRESSION = "regression"; - public final static String CLASSIFICIATION = "classification"; - - public final static String RANDOM_CANDIDATE = "random"; - public final static String GRID_SEARCH_CANDIDATE = "gridsearch"; - - public final static String SEQUENTIAL_ORDER = "sequence"; - public final static String RANDOM_ORDER = "random"; - - public final static String COMP_GRAPH = "compgraph"; - public final static String MULTI_LAYER = "multilayer"; - - public final static String ACCURACY = "accuracy"; - public final static String F1 = "f1"; - - public final static String ACCURACY_MULTI = "accuracy_multi"; - public final static String F1_MULTI = "f1_multi"; - - - public final static String REGRESSION_SCORE = "regression_score"; - public final static String REGRESSION_SCORE_MULTI = "regression_score_multi"; - - public void runMain(String...args) throws Exception { - JCommander jcmdr = new JCommander(this); - - try { - jcmdr.parse(args); - } catch(ParameterException e) { - System.err.println(e.getMessage()); - //User provides invalid input -> print the usage info - jcmdr.usage(); - try{ Thread.sleep(500); } catch(Exception e2){ } - System.exit(1); - } - - - DataProvider dataProvider = new DataSetIteratorFactoryProvider(); - Map commands = new HashMap<>(); - commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY,dataSetIteratorClass); - - - if(neuralNetType.equals(MULTI_LAYER)) { - MultiLayerSpace multiLayerSpace = loadMultiLayer(); - CandidateGenerator candidateGenerator = null; - if(candidateType.equals(GRID_SEARCH_CANDIDATE)) { - candidateGenerator = new RandomSearchGenerator(multiLayerSpace,commands); - - - - } - else if(candidateType.equals(RANDOM_CANDIDATE)) { - candidateGenerator = new RandomSearchGenerator(multiLayerSpace,commands); - - } - - if(problemType.equals(CLASSIFICIATION)) { - OptimizationConfiguration configuration - = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator) - .dataProvider(dataProvider) - .modelSaver(new FileModelSaver(modelOutputPath)) - .scoreFunction(scoreFunctionMultiLayerNetwork()) - .terminationConditions(getConditions()) - .build(); - FileUtils.writeStringToFile(new File(configSavePath),configuration.toJson()); - - } - else if(problemType.equals(REGRESSION)) { - OptimizationConfiguration configuration - = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator) - .dataProvider(dataProvider) - .modelSaver(new FileModelSaver(modelOutputPath)) - .scoreFunction(scoreFunctionMultiLayerNetwork()) - .terminationConditions(getConditions()) - .build(); - FileUtils.writeStringToFile(new File(configSavePath),configuration.toJson()); - - } - - - } - else if(neuralNetType.equals(COMP_GRAPH)) { - ComputationGraphSpace computationGraphSpace = loadCompGraph(); - CandidateGenerator candidateGenerator = null; - if(candidateType.equals(GRID_SEARCH_CANDIDATE)) { - candidateGenerator = new RandomSearchGenerator(computationGraphSpace,commands); - - } - else if(candidateType.equals(RANDOM_CANDIDATE)) { - candidateGenerator = new RandomSearchGenerator(computationGraphSpace,commands); - - } - - - if(problemType.equals(CLASSIFICIATION)) { - OptimizationConfiguration configuration - = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator) - .dataProvider(dataProvider) - .modelSaver(new FileModelSaver(modelOutputPath)) - .scoreFunction(scoreFunctionCompGraph()) - .terminationConditions(getConditions()) - .build(); - - FileUtils.writeStringToFile(new File(configSavePath),configuration.toJson()); - } - else { - OptimizationConfiguration configuration - = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator) - .dataProvider(dataProvider) - .modelSaver(new FileModelSaver(modelOutputPath)) - .scoreFunction(scoreFunctionCompGraph()) - .terminationConditions(getConditions()) - .build(); - FileUtils.writeStringToFile(new File(configSavePath),configuration.toJson()); - - - } - - - } - - - } - - public static void main(String...args) throws Exception { - new ArbiterCliGenerator().runMain(args); - } - - private List getConditions() { - List ret = new ArrayList<>(); - if(duration > 0) { - ret.add(new MaxTimeCondition(duration,TimeUnit.MINUTES)); - } - - if(numCandidates > 0) - ret.add(new MaxCandidatesCondition(numCandidates)); - if(ret.isEmpty()) { - ret.add(new MaxCandidatesCondition(1)); - } - return ret; - } - - - private GridSearchCandidateGenerator.Mode getMode() { - if(gridSearchOrder.equals(RANDOM_ORDER)) - return GridSearchCandidateGenerator.Mode.RandomOrder; - else if(gridSearchOrder.equals(SEQUENTIAL_ORDER)) { - return GridSearchCandidateGenerator.Mode.Sequential; - } - else throw new IllegalArgumentException("Illegal mode " + gridSearchOrder); - } - - private ScoreFunction scoreFunctionCompGraph() { - if(problemType.equals(CLASSIFICIATION)) { - switch(score) { - case ACCURACY: return ScoreFunctions.testSetAccuracy(); - case F1: return ScoreFunctions.testSetF1(); - case F1_MULTI : return ScoreFunctions.testSetF1(); - case ACCURACY_MULTI: return ScoreFunctions.testSetAccuracy(); - - default: throw new IllegalArgumentException("Score " + score + " not valid for type " + problemType); - } - } - else if(problemType.equals(REGRESSION)) { - switch(score) { - case REGRESSION_SCORE: return ScoreFunctions.testSetRegression(RegressionValue.valueOf(score)); - case REGRESSION_SCORE_MULTI: return ScoreFunctions.testSetRegression(RegressionValue.valueOf(score)); - default: throw new IllegalArgumentException("Score " + score + " not valid for type " + problemType); - } - } - throw new IllegalStateException("Illegal problem type " + problemType); - } - - private ScoreFunction scoreFunctionMultiLayerNetwork() { - if(problemType.equals(CLASSIFICIATION)) { - switch(score) { - case ACCURACY: return ScoreFunctions.testSetAccuracy(); - case F1: return ScoreFunctions.testSetF1(); - - default: throw new IllegalArgumentException("Score " + score + " not valid for type " + problemType); - } - } - else if(problemType.equals(REGRESSION)) { - switch(score) { - case REGRESSION_SCORE: return ScoreFunctions.testSetRegression(RegressionValue.valueOf(score)); - default: throw new IllegalArgumentException("Score " + score + " not valid for type " + problemType); - - } - } - throw new IllegalStateException("Illegal problem type " + problemType); - } - - private ComputationGraphSpace loadCompGraph() throws Exception { - ComputationGraphSpace multiLayerSpace = ComputationGraphSpace.fromJson(FileUtils.readFileToString(new File(searchSpacePath))); - return multiLayerSpace; - } - - private MultiLayerSpace loadMultiLayer() throws Exception { - MultiLayerSpace multiLayerSpace = MultiLayerSpace.fromJson(FileUtils.readFileToString(new File(searchSpacePath))); - return multiLayerSpace; - } -} diff --git a/arbiter/arbiter-server/src/main/java/org/deeplearning4j/arbiter/server/ArbiterCliRunner.java b/arbiter/arbiter-server/src/main/java/org/deeplearning4j/arbiter/server/ArbiterCliRunner.java deleted file mode 100644 index c845828cf..000000000 --- a/arbiter/arbiter-server/src/main/java/org/deeplearning4j/arbiter/server/ArbiterCliRunner.java +++ /dev/null @@ -1,152 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.server; - -import com.beust.jcommander.JCommander; -import com.beust.jcommander.Parameter; -import com.beust.jcommander.ParameterException; -import org.apache.commons.io.FileUtils; -import org.deeplearning4j.arbiter.evaluator.multilayer.ClassificationEvaluator; -import org.deeplearning4j.arbiter.evaluator.multilayer.RegressionDataEvaluator; -import org.deeplearning4j.arbiter.optimize.api.data.DataSetIteratorFactoryProvider; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.LocalOptimizationRunner; -import org.deeplearning4j.arbiter.scoring.RegressionValue; -import org.deeplearning4j.arbiter.server.cli.NeuralNetTypeValidator; -import org.deeplearning4j.arbiter.server.cli.ProblemTypeValidator; -import org.deeplearning4j.arbiter.task.ComputationGraphTaskCreator; -import org.deeplearning4j.arbiter.task.MultiLayerNetworkTaskCreator; - -import java.io.File; -import java.util.HashMap; -import java.util.Map; - -/** - * Options: - * --dataSetIteratorClass - --modelSavePath - Default: /tmp - * --neuralNetType - --optimizationConfigPath - --problemType - Default: classification - --regressionType - - - - @author Adam Gibson - */ -public class ArbiterCliRunner { - @Parameter(names = {"--modelSavePath"}) - private String modelSavePath = System.getProperty("java.io.tmpdir"); - @Parameter(names = {"--optimizationConfigPath"}) - private String optimizationConfigPath = null; - @Parameter(names = {"--problemType"},validateWith = ProblemTypeValidator.class) - private String problemType = CLASSIFICATION; - @Parameter(names = {"--regressionType"}) - private String regressionType = null; - @Parameter(names = {"--dataSetIteratorClass"},required = true) - private String dataSetIteratorClass = null; - @Parameter(names = {"--neuralNetType"},required = true,validateWith = NeuralNetTypeValidator.class) - private String neuralNetType = null; - - public final static String CLASSIFICATION = "classification"; - public final static String REGRESSION = "regression"; - - - public final static String COMP_GRAPH = "compgraph"; - public final static String MULTI_LAYER_NETWORK = "multilayernetwork"; - - public void runMain(String...args) throws Exception { - JCommander jcmdr = new JCommander(this); - - try { - jcmdr.parse(args); - } catch(ParameterException e) { - System.err.println(e.getMessage()); - //User provides invalid input -> print the usage info - jcmdr.usage(); - try{ Thread.sleep(500); } catch(Exception e2){ } - System.exit(1); - } - - Map commands = new HashMap<>(); - commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY,dataSetIteratorClass); - - File f = new File(modelSavePath); - - if(f.exists()) f.delete(); - f.mkdir(); - f.deleteOnExit(); - - if(problemType.equals(REGRESSION)) { - if(neuralNetType.equals(COMP_GRAPH)) { - OptimizationConfiguration configuration - = OptimizationConfiguration.fromJson( - FileUtils.readFileToString(new File(optimizationConfigPath))); - - IOptimizationRunner runner - = new LocalOptimizationRunner(configuration, new ComputationGraphTaskCreator( - new RegressionDataEvaluator(RegressionValue.valueOf(regressionType),commands))); - runner.execute(); - } - else if(neuralNetType.equals(MULTI_LAYER_NETWORK)) { - OptimizationConfiguration configuration = OptimizationConfiguration. - fromJson(FileUtils.readFileToString(new File(optimizationConfigPath))); - - IOptimizationRunner runner - = new LocalOptimizationRunner( - configuration, - new MultiLayerNetworkTaskCreator( - new RegressionDataEvaluator( - RegressionValue.valueOf(regressionType), - commands))); - runner.execute(); - } - } - - else if(problemType.equals(CLASSIFICATION)) { - if(neuralNetType.equals(COMP_GRAPH)) { - OptimizationConfiguration configuration - = OptimizationConfiguration.fromJson(FileUtils.readFileToString(new File(optimizationConfigPath))); - - IOptimizationRunner runner - = new LocalOptimizationRunner( - configuration,new ComputationGraphTaskCreator(new ClassificationEvaluator())); - - runner.execute(); - } - else if(neuralNetType.equals(MULTI_LAYER_NETWORK)) { - OptimizationConfiguration configuration = OptimizationConfiguration - .fromJson(FileUtils.readFileToString(new File(optimizationConfigPath))); - - IOptimizationRunner runner - = new LocalOptimizationRunner(configuration, - new MultiLayerNetworkTaskCreator( - new ClassificationEvaluator()) - ); - - runner.execute(); - } - } - } - public static void main(String...args) throws Exception { - new ArbiterCliRunner().runMain(args); - } - -} diff --git a/arbiter/arbiter-server/src/main/java/org/deeplearning4j/arbiter/server/cli/NeuralNetTypeValidator.java b/arbiter/arbiter-server/src/main/java/org/deeplearning4j/arbiter/server/cli/NeuralNetTypeValidator.java deleted file mode 100644 index 1a338bdc0..000000000 --- a/arbiter/arbiter-server/src/main/java/org/deeplearning4j/arbiter/server/cli/NeuralNetTypeValidator.java +++ /dev/null @@ -1,41 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.server.cli; - -import com.beust.jcommander.IParameterValidator; -import com.beust.jcommander.ParameterException; -import org.deeplearning4j.arbiter.server.ArbiterCliRunner; - -/** - * Created by agibsonccc on 3/13/17. - */ -public class NeuralNetTypeValidator implements IParameterValidator { - /** - * Validate the parameter. - * - * @param name The name of the parameter (e.g. "-host"). - * @param value The value of the parameter that we need to validate - * @throws ParameterException Thrown if the value of the parameter is invalid. - */ - @Override - public void validate(String name, String value) throws ParameterException { - if(!value.equals(ArbiterCliRunner.MULTI_LAYER_NETWORK) || value.equals(ArbiterCliRunner.COMP_GRAPH)) { - throw new ParameterException("Neural net type can only be " + ArbiterCliRunner.COMP_GRAPH + " or " + ArbiterCliRunner.MULTI_LAYER_NETWORK); - - } - } -} diff --git a/arbiter/arbiter-server/src/main/java/org/deeplearning4j/arbiter/server/cli/ProblemTypeValidator.java b/arbiter/arbiter-server/src/main/java/org/deeplearning4j/arbiter/server/cli/ProblemTypeValidator.java deleted file mode 100644 index 3df2f6449..000000000 --- a/arbiter/arbiter-server/src/main/java/org/deeplearning4j/arbiter/server/cli/ProblemTypeValidator.java +++ /dev/null @@ -1,41 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.server.cli; - -import com.beust.jcommander.IParameterValidator; -import com.beust.jcommander.ParameterException; -import org.deeplearning4j.arbiter.server.ArbiterCliGenerator; - -/** - * Created by agibsonccc on 3/13/17. - */ -public class ProblemTypeValidator implements IParameterValidator { - /** - * Validate the parameter. - * - * @param name The name of the parameter (e.g. "-host"). - * @param value The value of the parameter that we need to validate - * @throws ParameterException Thrown if the value of the parameter is invalid. - */ - @Override - public void validate(String name, String value) throws ParameterException { - if(!value.equals(ArbiterCliGenerator.REGRESSION) || value.equals(ArbiterCliGenerator.CLASSIFICIATION)) { - throw new ParameterException("Problem type can only be " + ArbiterCliGenerator.REGRESSION + " or " + ArbiterCliGenerator.CLASSIFICIATION); - - } - } -} diff --git a/arbiter/arbiter-server/src/test/java/org/deeplearning4j/arbiter/server/ArbiterCLIRunnerTest.java b/arbiter/arbiter-server/src/test/java/org/deeplearning4j/arbiter/server/ArbiterCLIRunnerTest.java deleted file mode 100644 index 5efcd9657..000000000 --- a/arbiter/arbiter-server/src/test/java/org/deeplearning4j/arbiter/server/ArbiterCLIRunnerTest.java +++ /dev/null @@ -1,121 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.server; - -import lombok.extern.slf4j.Slf4j; -import org.apache.commons.io.FileUtils; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.arbiter.MultiLayerSpace; -import org.deeplearning4j.arbiter.conf.updater.SgdSpace; -import org.deeplearning4j.arbiter.layers.DenseLayerSpace; -import org.deeplearning4j.arbiter.layers.OutputLayerSpace; -import org.deeplearning4j.arbiter.optimize.api.CandidateGenerator; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSetIteratorFactoryProvider; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxCandidatesCondition; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxTimeCondition; -import org.deeplearning4j.arbiter.optimize.generator.RandomSearchGenerator; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; -import org.deeplearning4j.arbiter.optimize.parameter.continuous.ContinuousParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.discrete.DiscreteParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.integer.IntegerParameterSpace; -import org.deeplearning4j.arbiter.saver.local.FileModelSaver; -import org.deeplearning4j.arbiter.scoring.impl.TestSetLossScoreFunction; -import org.deeplearning4j.nn.api.OptimizationAlgorithm; -import org.junit.jupiter.api.Test; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.learning.config.Sgd; -import org.nd4j.linalg.lossfunctions.LossFunctions; - -import java.io.File; -import java.util.HashMap; -import java.util.Map; -import java.util.UUID; -import java.util.concurrent.TimeUnit; - -import static org.junit.jupiter.api.Assertions.assertEquals; - -/** - * Created by agibsonccc on 3/12/17. - */ -@Slf4j -public class ArbiterCLIRunnerTest extends BaseDL4JTest { - - @Override - public long getTimeoutMilliseconds() { - return 90000; - } - - @Test - public void testCliRunner() throws Exception { - ArbiterCliRunner cliRunner = new ArbiterCliRunner(); - - //Define: network config (hyperparameter space) - MultiLayerSpace mls = new MultiLayerSpace.Builder() - .optimizationAlgo(OptimizationAlgorithm.STOCHASTIC_GRADIENT_DESCENT) - .updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.1))) - .l2(new ContinuousParameterSpace(0.0001, 0.01)) - .addLayer(new DenseLayerSpace.Builder().nIn(784).nOut(new IntegerParameterSpace(2,10)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, Activation.TANH)) - .build()) - .addLayer(new OutputLayerSpace.Builder().nOut(10).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build()) - .numEpochs(3).build(); - assertEquals(mls,MultiLayerSpace.fromJson(mls.toJson())); - //Define configuration: - Map commands = new HashMap<>(); - commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY,TestDataFactoryProviderMnist.class.getCanonicalName()); - - CandidateGenerator candidateGenerator = new RandomSearchGenerator(mls,commands); - DataProvider dataProvider = new DataSetIteratorFactoryProvider(); - - -// String modelSavePath = FilenameUtils.concat(System.getProperty("java.io.tmpdir"),"ArbiterDL4JTest/"); - String modelSavePath = new File(System.getProperty("java.io.tmpdir"),"ArbiterDL4JTest/").getAbsolutePath(); - File dir = new File(modelSavePath); - if(!dir.exists()) - dir.mkdirs(); - String configPath = System.getProperty("java.io.tmpdir") + File.separator + UUID.randomUUID().toString() + ".json"; - OptimizationConfiguration configuration - = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator) - .dataProvider(dataProvider) - .modelSaver(new FileModelSaver(modelSavePath)) - .scoreFunction(new TestSetLossScoreFunction()) - .terminationConditions(new MaxTimeCondition(30, TimeUnit.SECONDS), - new MaxCandidatesCondition(5)) - .build(); - assertEquals(configuration,OptimizationConfiguration.fromJson(configuration.toJson())); - - FileUtils.writeStringToFile(new File(configPath),configuration.toJson()); -// System.out.println(configuration.toJson()); - configuration.toJson(); - - log.info("Starting test"); - cliRunner.runMain( - "--dataSetIteratorClass", - TestDataFactoryProviderMnist.class.getCanonicalName(), - "--neuralNetType", - ArbiterCliRunner.MULTI_LAYER_NETWORK, - "--optimizationConfigPath", - configPath - ); - } - - - -} diff --git a/arbiter/arbiter-server/src/test/java/org/deeplearning4j/arbiter/server/AssertTestsExtendBaseClass.java b/arbiter/arbiter-server/src/test/java/org/deeplearning4j/arbiter/server/AssertTestsExtendBaseClass.java deleted file mode 100644 index 256a8af9b..000000000 --- a/arbiter/arbiter-server/src/test/java/org/deeplearning4j/arbiter/server/AssertTestsExtendBaseClass.java +++ /dev/null @@ -1,50 +0,0 @@ -/* ****************************************************************************** - * Copyright (c) 2020 Konduit K.K. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ -package org.deeplearning4j.arbiter.server; - -import lombok.extern.slf4j.Slf4j; -import org.deeplearning4j.BaseDL4JTest; -import org.nd4j.common.tests.AbstractAssertTestsClass; - -import java.util.*; - -/** - * This class checks that all test classes (i.e., anything with one or more methods annotated with @Test) - * extends BaseDl4jTest - either directly or indirectly. - * Other than a small set of exceptions, all tests must extend this - * - * @author Alex Black - */ - -@Slf4j -public class AssertTestsExtendBaseClass extends AbstractAssertTestsClass { - - @Override - protected Set> getExclusions() { - //Set of classes that are exclusions to the rule (either run manually or have their own logging + timeouts) - return new HashSet<>(); - } - - @Override - protected String getPackageName() { - return "org.deeplearning4j.arbiter.server"; - } - - @Override - protected Class getBaseClass() { - return BaseDL4JTest.class; - } -} diff --git a/arbiter/arbiter-server/src/test/java/org/deeplearning4j/arbiter/server/MnistDataSetIteratorFactory.java b/arbiter/arbiter-server/src/test/java/org/deeplearning4j/arbiter/server/MnistDataSetIteratorFactory.java deleted file mode 100644 index 57bef758d..000000000 --- a/arbiter/arbiter-server/src/test/java/org/deeplearning4j/arbiter/server/MnistDataSetIteratorFactory.java +++ /dev/null @@ -1,43 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.server; - -import lombok.Data; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.datasets.iterator.impl.MnistDataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.DataSetIteratorFactory; - -import java.io.IOException; - -/** - * Created by agibsonccc on 3/13/17. - */ -@Data -public class MnistDataSetIteratorFactory extends BaseDL4JTest implements DataSetIteratorFactory { - /** - * @return - */ - @Override - public DataSetIterator create() { - try { - return new MnistDataSetIterator(1000,1000); - } catch (IOException e) { - throw new RuntimeException(e); - } - } -} diff --git a/arbiter/arbiter-server/src/test/java/org/deeplearning4j/arbiter/server/TestDataFactoryProviderMnist.java b/arbiter/arbiter-server/src/test/java/org/deeplearning4j/arbiter/server/TestDataFactoryProviderMnist.java deleted file mode 100644 index c4a75ffb4..000000000 --- a/arbiter/arbiter-server/src/test/java/org/deeplearning4j/arbiter/server/TestDataFactoryProviderMnist.java +++ /dev/null @@ -1,44 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.server; - -import lombok.AllArgsConstructor; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.datasets.iterator.EarlyTerminationDataSetIterator; -import org.deeplearning4j.datasets.iterator.impl.MnistDataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.dataset.api.iterator.DataSetIteratorFactory; - -@AllArgsConstructor -public class TestDataFactoryProviderMnist extends BaseDL4JTest implements DataSetIteratorFactory { - - private int batchSize; - private int terminationIter; - - public TestDataFactoryProviderMnist(){ - this(16, 10); - } - - @Override - public DataSetIterator create() { - try { - return new EarlyTerminationDataSetIterator(new MnistDataSetIterator(batchSize, true, 12345), terminationIter); - } catch (Exception e){ - throw new RuntimeException(e); - } - } -} diff --git a/arbiter/arbiter-ui/pom.xml b/arbiter/arbiter-ui/pom.xml deleted file mode 100644 index 86f4530a9..000000000 --- a/arbiter/arbiter-ui/pom.xml +++ /dev/null @@ -1,73 +0,0 @@ - - - - - - arbiter - net.brutex.ai - 1.0.0-SNAPSHOT - - - 4.0.0 - - arbiter-ui - arbiter-ui - - - - net.brutex.ai - arbiter-core - ${project.version} - - - - net.brutex.ai - deeplearning4j-ui - ${project.version} - - - - net.brutex.ai - deeplearning4j-common-tests - ${project.version} - test - - - - net.brutex.ai - arbiter-deeplearning4j - ${project.version} - - - com.fasterxml.jackson.core - jackson-core - ${jackson.version} - - - com.fasterxml.jackson.core - jackson-annotations - ${jackson.version} - - - com.fasterxml.jackson.core - jackson-databind - ${jackson.databind.version} - - - diff --git a/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/UpdateStatus.java b/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/UpdateStatus.java deleted file mode 100644 index a92b4f0e7..000000000 --- a/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/UpdateStatus.java +++ /dev/null @@ -1,33 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.ui; - -import lombok.AllArgsConstructor; -import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.NoArgsConstructor; - -@AllArgsConstructor -@NoArgsConstructor -@EqualsAndHashCode -@Data -public class UpdateStatus { - - private long statusUpdateTime; - private long settingsUpdateTime; - private long resultsUpdateTime; -} diff --git a/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/data/BaseJavaPersistable.java b/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/data/BaseJavaPersistable.java deleted file mode 100644 index 1fb699e0b..000000000 --- a/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/data/BaseJavaPersistable.java +++ /dev/null @@ -1,159 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.ui.data; - -import lombok.AllArgsConstructor; -import org.apache.commons.compress.utils.IOUtils; -import org.deeplearning4j.core.storage.Persistable; -import org.deeplearning4j.arbiter.ui.module.ArbiterModule; - -import java.io.*; -import java.lang.reflect.Field; -import java.lang.reflect.Modifier; -import java.nio.ByteBuffer; -import java.util.ArrayList; -import java.util.List; - -/** - * Common implementation - * - * @author Alex Black - */ -@AllArgsConstructor -public abstract class BaseJavaPersistable implements Persistable { - - private String sessionId; - private long timestamp; - - public BaseJavaPersistable(Builder builder){ - this.sessionId = builder.sessionId; - this.timestamp = builder.timestamp; - } - - protected BaseJavaPersistable(){ - //No-arg costructor for Pesistable encoding/decoding - } - - @Override - public String getTypeID() { - return ArbiterModule.ARBITER_UI_TYPE_ID; - } - - @Override - public long getTimeStamp() { - return timestamp; - } - - @Override - public String getSessionID() { - return sessionId; - } - - @Override - public int encodingLengthBytes() { - //TODO - presumably a more efficient way to do this - byte[] encoded = encode(); - return encoded.length; - } - - @Override - public byte[] encode() { - ByteArrayOutputStream baos = new ByteArrayOutputStream(); - try (ObjectOutputStream oos = new ObjectOutputStream(baos)) { - oos.writeObject(this); - } catch (IOException e) { - throw new RuntimeException(e); //Should never happen - } - return baos.toByteArray(); - } - - @Override - public void encode(ByteBuffer buffer) { - buffer.put(encode()); - } - - @Override - public void encode(OutputStream outputStream) throws IOException { - try (ObjectOutputStream oos = new ObjectOutputStream(outputStream)) { - oos.writeObject(this); - } - } - - @Override - public void decode(byte[] decode) { - BaseJavaPersistable r; - try (ObjectInputStream ois = new ObjectInputStream(new ByteArrayInputStream(decode))) { - r = (BaseJavaPersistable) ois.readObject(); - } catch (IOException | ClassNotFoundException e) { - throw new RuntimeException(e); //Should never happen - } - - //Need to manually build and walk the class heirarchy... - Class currClass = this.getClass(); - List> classHeirarchy = new ArrayList<>(); - while (currClass != Object.class) { - classHeirarchy.add(currClass); - currClass = currClass.getSuperclass(); - } - - for (int i = classHeirarchy.size() - 1; i >= 0; i--) { - //Use reflection here to avoid a mass of boilerplate code... - Field[] allFields = classHeirarchy.get(i).getDeclaredFields(); - - for (Field f : allFields) { - if (Modifier.isStatic(f.getModifiers())) { - //Skip static fields - continue; - } - f.setAccessible(true); - try { - f.set(this, f.get(r)); - } catch (IllegalAccessException e) { - throw new RuntimeException(e); //Should never happen - } - } - } - } - - @Override - public void decode(ByteBuffer buffer) { - byte[] bytes = new byte[buffer.remaining()]; - buffer.get(bytes); - decode(bytes); - } - - @Override - public void decode(InputStream inputStream) throws IOException { - decode(IOUtils.toByteArray(inputStream)); - } - - public static abstract class Builder> { - protected String sessionId; - protected long timestamp; - - public T sessionId(String sessionId){ - this.sessionId = sessionId; - return (T) this; - } - - public T timestamp(long timestamp){ - this.timestamp = timestamp; - return (T) this; - } - - } -} diff --git a/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/data/GlobalConfigPersistable.java b/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/data/GlobalConfigPersistable.java deleted file mode 100644 index 9a6c3faa9..000000000 --- a/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/data/GlobalConfigPersistable.java +++ /dev/null @@ -1,119 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.ui.data; - -import lombok.Getter; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; -import org.deeplearning4j.arbiter.optimize.serde.jackson.JsonMapper; -import org.deeplearning4j.arbiter.ui.module.ArbiterModule; -import org.deeplearning4j.core.storage.Persistable; - -import java.io.IOException; - -/** - * - * A {@link Persistable} implemention for global settings - * @author Alex Black - */ -@Getter -public class GlobalConfigPersistable extends BaseJavaPersistable { - public static final String GLOBAL_WORKER_ID = "global"; - - private String optimizationConfigJson; - private int[] candidateCounts; //queued, completed, failed, total - private String optimizationRunner; - - public GlobalConfigPersistable(String sessionId, long timestamp){ - super(sessionId, timestamp); - } - - public GlobalConfigPersistable(Builder builder){ - super(builder); - this.optimizationConfigJson = builder.optimizationConfigJson; - this.candidateCounts = builder.candidateCounts; - if(this.candidateCounts == null){ - this.candidateCounts = new int[4]; - } - this.optimizationRunner = builder.optimizationRunner; - } - - public GlobalConfigPersistable(){ - //No-arg costructor for Pesistable encoding/decoding - } - - @Override - public String getTypeID() { - return ArbiterModule.ARBITER_UI_TYPE_ID; - } - - @Override - public String getWorkerID() { - return GLOBAL_WORKER_ID; - } - - - public OptimizationConfiguration getOptimizationConfiguration(){ - try { - return JsonMapper.getMapper().readValue(optimizationConfigJson, OptimizationConfiguration.class); - } catch (IOException e){ - throw new RuntimeException(e); - } - } - - public int getCandidatesQueued(){ - return candidateCounts[0]; - } - - public int getCandidatesCompleted(){ - return candidateCounts[1]; - } - - public int getCandidatesFailed(){ - return candidateCounts[2]; - } - - public int getCandidatesTotal(){ - return candidateCounts[3]; - } - - public static class Builder extends BaseJavaPersistable.Builder{ - - private String optimizationConfigJson; - private int[] candidateCounts; //queued, completed, failed, total - private String optimizationRunner; - - public Builder optimizationConfigJson(String optimizationConfigJson){ - this.optimizationConfigJson = optimizationConfigJson; - return this; - } - - public Builder candidateCounts(int queued, int completed, int failed, int total){ - this.candidateCounts = new int[]{queued, completed, failed, total}; - return this; - } - - public Builder optimizationRunner(String optimizationRunner){ - this.optimizationRunner = optimizationRunner; - return this; - } - - public GlobalConfigPersistable build(){ - return new GlobalConfigPersistable(this); - } - - } -} diff --git a/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/data/ModelInfoPersistable.java b/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/data/ModelInfoPersistable.java deleted file mode 100644 index 4d1ee4e5f..000000000 --- a/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/data/ModelInfoPersistable.java +++ /dev/null @@ -1,163 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.ui.data; - -import lombok.Data; -import org.deeplearning4j.arbiter.optimize.runner.CandidateStatus; -import org.deeplearning4j.core.storage.Persistable; - -/** - * A {@link Persistable} implemention for model results - i.e., results for - * each model - * - * @author Alex BLack - */ -@Data -public class ModelInfoPersistable extends BaseJavaPersistable { - - private String workerId; - private Integer modelIdx; - private Double score; - private CandidateStatus status; - private long lastUpdateTime; - private long numParameters; - private int numLayers; - //From candidate generator - this + model hyperparam space means we can work out specific hyperparam - // settings for this model - private double[] paramSpaceValues; - private int totalNumUpdates; - //Values for score vs. iteration chart - private int[] iter; - private float[] scoreVsIter; - private String modelConfigJson; - private String exceptionStackTrace; - - public ModelInfoPersistable(String sessionId, String workerId, long timeStamp){ - super(sessionId, timeStamp); - - this.workerId = workerId; - } - - private ModelInfoPersistable(Builder builder){ - super(builder); - this.workerId = builder.workerId; - this.modelIdx = builder.modelIdx; - this.score = builder.score; - this.status = builder.status; - this.iter = builder.iter; - this.scoreVsIter = builder.scoreVsIter; - this.lastUpdateTime = builder.lastUpdateTime; - this.numParameters = builder.numParameters; - this.numLayers = builder.numLayers; - this.paramSpaceValues = builder.paramSpaceValues; - this.modelConfigJson = builder.modelConfigJson; - this.totalNumUpdates = builder.totalNumUpdates; - this.exceptionStackTrace = builder.exceptionStackTrace; - } - - public ModelInfoPersistable(){ - //No-arg costructor for Pesistable encoding/decoding - } - - @Override - public String getWorkerID() { - return workerId; - } - - - public static class Builder extends BaseJavaPersistable.Builder { - - private String workerId; - private Integer modelIdx; - private Double score; - private CandidateStatus status; - private long lastUpdateTime;; - private long numParameters; - private int numLayers; - private int totalNumUpdates; - private double[] paramSpaceValues; - private int[] iter; - private float[] scoreVsIter; - private String modelConfigJson; - private String exceptionStackTrace; - - public Builder workerId(String workerId){ - this.workerId = workerId; - return this; - } - - public Builder modelIdx(Integer idx){ - this.modelIdx = idx; - return this; - } - - public Builder score(Double score){ - this.score = score; - return this; - } - - public Builder status(CandidateStatus status){ - this.status = status; - return this; - } - - public Builder scoreVsIter(int[] iter, float[] scoreVsIter){ - this.iter = iter; - this.scoreVsIter = scoreVsIter; - return this; - } - - public Builder lastUpdateTime(long lastUpdateTime){ - this.lastUpdateTime = lastUpdateTime; - return this; - } - - public Builder numParameters(long numParameters){ - this.numParameters = numParameters; - return this; - } - - public Builder numLayers(int numLayers){ - this.numLayers = numLayers; - return this; - } - - public Builder totalNumUpdates(int totalNumUpdates){ - this.totalNumUpdates = totalNumUpdates; - return this; - } - - public Builder paramSpaceValues(double[] paramSpaceValues){ - this.paramSpaceValues = paramSpaceValues; - return this; - } - - public Builder modelConfigJson(String modelConfigJson){ - this.modelConfigJson = modelConfigJson; - return this; - } - - public Builder exceptionStackTrace(String exceptionStackTrace){ - this.exceptionStackTrace = exceptionStackTrace; - return this; - } - - public ModelInfoPersistable build(){ - return new ModelInfoPersistable(this); - } - } -} diff --git a/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/listener/ArbiterStatusListener.java b/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/listener/ArbiterStatusListener.java deleted file mode 100644 index c14258be2..000000000 --- a/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/listener/ArbiterStatusListener.java +++ /dev/null @@ -1,238 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.ui.listener; - -import it.unimi.dsi.fastutil.floats.FloatArrayList; -import it.unimi.dsi.fastutil.ints.IntArrayList; -import lombok.NonNull; -import lombok.extern.slf4j.Slf4j; -import org.deeplearning4j.core.storage.Persistable; -import org.deeplearning4j.core.storage.StatsStorageRouter; -import org.deeplearning4j.arbiter.optimize.api.OptimizationResult; -import org.deeplearning4j.arbiter.optimize.runner.CandidateInfo; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.listener.StatusListener; -import org.deeplearning4j.arbiter.optimize.serde.jackson.JsonMapper; -import org.deeplearning4j.arbiter.ui.data.GlobalConfigPersistable; -import org.deeplearning4j.arbiter.ui.data.ModelInfoPersistable; -import org.deeplearning4j.nn.graph.ComputationGraph; -import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; -import org.nd4j.common.primitives.Pair; - -import java.io.IOException; -import java.util.Map; -import java.util.UUID; -import java.util.concurrent.ConcurrentHashMap; - -/** - * A {@link StatusListener} for reporting Arbiter/DL4J optimization results to a {@link StatsStorageRouter} - * - * @author Alex Black - */ -@Slf4j -public class ArbiterStatusListener implements StatusListener { - - public static final int MAX_SCORE_VS_ITER_PTS = 1024; //Above this: subsample... every 2nd, 4th, 8th etc - - private final String sessionId; - private final StatsStorageRouter statsStorage; - - private String ocJson; - private long startTime = 0; - - private Map candidateScoreVsIterSubsampleFreq = new ConcurrentHashMap<>(); - private Map> candidateScoreVsIter = new ConcurrentHashMap<>(); - - private Map lastModelInfoPersistable = new ConcurrentHashMap<>(); - - public ArbiterStatusListener(@NonNull StatsStorageRouter statsStorage) { - this(UUID.randomUUID().toString(), statsStorage); - } - - public ArbiterStatusListener(@NonNull String sessionId, @NonNull StatsStorageRouter statsStorage){ - this.sessionId = sessionId; - this.statsStorage = statsStorage; - } - - @Override - public void onInitialization(IOptimizationRunner r) { - Persistable p = getNewStatusPersistable(r); - statsStorage.putStaticInfo(p); - } - - @Override - public void onShutdown(IOptimizationRunner runner) { - //No op? - - } - - @Override - public void onRunnerStatusChange(IOptimizationRunner r) { - Persistable p = getNewStatusPersistable(r); - statsStorage.putStaticInfo(p); - } - - @Override - public void onCandidateStatusChange(CandidateInfo candidateInfo, IOptimizationRunner runner, OptimizationResult result) { - ModelInfoPersistable p = lastModelInfoPersistable.get(candidateInfo.getIndex()); - if(p == null){ - p = new ModelInfoPersistable.Builder() - .timestamp(candidateInfo.getCreatedTime()) - .sessionId(sessionId) - .workerId(String.valueOf(candidateInfo.getIndex())) - .modelIdx(candidateInfo.getIndex()) - .score(candidateInfo.getScore()) - .status(candidateInfo.getCandidateStatus()) - .exceptionStackTrace(candidateInfo.getExceptionStackTrace()) - .build(); - - lastModelInfoPersistable.put(candidateInfo.getIndex(), p); - } - - if(p.getScore() == null){ - p.setScore(candidateInfo.getScore()); - } - - if(result != null && p.getExceptionStackTrace() == null && result.getCandidateInfo().getExceptionStackTrace() != null){ - //Update exceptions that may have occurred since earlier model info instance - p.setExceptionStackTrace(result.getCandidateInfo().getExceptionStackTrace()); - } - - p.setStatus(candidateInfo.getCandidateStatus()); - - statsStorage.putUpdate(p); - } - - @Override - public void onCandidateIteration(CandidateInfo candidateInfo, Object candidate, int iteration) { - double score; - long numParams; - int numLayers; - String modelConfigJson; - int totalNumUpdates; - if(candidate instanceof MultiLayerNetwork){ - MultiLayerNetwork m = (MultiLayerNetwork)candidate; - score = m.score(); - numParams = m.numParams(); - numLayers = m.getnLayers(); - modelConfigJson = m.getLayerWiseConfigurations().toJson(); - totalNumUpdates = m.getLayerWiseConfigurations().getIterationCount(); - } else if(candidate instanceof ComputationGraph) { - ComputationGraph cg = (ComputationGraph)candidate; - score = cg.score(); - numParams = cg.numParams(); - numLayers = cg.getNumLayers(); - modelConfigJson = cg.getConfiguration().toJson(); - totalNumUpdates = cg.getConfiguration().getIterationCount(); - } else { - score = 0; - numParams = 0; - numLayers = 0; - totalNumUpdates = 0; - modelConfigJson = ""; - } - - int idx = candidateInfo.getIndex(); - - Pair pair = candidateScoreVsIter.computeIfAbsent(idx, k -> new Pair<>(new IntArrayList(), new FloatArrayList())); - - IntArrayList iter = pair.getFirst(); - FloatArrayList scores = pair.getSecond(); - - //Do we need subsampling to avoid having too many data points? - int subsamplingFreq = candidateScoreVsIterSubsampleFreq.computeIfAbsent(idx, k -> 1); - if(iteration / subsamplingFreq > MAX_SCORE_VS_ITER_PTS){ - //Double subsampling frequency and re-parse data - subsamplingFreq *= 2; - candidateScoreVsIterSubsampleFreq.put(idx, subsamplingFreq); - - IntArrayList newIter = new IntArrayList(); - FloatArrayList newScores = new FloatArrayList(); - for( int i=0; i(iter, scores)); - } - - if(iteration % subsamplingFreq == 0) { - iter.add(iteration); - scores.add((float) score); - } - - - int[] iters = iter.toIntArray(); - float[] fScores = new float[iters.length]; - for( int i=0; i T fromJson(String json, Class type){ - try{ - return getMapper().readValue(json, type); - } catch (IOException e) { - throw new RuntimeException(e); - } - } - - public static ObjectMapper getInstance(){ - return MAPPER; - } - -} diff --git a/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/misc/UIUtils.java b/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/misc/UIUtils.java deleted file mode 100644 index 8ea969c82..000000000 --- a/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/misc/UIUtils.java +++ /dev/null @@ -1,112 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.ui.misc; - -import org.joda.time.Period; -import org.joda.time.PeriodType; -import org.joda.time.format.PeriodFormatter; -import org.joda.time.format.PeriodFormatterBuilder; - -/** - * Created by Alex on 20/07/2017. - */ -public class UIUtils { - - /** - * Convert the "messy" min/max values on a dataset to something clean. For example, 0.895732 becomes 1.0 - * - * @param max Maximum data point value - * @param min Minimum data point value - * @param nTick Number of tick marks desired on chart (good setting: 5) - * @return double[] of length 2 - with new minimum and maximum - */ - public static double[] graphNiceRange(double max, double min, int nTick){ - if(max == min || !Double.isFinite(max)){ - if(max == 0.0 || !Double.isFinite(max)){ - return new double[]{0.0, 1.0}; - } - - return graphNiceRange(1.5 * max, 0.5 * max, nTick); - } - - double range = niceNum(max-min, false); - double d = niceNum(range / (nTick-1), true ); - double graphMin = Math.floor(min/d)*d; - double graphMax = Math.ceil(max/d)*d; - - - return new double[]{graphMin, graphMax}; - } - - public static double niceNum(double x, boolean round){ - double exp = Math.floor(Math.log10(x)); - double f = x / Math.pow(10, exp); - - double nf; - if(round){ - if(f < 1.5 ){ - nf = 1; - } else if( f < 3){ - nf = 2; - } else if( f < 7){ - nf = 5; - } else { - nf = 10; - } - } else { - if(f <= 1 ){ - nf = 1; - } else if( f <= 2){ - nf = 2; - } else if( f <= 5){ - nf = 5; - } else { - nf = 10; - } - } - return nf * Math.pow(10, exp); - } - - /** - * Format the duration in milliseconds to a human readable String, with "yr", "days", "hr" etc prefixes - * - * - * @param durationMs Duration in milliseconds - * @return Human readable string - */ - public static String formatDuration(long durationMs){ - Period period = Period.seconds((int)(durationMs/1000L)); - Period p2 = period.normalizedStandard(PeriodType.yearMonthDayTime()); - - PeriodFormatter formatter = new PeriodFormatterBuilder() - .appendYears() - .appendSuffix(" yr ") - .appendMonths() - .appendSuffix(" months ") - .appendDays() - .appendSuffix(" days ") - .appendHours() - .appendSuffix(" hr ") - .appendMinutes() - .appendSuffix(" min ") - .appendSeconds() - .appendSuffix(" sec") - .toFormatter(); - - return formatter.print(p2); - } -} diff --git a/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/module/ArbiterModule.java b/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/module/ArbiterModule.java deleted file mode 100644 index 1ee0ce729..000000000 --- a/arbiter/arbiter-ui/src/main/java/org/deeplearning4j/arbiter/ui/module/ArbiterModule.java +++ /dev/null @@ -1,943 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * Copyright (c) 2019 Konduit K.K. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.ui.module; - -import com.fasterxml.jackson.core.JsonProcessingException; -import io.netty.handler.codec.http.HttpResponseStatus; -import io.vertx.ext.web.RoutingContext; -import lombok.extern.slf4j.Slf4j; -import org.deeplearning4j.core.storage.Persistable; -import org.deeplearning4j.core.storage.StatsStorage; -import org.deeplearning4j.core.storage.StatsStorageEvent; -import org.deeplearning4j.core.storage.StatsStorageListener; -import org.deeplearning4j.arbiter.BaseNetworkSpace; -import org.deeplearning4j.arbiter.layers.LayerSpace; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.api.termination.TerminationCondition; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; -import org.deeplearning4j.arbiter.optimize.runner.CandidateStatus; -import org.deeplearning4j.arbiter.ui.UpdateStatus; -import org.deeplearning4j.arbiter.ui.data.GlobalConfigPersistable; -import org.deeplearning4j.arbiter.ui.data.ModelInfoPersistable; -import org.deeplearning4j.arbiter.ui.misc.UIUtils; -import org.deeplearning4j.arbiter.util.ObjectUtils; -import org.deeplearning4j.nn.conf.serde.JsonMappers; -import org.deeplearning4j.ui.VertxUIServer; -import org.deeplearning4j.ui.api.Component; -import org.deeplearning4j.ui.api.*; -import org.deeplearning4j.ui.components.chart.ChartLine; -import org.deeplearning4j.ui.components.chart.ChartScatter; -import org.deeplearning4j.ui.components.chart.style.StyleChart; -import org.deeplearning4j.ui.components.component.ComponentDiv; -import org.deeplearning4j.ui.components.component.style.StyleDiv; -import org.deeplearning4j.ui.components.table.ComponentTable; -import org.deeplearning4j.ui.components.table.style.StyleTable; -import org.deeplearning4j.ui.components.text.ComponentText; -import org.deeplearning4j.ui.components.text.style.StyleText; -import org.deeplearning4j.ui.i18n.I18NResource; -import org.joda.time.format.DateTimeFormat; -import org.joda.time.format.DateTimeFormatter; -import org.nd4j.common.function.Function; -import org.nd4j.common.primitives.Pair; - -import java.awt.*; -import java.text.DecimalFormat; -import java.util.List; -import java.util.*; -import java.util.concurrent.atomic.AtomicBoolean; - -/** - * A Deeplearning4j {@link UIModule}, for integration with DL4J's user interface - * - * @author Alex Black - */ -@Slf4j -public class ArbiterModule implements UIModule { - - private static final DecimalFormat DECIMAL_FORMAT_2DP = new DecimalFormat("#.00"); - private static final DateTimeFormatter TIME_FORMATTER = DateTimeFormat.forPattern("YYYY-MM-dd HH:mm ZZ"); - public static final String ARBITER_UI_TYPE_ID = "ArbiterUI"; - - private AtomicBoolean loggedArbiterAddress = new AtomicBoolean(false); - private Map knownSessionIDs = Collections.synchronizedMap(new LinkedHashMap<>()); - private String currentSessionID; - - private Map lastUpdateForSession = Collections.synchronizedMap(new HashMap<>()); - - //Styles for UI: - private static final StyleTable STYLE_TABLE = new StyleTable.Builder() - .width(100, LengthUnit.Percent) - .backgroundColor(Color.WHITE) - .borderWidth(1) - .columnWidths(LengthUnit.Percent, 30, 70) - .build(); - - private static final StyleTable STYLE_TABLE3_25_25_50 = new StyleTable.Builder() - .width(100, LengthUnit.Percent) - .backgroundColor(Color.WHITE) - .borderWidth(1) - .columnWidths(LengthUnit.Percent, 25, 25, 50) - .build(); - - private static final StyleDiv STYLE_DIV_WIDTH_100_PC = new StyleDiv.Builder() - .width(100, LengthUnit.Percent) - .build(); - - private static final ComponentDiv DIV_SPACER_20PX = new ComponentDiv(new StyleDiv.Builder() - .width(100,LengthUnit.Percent) - .height(20, LengthUnit.Px).build()); - - private static final ComponentDiv DIV_SPACER_60PX = new ComponentDiv(new StyleDiv.Builder() - .width(100,LengthUnit.Percent) - .height(60, LengthUnit.Px).build()); - - private static final StyleChart STYLE_CHART_560_320 = new StyleChart.Builder() - .width(560, LengthUnit.Px) - .height(320, LengthUnit.Px) - .build(); - - private static final StyleChart STYLE_CHART_800_400 = new StyleChart.Builder() - .width(800, LengthUnit.Px) - .height(400, LengthUnit.Px) - .build(); - - - private StyleText STYLE_TEXT_SZ12 = new StyleText.Builder() - .fontSize(12) - .build(); - - //Set whitespacePre(true) to avoid losing new lines, tabs, multiple spaces etc - private StyleText STYLE_TEXT_SZ10_WHITESPACE_PRE = new StyleText.Builder() - .fontSize(10) - .whitespacePre(true) - .build(); - - - @Override - public List getCallbackTypeIDs() { - return Collections.singletonList(ARBITER_UI_TYPE_ID); - } - - @Override - public List getRoutes() { - boolean multiSession = VertxUIServer.getMultiSession().get(); - List r = new ArrayList<>(); - r.add(new Route("/arbiter/multisession", HttpMethod.GET, - (path, rc) -> rc.response().end(multiSession ? "true" : "false"))); - if (multiSession) { - r.add(new Route("/arbiter", HttpMethod.GET, (path, rc) -> this.listSessions(rc))); - r.add(new Route("/arbiter/:sessionId", HttpMethod.GET, (path, rc) -> { - if (knownSessionIDs.containsKey(path.get(0))) { - rc.response() - .putHeader("content-type", "text/html; charset=utf-8") - .sendFile("templates/ArbiterUI.html"); - } else { - sessionNotFound(path.get(0), rc.request().path(), rc); - } - })); - - r.add(new Route("/arbiter/:sessionId/lastUpdate", HttpMethod.GET, (path, rc) -> { - if (knownSessionIDs.containsKey(path.get(0))) { - this.getLastUpdateTime(path.get(0), rc); - } else { - sessionNotFound(path.get(0), rc.request().path(), rc); - } - })); - r.add(new Route("/arbiter/:sessionId/candidateInfo/:id", HttpMethod.GET, (path, rc) -> { - if (knownSessionIDs.containsKey(path.get(0))) { - this.getCandidateInfo(path.get(0), path.get(1), rc); - } else { - sessionNotFound(path.get(0), rc.request().path(), rc); - } - })); - r.add(new Route("/arbiter/:sessionId/config", HttpMethod.GET, (path, rc) -> { - if (knownSessionIDs.containsKey(path.get(0))) { - this.getOptimizationConfig(path.get(0), rc); - } else { - sessionNotFound(path.get(0), rc.request().path(), rc); - } - })); - r.add(new Route("/arbiter/:sessionId/results", HttpMethod.GET, (path, rc) -> { - if (knownSessionIDs.containsKey(path.get(0))) { - this.getSummaryResults(path.get(0), rc); - } else { - sessionNotFound(path.get(0), rc.request().path(), rc); - } - })); - r.add(new Route("/arbiter/:sessionId/summary", HttpMethod.GET, (path, rc) -> { - if (knownSessionIDs.containsKey(path.get(0))) { - this.getSummaryStatus(path.get(0), rc); - } else { - sessionNotFound(path.get(0), rc.request().path(), rc); - } - })); - } else { - r.add(new Route("/arbiter", HttpMethod.GET, (path, rc) -> rc.response() - .putHeader("content-type", "text/html; charset=utf-8") - .sendFile("templates/ArbiterUI.html"))); - r.add(new Route("/arbiter/lastUpdate", HttpMethod.GET, (path, rc) -> this.getLastUpdateTime(null, rc))); - r.add(new Route("/arbiter/candidateInfo/:id", HttpMethod.GET, - (path, rc) -> this.getCandidateInfo(null, path.get(0), rc))); - r.add(new Route("/arbiter/config", HttpMethod.GET, (path, rc) -> this.getOptimizationConfig(null, rc))); - r.add(new Route("/arbiter/results", HttpMethod.GET, (path, rc) -> this.getSummaryResults(null, rc))); - r.add(new Route("/arbiter/summary", HttpMethod.GET, (path, rc) -> this.getSummaryStatus(null, rc))); - - r.add(new Route("/arbiter/sessions/current", HttpMethod.GET, (path, rc) -> this.currentSession(rc))); - r.add(new Route("/arbiter/sessions/set/:to", HttpMethod.GET, - (path, rc) -> this.setSession(path.get(0), rc))); - } - // common for single- and multi-session mode - r.add(new Route("/arbiter/sessions/all", HttpMethod.GET, (path, rc) -> this.sessionInfo(rc))); - - return r; - } - - - /** - * Load StatsStorage via provider, or return "not found" - * - * @param sessionId session ID to look fo with provider - * @param targetPath one of overview / model / system, or null - * @param rc routing context - */ - private void sessionNotFound(String sessionId, String targetPath, RoutingContext rc) { - Function loader = VertxUIServer.getInstance().getStatsStorageLoader(); - if (loader != null && loader.apply(sessionId)) { - if (targetPath != null) { - rc.reroute(targetPath); - } else { - rc.response().end(); - } - } else { - rc.response().setStatusCode(HttpResponseStatus.NOT_FOUND.code()) - .end("Unknown session ID: " + sessionId); - } - } - - - /** - * List optimization sessions. Returns a HTML list of arbiter sessions - */ - private synchronized void listSessions(RoutingContext rc) { - StringBuilder sb = new StringBuilder("\n" + - "\n" + - "\n" + - " \n" + - " Optimization sessions - DL4J Arbiter UI\n" + - " \n" + - "\n" + - " \n" + - "

DL4J Arbiter UI

\n" + - "

UI server is in multi-session mode." + - " To visualize an optimization session, please select one from the following list.

\n" + - "

List of attached optimization sessions

\n"); - if (!knownSessionIDs.isEmpty()) { - sb.append(" "); - } else { - sb.append("No optimization session attached."); - } - - sb.append(" \n" + - "\n"); - - rc.response() - .putHeader("content-type", "text/html; charset=utf-8") - .end(sb.toString()); - } - - @Override - public void reportStorageEvents(Collection events) { - boolean attachedArbiter = false; - for (StatsStorageEvent sse : events) { - if (ARBITER_UI_TYPE_ID.equals(sse.getTypeID())) { - if (sse.getEventType() == StatsStorageListener.EventType.PostStaticInfo) { - knownSessionIDs.put(sse.getSessionID(), sse.getStatsStorage()); - } - - Long lastUpdate = lastUpdateForSession.get(sse.getSessionID()); - if (lastUpdate == null) { - lastUpdateForSession.put(sse.getSessionID(), sse.getTimestamp()); - } else if (sse.getTimestamp() > lastUpdate) { - lastUpdateForSession.put(sse.getSessionID(), sse.getTimestamp()); //Should be thread safe - read only elsewhere - } - attachedArbiter = true; - } - } - - if(currentSessionID == null){ - getDefaultSession(); - } - - if(attachedArbiter && !loggedArbiterAddress.getAndSet(true)){ - String address = UIServer.getInstance().getAddress(); - address += "/arbiter"; - log.info("DL4J Arbiter Hyperparameter Optimization UI: {}", address); - } - } - - @Override - public synchronized void onAttach(StatsStorage statsStorage) { - for (String sessionID : statsStorage.listSessionIDs()) { - for (String typeID : statsStorage.listTypeIDsForSession(sessionID)) { - if (!ARBITER_UI_TYPE_ID.equals(typeID)) - continue; - knownSessionIDs.put(sessionID, statsStorage); - } - } - - if (currentSessionID == null) - getDefaultSession(); - } - - private void currentSession(RoutingContext rc) { - String sid = currentSessionID == null ? "" : currentSessionID; - rc.response() - .putHeader("content-type", "application/json") - .end(asJson(sid)); - } - - private void sessionInfo(RoutingContext rc) { - rc.response() - .putHeader("content-type", "application/json") - .end(asJson(knownSessionIDs.keySet())); - } - - private void setSession(String newSessionID, RoutingContext rc) { - log.debug("Arbiter UI: Set to session {}", newSessionID); - - if (knownSessionIDs.containsKey(newSessionID)) { - currentSessionID = newSessionID; - rc.response().end(); - } else { - rc.response().setStatusCode(HttpResponseStatus.BAD_REQUEST.code()).end("Unknown session ID: " + newSessionID); - } - } - - private void getDefaultSession() { - if (currentSessionID != null) - return; - - long mostRecentTime = Long.MIN_VALUE; - String sessionID = null; - for (Map.Entry entry : knownSessionIDs.entrySet()) { - List staticInfos = entry.getValue().getAllStaticInfos(entry.getKey(), ARBITER_UI_TYPE_ID); - if (staticInfos == null || staticInfos.size() == 0) - continue; - Persistable p = staticInfos.get(0); - long thisTime = p.getTimeStamp(); - if (thisTime > mostRecentTime) { - mostRecentTime = thisTime; - sessionID = entry.getKey(); - } - } - - if (sessionID != null) { - currentSessionID = sessionID; - } - } - - @Override - public void onDetach(StatsStorage statsStorage) { - for (String s : knownSessionIDs.keySet()) { - if (knownSessionIDs.get(s) == statsStorage) { - knownSessionIDs.remove(s); - } - } - } - - @Override - public List getInternationalizationResources() { - return Collections.emptyList(); - } - - /** - * Return the last update time for the page - * @param sessionId session ID (optional, for multi-session mode) - * @param rc routing context - */ - private void getLastUpdateTime(String sessionId, RoutingContext rc){ - if (sessionId == null) { - sessionId = currentSessionID; - } - StatsStorage ss = knownSessionIDs.get(sessionId); - List latestUpdates = ss.getLatestUpdateAllWorkers(sessionId, ARBITER_UI_TYPE_ID); - long t = 0; - if (latestUpdates.isEmpty()) { - t = System.currentTimeMillis(); - } else { - for (Persistable update : latestUpdates) { - if (update.getTimeStamp() > t) { - t = update.getTimeStamp(); - } - } - } - UpdateStatus us = new UpdateStatus(t, t, t); - - rc.response().putHeader("content-type", "application/json").end(asJson(us)); - } - - private String asJson(Object o){ - try{ - return JsonMappers.getMapper().writeValueAsString(o); - } catch (JsonProcessingException e){ - throw new RuntimeException("Error converting object to JSON", e); - } - } - - /** - * Get the info for a specific candidate - last section in the UI - * @param sessionId session ID (optional, for multi-session mode) - * @param candidateId ID for the candidate - * @param rc routing context - */ - private void getCandidateInfo(String sessionId, String candidateId, RoutingContext rc){ - if (sessionId == null) { - sessionId = currentSessionID; - } - StatsStorage ss = knownSessionIDs.get(sessionId); - if(ss == null){ - log.debug("getModelLastUpdateTimes(): Session ID is unknown: {}", sessionId); - rc.response().end(); - return; - } - - GlobalConfigPersistable gcp = (GlobalConfigPersistable)ss - .getStaticInfo(sessionId, ARBITER_UI_TYPE_ID, GlobalConfigPersistable.GLOBAL_WORKER_ID); - OptimizationConfiguration oc = gcp.getOptimizationConfiguration(); - - Persistable p = ss.getLatestUpdate(sessionId, ARBITER_UI_TYPE_ID, candidateId); - if(p == null){ - String title = "No results found for model " + candidateId + "."; - ComponentText ct = new ComponentText.Builder(title,STYLE_TEXT_SZ12).build(); - rc.response() - .putHeader("content-type", "application/json") - .end(asJson(ct)); - return; - } - - ModelInfoPersistable mip = (ModelInfoPersistable)p; - - //First: static info - // Hyperparameter configuration/settings - // Number of parameters - // Maybe memory info in the future? - - //Second: dynamic info - //Runtime - // Performance stats (total minibatches, total time, - // Score vs. time - - List components = new ArrayList<>(); - - //First table: mix of static + dynamic in a table - long runtimeDurationMs = mip.getLastUpdateTime() - mip.getTimeStamp(); - double avgMinibatchesPerSec = mip.getTotalNumUpdates() / (runtimeDurationMs/1000.0); - String avgMinibatchesPerSecStr = DECIMAL_FORMAT_2DP.format(avgMinibatchesPerSec); - String runtimeStr = UIUtils.formatDuration(runtimeDurationMs); - - if(mip.getStatus() == CandidateStatus.Failed){ - runtimeStr = ""; - avgMinibatchesPerSecStr = ""; - } - - String[][] table = new String[][]{ - {"Model Index", String.valueOf(mip.getModelIdx())}, - {"Status", mip.getStatus().toString()}, - {"Model Score", mip.getScore() == null ? "" : String.valueOf(mip.getScore())}, - {"Created", TIME_FORMATTER.print(mip.getTimeStamp())}, - {"Runtime", runtimeStr}, - {"Total Number of Model Updates", String.valueOf(mip.getTotalNumUpdates())}, - {"Average # Updates / Sec", avgMinibatchesPerSecStr}, - {"Number of Parameters", String.valueOf(mip.getNumParameters())}, - {"Number of Layers", String.valueOf(mip.getNumLayers())} - }; - - ComponentTable cTable = new ComponentTable.Builder(STYLE_TABLE) - .content(table) - .header("Model Information", "") - .build(); - components.add(cTable); - - - //Second: parameter space values, in multiple tables - double[] paramSpaceValues = mip.getParamSpaceValues(); - if(paramSpaceValues != null){ - BaseNetworkSpace bns = (BaseNetworkSpace)oc.getCandidateGenerator().getParameterSpace(); - Map m = bns.getNestedSpaces(); - - String[][] hSpaceTable = new String[m.size()][3]; - int i=0; - for(Map.Entry e : m.entrySet()){ - hSpaceTable[i][0] = e.getKey(); - Object currCandidateValue = e.getValue().getValue(paramSpaceValues); - hSpaceTable[i][1] = ObjectUtils.valueToString(currCandidateValue); - hSpaceTable[i][2] = e.getValue().toString(); - i++; - } - - String[] hSpaceTableHeader = new String[]{"Hyperparameter", "Model Value", "Hyperparameter Space"}; - - ComponentTable ct2 = new ComponentTable.Builder(STYLE_TABLE3_25_25_50) - .content(hSpaceTable) - .header(hSpaceTableHeader) - .build(); - - - String title = "Global Network Configuration"; - components.add(DIV_SPACER_20PX); - components.add(new ComponentText.Builder(title, STYLE_TEXT_SZ12).build()); - components.add(ct2); - - List layerConfs = bns.getLayerSpaces(); - - for(BaseNetworkSpace.LayerConf l : layerConfs){ - LayerSpace ls = l.getLayerSpace(); - Map lpsm = ls.getNestedSpaces(); - - String[][] t = new String[lpsm.size()][3]; - i=0; - for(Map.Entry e : lpsm.entrySet()){ - t[i][0] = e.getKey(); - Object currCandidateValue = e.getValue().getValue(paramSpaceValues); - t[i][1] = ObjectUtils.valueToString(currCandidateValue); - t[i][2] = e.getValue().toString(); - i++; - } - - ComponentTable ct3 = new ComponentTable.Builder(STYLE_TABLE3_25_25_50) - .content(t) - .header(hSpaceTableHeader) - .build(); - - title = "Layer Space: " + ls.getClass().getSimpleName() + ", Name: " + l.getLayerName(); - - components.add(DIV_SPACER_20PX); - components.add(new ComponentText.Builder(title, STYLE_TEXT_SZ12).build()); - components.add(ct3); - } - } - - - //Third: Score vs. time chart - int[] iters = mip.getIter(); - float[] scores = mip.getScoreVsIter(); - - if(iters != null) { - double[] si = new double[iters.length]; - double[] scoresD = new double[iters.length]; - - double minScore = Double.MAX_VALUE; - double maxScore = -Double.MAX_VALUE; - for( int i=0; i components = new ArrayList<>(); - - GlobalConfigPersistable gcp = (GlobalConfigPersistable)p; - OptimizationConfiguration oc = gcp.getOptimizationConfiguration(); - - //Report optimization settings/configuration. - String[] tableHeader = {"Configuration", "Value"}; - String [] dataSourceOrProvider; - if (oc.getDataProvider() != null) { - dataSourceOrProvider = new String[] {"Data Provider", oc.getDataProvider().toString()}; - } - else { - dataSourceOrProvider = new String[] {"Data Source", oc.getDataSource().getCanonicalName()}; - } - String[][] table = new String[][]{ - {"Candidate Generator", oc.getCandidateGenerator().getClass().getSimpleName()}, - dataSourceOrProvider, - {"Score Function", oc.getScoreFunction().toString()}, - {"Result Saver", oc.getResultSaver().toString()}, - }; - - ComponentTable ct = new ComponentTable.Builder(STYLE_TABLE) - .content(table) - .header(tableHeader) - .build(); - components.add(ct); - - - String title = "Global Network Configuration"; - components.add(DIV_SPACER_20PX); - components.add(new ComponentText.Builder(title, STYLE_TEXT_SZ12).build()); - BaseNetworkSpace ps = (BaseNetworkSpace)oc.getCandidateGenerator().getParameterSpace(); - Map m = ps.getNestedSpaces(); - - String[][] hSpaceTable = new String[m.size()][2]; - int i=0; - for(Map.Entry e : m.entrySet()){ - hSpaceTable[i][0] = e.getKey(); - hSpaceTable[i][1] = e.getValue().toString(); - i++; - } - - components.add(DIV_SPACER_20PX); - String[] hSpaceTableHeader = new String[]{"Hyperparameter", "Hyperparameter Configuration"}; - - ComponentTable ct2 = new ComponentTable.Builder(STYLE_TABLE) - .content(hSpaceTable) - .header(hSpaceTableHeader) - .build(); - components.add(ct2); - - //Configuration for each layer: - List layerConfs = ps.getLayerSpaces(); - for(BaseNetworkSpace.LayerConf l : layerConfs){ - LayerSpace ls = l.getLayerSpace(); - Map lpsm = ls.getNestedSpaces(); - - String[][] t = new String[lpsm.size()][2]; - i=0; - for(Map.Entry e : lpsm.entrySet()){ - t[i][0] = e.getKey(); - t[i][1] = e.getValue().toString(); - i++; - } - - ComponentTable ct3 = new ComponentTable.Builder(STYLE_TABLE) - .content(t) - .header(hSpaceTableHeader) - .build(); - - title = "Layer Space: " + ls.getClass().getSimpleName() + ", Name: " + l.getLayerName(); - - components.add(DIV_SPACER_20PX); - components.add(new ComponentText.Builder(title, STYLE_TEXT_SZ12).build()); - components.add(ct3); - } - - ComponentDiv cd = new ComponentDiv(STYLE_DIV_WIDTH_100_PC, components); - - rc.response().putHeader("content-type", "application/json").end(asJson(cd)); - } - - /** - * Get candidates summary results list - third section on the page: Results table - * @param sessionId session ID (optional, for multi-session mode) - * @param rc routing context - */ - private void getSummaryResults(String sessionId, RoutingContext rc){ - if (sessionId == null) { - sessionId = currentSessionID; - } - StatsStorage ss = knownSessionIDs.get(sessionId); - if(ss == null){ - log.debug("getSummaryResults(): Session ID is unknown: {}", sessionId); - rc.response().end(); - return; - } - - List allModelInfoTemp = new ArrayList<>(ss.getLatestUpdateAllWorkers(sessionId, ARBITER_UI_TYPE_ID)); - List table = new ArrayList<>(); - for(Persistable per : allModelInfoTemp){ - ModelInfoPersistable mip = (ModelInfoPersistable)per; - String score = (mip.getScore() == null ? "" : mip.getScore().toString()); - table.add(new String[]{mip.getModelIdx().toString(), score, mip.getStatus().toString()}); - } - - rc.response().putHeader("content-type", "application/json").end(asJson(table)); - } - - /** - * Get summary status information: first section in the page - * @param sessionId session ID (optional, for multi-session mode) - * @param rc routing context - */ - private void getSummaryStatus(String sessionId, RoutingContext rc){ - if (sessionId == null) { - sessionId = currentSessionID; - } - StatsStorage ss = knownSessionIDs.get(sessionId); - if(ss == null){ - log.debug("getOptimizationConfig(): Session ID is unknown: {}", sessionId); - rc.response().end(); - return; - } - - Persistable p = ss.getStaticInfo(sessionId, ARBITER_UI_TYPE_ID, GlobalConfigPersistable.GLOBAL_WORKER_ID); - - if(p == null){ - log.info("No static info"); - rc.response().end(); - return; - } - - GlobalConfigPersistable gcp = (GlobalConfigPersistable)p; - OptimizationConfiguration oc = gcp.getOptimizationConfiguration(); - long execStartTime = oc.getExecutionStartTime(); - - - - //Charts: - //Best model score vs. time - //All candidate scores (scatter plot vs. time) - - //How to get this? query all model infos... - - List allModelInfoTemp = new ArrayList<>(ss.getLatestUpdateAllWorkers(sessionId, ARBITER_UI_TYPE_ID)); - List allModelInfo = new ArrayList<>(); - for(Persistable per : allModelInfoTemp){ - ModelInfoPersistable mip = (ModelInfoPersistable)per; - if(mip.getStatus() == CandidateStatus.Complete && mip.getScore() != null && Double.isFinite(mip.getScore())){ - allModelInfo.add(mip); - } - } - - allModelInfo.sort(Comparator.comparingLong(Persistable::getTimeStamp)); - - Pair, ModelInfoPersistable> chartsAndBest = getSummaryChartsAndBest(allModelInfo, oc.getScoreFunction().minimize(), execStartTime ); - - //First: table - number completed, queued, running, failed, total - //Best model index, score, and time - //Total runtime - //Termination conditions - List components = new ArrayList<>(); - - - - List tcs = oc.getTerminationConditions(); - - //TODO: I18N - - long bestTime; - Double bestScore = null; - String bestModelString = null; - if(chartsAndBest.getSecond() != null){ - bestTime = chartsAndBest.getSecond().getTimeStamp(); - bestScore = chartsAndBest.getSecond().getScore(); - String sinceBest = UIUtils.formatDuration(System.currentTimeMillis() - bestTime); - - bestModelString = "Model " + chartsAndBest.getSecond().getModelIdx() + ", Found at " + - TIME_FORMATTER.print(bestTime) + " (" + sinceBest + " ago)"; - } - - String execStartTimeStr = ""; - String execTotalRuntimeStr = ""; - if(execStartTime > 0){ - execStartTimeStr = TIME_FORMATTER.print(execStartTime); - // allModelInfo is sorted by Persistable::getTimeStamp - long lastCompleteTime = execStartTime; - if (!allModelInfo.isEmpty()) { - lastCompleteTime = allModelInfo.get(allModelInfo.size() - 1).getTimeStamp(); - } - execTotalRuntimeStr = UIUtils.formatDuration(lastCompleteTime - execStartTime); - } - - - String[][] table = new String[][]{ - {"Models Completed", String.valueOf(gcp.getCandidatesCompleted())}, - {"Models Queued/Running", String.valueOf(gcp.getCandidatesQueued())}, - {"Models Failed", String.valueOf(gcp.getCandidatesFailed())}, - {"Models Total", String.valueOf(gcp.getCandidatesTotal())}, - {"Best Score", (bestScore != null ? String.valueOf(bestScore) : "")}, - {"Best Scoring Model", bestModelString != null ? bestModelString : ""}, - {"Optimization Runner", gcp.getOptimizationRunner()}, - {"Execution Start Time", execStartTimeStr}, - {"Total Runtime", execTotalRuntimeStr} - }; - - - - ComponentTable ct = new ComponentTable.Builder(STYLE_TABLE) - .content(table) - .header("Status", "") - .build(); - - components.add(ct); - - String[][] tcTable = new String[tcs.size()][2]; - for( int i=0; i,ModelInfoPersistable> getSummaryChartsAndBest(List allModelInfo, - boolean minimize, long execStartTime){ - List bestX = new ArrayList<>(); - List bestY = new ArrayList<>(); - - double[] allX = new double[allModelInfo.size()]; - double[] allY = new double[allModelInfo.size()]; - - double bestScore = (minimize ? Double.MAX_VALUE : -Double.MAX_VALUE); - double worstScore = (minimize ? -Double.MAX_VALUE : Double.MAX_VALUE); - double lastTime = -1L; - ModelInfoPersistable bestModel = null; - for(int i=0; i bestScore) || (minimize && currScore < bestScore)){ - bestX.add(t); - bestY.add(bestScore); - bestX.add(t); //TODO non-real time rendering support... - bestY.add(currScore); - - bestScore = currScore; - bestModel = mip; - } - - if((!minimize && currScore < worstScore) || (minimize && currScore > worstScore)){ - worstScore = currScore; - } - - if(t > lastTime){ - lastTime = t; - } - } - - - double[] scatterGraphMinMax = UIUtils.graphNiceRange(Math.max(bestScore, worstScore), Math.min(bestScore, worstScore), 5); - double[] lineGraphMinMax = UIUtils.graphNiceRange( - bestY.stream().mapToDouble(s -> s).max().orElse(0),bestY.stream().mapToDouble(s -> s).min().orElse(0), 5 - ); - - if(bestX.size() > 0) { - bestX.add(lastTime); - bestY.add(bestY.get(bestY.size() - 1)); - } - - - double[] bestXd = new double[bestX.size()]; - double[] bestYd = new double[bestXd.length]; - for( int i=0; i components = new ArrayList<>(2); - - ChartLine cl = new ChartLine.Builder("Best Model Score vs. Time (Minutes)", STYLE_CHART_560_320) - .addSeries("Best Score vs. Time", bestXd, bestYd) - .setYMin(lineGraphMinMax[0]) - .setYMax(lineGraphMinMax[1]) - .build(); - components.add(cl); - - ChartScatter cs = new ChartScatter.Builder("All Candidate Scores vs. Time (Minutes)", STYLE_CHART_560_320) - .addSeries("Candidates", allX, allY) - .setYMin(scatterGraphMinMax[0]) - .setYMax(scatterGraphMinMax[1]) - .build(); - - components.add(cs); - - return new Pair<>(components, bestModel); - } -} diff --git a/arbiter/arbiter-ui/src/main/resources/META-INF/services/org.deeplearning4j.ui.api.UIModule b/arbiter/arbiter-ui/src/main/resources/META-INF/services/org.deeplearning4j.ui.api.UIModule deleted file mode 100644 index 083fd24c9..000000000 --- a/arbiter/arbiter-ui/src/main/resources/META-INF/services/org.deeplearning4j.ui.api.UIModule +++ /dev/null @@ -1,17 +0,0 @@ -################################################################################ -# Copyright (c) 2015-2018 Skymind, Inc. -# -# This program and the accompanying materials are made available under the -# terms of the Apache License, Version 2.0 which is available at -# https://www.apache.org/licenses/LICENSE-2.0. -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT -# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. -# -# SPDX-License-Identifier: Apache-2.0 -################################################################################ - -org.deeplearning4j.arbiter.ui.module.ArbiterModule \ No newline at end of file diff --git a/arbiter/arbiter-ui/src/main/resources/deeplearning4jUiAssets/dl4j-ui.js b/arbiter/arbiter-ui/src/main/resources/deeplearning4jUiAssets/dl4j-ui.js deleted file mode 100644 index 4c99517d0..000000000 --- a/arbiter/arbiter-ui/src/main/resources/deeplearning4jUiAssets/dl4j-ui.js +++ /dev/null @@ -1,1319 +0,0 @@ -var __extends = (this && this.__extends) || function (d, b) { - for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; - function __() { this.constructor = d; } - d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); -}; -var Style = (function () { - function Style(jsonObj) { - var _this = this; - this.getWidth = function () { return _this.width; }; - this.getHeight = function () { return _this.height; }; - this.getWidthUnit = function () { return _this.widthUnit; }; - this.getHeightUnit = function () { return _this.heightUnit; }; - this.getMarginTop = function () { return _this.marginTop; }; - this.getMarginBottom = function () { return _this.marginBottom; }; - this.getMarginLeft = function () { return _this.marginLeft; }; - this.getMarginRight = function () { return _this.marginRight; }; - this.getBackgroundColor = function () { return _this.backgroundColor; }; - this.width = jsonObj['width']; - this.height = jsonObj['height']; - this.widthUnit = TSUtils.normalizeLengthUnit(jsonObj['widthUnit']); - this.heightUnit = TSUtils.normalizeLengthUnit(jsonObj['heightUnit']); - this.marginTop = jsonObj['marginTop']; - this.marginBottom = jsonObj['marginBottom']; - this.marginLeft = jsonObj['marginLeft']; - this.marginRight = jsonObj['marginRight']; - this.backgroundColor = jsonObj['backgroundColor']; - } - Style.getMargins = function (s) { - var mTop = (s ? s.getMarginTop() : 0); - var mBottom = (s ? s.getMarginBottom() : 0); - var mLeft = (s ? s.getMarginLeft() : 0); - var mRight = (s ? s.getMarginRight() : 0); - return { top: mTop, - right: mRight, - bottom: mBottom, - left: mLeft, - widthExMargins: s.getWidth() - mLeft - mRight, - heightExMargins: s.getHeight() - mTop - mBottom }; - }; - return Style; -}()); -var ComponentType; -(function (ComponentType) { - ComponentType[ComponentType["ComponentText"] = 0] = "ComponentText"; - ComponentType[ComponentType["ComponentTable"] = 1] = "ComponentTable"; - ComponentType[ComponentType["ComponentDiv"] = 2] = "ComponentDiv"; - ComponentType[ComponentType["ChartHistogram"] = 3] = "ChartHistogram"; - ComponentType[ComponentType["ChartHorizontalBar"] = 4] = "ChartHorizontalBar"; - ComponentType[ComponentType["ChartLine"] = 5] = "ChartLine"; - ComponentType[ComponentType["ChartScatter"] = 6] = "ChartScatter"; - ComponentType[ComponentType["ChartStackedArea"] = 7] = "ChartStackedArea"; - ComponentType[ComponentType["ChartTimeline"] = 8] = "ChartTimeline"; - ComponentType[ComponentType["DecoratorAccordion"] = 9] = "DecoratorAccordion"; -})(ComponentType || (ComponentType = {})); -var Component = (function () { - function Component(componentType) { - this.componentType = componentType; - } - Component.prototype.getComponentType = function () { - return this.componentType; - }; - Component.getComponent = function (jsonStr) { - var json = JSON.parse(jsonStr); - var key; - if (json["componentType"]) - key = json["componentType"]; - else - key = Object.keys(json)[0]; - switch (key) { - case ComponentType[ComponentType.ComponentText]: - return new ComponentText(jsonStr); - case ComponentType[ComponentType.ComponentTable]: - return new ComponentTable(jsonStr); - case ComponentType[ComponentType.ChartHistogram]: - return new ChartHistogram(jsonStr); - case ComponentType[ComponentType.ChartHorizontalBar]: - throw new Error("Horizontal bar chart: not yet implemented"); - case ComponentType[ComponentType.ChartLine]: - return new ChartLine(jsonStr); - case ComponentType[ComponentType.ChartScatter]: - return new ChartScatter(jsonStr); - case ComponentType[ComponentType.ChartStackedArea]: - return new ChartStackedArea(jsonStr); - case ComponentType[ComponentType.ChartTimeline]: - return new ChartTimeline(jsonStr); - case ComponentType[ComponentType.DecoratorAccordion]: - return new DecoratorAccordion(jsonStr); - case ComponentType[ComponentType.ComponentDiv]: - return new ComponentDiv(jsonStr); - default: - throw new Error("Unknown component type \"" + key + "\" or invalid JSON: \"" + jsonStr + "\""); - } - }; - return Component; -}()); -var ChartConstants = (function () { - function ChartConstants() { - } - ChartConstants.DEFAULT_CHART_STROKE_WIDTH = 1.0; - ChartConstants.DEFAULT_CHART_POINT_SIZE = 3.0; - ChartConstants.DEFAULT_AXIS_STROKE_WIDTH = 1.0; - ChartConstants.DEFAULT_TITLE_COLOR = "#000000"; - return ChartConstants; -}()); -var TSUtils = (function () { - function TSUtils() { - } - TSUtils.max = function (input) { - var max = -Number.MAX_VALUE; - for (var i = 0; i < input.length; i++) { - for (var j = 0; j < input[i].length; j++) { - max = Math.max(max, input[i][j]); - } - } - return max; - }; - TSUtils.min = function (input) { - var min = Number.MAX_VALUE; - for (var i = 0; i < input.length; i++) { - for (var j = 0; j < input[i].length; j++) { - min = Math.min(min, input[i][j]); - } - } - return min; - }; - TSUtils.normalizeLengthUnit = function (input) { - if (input == null) - return input; - switch (input.toLowerCase()) { - case "px": - return "px"; - case "percent": - case "%": - return "%"; - case "cm": - return "cm"; - case "mm": - return "mm"; - case "in": - return "in"; - default: - return input; - } - }; - return TSUtils; -}()); -var Chart = (function (_super) { - __extends(Chart, _super); - function Chart(componentType, jsonStr) { - _super.call(this, componentType); - var jsonOrig = JSON.parse(jsonStr); - var json = JSON.parse(jsonStr); - if (!json["componentType"]) - json = json[ComponentType[componentType]]; - this.suppressAxisHorizontal = json['suppressAxisHorizontal']; - this.suppressAxisVertical = json['suppressAxisVertical']; - this.showLegend = json['showLegend']; - this.title = json['title']; - this.setXMin = json['setXMin']; - this.setXMax = json['setXMax']; - this.setYMin = json['setYMin']; - this.setYMax = json['setYMax']; - this.gridVerticalStrokeWidth = json['gridVerticalStrokeWidth']; - this.gridHorizontalStrokeWidth = json['gridHorizontalStrokeWidth']; - if (json['style']) - this.style = new StyleChart(json['style']); - } - Chart.prototype.getStyle = function () { - return this.style; - }; - Chart.appendTitle = function (svg, title, margin, titleStyle) { - var text = svg.append("text") - .text(title) - .attr("x", (margin.widthExMargins / 2)) - .attr("y", 0 - ((margin.top - 30) / 2)) - .attr("text-anchor", "middle"); - if (titleStyle) { - if (titleStyle.getFont()) - text.attr("font-family", titleStyle.getFont); - if (titleStyle.getFontSize() != null) - text.attr("font-size", titleStyle.getFontSize() + "pt"); - if (titleStyle.getUnderline() != null) - text.style("text-decoration", "underline"); - if (titleStyle.getColor()) - text.style("fill", titleStyle.getColor); - else - text.style("fill", ChartConstants.DEFAULT_TITLE_COLOR); - } - else { - text.style("text-decoration", "underline"); - text.style("fill", ChartConstants.DEFAULT_TITLE_COLOR); - } - }; - return Chart; -}(Component)); -var ChartHistogram = (function (_super) { - __extends(ChartHistogram, _super); - function ChartHistogram(jsonStr) { - _super.call(this, ComponentType.ChartHistogram, jsonStr); - this.render = function (appendToObject) { - var s = this.getStyle(); - var margin = Style.getMargins(s); - var xMin; - var xMax; - var yMin; - var yMax; - if (this.setXMin) - xMin = this.setXMin; - else - xMin = (this.lowerBounds ? d3.min(this.lowerBounds) : 0); - if (this.setXMax) - xMax = this.setXMax; - else - xMax = (this.upperBounds ? d3.max(this.upperBounds) : 1); - if (this.setYMin) - yMin = this.setYMin; - else - yMin = 0; - if (this.setYMax) - yMax = this.setYMax; - else - yMax = (this.yValues ? d3.max(this.yValues) : 1); - var xScale = d3.scale.linear() - .domain([xMin, xMax]) - .range([0, margin.widthExMargins]); - var xAxis = d3.svg.axis().scale(xScale) - .orient("bottom").ticks(5); - if (this.gridVerticalStrokeWidth && this.gridVerticalStrokeWidth > 0) { - xAxis.innerTickSize(-margin.heightExMargins); - } - var yScale = d3.scale.linear() - .domain([0, yMax]) - .range([margin.heightExMargins, 0]); - var yAxis = d3.svg.axis().scale(yScale) - .orient("left").ticks(5); - if (this.gridHorizontalStrokeWidth && this.gridHorizontalStrokeWidth > 0) { - yAxis.innerTickSize(-margin.widthExMargins); - } - if (this.suppressAxisHorizontal === true) - xAxis.tickValues([]); - if (this.suppressAxisVertical === true) - yAxis.tickValues([]); - var lowerBounds = this.lowerBounds; - var upperBounds = this.upperBounds; - var yValues = this.yValues; - var data = lowerBounds.map(function (d, i) { - return { 'width': upperBounds[i] - lowerBounds[i], 'height': yValues[i], 'offset': lowerBounds[i] }; - }); - var svg = d3.select("#" + appendToObject.attr("id")) - .append("svg") - .style("fill", "none") - .attr("width", s.getWidth()) - .attr("height", s.getHeight()) - .attr("padding", "20px") - .append("g") - .attr("transform", "translate(" + margin.left + "," + margin.top + ")"); - svg.selectAll(".bin") - .data(data) - .enter().append("rect") - .attr("class", "bin") - .style("fill", "steelblue") - .attr("x", function (d) { return xScale(d.offset); }) - .attr("width", function (d) { return xScale(xMin + d.width) - 1; }) - .attr("y", function (d) { return yScale(d.height); }) - .attr("height", function (d) { return margin.heightExMargins - yScale(d.height); }); - var xAxisNode = svg.append("g") - .attr("class", "x axis") - .attr("transform", "translate(0," + margin.heightExMargins + ")") - .style("stroke", "#000") - .style("stroke-width", (s != null && s.getAxisStrokeWidth() != null ? s.getAxisStrokeWidth() : ChartConstants.DEFAULT_AXIS_STROKE_WIDTH)) - .style("fill", "none") - .call(xAxis); - xAxisNode.selectAll('text').style("stroke-width", 0).style("fill", "#000000"); - if (this.gridVerticalStrokeWidth != null) - xAxisNode.selectAll('.axis line').style({ 'stroke-width': this.gridVerticalStrokeWidth }); - var yAxisNode = svg.append("g") - .attr("class", "y axis") - .style("stroke", "#000") - .style("stroke-width", (s != null && s.getAxisStrokeWidth() != null ? s.getAxisStrokeWidth() : ChartConstants.DEFAULT_AXIS_STROKE_WIDTH)) - .style("fill", "none") - .call(yAxis); - yAxisNode.selectAll('text').style("stroke-width", 0).style("fill", "#000000"); - if (this.gridHorizontalStrokeWidth != null) - yAxisNode.selectAll('.axis line').style({ 'stroke-width': this.gridHorizontalStrokeWidth }); - if (this.title) { - var titleStyle; - if (this.style) - titleStyle = this.style.getTitleStyle(); - Chart.appendTitle(svg, this.title, margin, titleStyle); - } - }; - var json = JSON.parse(jsonStr); - if (!json["componentType"]) - json = json[ComponentType[ComponentType.ChartHistogram]]; - this.lowerBounds = json['lowerBounds']; - this.upperBounds = json['upperBounds']; - this.yValues = json['yvalues']; - } - return ChartHistogram; -}(Chart)); -var ChartLine = (function (_super) { - __extends(ChartLine, _super); - function ChartLine(jsonStr) { - _super.call(this, ComponentType.ChartLine, jsonStr); - this.render = function (appendToObject) { - var nSeries = (!this.xData ? 0 : this.xData.length); - var s = this.getStyle(); - var margin = Style.getMargins(s); - var xScale = d3.scale.linear().range([0, margin.widthExMargins]); - var yScale = d3.scale.linear().range([margin.heightExMargins, 0]); - var xAxis = d3.svg.axis().scale(xScale) - .orient("bottom").ticks(5); - if (this.gridVerticalStrokeWidth != null && this.gridVerticalStrokeWidth > 0) { - xAxis.innerTickSize(-margin.heightExMargins); - } - var yAxis = d3.svg.axis().scale(yScale) - .orient("left").ticks(5); - if (this.gridHorizontalStrokeWidth != null && this.gridHorizontalStrokeWidth > 0) { - yAxis.innerTickSize(-margin.widthExMargins); - } - if (this.suppressAxisHorizontal === true) - xAxis.tickValues([]); - if (this.suppressAxisVertical === true) - yAxis.tickValues([]); - var valueline = d3.svg.line() - .x(function (d) { - return xScale(d.xPos); - }) - .y(function (d) { - return yScale(d.yPos); - }); - var svg = d3.select("#" + appendToObject.attr("id")) - .append("svg") - .style("stroke-width", (s && s.getStrokeWidth() ? s.getStrokeWidth() : ChartConstants.DEFAULT_CHART_STROKE_WIDTH)) - .style("fill", "none") - .attr("width", s.getWidth()) - .attr("height", s.getHeight()) - .append("g") - .attr("transform", "translate(" + margin.left + "," + margin.top + ")"); - var xMin; - var xMax; - var yMin; - var yMax; - if (this.setXMin != null) - xMin = this.setXMin; - else - xMin = (this.xData ? TSUtils.min(this.xData) : 0); - if (this.setXMax != null) - xMax = this.setXMax; - else - xMax = (this.xData ? TSUtils.max(this.xData) : 1); - if (this.setYMin != null) - yMin = this.setYMin; - else - yMin = (this.yData ? TSUtils.min(this.yData) : 0); - if (this.setYMax != null) - yMax = this.setYMax; - else - yMax = (this.yData ? TSUtils.max(this.yData) : 1); - xScale.domain([xMin, xMax]); - yScale.domain([yMin, yMax]); - var defaultColor = d3.scale.category10(); - for (var i = 0; i < nSeries; i++) { - var xVals = this.xData[i]; - var yVals = this.yData[i]; - var data = xVals.map(function (d, i) { - return { 'xPos': xVals[i], 'yPos': yVals[i] }; - }); - svg.append("path") - .attr("class", "line") - .style("stroke", (s && s.getSeriesColor(i) ? s.getSeriesColor(i) : defaultColor(String(i)))) - .attr("d", valueline(data)); - } - var xAxisNode = svg.append("g") - .attr("class", "x axis") - .attr("transform", "translate(0," + margin.heightExMargins + ")") - .style("stroke", "#000") - .style("stroke-width", (s != null && s.getAxisStrokeWidth() != null ? s.getAxisStrokeWidth() : ChartConstants.DEFAULT_AXIS_STROKE_WIDTH)) - .style("fill", "none") - .call(xAxis); - xAxisNode.selectAll('text').style("stroke-width", 0).style("fill", "#000000"); - if (this.gridVerticalStrokeWidth != null) - xAxisNode.selectAll('.axis line').style({ 'stroke-width': this.gridVerticalStrokeWidth }); - var yAxisNode = svg.append("g") - .attr("class", "y axis") - .style("stroke", "#000") - .style("stroke-width", (s != null && s.getAxisStrokeWidth() != null ? s.getAxisStrokeWidth() : ChartConstants.DEFAULT_AXIS_STROKE_WIDTH)) - .style("fill", "none") - .call(yAxis); - yAxisNode.selectAll('text').style("stroke-width", 0).style("fill", "#000000"); - if (this.gridHorizontalStrokeWidth != null) - yAxisNode.selectAll('.axis line').style({ 'stroke-width': this.gridHorizontalStrokeWidth }); - if (this.seriesNames && this.showLegend === true) { - var legendSpace = margin.widthExMargins / i; - for (var i = 0; i < nSeries; i++) { - var values = this.xData[i]; - var yValues = this.yData[i]; - var lastX = values[values.length - 1]; - var lastY = yValues[yValues.length - 1]; - var toDisplay = this.seriesNames[i]; - svg.append("text") - .attr("x", (legendSpace / 2) + i * legendSpace) - .attr("y", margin.heightExMargins + (margin.bottom / 2) + 5) - .attr("class", "legend") - .style("fill", (s && s.getSeriesColor(i) ? s.getSeriesColor(i) : defaultColor(String(i)))) - .text(toDisplay); - } - } - if (this.title) { - var titleStyle; - if (this.style) - titleStyle = this.style.getTitleStyle(); - Chart.appendTitle(svg, this.title, margin, titleStyle); - } - }; - var json = JSON.parse(jsonStr); - if (!json["componentType"]) - json = json[ComponentType[ComponentType.ChartLine]]; - this.xData = json['x']; - this.yData = json['y']; - this.seriesNames = json['seriesNames']; - } - return ChartLine; -}(Chart)); -var ChartScatter = (function (_super) { - __extends(ChartScatter, _super); - function ChartScatter(jsonStr) { - _super.call(this, ComponentType.ChartScatter, jsonStr); - this.render = function (appendToObject) { - var nSeries = (!this.xData ? 0 : this.xData.length); - var s = this.getStyle(); - var margin = Style.getMargins(s); - var xScale = d3.scale.linear().range([0, margin.widthExMargins]); - var yScale = d3.scale.linear().range([margin.heightExMargins, 0]); - var xAxis = d3.svg.axis().scale(xScale) - .innerTickSize(-margin.heightExMargins) - .orient("bottom").ticks(5); - var yAxis = d3.svg.axis().scale(yScale) - .innerTickSize(-margin.widthExMargins) - .orient("left").ticks(5); - if (this.suppressAxisHorizontal === true) - xAxis.tickValues([]); - if (this.suppressAxisVertical === true) - yAxis.tickValues([]); - var svg = d3.select("#" + appendToObject.attr("id")) - .append("svg") - .style("stroke-width", (s && s.getStrokeWidth() ? s.getStrokeWidth() : 1)) - .style("fill", "none") - .attr("width", s.getWidth()) - .attr("height", s.getHeight()) - .attr("padding", "20px") - .append("g") - .attr("transform", "translate(" + margin.left + "," + margin.top + ")"); - var xMin; - var xMax; - var yMin; - var yMax; - if (this.setXMin) - xMin = this.setXMin; - else - xMin = (this.xData ? TSUtils.min(this.xData) : 0); - if (this.setXMax) - xMax = this.setXMax; - else - xMax = (this.xData ? TSUtils.max(this.xData) : 1); - if (this.setYMin) - yMin = this.setYMin; - else - yMin = (this.yData ? TSUtils.min(this.yData) : 0); - if (this.setYMax) - yMax = this.setYMax; - else - yMax = (this.yData ? TSUtils.max(this.yData) : 1); - xScale.domain([xMin, xMax]); - yScale.domain([yMin, yMax]); - var defaultColor = d3.scale.category10(); - for (var i = 0; i < nSeries; i++) { - var xVals = this.xData[i]; - var yVals = this.yData[i]; - var data = xVals.map(function (d, i) { - return { 'xPos': xVals[i], 'yPos': yVals[i] }; - }); - svg.selectAll("circle") - .data(data) - .enter() - .append("circle") - .style("fill", (s && s.getSeriesColor(i) ? s.getSeriesColor(i) : defaultColor(String(i)))) - .attr("r", (s && s.getPointSize() ? s.getPointSize() : ChartConstants.DEFAULT_CHART_POINT_SIZE)) - .attr("cx", function (d) { - return xScale(d['xPos']); - }) - .attr("cy", function (d) { - return yScale(d['yPos']); - }); - } - var xAxisNode = svg.append("g") - .attr("class", "x axis") - .attr("transform", "translate(0," + margin.heightExMargins + ")") - .style("stroke", "#000") - .style("stroke-width", (s != null && s.getAxisStrokeWidth() != null ? s.getAxisStrokeWidth() : ChartConstants.DEFAULT_AXIS_STROKE_WIDTH)) - .style("fill", "none") - .call(xAxis); - xAxisNode.selectAll('text').style("stroke-width", 0).style("fill", "#000000"); - if (this.gridVerticalStrokeWidth != null) - xAxisNode.selectAll('.axis line').style({ 'stroke-width': this.gridVerticalStrokeWidth }); - var yAxisNode = svg.append("g") - .attr("class", "y axis") - .style("stroke", "#000") - .style("stroke-width", (s != null && s.getAxisStrokeWidth() != null ? s.getAxisStrokeWidth() : ChartConstants.DEFAULT_AXIS_STROKE_WIDTH)) - .style("fill", "none") - .call(yAxis); - yAxisNode.selectAll('text').style("stroke-width", 0).style("fill", "#000000"); - if (this.gridHorizontalStrokeWidth != null) - yAxisNode.selectAll('.axis line').style({ 'stroke-width': this.gridHorizontalStrokeWidth }); - if (this.seriesNames && this.showLegend === true) { - var legendSpace = margin.widthExMargins / i; - for (var i = 0; i < nSeries; i++) { - var values = this.xData[i]; - var yValues = this.yData[i]; - var lastX = values[values.length - 1]; - var lastY = yValues[yValues.length - 1]; - var toDisplay; - if (!lastX || !lastY) - toDisplay = this.seriesNames[i] + " (no data)"; - else - toDisplay = this.seriesNames[i] + " (" + lastX.toPrecision(5) + "," + lastY.toPrecision(5) + ")"; - svg.append("text") - .attr("x", (legendSpace / 2) + i * legendSpace) - .attr("y", margin.heightExMargins + (margin.bottom / 2) + 5) - .attr("class", "legend") - .style("fill", (s && s.getSeriesColor(i) ? s.getSeriesColor(i) : defaultColor(String(i)))) - .text(toDisplay); - } - } - if (this.title) { - var titleStyle; - if (this.style) - titleStyle = this.style.getTitleStyle(); - Chart.appendTitle(svg, this.title, margin, titleStyle); - } - }; - var json = JSON.parse(jsonStr); - if (!json["componentType"]) - json = json[ComponentType[ComponentType.ChartScatter]]; - this.xData = json['x']; - this.yData = json['y']; - this.seriesNames = json['seriesNames']; - } - return ChartScatter; -}(Chart)); -var Legend = (function () { - function Legend() { - } - Legend.offsetX = 15; - Legend.offsetY = 15; - Legend.padding = 8; - Legend.separation = 12; - Legend.boxSize = 10; - Legend.fillColor = "#FFFFFF"; - Legend.legendOpacity = 0.75; - Legend.borderStrokeColor = "#000000"; - Legend.legendFn = (function (g) { - var svg = d3.select(g.property("nearestViewportElement")); - var legendBox = g.selectAll(".outerRect").data([true]); - var legendItems = g.selectAll(".legendElement").data([true]); - legendBox.enter().append("rect").attr("class", "outerRect"); - legendItems.enter().append("g").attr("class", "legendElement"); - var legendElements = []; - svg.selectAll("[data-legend]").each(function () { - var thisVar = d3.select(this); - legendElements.push({ - label: thisVar.attr("data-legend"), - color: thisVar.style("fill") - }); - }); - legendItems.selectAll("rect") - .data(legendElements, function (d) { return d.label; }) - .call(function (d) { d.enter().append("rect"); }) - .call(function (d) { d.exit().remove(); }) - .attr("x", 0) - .attr("y", function (d, i) { return i * Legend.separation - Legend.boxSize + "px"; }) - .attr("width", Legend.boxSize) - .attr("height", Legend.boxSize) - .style("fill", function (d) { return d.color; }); - legendItems.selectAll("text") - .data(legendElements, function (d) { return d.label; }) - .call(function (d) { d.enter().append("text"); }) - .call(function (d) { d.exit().remove(); }) - .attr("y", function (d, i) { return i * Legend.separation + "px"; }) - .attr("x", (Legend.padding + Legend.boxSize) + "px") - .text(function (d) { return d.label; }); - var legendBoundingBox = legendItems[0][0].getBBox(); - legendBox.attr("x", (legendBoundingBox.x - Legend.padding)) - .attr("y", (legendBoundingBox.y - Legend.padding)) - .attr("height", (legendBoundingBox.height + 2 * Legend.padding)) - .attr("width", (legendBoundingBox.width + 2 * Legend.padding)) - .style("fill", Legend.fillColor) - .style("stroke", Legend.borderStrokeColor) - .style("opacity", Legend.legendOpacity); - svg.selectAll(".legend").attr("transform", "translate(" + Legend.offsetX + "," + Legend.offsetY + ")"); - }); - return Legend; -}()); -var ChartStackedArea = (function (_super) { - __extends(ChartStackedArea, _super); - function ChartStackedArea(jsonStr) { - _super.call(this, ComponentType.ChartStackedArea, jsonStr); - this.render = function (appendToObject) { - var nSeries = (!this.xData ? 0 : this.xData.length); - var s = this.getStyle(); - var margin = Style.getMargins(s); - var xScale = d3.scale.linear().range([0, margin.widthExMargins]); - var yScale = d3.scale.linear().range([margin.heightExMargins, 0]); - var xAxis = d3.svg.axis().scale(xScale) - .orient("bottom").ticks(5); - if (this.gridVerticalStrokeWidth != null && this.gridVerticalStrokeWidth > 0) { - xAxis.innerTickSize(-margin.heightExMargins); - } - var yAxis = d3.svg.axis().scale(yScale) - .orient("left").ticks(5); - if (this.gridHorizontalStrokeWidth != null && this.gridHorizontalStrokeWidth > 0) { - yAxis.innerTickSize(-margin.widthExMargins); - } - if (this.suppressAxisHorizontal === true) - xAxis.tickValues([]); - if (this.suppressAxisVertical === true) - yAxis.tickValues([]); - var data = []; - for (var i = 0; i < this.xData.length; i++) { - var obj = {}; - for (var j = 0; j < this.labels.length; j++) { - obj[this.labels[j]] = this.yData[j][i]; - obj['xValue'] = this.xData[i]; - } - data.push(obj); - } - var area = d3.svg.area() - .x(function (d) { return xScale(d.xValue); }) - .y0(function (d) { return yScale(d.y0); }) - .y1(function (d) { return yScale(d.y0 + d.y); }); - var stack = d3.layout.stack() - .values(function (d) { return d.values; }); - var svg = d3.select("#" + appendToObject.attr("id")).append("svg") - .attr("width", margin.widthExMargins + margin.left + margin.right) - .attr("height", margin.heightExMargins + margin.top + margin.bottom) - .append("g") - .attr("transform", "translate(" + margin.left + "," + margin.top + ")"); - var color = d3.scale.category20(); - color.domain(d3.keys(data[0]).filter(function (key) { - return key !== "xValue"; - })); - var browsers = stack(color.domain().map(function (name) { - return { - name: name, - values: data.map(function (d) { - return { xValue: d.xValue, y: d[name] * 1 }; - }) - }; - })); - var maxX = d3.max(data, function (d) { - var vals = d3.keys(d).map(function (key) { - return key !== "xValue" ? d[key] : 0; - }); - return d3.sum(vals); - }); - xScale.domain(d3.extent(data, function (d) { - return d.xValue; - })); - yScale.domain([0, maxX]); - var browser = svg.selectAll(".browser") - .data(browsers) - .enter().append("g") - .attr("class", "browser"); - var tempLabels = this.labels; - var defaultColor = d3.scale.category20(); - browser.append("path") - .attr("class", "area") - .attr("data-legend", function (d) { return d.name; }) - .attr("d", function (d) { - return area(d.values); - }) - .style("fill", function (d) { - if (s && s.getSeriesColor(tempLabels.indexOf(d.name))) { - return s.getSeriesColor(tempLabels.indexOf(d.name)); - } - else { - return defaultColor(String(tempLabels.indexOf(d.name))); - } - }) - .style({ "stroke-width": "0px" }); - var xAxisNode = svg.append("g") - .attr("class", "x axis") - .style("stroke", "#000") - .style("stroke-width", (s != null && s.getAxisStrokeWidth() != null ? s.getAxisStrokeWidth() : ChartConstants.DEFAULT_AXIS_STROKE_WIDTH)) - .style("fill", "none") - .attr("transform", "translate(0," + margin.heightExMargins + ")") - .call(xAxis); - xAxisNode.selectAll('text').style("stroke-width", 0).style("fill", "#000000"); - var yAxisNode = svg.append("g") - .attr("class", "y axis") - .style("stroke", "#000") - .style("stroke-width", (s != null && s.getAxisStrokeWidth() != null ? s.getAxisStrokeWidth() : ChartConstants.DEFAULT_AXIS_STROKE_WIDTH)) - .style("fill", "none") - .call(yAxis); - yAxisNode.selectAll('text').style("stroke-width", 0).style("fill", "#000000"); - if (this.title) { - var titleStyle; - if (this.style) - titleStyle = this.style.getTitleStyle(); - Chart.appendTitle(svg, this.title, margin, titleStyle); - } - var legend = svg.append("g") - .attr("class", "legend") - .attr("transform", "translate(40,40)") - .style("font-size", "12px") - .call(Legend.legendFn); - }; - var json = JSON.parse(jsonStr); - if (!json["componentType"]) - json = json[ComponentType[ComponentType.ChartStackedArea]]; - this.xData = json['x']; - this.yData = json['y']; - this.labels = json['labels']; - } - return ChartStackedArea; -}(Chart)); -var ChartTimeline = (function (_super) { - __extends(ChartTimeline, _super); - function ChartTimeline(jsonStr) { - _super.call(this, ComponentType.ChartTimeline, jsonStr); - this.render = function (appendToObject) { - var instance = this; - var s = this.getStyle(); - var margin = Style.getMargins(s); - this.itemData = []; - var count = 0; - for (var i = 0; i < this.laneData.length; i++) { - for (var j = 0; j < this.laneData[i].length; j++) { - var obj = {}; - obj["start"] = this.laneData[i][j]["startTimeMs"]; - obj["end"] = this.laneData[i][j]["endTimeMs"]; - obj["id"] = count++; - obj["lane"] = i; - obj["color"] = this.laneData[i][j]["color"]; - obj["label"] = this.laneData[i][j]["entryLabel"]; - this.itemData.push(obj); - } - } - this.lanes = []; - for (var i = 0; i < this.laneNames.length; i++) { - var obj = {}; - obj["label"] = this.laneNames[i]; - obj["id"] = i; - this.lanes.push(obj); - } - var svg = d3.select("#" + appendToObject.attr("id")) - .append("svg") - .style("stroke-width", (s && s.getStrokeWidth() ? s.getStrokeWidth() : ChartConstants.DEFAULT_CHART_STROKE_WIDTH)) - .style("fill", "none") - .attr("width", s.getWidth()) - .attr("height", s.getHeight()) - .append("g"); - var heightExMargins = s.getHeight() - margin.top - margin.bottom; - var widthExMargins = s.getWidth() - margin.left - margin.right; - var miniHeight = this.laneNames.length * ChartTimeline.MINI_LANE_HEIGHT_PX; - var mainHeight = s.getHeight() - miniHeight - margin.top - margin.bottom - 25; - var minTime = d3.min(this.itemData, function (d) { return d.start; }); - var maxTime = d3.max(this.itemData, function (d) { return d.end; }); - this.x = d3.time.scale() - .domain([minTime, maxTime]) - .range([0, widthExMargins]); - this.x1 = d3.time.scale().range([0, widthExMargins]); - this.y1 = d3.scale.linear().domain([0, this.laneNames.length]).range([0, mainHeight]); - this.y2 = d3.scale.linear().domain([0, this.laneNames.length]).range([0, miniHeight]); - this.rect = svg.append('defs').append('clipPath') - .attr('id', 'clip') - .append('rect') - .attr('width', widthExMargins) - .attr('height', s.getHeight() - 100); - this.mainView = svg.append('g') - .attr('transform', 'translate(' + margin.left + ',' + margin.top + ')') - .attr('width', widthExMargins) - .attr('height', mainHeight) - .attr('font-size', '12px') - .attr('font', 'sans-serif'); - this.miniView = svg.append('g') - .attr('transform', 'translate(' + margin.left + ',' + (mainHeight + margin.top + 25) + ')') - .attr('width', widthExMargins) - .attr('height', miniHeight) - .attr('font-size', '10px') - .attr('font', 'sans-serif'); - this.mainView.append('g').selectAll('.laneLines') - .data(this.lanes) - .enter().append('line') - .attr('x1', 0) - .attr('y1', function (d) { - return d3.round(instance.y1(d.id)) + 0.5; - }) - .attr('x2', widthExMargins) - .attr('y2', function (d) { - return d3.round(instance.y1(d.id)) + 0.5; - }) - .attr('stroke', 'lightgray') - .attr('stroke-width', 1); - this.mainView.append('g').selectAll('.laneText') - .data(this.lanes) - .enter().append('text') - .text(function (d) { - if (d.label) - return d.label; - return ""; - }) - .attr('x', -10) - .attr('y', function (d) { - return instance.y1(d.id + .5); - }) - .attr('text-anchor', 'end') - .attr("font", "8pt sans-serif") - .attr('fill', 'black'); - this.miniView.append('g').selectAll('.laneLines') - .data(this.lanes) - .enter().append('line') - .attr('x1', 0) - .attr('y1', function (d) { return d3.round(instance.y2(d.id)) + 0.5; }) - .attr('x2', widthExMargins) - .attr('y2', function (d) { return d3.round(instance.y2(d.id)) + 0.5; }) - .attr('stroke', 'gray') - .attr('stroke-width', 1.0); - this.miniView.append('g').selectAll('.laneText') - .data(this.lanes) - .enter().append('text') - .text(function (d) { - if (d.label) - return d.label; - return ""; - }) - .attr('x', -10) - .attr('y', function (d) { - return instance.y2(d.id + .5); - }) - .attr('dy', '0.5ex') - .attr('text-anchor', 'end') - .attr('fill', 'black'); - this.xTimeAxis = d3.svg.axis() - .scale(this.x1) - .orient('bottom') - .ticks(d3.time.days, 1) - .tickFormat(d3.time.format('%a %d')) - .tickSize(6, 0); - var temp = this.mainView.append('g') - .attr('transform', 'translate(0,' + mainHeight + ')') - .attr('class', 'timeAxis') - .attr('fill', 'black') - .style("stroke", "black").style("stroke-width", 1.0).style("fill", "black") - .attr("font", "10px sans-serif") - .call(this.xTimeAxis); - temp.selectAll('text').style("stroke-width", 0.0).attr('stroke-width', 0.0); - this.itemRects = this.mainView.append('g') - .attr('clip-path', 'url(#clip)'); - this.miniView.append('g').selectAll('miniItems') - .data(this.getMiniViewPaths(this.itemData)) - .enter().append('path') - .attr('class', function (d) { - return 'miniItem ' + d.class; - }) - .attr('d', function (d) { - return d.path; - }) - .attr('stroke', 'black') - .attr('stroke-width', 'black'); - this.miniView.append('rect') - .attr('pointer-events', 'painted') - .attr('width', widthExMargins) - .attr('height', miniHeight) - .attr('visibility', 'hidden') - .on('mouseup', this.moveBrush); - this.brush = d3.svg.brush() - .x(this.x) - .extent([minTime, maxTime]) - .on("brush", this.renderChart); - this.miniView.append('g') - .attr('class', 'x brush') - .call(this.brush) - .selectAll('rect') - .attr('y', 1) - .attr('height', miniHeight - 1) - .style('fill', 'gray') - .style('fill-opacity', '0.2') - .style('stroke', 'DarkSlateGray') - .style('stroke-width', 1); - this.miniView.selectAll('rect.background').remove(); - this.renderChart(); - if (this.title) { - var titleStyle; - if (this.style) - titleStyle = this.style.getTitleStyle(); - var text = svg.append("text") - .text(this.title) - .attr("x", (s.getWidth() / 2)) - .attr("y", ((margin.top - 30) / 2)) - .attr("text-anchor", "middle"); - if (titleStyle) { - if (titleStyle.getFont()) - text.attr("font-family", titleStyle.getFont); - if (titleStyle.getFontSize() != null) - text.attr("font-size", titleStyle.getFontSize() + "pt"); - if (titleStyle.getUnderline() != null) - text.style("text-decoration", "underline"); - if (titleStyle.getColor()) - text.style("fill", titleStyle.getColor); - else - text.style("fill", ChartConstants.DEFAULT_TITLE_COLOR); - } - else { - text.style("text-decoration", "underline"); - text.style("fill", ChartConstants.DEFAULT_TITLE_COLOR); - } - } - }; - this.renderChart = function () { - var instance = this; - var extent = this.brush.extent(); - var minExtent = extent[0]; - var maxExtent = extent[1]; - var visibleItems = this.itemData.filter(function (d) { - return d.start < maxExtent && d.end > minExtent; - }); - this.miniView.select('.brush').call(this.brush.extent([minExtent, maxExtent])); - this.x1.domain([minExtent, maxExtent]); - var range = maxExtent - minExtent; - if (range > 2 * ChartTimeline.MILLISEC_PER_WEEK) { - this.xTimeAxis.ticks(d3.time.mondays, 1).tickFormat(d3.time.format('%a %d')); - } - else if (range > 2 * ChartTimeline.MILLISEC_PER_DAY) { - this.xTimeAxis.ticks(d3.time.days, 1).tickFormat(d3.time.format('%a %d')); - } - else if (range > 2 * ChartTimeline.MILLISEC_PER_HOUR) { - this.xTimeAxis.ticks(d3.time.hours, 4).tickFormat(d3.time.format('%H %p')); - } - else if (range > 2 * ChartTimeline.MILLISEC_PER_MINUTE) { - this.xTimeAxis.ticks(d3.time.minutes, 1).tickFormat(d3.time.format('%H:%M')); - } - else if (range >= 30000) { - this.xTimeAxis.ticks(d3.time.seconds, 10).tickFormat(d3.time.format('%H:%M:%S')); - } - else { - this.xTimeAxis.ticks(d3.time.seconds, 1).tickFormat(d3.time.format('%H:%M:%S')); - } - this.mainView.select('.timeAxis').call(this.xTimeAxis); - var rects = this.itemRects.selectAll('rect') - .data(visibleItems, function (d) { return d.id; }) - .attr('x', function (d) { return instance.x1(d.start); }) - .attr('width', function (d) { return instance.x1(d.end) - instance.x1(d.start); }); - rects.enter().append('rect') - .attr('x', function (d) { return instance.x1(d.start); }) - .attr('y', function (d) { return instance.y1(d.lane) + ChartTimeline.ENTRY_LANE_HEIGHT_OFFSET_FRACTION * instance.y1(1) + 0.5; }) - .attr('width', function (d) { return instance.x1(d.end) - instance.x1(d.start); }) - .attr('height', function (d) { return ChartTimeline.ENTRY_LANE_HEIGHT_TOTAL_FRACTION * instance.y1(1); }) - .attr('stroke', 'black') - .attr('fill', function (d) { - if (d.color) - return d.color; - return ChartTimeline.DEFAULT_COLOR; - }) - .attr('stroke-width', 1); - rects.exit().remove(); - var labels = this.itemRects.selectAll('text') - .data(visibleItems, function (d) { - return d.id; - }) - .attr('x', function (d) { - return instance.x1(Math.max(d.start, minExtent)) + 2; - }) - .attr('fill', 'black'); - labels.enter().append('text') - .text(function (d) { - if (instance.x1(d.end) - instance.x1(d.start) <= 30) - return ""; - if (d.label) - return d.label; - return ""; - }) - .attr('x', function (d) { - return instance.x1(Math.max(d.start, minExtent)) + 2; - }) - .attr('y', function (d) { - return instance.y1(d.lane) + .4 * instance.y1(1) + 0.5; - }) - .attr('text-anchor', 'start') - .attr('class', 'itemLabel') - .attr('fill', 'black'); - labels.exit().remove(); - }; - this.moveBrush = function () { - var origin = d3.mouse(this.rect[0]); - var time = this.x.invert(origin[0]).getTime(); - var halfExtent = (this.brush.extent()[1].getTime() - this.brush.extent()[0].getTime()) / 2; - this.brush.extent([new Date(time - halfExtent), new Date(time + halfExtent)]); - this.renderChart(); - }; - this.getMiniViewPaths = function (items) { - var paths = {}, d, offset = .5 * this.y2(1) + 0.5, result = []; - for (var i = 0; i < items.length; i++) { - d = items[i]; - if (!paths[d.class]) - paths[d.class] = ''; - paths[d.class] += ['M', this.x(d.start), (this.y2(d.lane) + offset), 'H', this.x(d.end)].join(' '); - } - for (var className in paths) { - result.push({ class: className, path: paths[className] }); - } - return result; - }; - var json = JSON.parse(jsonStr); - if (!json["componentType"]) - json = json[ComponentType[ComponentType.ChartTimeline]]; - this.laneNames = json['laneNames']; - this.laneData = json['laneData']; - } - ChartTimeline.MINI_LANE_HEIGHT_PX = 12; - ChartTimeline.ENTRY_LANE_HEIGHT_OFFSET_FRACTION = 0.05; - ChartTimeline.ENTRY_LANE_HEIGHT_TOTAL_FRACTION = 0.90; - ChartTimeline.MILLISEC_PER_MINUTE = 60 * 1000; - ChartTimeline.MILLISEC_PER_HOUR = 60 * ChartTimeline.MILLISEC_PER_MINUTE; - ChartTimeline.MILLISEC_PER_DAY = 24 * ChartTimeline.MILLISEC_PER_HOUR; - ChartTimeline.MILLISEC_PER_WEEK = 7 * ChartTimeline.MILLISEC_PER_DAY; - ChartTimeline.DEFAULT_COLOR = "LightGrey"; - return ChartTimeline; -}(Chart)); -var StyleChart = (function (_super) { - __extends(StyleChart, _super); - function StyleChart(jsonObj) { - var _this = this; - _super.call(this, jsonObj['StyleChart']); - this.getStrokeWidth = function () { return _this.strokeWidth; }; - this.getPointSize = function () { return _this.pointSize; }; - this.getSeriesColors = function () { return _this.seriesColors; }; - this.getSeriesColor = function (idx) { - if (!this.seriesColors || idx < 0 || idx > this.seriesColors.length) - return null; - return _this.seriesColors[idx]; - }; - this.getAxisStrokeWidth = function () { return _this.axisStrokeWidth; }; - this.getTitleStyle = function () { return _this.titleStyle; }; - var style = jsonObj['StyleChart']; - if (style) { - this.strokeWidth = style['strokeWidth']; - this.pointSize = style['pointSize']; - this.seriesColors = style['seriesColors']; - if (style['titleStyle']) - this.titleStyle = new StyleText(style['titleStyle']); - } - } - return StyleChart; -}(Style)); -var ComponentDiv = (function (_super) { - __extends(ComponentDiv, _super); - function ComponentDiv(jsonStr) { - _super.call(this, ComponentType.ComponentDiv); - this.render = function (appendToObject) { - var newDiv = $('
'); - newDiv.uniqueId(); - if (this.style) { - if (this.style.getWidth()) { - var unit = this.style.getWidthUnit(); - newDiv.width(this.style.getWidth() + (unit ? unit : "")); - } - if (this.style.getHeight()) { - var unit = this.style.getHeightUnit(); - newDiv.height(this.style.getHeight() + (unit ? unit : "")); - } - if (this.style.getBackgroundColor()) - newDiv.css("background-color", this.style.getBackgroundColor()); - if (this.style.getFloatValue()) - newDiv.css("float", this.style.getFloatValue()); - } - appendToObject.append(newDiv); - if (this.components) { - for (var i = 0; i < this.components.length; i++) { - this.components[i].render(newDiv); - } - } - }; - var json = JSON.parse(jsonStr); - if (!json["componentType"]) - json = json[ComponentType[ComponentType.ComponentDiv]]; - var components = json['components']; - if (components) { - this.components = []; - for (var i = 0; i < components.length; i++) { - var asStr = JSON.stringify(components[i]); - this.components.push(Component.getComponent(asStr)); - } - } - if (json['style']) - this.style = new StyleDiv(json['style']); - } - return ComponentDiv; -}(Component)); -var StyleDiv = (function (_super) { - __extends(StyleDiv, _super); - function StyleDiv(jsonObj) { - var _this = this; - _super.call(this, jsonObj['StyleDiv']); - this.getFloatValue = function () { return _this.floatValue; }; - if (jsonObj && jsonObj['StyleDiv']) - this.floatValue = jsonObj['StyleDiv']['floatValue']; - } - return StyleDiv; -}(Style)); -var DecoratorAccordion = (function (_super) { - __extends(DecoratorAccordion, _super); - function DecoratorAccordion(jsonStr) { - _super.call(this, ComponentType.DecoratorAccordion); - this.render = function (appendToObject) { - var s = this.style; - var outerDiv = $('
'); - outerDiv.uniqueId(); - var titleDiv; - if (this.title) - titleDiv = $('
' + this.title + '
'); - else - titleDiv = $('
'); - titleDiv.uniqueId(); - outerDiv.append(titleDiv); - var innerDiv = $('
'); - innerDiv.uniqueId(); - outerDiv.append(innerDiv); - if (this.innerComponents) { - for (var i = 0; i < this.innerComponents.length; i++) { - this.innerComponents[i].render(innerDiv); - } - } - appendToObject.append(outerDiv); - if (this.defaultCollapsed) - outerDiv.accordion({ collapsible: true, heightStyle: "content", active: false }); - else - outerDiv.accordion({ collapsible: true, heightStyle: "content" }); - }; - var json = JSON.parse(jsonStr); - if (!json["componentType"]) - json = json[ComponentType[ComponentType.DecoratorAccordion]]; - this.title = json['title']; - this.defaultCollapsed = json['defaultCollapsed']; - var innerCs = json['innerComponents']; - if (innerCs) { - this.innerComponents = []; - for (var i = 0; i < innerCs.length; i++) { - var asStr = JSON.stringify(innerCs[i]); - this.innerComponents.push(Component.getComponent(asStr)); - } - } - if (json['style']) - this.style = new StyleAccordion(json['style']); - } - return DecoratorAccordion; -}(Component)); -var StyleAccordion = (function (_super) { - __extends(StyleAccordion, _super); - function StyleAccordion(jsonObj) { - _super.call(this, jsonObj['StyleAccordion']); - } - return StyleAccordion; -}(Style)); -var ComponentTable = (function (_super) { - __extends(ComponentTable, _super); - function ComponentTable(jsonStr) { - _super.call(this, ComponentType.ComponentTable); - this.render = function (appendToObject) { - var s = this.style; - var margin = Style.getMargins(s); - var tbl = document.createElement('table'); - tbl.style.width = '100%'; - if (s && s.getBorderWidthPx() != null) - tbl.setAttribute('border', String(s.getBorderWidthPx())); - if (s && s.getBackgroundColor()) - tbl.style.backgroundColor = s.getBackgroundColor(); - if (s && s.getWhitespaceMode()) - tbl.style.whiteSpace = s.getWhitespaceMode(); - if (s && s.getColumnWidths()) { - var colWidths = s.getColumnWidths(); - var unit = TSUtils.normalizeLengthUnit(s.getColumnWidthUnit()); - for (var i = 0; i < colWidths.length; i++) { - var col = document.createElement('col'); - col.setAttribute('width', colWidths[i] + unit); - tbl.appendChild(col); - } - } - var padTop = 1; - var padRight = 1; - var padBottom = 1; - var padLeft = 1; - if (this.header) { - var theader = document.createElement('thead'); - var headerRow = document.createElement('tr'); - if (s && s.getHeaderColor()) - headerRow.style.backgroundColor = s.getHeaderColor(); - for (var i = 0; i < this.header.length; i++) { - var headerd = document.createElement('th'); - headerd.style.padding = padTop + 'px ' + padRight + 'px ' + padBottom + 'px ' + padLeft + 'px'; - headerd.appendChild(document.createTextNode(this.header[i])); - headerRow.appendChild(headerd); - } - tbl.appendChild(headerRow); - } - if (this.content) { - var tbdy = document.createElement('tbody'); - for (var i = 0; i < this.content.length; i++) { - var tr = document.createElement('tr'); - for (var j = 0; j < this.content[i].length; j++) { - var td = document.createElement('td'); - td.style.padding = padTop + 'px ' + padRight + 'px ' + padBottom + 'px ' + padLeft + 'px'; - td.appendChild(document.createTextNode(this.content[i][j])); - tr.appendChild(td); - } - tbdy.appendChild(tr); - } - tbl.appendChild(tbdy); - } - appendToObject.append(tbl); - }; - var json = JSON.parse(jsonStr); - if (!json["componentType"]) - json = json[ComponentType[ComponentType.ComponentTable]]; - this.header = json['header']; - this.content = json['content']; - if (json['style']) - this.style = new StyleTable(json['style']); - } - return ComponentTable; -}(Component)); -var StyleTable = (function (_super) { - __extends(StyleTable, _super); - function StyleTable(jsonObj) { - var _this = this; - _super.call(this, jsonObj['StyleTable']); - this.getColumnWidths = function () { return _this.columnWidths; }; - this.getColumnWidthUnit = function () { return _this.columnWidthUnit; }; - this.getBorderWidthPx = function () { return _this.borderWidthPx; }; - this.getHeaderColor = function () { return _this.headerColor; }; - this.getWhitespaceMode = function () { return _this.whitespaceMode; }; - var style = jsonObj['StyleTable']; - if (style) { - this.columnWidths = jsonObj['StyleTable']['columnWidths']; - this.borderWidthPx = jsonObj['StyleTable']['borderWidthPx']; - this.headerColor = jsonObj['StyleTable']['headerColor']; - this.columnWidthUnit = jsonObj['StyleTable']['columnWidthUnit']; - this.whitespaceMode = jsonObj['StyleTable']['whitespaceMode']; - } - } - return StyleTable; -}(Style)); -var ComponentText = (function (_super) { - __extends(ComponentText, _super); - function ComponentText(jsonStr) { - var _this = this; - _super.call(this, ComponentType.ComponentText); - this.render = function (appendToObject) { - var textNode = document.createTextNode(_this.text); - if (_this.style) { - var newSpan = document.createElement('span'); - if (_this.style.getFont()) - newSpan.style.font = _this.style.getFont(); - if (_this.style.getFontSize() != null) - newSpan.style.fontSize = _this.style.getFontSize() + "pt"; - if (_this.style.getUnderline() != null) - newSpan.style.textDecoration = 'underline'; - if (_this.style.getColor()) - newSpan.style.color = _this.style.getColor(); - if (_this.style.getMarginTop()) - newSpan.style.marginTop = _this.style.getMarginTop() + "px"; - if (_this.style.getMarginBottom()) - newSpan.style.marginBottom = _this.style.getMarginBottom() + "px"; - if (_this.style.getMarginLeft()) - newSpan.style.marginLeft = _this.style.getMarginLeft() + "px"; - if (_this.style.getMarginRight()) - newSpan.style.marginRight = _this.style.getMarginRight() + "px"; - if (_this.style.getWhitespacePre()) - newSpan.style.whiteSpace = 'pre'; - newSpan.appendChild(textNode); - appendToObject.append(newSpan); - } - else { - var newSpan = document.createElement('span'); - newSpan.appendChild(textNode); - appendToObject.append(newSpan); - } - }; - var json = JSON.parse(jsonStr); - if (!json["componentType"]) - json = json[ComponentType[ComponentType.ComponentText]]; - this.text = json['text']; - if (json['style']) - this.style = new StyleText(json['style']); - } - return ComponentText; -}(Component)); -var StyleText = (function (_super) { - __extends(StyleText, _super); - function StyleText(jsonObj) { - var _this = this; - _super.call(this, jsonObj['StyleText']); - this.getFont = function () { return _this.font; }; - this.getFontSize = function () { return _this.fontSize; }; - this.getUnderline = function () { return _this.underline; }; - this.getColor = function () { return _this.color; }; - this.getWhitespacePre = function () { return _this.whitespacePre; }; - var style = jsonObj['StyleText']; - if (style) { - this.font = style['font']; - this.fontSize = style['fontSize']; - this.underline = style['underline']; - this.color = style['color']; - this.whitespacePre = style['whitespacePre']; - } - } - return StyleText; -}(Style)); -//# sourceMappingURL=dl4j-ui.js.map \ No newline at end of file diff --git a/arbiter/arbiter-ui/src/main/resources/deeplearning4jUiAssets/dl4j-ui.js.map b/arbiter/arbiter-ui/src/main/resources/deeplearning4jUiAssets/dl4j-ui.js.map deleted file mode 100644 index 3545aed31..000000000 --- a/arbiter/arbiter-ui/src/main/resources/deeplearning4jUiAssets/dl4j-ui.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"dl4j-ui.js","sourceRoot":"","sources":["../../typescript/org/deeplearning4j/ui/api/Style.ts","../../typescript/org/deeplearning4j/ui/api/ComponentType.ts","../../typescript/org/deeplearning4j/ui/api/Component.ts","../../typescript/org/deeplearning4j/ui/api/Constants.ts","../../typescript/org/deeplearning4j/ui/api/Margin.ts","../../typescript/org/deeplearning4j/ui/api/Renderable.ts","../../typescript/org/deeplearning4j/ui/util/TSUtils.ts","../../typescript/org/deeplearning4j/ui/components/chart/Chart.ts","../../typescript/org/deeplearning4j/ui/components/chart/ChartHistogram.ts","../../typescript/org/deeplearning4j/ui/components/chart/ChartLine.ts","../../typescript/org/deeplearning4j/ui/components/chart/ChartScatter.ts","../../typescript/org/deeplearning4j/ui/components/chart/Legend.ts","../../typescript/org/deeplearning4j/ui/components/chart/ChartStackedArea.ts","../../typescript/org/deeplearning4j/ui/components/chart/ChartTimeline.ts","../../typescript/org/deeplearning4j/ui/components/chart/style/StyleChart.ts","../../typescript/org/deeplearning4j/ui/components/component/ComponentDiv.ts","../../typescript/org/deeplearning4j/ui/components/component/style/StyleDiv.ts","../../typescript/org/deeplearning4j/ui/components/decorator/DecoratorAccordion.ts","../../typescript/org/deeplearning4j/ui/components/decorator/style/StyleAccordion.ts","../../typescript/org/deeplearning4j/ui/components/table/ComponentTable.ts","../../typescript/org/deeplearning4j/ui/components/table/style/StyleTable.ts","../../typescript/org/deeplearning4j/ui/components/text/ComponentText.ts","../../typescript/org/deeplearning4j/ui/components/text/style/StyleText.ts"],"names":[],"mappings":";;;;;AAkBA;IAcI,eAAa,OAAY;QAd7B,iBAmDC;QAzBG,aAAQ,GAAG,cAAM,OAAA,KAAI,CAAC,KAAK,EAAV,CAAU,CAAC;QAC5B,cAAS,GAAG,cAAM,OAAA,KAAI,CAAC,MAAM,EAAX,CAAW,CAAC;QAC9B,iBAAY,GAAG,cAAM,OAAA,KAAI,CAAC,SAAS,EAAd,CAAc,CAAC;QACpC,kBAAa,GAAG,cAAM,OAAA,KAAI,CAAC,UAAU,EAAf,CAAe,CAAC;QACtC,iBAAY,GAAG,cAAM,OAAA,KAAI,CAAC,SAAS,EAAd,CAAc,CAAC;QACpC,oBAAe,GAAG,cAAM,OAAA,KAAI,CAAC,YAAY,EAAjB,CAAiB,CAAC;QAC1C,kBAAa,GAAG,cAAM,OAAA,KAAI,CAAC,UAAU,EAAf,CAAe,CAAC;QACtC,mBAAc,GAAG,cAAM,OAAA,KAAI,CAAC,WAAW,EAAhB,CAAgB,CAAC;QACxC,uBAAkB,GAAG,cAAM,OAAA,KAAI,CAAC,eAAe,EAApB,CAAoB,CAAC;QAnB5C,IAAI,CAAC,KAAK,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;QAC9B,IAAI,CAAC,MAAM,GAAG,OAAO,CAAC,QAAQ,CAAC,CAAC;QAChC,IAAI,CAAC,SAAS,GAAG,OAAO,CAAC,mBAAmB,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC;QACnE,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,mBAAmB,CAAC,OAAO,CAAC,YAAY,CAAC,CAAC,CAAC;QACrE,IAAI,CAAC,SAAS,GAAG,OAAO,CAAC,WAAW,CAAC,CAAC;QACtC,IAAI,CAAC,YAAY,GAAG,OAAO,CAAC,cAAc,CAAC,CAAC;QAC5C,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,YAAY,CAAC,CAAC;QACxC,IAAI,CAAC,WAAW,GAAG,OAAO,CAAC,aAAa,CAAC,CAAC;QAC1C,IAAI,CAAC,eAAe,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAC;IACtD,CAAC;IAaM,gBAAU,GAAjB,UAAkB,CAAQ;QACtB,IAAI,IAAI,GAAW,CAAC,CAAC,GAAG,CAAC,CAAC,YAAY,EAAE,GAAG,CAAC,CAAC,CAAC;QAC9C,IAAI,OAAO,GAAW,CAAC,CAAC,GAAG,CAAC,CAAC,eAAe,EAAE,GAAG,CAAC,CAAC,CAAC;QACpD,IAAI,KAAK,GAAW,CAAC,CAAC,GAAG,CAAC,CAAC,aAAa,EAAE,GAAG,CAAC,CAAC,CAAC;QAChD,IAAI,MAAM,GAAW,CAAC,CAAC,GAAG,CAAC,CAAC,cAAc,EAAE,GAAG,CAAC,CAAC,CAAC;QAGlD,MAAM,CAAC,EAAC,GAAG,EAAE,IAAI;YACb,KAAK,EAAE,MAAM;YACb,MAAM,EAAE,OAAO;YACf,IAAI,EAAE,KAAK;YACX,cAAc,EAAE,CAAC,CAAC,QAAQ,EAAE,GAAG,KAAK,GAAG,MAAM;YAC7C,eAAe,EAAE,CAAC,CAAC,SAAS,EAAE,GAAG,IAAI,GAAG,OAAO,EAAC,CAAC;IACzD,CAAC;IACL,YAAC;AAAD,CAAC,AAnDD,IAmDC;ACjDD,IAAK,aAWJ;AAXD,WAAK,aAAa;IACd,mEAAa,CAAA;IACb,qEAAc,CAAA;IACd,iEAAY,CAAA;IACZ,qEAAc,CAAA;IACd,6EAAkB,CAAA;IAClB,2DAAS,CAAA;IACT,iEAAY,CAAA;IACZ,yEAAgB,CAAA;IAChB,mEAAa,CAAA;IACb,6EAAkB,CAAA;AACtB,CAAC,EAXI,aAAa,KAAb,aAAa,QAWjB;ACTD;IAII,mBAAY,aAA4B;QACpC,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC;IACvC,CAAC;IAEM,oCAAgB,GAAvB;QACI,MAAM,CAAC,IAAI,CAAC,aAAa,CAAC;IAC9B,CAAC;IAKa,sBAAY,GAA1B,UAA2B,OAAe;QAEtC,IAAI,IAAI,GAAQ,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QACpC,IAAI,GAAW,CAAC;QAChB,EAAE,CAAA,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;YAAC,GAAG,GAAG,IAAI,CAAC,eAAe,CAAC,CAAC;QACtD,IAAI;YAAC,GAAG,GAAG,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC;QAIhC,MAAM,CAAA,CAAC,GAAG,CAAC,CAAA,CAAC;YACR,KAAK,aAAa,CAAC,aAAa,CAAC,aAAa,CAAC;gBAC3C,MAAM,CAAC,IAAI,aAAa,CAAC,OAAO,CAAC,CAAC;YAEtC,KAAK,aAAa,CAAC,aAAa,CAAC,cAAc,CAAC;gBAC5C,MAAM,CAAC,IAAI,cAAc,CAAC,OAAO,CAAC,CAAC;YAEvC,KAAK,aAAa,CAAC,aAAa,CAAC,cAAc,CAAC;gBAC5C,MAAM,CAAC,IAAI,cAAc,CAAC,OAAO,CAAC,CAAC;YAEvC,KAAK,aAAa,CAAC,aAAa,CAAC,kBAAkB,CAAC;gBAChD,MAAM,IAAI,KAAK,CAAC,2CAA2C,CAAC,CAAC;YAEjE,KAAK,aAAa,CAAC,aAAa,CAAC,SAAS,CAAC;gBACvC,MAAM,CAAC,IAAI,SAAS,CAAC,OAAO,CAAC,CAAC;YAElC,KAAK,aAAa,CAAC,aAAa,CAAC,YAAY,CAAC;gBAC1C,MAAM,CAAC,IAAI,YAAY,CAAC,OAAO,CAAC,CAAC;YAErC,KAAK,aAAa,CAAC,aAAa,CAAC,gBAAgB,CAAC;gBAC9C,MAAM,CAAC,IAAI,gBAAgB,CAAC,OAAO,CAAC,CAAC;YAEzC,KAAK,aAAa,CAAC,aAAa,CAAC,aAAa,CAAC;gBAC3C,MAAM,CAAC,IAAI,aAAa,CAAC,OAAO,CAAC,CAAC;YAEtC,KAAK,aAAa,CAAC,aAAa,CAAC,kBAAkB,CAAC;gBAChD,MAAM,CAAC,IAAI,kBAAkB,CAAC,OAAO,CAAC,CAAC;YAE3C,KAAK,aAAa,CAAC,aAAa,CAAC,YAAY,CAAC;gBAC1C,MAAM,CAAC,IAAI,YAAY,CAAC,OAAO,CAAC,CAAC;YAErC;gBACI,MAAM,IAAI,KAAK,CAAC,2BAA2B,GAAG,GAAG,GAAG,wBAAwB,GAAG,OAAO,GAAG,IAAI,CAAC,CAAC;QACvG,CAAC;IACL,CAAC;IACL,gBAAC;AAAD,CAAC,AA3DD,IA2DC;AChED;IAAA;IAMA,CAAC;IAJU,yCAA0B,GAAG,GAAG,CAAC;IACjC,uCAAwB,GAAG,GAAG,CAAC;IAC/B,wCAAyB,GAAG,GAAG,CAAC;IAChC,kCAAmB,GAAG,SAAS,CAAC;IAC3C,qBAAC;AAAD,CAAC,AAND,IAMC;AGJD;IAAA;IA6CA,CAAC;IA1CU,WAAG,GAAV,UAAW,KAAiB;QACxB,IAAI,GAAG,GAAW,CAAC,MAAM,CAAC,SAAS,CAAC;QACpC,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;YACpC,GAAG,CAAA,CAAE,IAAI,CAAC,GAAC,CAAC,EAAE,CAAC,GAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;gBACnC,GAAG,GAAG,IAAI,CAAC,GAAG,CAAC,GAAG,EAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;YACpC,CAAC;QACL,CAAC;QACD,MAAM,CAAC,GAAG,CAAC;IACf,CAAC;IAGM,WAAG,GAAV,UAAW,KAAiB;QACxB,IAAI,GAAG,GAAW,MAAM,CAAC,SAAS,CAAC;QACnC,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;YACpC,GAAG,CAAA,CAAE,IAAI,CAAC,GAAC,CAAC,EAAE,CAAC,GAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;gBACnC,GAAG,GAAG,IAAI,CAAC,GAAG,CAAC,GAAG,EAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;YACpC,CAAC;QACL,CAAC;QACD,MAAM,CAAC,GAAG,CAAC;IACf,CAAC;IAGM,2BAAmB,GAA1B,UAA2B,KAAa;QACpC,EAAE,CAAA,CAAC,KAAK,IAAI,IAAI,CAAC;YAAC,MAAM,CAAC,KAAK,CAAC;QAE/B,MAAM,CAAA,CAAC,KAAK,CAAC,WAAW,EAAE,CAAC,CAAA,CAAC;YACxB,KAAK,IAAI;gBACL,MAAM,CAAC,IAAI,CAAC;YAChB,KAAK,SAAS,CAAC;YACf,KAAK,GAAG;gBACJ,MAAM,CAAC,GAAG,CAAC;YACf,KAAK,IAAI;gBACL,MAAM,CAAC,IAAI,CAAC;YAChB,KAAK,IAAI;gBACL,MAAM,CAAC,IAAI,CAAC;YAChB,KAAK,IAAI;gBACL,MAAM,CAAC,IAAI,CAAC;YAChB;gBACI,MAAM,CAAC,KAAK,CAAC;QACrB,CAAC;IAEL,CAAC;IACL,cAAC;AAAD,CAAC,AA7CD,IA6CC;ACxCD;IAA6B,yBAAS;IAiBlC,eAAY,aAA4B,EAAE,OAAe;QACrD,kBAAM,aAAa,CAAC,CAAC;QAErB,IAAI,QAAQ,GAAQ,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QACxC,IAAI,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QAC/B,EAAE,CAAA,CAAC,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;YAAC,IAAI,GAAG,IAAI,CAAC,aAAa,CAAC,aAAa,CAAC,CAAC,CAAC;QAErE,IAAI,CAAC,sBAAsB,GAAG,IAAI,CAAC,wBAAwB,CAAC,CAAC;QAC7D,IAAI,CAAC,oBAAoB,GAAG,IAAI,CAAC,sBAAsB,CAAC,CAAC;QACzD,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,YAAY,CAAC,CAAC;QAErC,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,OAAO,CAAC,CAAC;QAC3B,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC,SAAS,CAAC,CAAC;QAC/B,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC,SAAS,CAAC,CAAC;QAC/B,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC,SAAS,CAAC,CAAC;QAC/B,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC,SAAS,CAAC,CAAC;QAE/B,IAAI,CAAC,uBAAuB,GAAG,IAAI,CAAC,yBAAyB,CAAC,CAAC;QAC/D,IAAI,CAAC,yBAAyB,GAAG,IAAI,CAAC,2BAA2B,CAAC,CAAC;QAEnE,EAAE,CAAA,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;YAAC,IAAI,CAAC,KAAK,GAAG,IAAI,UAAU,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC;IACjE,CAAC;IAED,wBAAQ,GAAR;QACI,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC;IACtB,CAAC;IAEgB,iBAAW,GAA5B,UAA6B,GAAQ,EAAE,KAAa,EAAE,MAAc,EAAE,UAAqB;QACvF,IAAI,IAAI,GAAG,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC;aACxB,IAAI,CAAC,KAAK,CAAC;aACX,IAAI,CAAC,GAAG,EAAE,CAAC,MAAM,CAAC,cAAc,GAAG,CAAC,CAAC,CAAC;aACtC,IAAI,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,MAAM,CAAC,GAAG,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC;aACtC,IAAI,CAAC,aAAa,EAAE,QAAQ,CAAC,CAAC;QAEnC,EAAE,CAAA,CAAC,UAAU,CAAC,CAAA,CAAC;YACX,EAAE,CAAA,CAAC,UAAU,CAAC,OAAO,EAAE,CAAC;gBAAC,IAAI,CAAC,IAAI,CAAC,aAAa,EAAC,UAAU,CAAC,OAAO,CAAC,CAAC;YACrE,EAAE,CAAA,CAAC,UAAU,CAAC,WAAW,EAAE,IAAI,IAAI,CAAC;gBAAC,IAAI,CAAC,IAAI,CAAC,WAAW,EAAC,UAAU,CAAC,WAAW,EAAE,GAAC,IAAI,CAAC,CAAC;YAC1F,EAAE,CAAA,CAAC,UAAU,CAAC,YAAY,EAAE,IAAI,IAAI,CAAC;gBAAC,IAAI,CAAC,KAAK,CAAC,iBAAiB,EAAE,WAAW,CAAC,CAAC;YACjF,EAAE,CAAA,CAAC,UAAU,CAAC,QAAQ,EAAE,CAAC;gBAAC,IAAI,CAAC,KAAK,CAAC,MAAM,EAAC,UAAU,CAAC,QAAQ,CAAC,CAAC;YACjE,IAAI;gBAAC,IAAI,CAAC,KAAK,CAAC,MAAM,EAAC,cAAc,CAAC,mBAAmB,CAAC,CAAC;QAC/D,CAAC;QAAC,IAAI,CAAC,CAAC;YACJ,IAAI,CAAC,KAAK,CAAC,iBAAiB,EAAE,WAAW,CAAC,CAAC;YAC3C,IAAI,CAAC,KAAK,CAAC,MAAM,EAAC,cAAc,CAAC,mBAAmB,CAAC,CAAC;QAC1D,CAAC;IACL,CAAC;IACL,YAAC;AAAD,CAAC,AA9DD,CAA6B,SAAS,GA8DrC;AChED;IAA6B,kCAAK;IAM9B,wBAAY,OAAe;QACvB,kBAAM,aAAa,CAAC,cAAc,EAAE,OAAO,CAAC,CAAC;QAYjD,WAAM,GAAG,UAAC,cAAsB;YAC5B,IAAI,CAAC,GAAe,IAAI,CAAC,QAAQ,EAAE,CAAC;YACpC,IAAI,MAAM,GAAW,KAAK,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC;YAGzC,IAAI,IAAY,CAAC;YACjB,IAAI,IAAY,CAAC;YACjB,IAAI,IAAY,CAAC;YACjB,IAAI,IAAY,CAAC;YACjB,EAAE,CAAA,CAAC,IAAI,CAAC,OAAO,CAAC;gBAAC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC;YACrC,IAAI;gBAAC,IAAI,GAAG,CAAC,IAAI,CAAC,WAAW,GAAG,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC,CAAC;YAC9D,EAAE,CAAA,CAAC,IAAI,CAAC,OAAO,CAAC;gBAAC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC;YACrC,IAAI;gBAAC,IAAI,GAAG,CAAC,IAAI,CAAC,WAAW,GAAG,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC,CAAC;YAC9D,EAAE,CAAA,CAAC,IAAI,CAAC,OAAO,CAAC;gBAAC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC;YACrC,IAAI;gBAAC,IAAI,GAAG,CAAC,CAAC;YACd,EAAE,CAAA,CAAC,IAAI,CAAC,OAAO,CAAC;gBAAC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC;YACrC,IAAI;gBAAC,IAAI,GAAG,CAAC,IAAI,CAAC,OAAO,GAAG,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC;YAGtD,IAAI,MAAM,GAAQ,EAAE,CAAC,KAAK,CAAC,MAAM,EAAE;iBAC9B,MAAM,CAAC,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;iBACpB,KAAK,CAAC,CAAC,CAAC,EAAE,MAAM,CAAC,cAAc,CAAC,CAAC,CAAC;YAEvC,IAAI,KAAK,GAAQ,EAAE,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC,KAAK,CAAC,MAAM,CAAC;iBACvC,MAAM,CAAC,QAAQ,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;YAE/B,EAAE,CAAA,CAAC,IAAI,CAAC,uBAAuB,IAAI,IAAI,CAAC,uBAAuB,GAAG,CAAC,CAAC,CAAA,CAAC;gBACjE,KAAK,CAAC,aAAa,CAAC,CAAC,MAAM,CAAC,eAAe,CAAC,CAAC;YACjD,CAAC;YAED,IAAI,MAAM,GAAQ,EAAE,CAAC,KAAK,CAAC,MAAM,EAAE;iBAC9B,MAAM,CAAC,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC;iBACjB,KAAK,CAAC,CAAC,MAAM,CAAC,eAAe,EAAE,CAAC,CAAC,CAAC,CAAC;YACxC,IAAI,KAAK,GAAQ,EAAE,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC,KAAK,CAAC,MAAM,CAAC;iBACvC,MAAM,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;YAC7B,EAAE,CAAA,CAAC,IAAI,CAAC,yBAAyB,IAAI,IAAI,CAAC,yBAAyB,GAAG,CAAC,CAAC,CAAA,CAAC;gBACrE,KAAK,CAAC,aAAa,CAAC,CAAC,MAAM,CAAC,cAAc,CAAC,CAAC;YAChD,CAAC;YAID,EAAE,CAAA,CAAC,IAAI,CAAC,sBAAsB,KAAK,IAAI,CAAC;gBAAC,KAAK,CAAC,UAAU,CAAC,EAAE,CAAC,CAAC;YAE9D,EAAE,CAAA,CAAC,IAAI,CAAC,oBAAoB,KAAK,IAAI,CAAC;gBAAC,KAAK,CAAC,UAAU,CAAC,EAAE,CAAC,CAAC;YAG5D,IAAI,WAAW,GAAa,IAAI,CAAC,WAAW,CAAC;YAC7C,IAAI,WAAW,GAAa,IAAI,CAAC,WAAW,CAAC;YAC7C,IAAI,OAAO,GAAa,IAAI,CAAC,OAAO,CAAC;YAErC,IAAI,IAAI,GAAQ,WAAW,CAAC,GAAG,CAAC,UAAU,CAAC,EAAE,CAAC;gBAC1C,MAAM,CAAC,EAAC,OAAO,EAAE,WAAW,CAAC,CAAC,CAAC,GAAG,WAAW,CAAC,CAAC,CAAC,EAAE,QAAQ,EAAE,OAAO,CAAC,CAAC,CAAC,EAAE,QAAQ,EAAE,WAAW,CAAC,CAAC,CAAC,EAAC,CAAC;YACtG,CAAC,CAAC,CAAC;YAGH,IAAI,GAAG,GAAG,EAAE,CAAC,MAAM,CAAC,GAAG,GAAG,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;iBAC/C,MAAM,CAAC,KAAK,CAAC;iBACb,KAAK,CAAC,MAAM,EAAE,MAAM,CAAC;iBACrB,IAAI,CAAC,OAAO,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC;iBAC3B,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC,SAAS,EAAE,CAAC;iBAC7B,IAAI,CAAC,SAAS,EAAE,MAAM,CAAC;iBACvB,MAAM,CAAC,GAAG,CAAC;iBACX,IAAI,CAAC,WAAW,EACb,YAAY,GAAG,MAAM,CAAC,IAAI,GAAG,GAAG,GAAG,MAAM,CAAC,GAAG,GAAG,GAAG,CAAC,CAAC;YAI7D,GAAG,CAAC,SAAS,CAAC,MAAM,CAAC;iBAChB,IAAI,CAAC,IAAI,CAAC;iBACV,KAAK,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC;iBACtB,IAAI,CAAC,OAAO,EAAE,KAAK,CAAC;iBACpB,KAAK,CAAC,MAAM,EAAC,WAAW,CAAC;iBACzB,IAAI,CAAC,GAAG,EAAE,UAAS,CAAM,IAAI,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;iBACxD,IAAI,CAAC,OAAO,EAAE,UAAS,CAAM,IAAI,MAAM,CAAC,MAAM,CAAC,IAAI,GAAG,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC;iBACtE,IAAI,CAAC,GAAG,EAAE,UAAS,CAAM,IAAI,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;iBACxD,IAAI,CAAC,QAAQ,EAAE,UAAS,CAAM,IAAI,MAAM,CAAC,MAAM,CAAC,eAAe,GAAG,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;YAG5F,IAAI,SAAS,GAAG,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC;iBAC1B,IAAI,CAAC,OAAO,EAAE,QAAQ,CAAC;iBACvB,IAAI,CAAC,WAAW,EAAE,cAAc,GAAG,MAAM,CAAC,eAAe,GAAG,GAAG,CAAC;iBAChE,KAAK,CAAC,QAAQ,EAAC,MAAM,CAAC;iBACtB,KAAK,CAAC,cAAc,EAAE,CAAC,CAAC,IAAI,IAAI,IAAI,CAAC,CAAC,kBAAkB,EAAE,IAAI,IAAI,GAAG,CAAC,CAAC,kBAAkB,EAAE,GAAG,cAAc,CAAC,yBAAyB,CAAC,CAAC;iBACxI,KAAK,CAAC,MAAM,EAAC,MAAM,CAAC;iBACpB,IAAI,CAAC,KAAK,CAAC,CAAC;YACjB,SAAS,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC,cAAc,EAAC,CAAC,CAAC,CAAC,KAAK,CAAC,MAAM,EAAC,SAAS,CAAC,CAAC;YAE5E,EAAE,CAAA,CAAC,IAAI,CAAC,uBAAuB,IAAI,IAAI,CAAC;gBAAC,SAAS,CAAC,SAAS,CAAC,YAAY,CAAC,CAAC,KAAK,CAAC,EAAC,cAAc,EAAE,IAAI,CAAC,uBAAuB,EAAC,CAAC,CAAC;YAGjI,IAAI,SAAS,GAAG,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC;iBAC1B,IAAI,CAAC,OAAO,EAAE,QAAQ,CAAC;iBACvB,KAAK,CAAC,QAAQ,EAAC,MAAM,CAAC;iBACtB,KAAK,CAAC,cAAc,EAAE,CAAC,CAAC,IAAI,IAAI,IAAI,CAAC,CAAC,kBAAkB,EAAE,IAAI,IAAI,GAAG,CAAC,CAAC,kBAAkB,EAAE,GAAG,cAAc,CAAC,yBAAyB,CAAC,CAAC;iBACxI,KAAK,CAAC,MAAM,EAAC,MAAM,CAAC;iBACpB,IAAI,CAAC,KAAK,CAAC,CAAC;YACjB,SAAS,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC,cAAc,EAAC,CAAC,CAAC,CAAC,KAAK,CAAC,MAAM,EAAC,SAAS,CAAC,CAAC;YAE5E,EAAE,CAAA,CAAC,IAAI,CAAC,yBAAyB,IAAI,IAAI,CAAC;gBAAC,SAAS,CAAC,SAAS,CAAC,YAAY,CAAC,CAAC,KAAK,CAAC,EAAC,cAAc,EAAE,IAAI,CAAC,yBAAyB,EAAC,CAAC,CAAC;YAGrI,EAAE,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC;gBACb,IAAI,UAAqB,CAAC;gBAC1B,EAAE,CAAA,CAAC,IAAI,CAAC,KAAK,CAAC;oBAAC,UAAU,GAAG,IAAI,CAAC,KAAK,CAAC,aAAa,EAAE,CAAC;gBACvD,KAAK,CAAC,WAAW,CAAC,GAAG,EAAE,IAAI,CAAC,KAAK,EAAE,MAAM,EAAE,UAAU,CAAC,CAAC;YAC3D,CAAC;QACL,CAAC,CAAA;QApHG,IAAI,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QAC/B,EAAE,CAAA,CAAC,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;YAAC,IAAI,GAAG,IAAI,CAAC,aAAa,CAAC,aAAa,CAAC,cAAc,CAAC,CAAC,CAAC;QAGpF,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC,aAAa,CAAC,CAAC;QACvC,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC,aAAa,CAAC,CAAC;QACvC,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC,SAAS,CAAC,CAAC;IACnC,CAAC;IA8GL,qBAAC;AAAD,CAAC,AA9HD,CAA6B,KAAK,GA8HjC;AC9HD;IAAwB,6BAAK;IAMzB,mBAAY,OAAe;QACvB,kBAAM,aAAa,CAAC,SAAS,EAAE,OAAO,CAAC,CAAC;QAU5C,WAAM,GAAG,UAAC,cAAsB;YAE5B,IAAI,OAAO,GAAW,CAAC,CAAC,IAAI,CAAC,KAAK,GAAG,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;YAC5D,IAAI,CAAC,GAAe,IAAI,CAAC,QAAQ,EAAE,CAAC;YACpC,IAAI,MAAM,GAAW,KAAK,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC;YAGzC,IAAI,MAAM,GAAmC,EAAE,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,MAAM,CAAC,cAAc,CAAC,CAAC,CAAC;YACjG,IAAI,MAAM,GAAmC,EAAE,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,eAAe,EAAE,CAAC,CAAC,CAAC,CAAC;YAGlG,IAAI,KAAK,GAAG,EAAE,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC,KAAK,CAAC,MAAM,CAAC;iBAClC,MAAM,CAAC,QAAQ,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;YAC/B,EAAE,CAAA,CAAC,IAAI,CAAC,uBAAuB,IAAI,IAAI,IAAI,IAAI,CAAC,uBAAuB,GAAG,CAAC,CAAC,CAAA,CAAC;gBACzE,KAAK,CAAC,aAAa,CAAC,CAAC,MAAM,CAAC,eAAe,CAAC,CAAC;YACjD,CAAC;YAGD,IAAI,KAAK,GAAG,EAAE,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC,KAAK,CAAC,MAAM,CAAC;iBAClC,MAAM,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;YAC7B,EAAE,CAAA,CAAC,IAAI,CAAC,yBAAyB,IAAI,IAAI,IAAI,IAAI,CAAC,yBAAyB,GAAG,CAAC,CAAC,CAAA,CAAC;gBAC7E,KAAK,CAAC,aAAa,CAAC,CAAC,MAAM,CAAC,cAAc,CAAC,CAAC;YAChD,CAAC;YAED,EAAE,CAAA,CAAC,IAAI,CAAC,sBAAsB,KAAK,IAAI,CAAC;gBAAC,KAAK,CAAC,UAAU,CAAC,EAAE,CAAC,CAAC;YAE9D,EAAE,CAAA,CAAC,IAAI,CAAC,oBAAoB,KAAK,IAAI,CAAC;gBAAC,KAAK,CAAC,UAAU,CAAC,EAAE,CAAC,CAAC;YAG5D,IAAI,SAAS,GAAG,EAAE,CAAC,GAAG,CAAC,IAAI,EAAE;iBACxB,CAAC,CAAC,UAAU,CAAM;gBACf,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC;YAC1B,CAAC,CAAC;iBACD,CAAC,CAAC,UAAU,CAAM;gBACf,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC;YAC1B,CAAC,CAAC,CAAC;YAIP,IAAI,GAAG,GAAG,EAAE,CAAC,MAAM,CAAC,GAAG,GAAG,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;iBAC/C,MAAM,CAAC,KAAK,CAAC;iBACb,KAAK,CAAC,cAAc,EAAE,CAAE,CAAC,IAAI,CAAC,CAAC,cAAc,EAAE,GAAG,CAAC,CAAC,cAAc,EAAE,GAAG,cAAc,CAAC,0BAA0B,CAAC,CAAC;iBAClH,KAAK,CAAC,MAAM,EAAE,MAAM,CAAC;iBACrB,IAAI,CAAC,OAAO,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC;iBAC3B,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC,SAAS,EAAE,CAAC;iBAC7B,MAAM,CAAC,GAAG,CAAC;iBACX,IAAI,CAAC,WAAW,EAAE,YAAY,GAAG,MAAM,CAAC,IAAI,GAAG,GAAG,GAAG,MAAM,CAAC,GAAG,GAAG,GAAG,CAAC,CAAC;YAG5E,IAAI,IAAY,CAAC;YACjB,IAAI,IAAY,CAAC;YACjB,IAAI,IAAY,CAAC;YACjB,IAAI,IAAY,CAAC;YACjB,EAAE,CAAA,CAAC,IAAI,CAAC,OAAO,IAAI,IAAI,CAAC;gBAAC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC;YAC7C,IAAI;gBAAC,IAAI,GAAG,CAAC,IAAI,CAAC,KAAK,GAAG,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;YACvD,EAAE,CAAA,CAAC,IAAI,CAAC,OAAO,IAAI,IAAI,CAAC;gBAAC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC;YAC7C,IAAI;gBAAC,IAAI,GAAG,CAAC,IAAI,CAAC,KAAK,GAAG,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;YACvD,EAAE,CAAA,CAAC,IAAI,CAAC,OAAO,IAAI,IAAI,CAAC;gBAAC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC;YAC7C,IAAI;gBAAC,IAAI,GAAG,CAAC,IAAI,CAAC,KAAK,GAAG,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;YACvD,EAAE,CAAA,CAAC,IAAI,CAAC,OAAO,IAAI,IAAI,CAAC;gBAAC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC;YAC7C,IAAI;gBAAC,IAAI,GAAG,CAAC,IAAI,CAAC,KAAK,GAAG,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;YAEvD,MAAM,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC;YAC5B,MAAM,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC;YAG5B,IAAI,YAAY,GAA2B,EAAE,CAAC,KAAK,CAAC,UAAU,EAAE,CAAC;YACjE,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,OAAO,EAAE,CAAC,EAAE,EAAE,CAAC;gBAC/B,IAAI,KAAK,GAAa,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;gBACpC,IAAI,KAAK,GAAa,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;gBAEpC,IAAI,IAAI,GAAU,KAAK,CAAC,GAAG,CAAC,UAAU,CAAC,EAAE,CAAC;oBACtC,MAAM,CAAC,EAAC,MAAM,EAAE,KAAK,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,KAAK,CAAC,CAAC,CAAC,EAAC,CAAC;gBAChD,CAAC,CAAC,CAAC;gBAEH,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC;qBACb,IAAI,CAAC,OAAO,EAAE,MAAM,CAAC;qBACrB,KAAK,CAAC,QAAQ,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,GAAG,YAAY,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;qBAC3F,IAAI,CAAC,GAAG,EAAE,SAAS,CAAC,IAAI,CAAC,CAAC,CAAC;YACpC,CAAC;YAGD,IAAI,SAAS,GAAG,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC;iBAC1B,IAAI,CAAC,OAAO,EAAE,QAAQ,CAAC;iBACvB,IAAI,CAAC,WAAW,EAAE,cAAc,GAAG,MAAM,CAAC,eAAe,GAAG,GAAG,CAAC;iBAChE,KAAK,CAAC,QAAQ,EAAC,MAAM,CAAC;iBACtB,KAAK,CAAC,cAAc,EAAE,CAAC,CAAC,IAAI,IAAI,IAAI,CAAC,CAAC,kBAAkB,EAAE,IAAI,IAAI,GAAG,CAAC,CAAC,kBAAkB,EAAE,GAAG,cAAc,CAAC,yBAAyB,CAAC,CAAC;iBACxI,KAAK,CAAC,MAAM,EAAC,MAAM,CAAC;iBACpB,IAAI,CAAC,KAAK,CAAC,CAAC;YACjB,SAAS,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC,cAAc,EAAC,CAAC,CAAC,CAAC,KAAK,CAAC,MAAM,EAAC,SAAS,CAAC,CAAC;YAE5E,EAAE,CAAA,CAAC,IAAI,CAAC,uBAAuB,IAAI,IAAI,CAAC;gBAAC,SAAS,CAAC,SAAS,CAAC,YAAY,CAAC,CAAC,KAAK,CAAC,EAAC,cAAc,EAAE,IAAI,CAAC,uBAAuB,EAAC,CAAC,CAAC;YAGjI,IAAI,SAAS,GAAG,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC;iBAC1B,IAAI,CAAC,OAAO,EAAE,QAAQ,CAAC;iBACvB,KAAK,CAAC,QAAQ,EAAC,MAAM,CAAC;iBACtB,KAAK,CAAC,cAAc,EAAE,CAAC,CAAC,IAAI,IAAI,IAAI,CAAC,CAAC,kBAAkB,EAAE,IAAI,IAAI,GAAG,CAAC,CAAC,kBAAkB,EAAE,GAAG,cAAc,CAAC,yBAAyB,CAAC,CAAC;iBACxI,KAAK,CAAC,MAAM,EAAC,MAAM,CAAC;iBACpB,IAAI,CAAC,KAAK,CAAC,CAAC;YACjB,SAAS,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC,cAAc,EAAC,CAAC,CAAC,CAAC,KAAK,CAAC,MAAM,EAAC,SAAS,CAAC,CAAC;YAE5E,EAAE,CAAA,CAAC,IAAI,CAAC,yBAAyB,IAAI,IAAI,CAAC;gBAAC,SAAS,CAAC,SAAS,CAAC,YAAY,CAAC,CAAC,KAAK,CAAC,EAAC,cAAc,EAAE,IAAI,CAAC,yBAAyB,EAAC,CAAC,CAAC;YAGrI,EAAE,CAAC,CAAC,IAAI,CAAC,WAAW,IAAI,IAAI,CAAC,UAAU,KAAK,IAAI,CAAC,CAAC,CAAC;gBAC/C,IAAI,WAAW,GAAG,MAAM,CAAC,cAAc,GAAG,CAAC,CAAC;gBAC5C,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,OAAO,EAAE,CAAC,EAAE,EAAE,CAAC;oBAC/B,IAAI,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;oBAC3B,IAAI,OAAO,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;oBAC5B,IAAI,KAAK,GAAG,MAAM,CAAC,MAAM,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC;oBACtC,IAAI,KAAK,GAAG,OAAO,CAAC,OAAO,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC;oBACxC,IAAI,SAAS,GAAG,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC;oBACpC,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC;yBACb,IAAI,CAAC,GAAG,EAAE,CAAC,WAAW,GAAG,CAAC,CAAC,GAAG,CAAC,GAAG,WAAW,CAAC;yBAC9C,IAAI,CAAC,GAAG,EAAE,MAAM,CAAC,eAAe,GAAG,CAAC,MAAM,CAAC,MAAM,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC;yBAC3D,IAAI,CAAC,OAAO,EAAE,QAAQ,CAAC;yBACvB,KAAK,CAAC,MAAM,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,GAAG,YAAY,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;yBACzF,IAAI,CAAC,SAAS,CAAC,CAAC;gBACzB,CAAC;YACL,CAAC;YAGD,EAAE,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC;gBACb,IAAI,UAAqB,CAAC;gBAC1B,EAAE,CAAA,CAAC,IAAI,CAAC,KAAK,CAAC;oBAAC,UAAU,GAAG,IAAI,CAAC,KAAK,CAAC,aAAa,EAAE,CAAC;gBACvD,KAAK,CAAC,WAAW,CAAC,GAAG,EAAE,IAAI,CAAC,KAAK,EAAE,MAAM,EAAE,UAAU,CAAC,CAAC;YAC3D,CAAC;QACL,CAAC,CAAA;QAxIG,IAAI,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QAC/B,EAAE,CAAA,CAAC,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;YAAC,IAAI,GAAG,IAAI,CAAC,aAAa,CAAC,aAAa,CAAC,SAAS,CAAC,CAAC,CAAC;QAE/E,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC;QACvB,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC;QACvB,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC,aAAa,CAAC,CAAC;IAC3C,CAAC;IAmIL,gBAAC;AAAD,CAAC,AAlJD,CAAwB,KAAK,GAkJ5B;AClJD;IAA2B,gCAAK;IAM5B,sBAAY,OAAc;QACtB,kBAAM,aAAa,CAAC,YAAY,EAAE,OAAO,CAAC,CAAC;QAW/C,WAAM,GAAG,UAAC,cAAqB;YAE3B,IAAI,OAAO,GAAU,CAAC,CAAC,IAAI,CAAC,KAAK,GAAG,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;YAC3D,IAAI,CAAC,GAAc,IAAI,CAAC,QAAQ,EAAE,CAAC;YACnC,IAAI,MAAM,GAAU,KAAK,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC;YAGxC,IAAI,MAAM,GAAkC,EAAE,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,MAAM,CAAC,cAAc,CAAC,CAAC,CAAC;YAChG,IAAI,MAAM,GAAkC,EAAE,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,eAAe,EAAE,CAAC,CAAC,CAAC,CAAC;YAGjG,IAAI,KAAK,GAAG,EAAE,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC,KAAK,CAAC,MAAM,CAAC;iBAClC,aAAa,CAAC,CAAC,MAAM,CAAC,eAAe,CAAC;iBACtC,MAAM,CAAC,QAAQ,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;YAC/B,IAAI,KAAK,GAAG,EAAE,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC,KAAK,CAAC,MAAM,CAAC;iBAClC,aAAa,CAAC,CAAC,MAAM,CAAC,cAAc,CAAC;iBACrC,MAAM,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;YAE7B,EAAE,CAAC,CAAC,IAAI,CAAC,sBAAsB,KAAK,IAAI,CAAC;gBAAC,KAAK,CAAC,UAAU,CAAC,EAAE,CAAC,CAAC;YAE/D,EAAE,CAAC,CAAC,IAAI,CAAC,oBAAoB,KAAK,IAAI,CAAC;gBAAC,KAAK,CAAC,UAAU,CAAC,EAAE,CAAC,CAAC;YAI7D,IAAI,GAAG,GAAG,EAAE,CAAC,MAAM,CAAC,GAAG,GAAG,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;iBAC/C,MAAM,CAAC,KAAK,CAAC;iBACb,KAAK,CAAC,cAAc,EAAE,CAAE,CAAC,IAAI,CAAC,CAAC,cAAc,EAAE,GAAG,CAAC,CAAC,cAAc,EAAE,GAAG,CAAC,CAAC,CAAC;iBAC1E,KAAK,CAAC,MAAM,EAAE,MAAM,CAAC;iBACrB,IAAI,CAAC,OAAO,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC;iBAC3B,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC,SAAS,EAAE,CAAC;iBAC7B,IAAI,CAAC,SAAS,EAAE,MAAM,CAAC;iBACvB,MAAM,CAAC,GAAG,CAAC;iBACX,IAAI,CAAC,WAAW,EACb,YAAY,GAAG,MAAM,CAAC,IAAI,GAAG,GAAG,GAAG,MAAM,CAAC,GAAG,GAAG,GAAG,CAAC,CAAC;YAG7D,IAAI,IAAW,CAAC;YAChB,IAAI,IAAW,CAAC;YAChB,IAAI,IAAW,CAAC;YAChB,IAAI,IAAW,CAAC;YAChB,EAAE,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC;gBAAC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC;YACtC,IAAI;gBAAC,IAAI,GAAG,CAAC,IAAI,CAAC,KAAK,GAAG,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;YACvD,EAAE,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC;gBAAC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC;YACtC,IAAI;gBAAC,IAAI,GAAG,CAAC,IAAI,CAAC,KAAK,GAAG,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;YACvD,EAAE,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC;gBAAC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC;YACtC,IAAI;gBAAC,IAAI,GAAG,CAAC,IAAI,CAAC,KAAK,GAAG,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;YACvD,EAAE,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC;gBAAC,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC;YACtC,IAAI;gBAAC,IAAI,GAAG,CAAC,IAAI,CAAC,KAAK,GAAG,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;YAEvD,MAAM,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC;YAC5B,MAAM,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC;YAG5B,IAAI,YAAY,GAA0B,EAAE,CAAC,KAAK,CAAC,UAAU,EAAE,CAAC;YAChE,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,OAAO,EAAE,CAAC,EAAE,EAAE,CAAC;gBAC/B,IAAI,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;gBAC1B,IAAI,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;gBAE1B,IAAI,IAAI,GAAG,KAAK,CAAC,GAAG,CAAC,UAAU,CAAC,EAAE,CAAC;oBAC/B,MAAM,CAAC,EAAC,MAAM,EAAE,KAAK,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,KAAK,CAAC,CAAC,CAAC,EAAC,CAAC;gBAChD,CAAC,CAAC,CAAC;gBAEH,GAAG,CAAC,SAAS,CAAC,QAAQ,CAAC;qBAClB,IAAI,CAAC,IAAI,CAAC;qBACV,KAAK,EAAE;qBACP,MAAM,CAAC,QAAQ,CAAC;qBAChB,KAAK,CAAC,MAAM,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,GAAG,YAAY,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;qBACzF,IAAI,CAAC,GAAG,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,YAAY,EAAE,GAAG,CAAC,CAAC,YAAY,EAAE,GAAG,cAAc,CAAC,wBAAwB,CAAC,CAAC;qBAC/F,IAAI,CAAC,IAAI,EAAE,UAAU,CAAC;oBACnB,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC;gBAC7B,CAAC,CAAC;qBACD,IAAI,CAAC,IAAI,EAAE,UAAU,CAAC;oBACnB,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC;gBAC7B,CAAC,CAAC,CAAC;YACX,CAAC;YAGD,IAAI,SAAS,GAAG,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC;iBAC1B,IAAI,CAAC,OAAO,EAAE,QAAQ,CAAC;iBACvB,IAAI,CAAC,WAAW,EAAE,cAAc,GAAG,MAAM,CAAC,eAAe,GAAG,GAAG,CAAC;iBAChE,KAAK,CAAC,QAAQ,EAAE,MAAM,CAAC;iBACvB,KAAK,CAAC,cAAc,EAAE,CAAC,CAAC,IAAI,IAAI,IAAI,CAAC,CAAC,kBAAkB,EAAE,IAAI,IAAI,GAAG,CAAC,CAAC,kBAAkB,EAAE,GAAG,cAAc,CAAC,yBAAyB,CAAC,CAAC;iBACxI,KAAK,CAAC,MAAM,EAAE,MAAM,CAAC;iBACrB,IAAI,CAAC,KAAK,CAAC,CAAC;YACjB,SAAS,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC,cAAc,EAAC,CAAC,CAAC,CAAC,KAAK,CAAC,MAAM,EAAC,SAAS,CAAC,CAAC;YAE5E,EAAE,CAAC,CAAC,IAAI,CAAC,uBAAuB,IAAI,IAAI,CAAC;gBAAC,SAAS,CAAC,SAAS,CAAC,YAAY,CAAC,CAAC,KAAK,CAAC,EAAC,cAAc,EAAE,IAAI,CAAC,uBAAuB,EAAC,CAAC,CAAC;YAGlI,IAAI,SAAS,GAAG,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC;iBAC1B,IAAI,CAAC,OAAO,EAAE,QAAQ,CAAC;iBACvB,KAAK,CAAC,QAAQ,EAAE,MAAM,CAAC;iBACvB,KAAK,CAAC,cAAc,EAAE,CAAC,CAAC,IAAI,IAAI,IAAI,CAAC,CAAC,kBAAkB,EAAE,IAAI,IAAI,GAAG,CAAC,CAAC,kBAAkB,EAAE,GAAG,cAAc,CAAC,yBAAyB,CAAC,CAAC;iBACxI,KAAK,CAAC,MAAM,EAAE,MAAM,CAAC;iBACrB,IAAI,CAAC,KAAK,CAAC,CAAC;YACjB,SAAS,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC,cAAc,EAAC,CAAC,CAAC,CAAC,KAAK,CAAC,MAAM,EAAC,SAAS,CAAC,CAAC;YAE5E,EAAE,CAAC,CAAC,IAAI,CAAC,yBAAyB,IAAI,IAAI,CAAC;gBAAC,SAAS,CAAC,SAAS,CAAC,YAAY,CAAC,CAAC,KAAK,CAAC,EAAC,cAAc,EAAE,IAAI,CAAC,yBAAyB,EAAC,CAAC,CAAC;YAGtI,EAAE,CAAC,CAAC,IAAI,CAAC,WAAW,IAAI,IAAI,CAAC,UAAU,KAAK,IAAI,CAAC,CAAC,CAAC;gBAC/C,IAAI,WAAW,GAAG,MAAM,CAAC,cAAc,GAAG,CAAC,CAAC;gBAC5C,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,OAAO,EAAE,CAAC,EAAE,EAAE,CAAC;oBAC/B,IAAI,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;oBAC3B,IAAI,OAAO,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;oBAC5B,IAAI,KAAK,GAAG,MAAM,CAAC,MAAM,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC;oBACtC,IAAI,KAAK,GAAG,OAAO,CAAC,OAAO,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC;oBACxC,IAAI,SAAS,CAAC;oBACd,EAAE,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC,KAAK,CAAC;wBAAC,SAAS,GAAG,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,GAAG,YAAY,CAAC;oBACrE,IAAI;wBAAC,SAAS,GAAG,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,GAAG,IAAI,GAAG,KAAK,CAAC,WAAW,CAAC,CAAC,CAAC,GAAG,GAAG,GAAG,KAAK,CAAC,WAAW,CAAC,CAAC,CAAC,GAAG,GAAG,CAAC;oBACtG,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC;yBACb,IAAI,CAAC,GAAG,EAAE,CAAC,WAAW,GAAG,CAAC,CAAC,GAAG,CAAC,GAAG,WAAW,CAAC;yBAC9C,IAAI,CAAC,GAAG,EAAE,MAAM,CAAC,eAAe,GAAG,CAAC,MAAM,CAAC,MAAM,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC;yBAC3D,IAAI,CAAC,OAAO,EAAE,QAAQ,CAAC;yBACvB,KAAK,CAAC,MAAM,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,GAAG,YAAY,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;yBACzF,IAAI,CAAC,SAAS,CAAC,CAAC;gBACzB,CAAC;YACL,CAAC;YAGD,EAAE,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC;gBACb,IAAI,UAAqB,CAAC;gBAC1B,EAAE,CAAA,CAAC,IAAI,CAAC,KAAK,CAAC;oBAAC,UAAU,GAAG,IAAI,CAAC,KAAK,CAAC,aAAa,EAAE,CAAC;gBACvD,KAAK,CAAC,WAAW,CAAC,GAAG,EAAE,IAAI,CAAC,KAAK,EAAE,MAAM,EAAE,UAAU,CAAC,CAAC;YAC3D,CAAC;QACL,CAAC,CAAA;QAtIG,IAAI,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QAC/B,EAAE,CAAA,CAAC,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;YAAC,IAAI,GAAG,IAAI,CAAC,aAAa,CAAC,aAAa,CAAC,YAAY,CAAC,CAAC,CAAC;QAElF,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC;QACvB,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC;QACvB,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC,aAAa,CAAC,CAAC;IAC3C,CAAC;IAiIL,mBAAC;AAAD,CAAC,AAhJD,CAA2B,KAAK,GAgJ/B;ACpJD;IAAA;IAiEA,CAAC;IA9DkB,cAAO,GAAW,EAAE,CAAC;IACrB,cAAO,GAAW,EAAE,CAAC;IACrB,cAAO,GAAW,CAAC,CAAC;IACpB,iBAAU,GAAW,EAAE,CAAC;IACxB,cAAO,GAAW,EAAE,CAAC;IACrB,gBAAS,GAAW,SAAS,CAAC;IAC9B,oBAAa,GAAW,IAAI,CAAC;IAC7B,wBAAiB,GAAW,SAAS,CAAC;IAG9C,eAAQ,GAAG,CAAC,UAAS,CAAM;QAE9B,IAAI,GAAG,GAAG,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC,QAAQ,CAAC,wBAAwB,CAAC,CAAC,CAAC;QAC1D,IAAI,SAAS,GAAG,CAAC,CAAC,SAAS,CAAC,YAAY,CAAC,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC;QACvD,IAAI,WAAW,GAAG,CAAC,CAAC,SAAS,CAAC,gBAAgB,CAAC,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC;QAE7D,SAAS,CAAC,KAAK,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,OAAO,EAAC,WAAW,CAAC,CAAC;QAC3D,WAAW,CAAC,KAAK,EAAE,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,IAAI,CAAC,OAAO,EAAC,eAAe,CAAC,CAAC;QAE9D,IAAI,cAAc,GAAU,EAAE,CAAC;QAC/B,GAAG,CAAC,SAAS,CAAC,eAAe,CAAC,CAAC,IAAI,CAAC;YAChC,IAAI,OAAO,GAAG,EAAE,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC;YAC9B,cAAc,CAAC,IAAI,CAAC;gBAChB,KAAK,EAAE,OAAO,CAAC,IAAI,CAAC,aAAa,CAAC;gBAClC,KAAK,EAAE,OAAO,CAAC,KAAK,CAAC,MAAM,CAAC;aAC/B,CAAC,CAAC;QACP,CAAC,CAAC,CAAC;QAIH,WAAW,CAAC,SAAS,CAAC,MAAM,CAAC;aACxB,IAAI,CAAC,cAAc,EAAC,UAAS,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,KAAK,CAAA,CAAA,CAAC,CAAC;aAClD,IAAI,CAAC,UAAS,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC,CAAA,CAAA,CAAC,CAAC;aAC7C,IAAI,CAAC,UAAS,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,CAAC,MAAM,EAAE,CAAA,CAAA,CAAC,CAAC;aACtC,IAAI,CAAC,GAAG,EAAC,CAAC,CAAC;aACX,IAAI,CAAC,GAAG,EAAC,UAAS,CAAC,EAAC,CAAC,IAAI,MAAM,CAAC,CAAC,GAAC,MAAM,CAAC,UAAU,GAAC,MAAM,CAAC,OAAO,GAAC,IAAI,CAAA,CAAA,CAAC,CAAC;aACzE,IAAI,CAAC,OAAO,EAAC,MAAM,CAAC,OAAO,CAAC;aAC5B,IAAI,CAAC,QAAQ,EAAC,MAAM,CAAC,OAAO,CAAC;aAE7B,KAAK,CAAC,MAAM,EAAC,UAAS,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,KAAK,CAAA,CAAA,CAAC,CAAC,CAAC;QAGjD,WAAW,CAAC,SAAS,CAAC,MAAM,CAAC;aACxB,IAAI,CAAC,cAAc,EAAC,UAAS,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,KAAK,CAAA,CAAA,CAAC,CAAC;aAClD,IAAI,CAAC,UAAS,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC,CAAA,CAAA,CAAC,CAAC;aAC7C,IAAI,CAAC,UAAS,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,CAAC,MAAM,EAAE,CAAA,CAAA,CAAC,CAAC;aACtC,IAAI,CAAC,GAAG,EAAC,UAAS,CAAC,EAAC,CAAC,IAAI,MAAM,CAAC,CAAC,GAAC,MAAM,CAAC,UAAU,GAAG,IAAI,CAAA,CAAA,CAAC,CAAC;aAC5D,IAAI,CAAC,GAAG,EAAC,CAAC,MAAM,CAAC,OAAO,GAAG,MAAM,CAAC,OAAO,CAAC,GAAG,IAAI,CAAC;aAClD,IAAI,CAAC,UAAS,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,KAAK,CAAA,CAAA,CAAC,CAAC,CAAC;QAGzC,IAAI,iBAAiB,GAAQ,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,OAAO,EAAE,CAAC;QACzD,SAAS,CAAC,IAAI,CAAC,GAAG,EAAC,CAAC,iBAAiB,CAAC,CAAC,GAAC,MAAM,CAAC,OAAO,CAAC,CAAC;aACnD,IAAI,CAAC,GAAG,EAAC,CAAC,iBAAiB,CAAC,CAAC,GAAC,MAAM,CAAC,OAAO,CAAC,CAAC;aAC9C,IAAI,CAAC,QAAQ,EAAC,CAAC,iBAAiB,CAAC,MAAM,GAAC,CAAC,GAAC,MAAM,CAAC,OAAO,CAAC,CAAC;aAC1D,IAAI,CAAC,OAAO,EAAC,CAAC,iBAAiB,CAAC,KAAK,GAAC,CAAC,GAAC,MAAM,CAAC,OAAO,CAAC,CAAC;aACxD,KAAK,CAAC,MAAM,EAAC,MAAM,CAAC,SAAS,CAAC;aAC9B,KAAK,CAAC,QAAQ,EAAC,MAAM,CAAC,iBAAiB,CAAC;aACxC,KAAK,CAAC,SAAS,EAAC,MAAM,CAAC,aAAa,CAAC,CAAC;QAE3C,GAAG,CAAC,SAAS,CAAC,SAAS,CAAC,CAAC,IAAI,CAAC,WAAW,EAAC,YAAY,GAAG,MAAM,CAAC,OAAO,GAAG,GAAG,GAAG,MAAM,CAAC,OAAO,GAAG,GAAG,CAAC,CAAC;IAC1G,CAAC,CAAC,CAAC;IACP,aAAC;AAAD,CAAC,AAjED,IAiEC;AC1DD;IAA+B,oCAAK;IAKhC,0BAAY,OAAe;QACvB,kBAAM,aAAa,CAAC,gBAAgB,EAAE,OAAO,CAAC,CAAC;QAYnD,WAAM,GAAG,UAAC,cAAsB;YAE5B,IAAI,OAAO,GAAW,CAAC,CAAC,IAAI,CAAC,KAAK,GAAG,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;YAC5D,IAAI,CAAC,GAAe,IAAI,CAAC,QAAQ,EAAE,CAAC;YACpC,IAAI,MAAM,GAAW,KAAK,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC;YAGzC,IAAI,MAAM,GAAmC,EAAE,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,MAAM,CAAC,cAAc,CAAC,CAAC,CAAC;YACjG,IAAI,MAAM,GAAmC,EAAE,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,eAAe,EAAE,CAAC,CAAC,CAAC,CAAC;YAGlG,IAAI,KAAK,GAAG,EAAE,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC,KAAK,CAAC,MAAM,CAAC;iBAClC,MAAM,CAAC,QAAQ,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;YAC/B,EAAE,CAAA,CAAC,IAAI,CAAC,uBAAuB,IAAI,IAAI,IAAI,IAAI,CAAC,uBAAuB,GAAG,CAAC,CAAC,CAAA,CAAC;gBACzE,KAAK,CAAC,aAAa,CAAC,CAAC,MAAM,CAAC,eAAe,CAAC,CAAC;YACjD,CAAC;YAGD,IAAI,KAAK,GAAG,EAAE,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC,KAAK,CAAC,MAAM,CAAC;iBAClC,MAAM,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;YAC7B,EAAE,CAAA,CAAC,IAAI,CAAC,yBAAyB,IAAI,IAAI,IAAI,IAAI,CAAC,yBAAyB,GAAG,CAAC,CAAC,CAAA,CAAC;gBAC7E,KAAK,CAAC,aAAa,CAAC,CAAC,MAAM,CAAC,cAAc,CAAC,CAAC;YAChD,CAAC;YAED,EAAE,CAAA,CAAC,IAAI,CAAC,sBAAsB,KAAK,IAAI,CAAC;gBAAC,KAAK,CAAC,UAAU,CAAC,EAAE,CAAC,CAAC;YAE9D,EAAE,CAAA,CAAC,IAAI,CAAC,oBAAoB,KAAK,IAAI,CAAC;gBAAC,KAAK,CAAC,UAAU,CAAC,EAAE,CAAC,CAAC;YAE5D,IAAI,IAAI,GAAU,EAAE,CAAC;YACrB,GAAG,CAAA,CAAC,IAAI,CAAC,GAAC,CAAC,EAAE,CAAC,GAAC,IAAI,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;gBACpC,IAAI,GAAG,GAAG,EAAE,CAAC;gBACb,GAAG,CAAA,CAAE,IAAI,CAAC,GAAC,CAAC,EAAE,CAAC,GAAC,IAAI,CAAC,MAAM,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;oBACtC,GAAG,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;oBACvC,GAAG,CAAC,QAAQ,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;gBAClC,CAAC;gBACD,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;YACnB,CAAC;YAED,IAAI,IAAI,GAAG,EAAE,CAAC,GAAG,CAAC,IAAI,EAAE;iBACnB,CAAC,CAAC,UAAS,CAAM,IAAI,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;iBAChD,EAAE,CAAC,UAAS,CAAM,IAAI,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC;iBAC7C,EAAE,CAAC,UAAS,CAAM,IAAI,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;YAEzD,IAAI,KAAK,GAAG,EAAE,CAAC,MAAM,CAAC,KAAK,EAAE;iBACxB,MAAM,CAAC,UAAS,CAAM,IAAI,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;YAEnD,IAAI,GAAG,GAAG,EAAE,CAAC,MAAM,CAAC,GAAG,GAAG,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC;iBAC7D,IAAI,CAAC,OAAO,EAAE,MAAM,CAAC,cAAc,GAAG,MAAM,CAAC,IAAI,GAAG,MAAM,CAAC,KAAK,CAAC;iBACjE,IAAI,CAAC,QAAQ,EAAE,MAAM,CAAC,eAAe,GAAG,MAAM,CAAC,GAAG,GAAG,MAAM,CAAC,MAAM,CAAC;iBACnE,MAAM,CAAC,GAAG,CAAC;iBACX,IAAI,CAAC,WAAW,EAAE,YAAY,GAAG,MAAM,CAAC,IAAI,GAAG,GAAG,GAAG,MAAM,CAAC,GAAG,GAAG,GAAG,CAAC,CAAC;YAE5E,IAAI,KAAK,GAAQ,EAAE,CAAC,KAAK,CAAC,UAAU,EAAE,CAAC;YACvC,KAAK,CAAC,MAAM,CAAC,EAAE,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,UAAU,GAAG;gBAC9C,MAAM,CAAC,GAAG,KAAK,QAAQ,CAAC;YAC5B,CAAC,CAAC,CAAC,CAAC;YAEJ,IAAI,QAAQ,GAAG,KAAK,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,UAAU,IAAI;gBAClD,MAAM,CAAC;oBACH,IAAI,EAAE,IAAI;oBACV,MAAM,EAAE,IAAI,CAAC,GAAG,CAAC,UAAU,CAAC;wBACxB,MAAM,CAAC,EAAC,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,EAAE,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAC,CAAC;oBAC9C,CAAC,CAAC;iBACL,CAAC;YACN,CAAC,CAAC,CAAC,CAAC;YAGJ,IAAI,IAAI,GAAG,EAAE,CAAC,GAAG,CAAC,IAAI,EAAE,UAAU,CAAC;gBAC/B,IAAI,IAAI,GAAG,EAAE,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,UAAU,GAAG;oBACnC,MAAM,CAAC,GAAG,KAAK,QAAQ,GAAG,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC,CAAA;gBACxC,CAAC,CAAC,CAAC;gBACH,MAAM,CAAC,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;YACxB,CAAC,CAAC,CAAC;YAGH,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC,MAAM,CAAC,IAAI,EAAE,UAAU,CAAC;gBACrC,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC;YACpB,CAAC,CAAC,CAAC,CAAC;YAEJ,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC,CAAC;YAEzB,IAAI,OAAO,GAAG,GAAG,CAAC,SAAS,CAAC,UAAU,CAAC;iBAClC,IAAI,CAAC,QAAQ,CAAC;iBACd,KAAK,EAAE,CAAC,MAAM,CAAC,GAAG,CAAC;iBACnB,IAAI,CAAC,OAAO,EAAE,SAAS,CAAC,CAAC;YAE9B,IAAI,UAAU,GAAG,IAAI,CAAC,MAAM,CAAC;YAE7B,IAAI,YAAY,GAA2B,EAAE,CAAC,KAAK,CAAC,UAAU,EAAE,CAAC;YACjE,OAAO,CAAC,MAAM,CAAC,MAAM,CAAC;iBACjB,IAAI,CAAC,OAAO,EAAE,MAAM,CAAC;iBACrB,IAAI,CAAC,aAAa,EAAC,UAAS,CAAM,IAAI,MAAM,CAAC,CAAC,CAAC,IAAI,CAAA,CAAA,CAAC,CAAC;iBACrD,IAAI,CAAC,GAAG,EAAE,UAAU,CAAM;gBACvB,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC;YAC1B,CAAC,CAAC;iBACD,KAAK,CAAC,MAAM,EAAE,UAAS,CAAM;gBAC1B,EAAE,CAAA,CAAC,CAAC,IAAI,CAAC,CAAC,cAAc,CAAC,UAAU,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAAA,CAAC;oBAClD,MAAM,CAAC,CAAC,CAAC,cAAc,CAAC,UAAU,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC;gBACxD,CAAC;gBAAC,IAAI,CAAA,CAAC;oBACH,MAAM,CAAC,YAAY,CAAC,MAAM,CAAC,UAAU,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAAA;gBAC3D,CAAC;YACL,CAAC,CAAC;iBACD,KAAK,CAAC,EAAC,cAAc,EAAE,KAAK,EAAC,CAAC,CAAC;YAGpC,IAAI,SAAS,GAAG,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC;iBAC1B,IAAI,CAAC,OAAO,EAAE,QAAQ,CAAC;iBACvB,KAAK,CAAC,QAAQ,EAAC,MAAM,CAAC;iBACtB,KAAK,CAAC,cAAc,EAAE,CAAC,CAAC,IAAI,IAAI,IAAI,CAAC,CAAC,kBAAkB,EAAE,IAAI,IAAI,GAAG,CAAC,CAAC,kBAAkB,EAAE,GAAG,cAAc,CAAC,yBAAyB,CAAC,CAAC;iBACxI,KAAK,CAAC,MAAM,EAAC,MAAM,CAAC;iBACpB,IAAI,CAAC,WAAW,EAAE,cAAc,GAAG,MAAM,CAAC,eAAe,GAAG,GAAG,CAAC;iBAChE,IAAI,CAAC,KAAK,CAAC,CAAC;YACjB,SAAS,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC,cAAc,EAAC,CAAC,CAAC,CAAC,KAAK,CAAC,MAAM,EAAC,SAAS,CAAC,CAAC;YAG5E,IAAI,SAAS,GAAG,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC;iBAC1B,IAAI,CAAC,OAAO,EAAE,QAAQ,CAAC;iBACvB,KAAK,CAAC,QAAQ,EAAC,MAAM,CAAC;iBACtB,KAAK,CAAC,cAAc,EAAE,CAAC,CAAC,IAAI,IAAI,IAAI,CAAC,CAAC,kBAAkB,EAAE,IAAI,IAAI,GAAG,CAAC,CAAC,kBAAkB,EAAE,GAAG,cAAc,CAAC,yBAAyB,CAAC,CAAC;iBACxI,KAAK,CAAC,MAAM,EAAC,MAAM,CAAC;iBACpB,IAAI,CAAC,KAAK,CAAC,CAAC;YACjB,SAAS,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC,cAAc,EAAC,CAAC,CAAC,CAAC,KAAK,CAAC,MAAM,EAAC,SAAS,CAAC,CAAC;YAG5E,EAAE,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC;gBACb,IAAI,UAAqB,CAAC;gBAC1B,EAAE,CAAA,CAAC,IAAI,CAAC,KAAK,CAAC;oBAAC,UAAU,GAAG,IAAI,CAAC,KAAK,CAAC,aAAa,EAAE,CAAC;gBACvD,KAAK,CAAC,WAAW,CAAC,GAAG,EAAE,IAAI,CAAC,KAAK,EAAE,MAAM,EAAE,UAAU,CAAC,CAAC;YAC3D,CAAC;YAGD,IAAI,MAAM,GAAQ,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC;iBAC5B,IAAI,CAAC,OAAO,EAAC,QAAQ,CAAC;iBACtB,IAAI,CAAC,WAAW,EAAC,kBAAkB,CAAC;iBACpC,KAAK,CAAC,WAAW,EAAC,MAAM,CAAC;iBACzB,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;QAC/B,CAAC,CAAA;QAlJG,IAAI,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QAC/B,EAAE,CAAA,CAAC,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;YAAC,IAAI,GAAG,IAAI,CAAC,aAAa,CAAC,aAAa,CAAC,gBAAgB,CAAC,CAAC,CAAC;QAGtF,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC;QACvB,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC;QACvB,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,QAAQ,CAAC,CAAC;IACjC,CAAC;IA4IL,uBAAC;AAAD,CAAC,AA3JD,CAA+B,KAAK,GA2JnC;AC9JD;IAA4B,iCAAK;IAgC7B,uBAAY,OAAc;QACtB,kBAAM,aAAa,CAAC,aAAa,EAAE,OAAO,CAAC,CAAC;QAUhD,WAAM,GAAG,UAAC,cAAqB;YAC3B,IAAI,QAAQ,GAAG,IAAI,CAAC;YACpB,IAAI,CAAC,GAAc,IAAI,CAAC,QAAQ,EAAE,CAAC;YACnC,IAAI,MAAM,GAAU,KAAK,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC;YAGxC,IAAI,CAAC,QAAQ,GAAG,EAAE,CAAC;YACnB,IAAI,KAAK,GAAG,CAAC,CAAC;YACd,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,IAAI,CAAC,QAAQ,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;gBAC5C,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;oBAC/C,IAAI,GAAG,GAAG,EAAE,CAAC;oBACb,GAAG,CAAC,OAAO,CAAC,GAAG,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC;oBAClD,GAAG,CAAC,KAAK,CAAC,GAAG,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC;oBAC9C,GAAG,CAAC,IAAI,CAAC,GAAG,KAAK,EAAE,CAAC;oBACpB,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;oBAChB,GAAG,CAAC,OAAO,CAAC,GAAG,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC;oBAC5C,GAAG,CAAC,OAAO,CAAC,GAAG,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC;oBACjD,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;gBAC5B,CAAC;YACL,CAAC;YAED,IAAI,CAAC,KAAK,GAAG,EAAE,CAAC;YAChB,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;gBAC7C,IAAI,GAAG,GAAG,EAAE,CAAC;gBACb,GAAG,CAAC,OAAO,CAAC,GAAG,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;gBACjC,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;gBACd,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;YACzB,CAAC;YAID,IAAI,GAAG,GAAG,EAAE,CAAC,MAAM,CAAC,GAAG,GAAG,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;iBAC/C,MAAM,CAAC,KAAK,CAAC;iBACb,KAAK,CAAC,cAAc,EAAE,CAAE,CAAC,IAAI,CAAC,CAAC,cAAc,EAAE,GAAG,CAAC,CAAC,cAAc,EAAE,GAAG,cAAc,CAAC,0BAA0B,CAAC,CAAC;iBAClH,KAAK,CAAC,MAAM,EAAE,MAAM,CAAC;iBACrB,IAAI,CAAC,OAAO,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC;iBAC3B,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC,SAAS,EAAE,CAAC;iBAC7B,MAAM,CAAC,GAAG,CAAC,CAAC;YAEjB,IAAI,eAAe,GAAG,CAAC,CAAC,SAAS,EAAE,GAAG,MAAM,CAAC,GAAG,GAAG,MAAM,CAAC,MAAM,CAAC;YACjE,IAAI,cAAc,GAAG,CAAC,CAAC,QAAQ,EAAE,GAAG,MAAM,CAAC,IAAI,GAAG,MAAM,CAAC,KAAK,CAAC;YAC/D,IAAI,UAAU,GAAG,IAAI,CAAC,SAAS,CAAC,MAAM,GAAG,aAAa,CAAC,mBAAmB,CAAC;YAC3E,IAAI,UAAU,GAAG,CAAC,CAAC,SAAS,EAAE,GAAG,UAAU,GAAG,MAAM,CAAC,GAAG,GAAG,MAAM,CAAC,MAAM,GAAG,EAAE,CAAC;YAE9E,IAAI,OAAO,GAAU,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,QAAQ,EAAE,UAAU,CAAK,IAAI,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC;YACjF,IAAI,OAAO,GAAU,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,QAAQ,EAAE,UAAU,CAAK,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC;YAC/E,IAAI,CAAC,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,KAAK,EAAE;iBACnB,MAAM,CAAC,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;iBAC1B,KAAK,CAAC,CAAC,CAAC,EAAE,cAAc,CAAC,CAAC,CAAC;YAChC,IAAI,CAAC,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,KAAK,EAAE,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,cAAc,CAAC,CAAC,CAAC;YAErD,IAAI,CAAC,EAAE,GAAG,EAAE,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,UAAU,CAAC,CAAC,CAAC;YACtF,IAAI,CAAC,EAAE,GAAG,EAAE,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,UAAU,CAAC,CAAC,CAAC;YAGtF,IAAI,CAAC,IAAI,GAAG,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,MAAM,CAAC,UAAU,CAAC;iBAC5C,IAAI,CAAC,IAAI,EAAE,MAAM,CAAC;iBAClB,MAAM,CAAC,MAAM,CAAC;iBACd,IAAI,CAAC,OAAO,EAAE,cAAc,CAAC;iBAC7B,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC,SAAS,EAAE,GAAG,GAAG,CAAC,CAAC;YAEzC,IAAI,CAAC,QAAQ,GAAG,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC;iBAC1B,IAAI,CAAC,WAAW,EAAE,YAAY,GAAG,MAAM,CAAC,IAAI,GAAG,GAAG,GAAG,MAAM,CAAC,GAAG,GAAG,GAAG,CAAC;iBACtE,IAAI,CAAC,OAAO,EAAE,cAAc,CAAC;iBAC7B,IAAI,CAAC,QAAQ,EAAE,UAAU,CAAC;iBAC1B,IAAI,CAAC,WAAW,EAAE,MAAM,CAAC;iBACzB,IAAI,CAAC,MAAM,EAAE,YAAY,CAAC,CAAC;YAEhC,IAAI,CAAC,QAAQ,GAAG,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC;iBAC1B,IAAI,CAAC,WAAW,EAAE,YAAY,GAAG,MAAM,CAAC,IAAI,GAAG,GAAG,GAAG,CAAC,UAAU,GAAG,MAAM,CAAC,GAAG,GAAG,EAAE,CAAC,GAAG,GAAG,CAAC;iBAC1F,IAAI,CAAC,OAAO,EAAE,cAAc,CAAC;iBAC7B,IAAI,CAAC,QAAQ,EAAE,UAAU,CAAC;iBAC1B,IAAI,CAAC,WAAW,EAAE,MAAM,CAAC;iBACzB,IAAI,CAAC,MAAM,EAAE,YAAY,CAAC,CAAC;YAGhC,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,SAAS,CAAC,YAAY,CAAC;iBAC5C,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC;iBAChB,KAAK,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC;iBACtB,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;iBACb,IAAI,CAAC,IAAI,EAAE,UAAU,CAAK;gBACvB,MAAM,CAAC,EAAE,CAAC,KAAK,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,GAAG,CAAC;YAC7C,CAAC,CAAC;iBACD,IAAI,CAAC,IAAI,EAAE,cAAc,CAAC;iBAC1B,IAAI,CAAC,IAAI,EAAE,UAAU,CAAK;gBACvB,MAAM,CAAC,EAAE,CAAC,KAAK,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,GAAG,CAAC;YAC7C,CAAC,CAAC;iBACD,IAAI,CAAC,QAAQ,EAAE,WAAW,CAAC;iBAC3B,IAAI,CAAC,cAAc,EAAE,CAAC,CAAC,CAAC;YAG7B,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,SAAS,CAAC,WAAW,CAAC;iBAC3C,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC;iBAChB,KAAK,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC;iBACtB,IAAI,CAAC,UAAU,CAAK;gBACjB,EAAE,CAAA,CAAC,CAAC,CAAC,KAAK,CAAC;oBAAC,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC;gBAC3B,MAAM,CAAC,EAAE,CAAC;YACd,CAAC,CAAC;iBACD,IAAI,CAAC,GAAG,EAAE,CAAC,EAAE,CAAC;iBACd,IAAI,CAAC,GAAG,EAAE,UAAU,CAAK;gBACtB,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,GAAG,EAAE,CAAC,CAAC;YAClC,CAAC,CAAC;iBACD,IAAI,CAAC,aAAa,EAAE,KAAK,CAAC;iBAC1B,IAAI,CAAC,MAAM,EAAC,gBAAgB,CAAC;iBAC7B,IAAI,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;YAG3B,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,SAAS,CAAC,YAAY,CAAC;iBAC5C,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC;iBAChB,KAAK,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC;iBACtB,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;iBACb,IAAI,CAAC,IAAI,EAAE,UAAU,CAAK,IAAI,MAAM,CAAC,EAAE,CAAC,KAAK,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,GAAG,CAAC,CAAC,CAAC,CAAC;iBAC1E,IAAI,CAAC,IAAI,EAAE,cAAc,CAAC;iBAC1B,IAAI,CAAC,IAAI,EAAE,UAAU,CAAK,IAAI,MAAM,CAAC,EAAE,CAAC,KAAK,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,GAAG,CAAC,CAAC,CAAC,CAAC;iBAC1E,IAAI,CAAC,QAAQ,EAAE,MAAM,CAAC;iBACtB,IAAI,CAAC,cAAc,EAAE,GAAG,CAAC,CAAC;YAG/B,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,SAAS,CAAC,WAAW,CAAC;iBAC3C,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC;iBAChB,KAAK,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC;iBACtB,IAAI,CAAC,UAAU,CAAK;gBACjB,EAAE,CAAA,CAAC,CAAC,CAAC,KAAK,CAAC;oBAAC,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC;gBAC3B,MAAM,CAAC,EAAE,CAAC;YACd,CAAC,CAAC;iBACD,IAAI,CAAC,GAAG,EAAE,CAAC,EAAE,CAAC;iBACd,IAAI,CAAC,GAAG,EAAE,UAAU,CAAK;gBACtB,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,GAAG,EAAE,CAAC,CAAC;YAClC,CAAC,CAAC;iBACD,IAAI,CAAC,IAAI,EAAE,OAAO,CAAC;iBACnB,IAAI,CAAC,aAAa,EAAE,KAAK,CAAC;iBAC1B,IAAI,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;YAG3B,IAAI,CAAC,SAAS,GAAG,EAAE,CAAC,GAAG,CAAC,IAAI,EAAE;iBACzB,KAAK,CAAC,IAAI,CAAC,EAAE,CAAC;iBACd,MAAM,CAAC,QAAQ,CAAC;iBAChB,KAAK,CAAC,EAAE,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;iBACtB,UAAU,CAAC,EAAE,CAAC,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;iBACnC,QAAQ,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;YAGpB,IAAI,IAAI,GAAO,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,GAAG,CAAC;iBACnC,IAAI,CAAC,WAAW,EAAE,cAAc,GAAG,UAAU,GAAG,GAAG,CAAC;iBAEpD,IAAI,CAAC,OAAO,EAAE,UAAU,CAAC;iBACzB,IAAI,CAAC,MAAM,EAAE,OAAO,CAAC;iBACrB,KAAK,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAC,KAAK,CAAC,cAAc,EAAE,GAAG,CAAC,CAAC,KAAK,CAAC,MAAM,EAAE,OAAO,CAAC;iBAC1E,IAAI,CAAC,MAAM,EAAE,iBAAiB,CAAC;iBAC/B,IAAI,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;YAC1B,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC,cAAc,EAAE,GAAG,CAAC,CAAC,IAAI,CAAC,cAAc,EAAE,GAAG,CAAC,CAAC;YAG5E,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,GAAG,CAAC;iBACrC,IAAI,CAAC,WAAW,EAAE,YAAY,CAAC,CAAC;YAGrC,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,SAAS,CAAC,WAAW,CAAC;iBAC3C,IAAI,CAAC,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;iBAC1C,KAAK,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC;iBACtB,IAAI,CAAC,OAAO,EAAE,UAAU,CAAK;gBAC1B,MAAM,CAAC,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC;YACjC,CAAC,CAAC;iBACD,IAAI,CAAC,GAAG,EAAE,UAAU,CAAK;gBACtB,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC;YAClB,CAAC,CAAC;iBACD,IAAI,CAAC,QAAQ,EAAE,OAAO,CAAC;iBACvB,IAAI,CAAC,cAAc,EAAE,OAAO,CAAC,CAAC;YAGnC,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,MAAM,CAAC;iBACvB,IAAI,CAAC,gBAAgB,EAAE,SAAS,CAAC;iBACjC,IAAI,CAAC,OAAO,EAAE,cAAc,CAAC;iBAC7B,IAAI,CAAC,QAAQ,EAAE,UAAU,CAAC;iBAC1B,IAAI,CAAC,YAAY,EAAE,QAAQ,CAAC;iBAC5B,EAAE,CAAC,SAAS,EAAE,IAAI,CAAC,SAAS,CAAC,CAAC;YACnC,IAAI,CAAC,KAAK,GAAG,EAAE,CAAC,GAAG,CAAC,KAAK,EAAE;iBACtB,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC;iBACT,MAAM,CAAC,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;iBAC1B,EAAE,CAAC,OAAO,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC;YACnC,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,GAAG,CAAC;iBACpB,IAAI,CAAC,OAAO,EAAE,SAAS,CAAC;iBACxB,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC;iBAChB,SAAS,CAAC,MAAM,CAAC;iBACjB,IAAI,CAAC,GAAG,EAAE,CAAC,CAAC;iBACZ,IAAI,CAAC,QAAQ,EAAE,UAAU,GAAG,CAAC,CAAC;iBAC9B,KAAK,CAAC,MAAM,EAAC,MAAM,CAAC;iBACpB,KAAK,CAAC,cAAc,EAAC,KAAK,CAAC;iBAC3B,KAAK,CAAC,QAAQ,EAAC,eAAe,CAAC;iBAC/B,KAAK,CAAC,cAAc,EAAC,CAAC,CAAC,CAAC;YAG7B,IAAI,CAAC,QAAQ,CAAC,SAAS,CAAC,iBAAiB,CAAC,CAAC,MAAM,EAAE,CAAC;YACpD,IAAI,CAAC,WAAW,EAAE,CAAC;YAGnB,EAAE,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC;gBACb,IAAI,UAAoB,CAAC;gBACzB,EAAE,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC;oBAAC,UAAU,GAAG,IAAI,CAAC,KAAK,CAAC,aAAa,EAAE,CAAC;gBACxD,IAAI,IAAI,GAAG,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC;qBACxB,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC;qBAChB,IAAI,CAAC,GAAG,EAAE,CAAC,CAAC,CAAC,QAAQ,EAAE,GAAG,CAAC,CAAC,CAAC;qBAC7B,IAAI,CAAC,GAAG,EAAE,CAAC,CAAC,MAAM,CAAC,GAAG,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC;qBAClC,IAAI,CAAC,aAAa,EAAE,QAAQ,CAAC,CAAC;gBAEnC,EAAE,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC;oBACb,EAAE,CAAC,CAAC,UAAU,CAAC,OAAO,EAAE,CAAC;wBAAC,IAAI,CAAC,IAAI,CAAC,aAAa,EAAE,UAAU,CAAC,OAAO,CAAC,CAAC;oBACvE,EAAE,CAAC,CAAC,UAAU,CAAC,WAAW,EAAE,IAAI,IAAI,CAAC;wBAAC,IAAI,CAAC,IAAI,CAAC,WAAW,EAAE,UAAU,CAAC,WAAW,EAAE,GAAG,IAAI,CAAC,CAAC;oBAC9F,EAAE,CAAC,CAAC,UAAU,CAAC,YAAY,EAAE,IAAI,IAAI,CAAC;wBAAC,IAAI,CAAC,KAAK,CAAC,iBAAiB,EAAE,WAAW,CAAC,CAAC;oBAClF,EAAE,CAAC,CAAC,UAAU,CAAC,QAAQ,EAAE,CAAC;wBAAC,IAAI,CAAC,KAAK,CAAC,MAAM,EAAE,UAAU,CAAC,QAAQ,CAAC,CAAC;oBACnE,IAAI;wBAAC,IAAI,CAAC,KAAK,CAAC,MAAM,EAAE,cAAc,CAAC,mBAAmB,CAAC,CAAC;gBAChE,CAAC;gBAAC,IAAI,CAAC,CAAC;oBACJ,IAAI,CAAC,KAAK,CAAC,iBAAiB,EAAE,WAAW,CAAC,CAAC;oBAC3C,IAAI,CAAC,KAAK,CAAC,MAAM,EAAE,cAAc,CAAC,mBAAmB,CAAC,CAAC;gBAC3D,CAAC;YACL,CAAC;QACL,CAAC,CAAC;QAGF,gBAAW,GAAG;YACV,IAAI,QAAQ,GAAO,IAAI,CAAC;YAExB,IAAI,MAAM,GAAY,IAAI,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC;YAC1C,IAAI,SAAS,GAAU,MAAM,CAAC,CAAC,CAAC,CAAC;YACjC,IAAI,SAAS,GAAU,MAAM,CAAC,CAAC,CAAC,CAAC;YAEjC,IAAI,YAAY,GAAO,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,UAAU,CAAC;gBACnD,MAAM,CAAC,CAAC,CAAC,KAAK,GAAG,SAAS,IAAI,CAAC,CAAC,GAAG,GAAG,SAAS,CAAA;YACnD,CAAC,CAAC,CAAC;YAEH,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,SAAS,EAAE,SAAS,CAAC,CAAC,CAAC,CAAC;YAE/E,IAAI,CAAC,EAAE,CAAC,MAAM,CAAC,CAAC,SAAS,EAAE,SAAS,CAAC,CAAC,CAAC;YAGvC,IAAI,KAAK,GAAG,SAAS,GAAG,SAAS,CAAC;YAClC,EAAE,CAAC,CAAC,KAAK,GAAG,CAAC,GAAG,aAAa,CAAC,iBAAiB,CAAC,CAAC,CAAC;gBAC9C,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,EAAE,CAAC,IAAI,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,UAAU,CAAC,EAAE,CAAC,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC;YACjF,CAAC;YAAC,IAAI,CAAC,EAAE,CAAC,CAAC,KAAK,GAAG,CAAC,GAAG,aAAa,CAAC,gBAAgB,CAAC,CAAC,CAAC;gBACpD,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,EAAE,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC,UAAU,CAAC,EAAE,CAAC,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC;YAC9E,CAAC;YAAC,IAAI,CAAC,EAAE,CAAC,CAAC,KAAK,GAAG,CAAC,GAAG,aAAa,CAAC,iBAAiB,CAAC,CAAC,CAAC;gBACrD,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,EAAE,CAAC,IAAI,CAAC,KAAK,EAAE,CAAC,CAAC,CAAC,UAAU,CAAC,EAAE,CAAC,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC;YAC/E,CAAC;YAAC,IAAI,CAAC,EAAE,CAAC,CAAC,KAAK,GAAG,CAAC,GAAG,aAAa,CAAC,mBAAmB,CAAC,CAAC,CAAC;gBACvD,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,EAAE,CAAC,IAAI,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,UAAU,CAAC,EAAE,CAAC,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC;YACjF,CAAC;YAAC,IAAI,CAAC,EAAE,CAAC,CAAC,KAAK,IAAI,KAAK,CAAC,CAAC,CAAC;gBACxB,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,EAAE,CAAC,IAAI,CAAC,OAAO,EAAE,EAAE,CAAC,CAAC,UAAU,CAAC,EAAE,CAAC,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC,CAAC;YACrF,CAAC;YAAC,IAAI,CAAC,CAAC;gBACJ,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,EAAE,CAAC,IAAI,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,UAAU,CAAC,EAAE,CAAC,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC,CAAC;YACpF,CAAC;YAGD,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;YAGvD,IAAI,KAAK,GAAO,IAAI,CAAC,SAAS,CAAC,SAAS,CAAC,MAAM,CAAC;iBACvC,IAAI,CAAC,YAAY,EAAE,UAAU,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;iBACjD,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC,IAAI,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC;iBACxD,IAAI,CAAC,OAAO,EAAE,UAAU,CAAC,IAAI,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;YAG3F,KAAK,CAAC,KAAK,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC;iBACvB,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC,IAAI,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC;iBACxD,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC,IAAI,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,aAAa,CAAC,iCAAiC,GAAG,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,GAAG,CAAC,CAAC,CAAC,CAAC;iBAChI,IAAI,CAAC,OAAO,EAAE,UAAU,CAAC,IAAI,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC;iBACjF,IAAI,CAAC,QAAQ,EAAE,UAAU,CAAC,IAAI,MAAM,CAAC,aAAa,CAAC,gCAAgC,GAAG,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;iBACxG,IAAI,CAAC,QAAQ,EAAE,OAAO,CAAC;iBACvB,IAAI,CAAC,MAAM,EAAE,UAAS,CAAC;gBACpB,EAAE,CAAA,CAAC,CAAC,CAAC,KAAK,CAAC;oBAAC,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC;gBAC3B,MAAM,CAAC,aAAa,CAAC,aAAa,CAAC;YACvC,CAAC,CAAC;iBACD,IAAI,CAAC,cAAc,EAAE,CAAC,CAAC,CAAC;YAC7B,KAAK,CAAC,IAAI,EAAE,CAAC,MAAM,EAAE,CAAC;YAGtB,IAAI,MAAM,GAAO,IAAI,CAAC,SAAS,CAAC,SAAS,CAAC,MAAM,CAAC;iBAC5C,IAAI,CAAC,YAAY,EAAE,UAAU,CAAC;gBAC3B,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC;YAChB,CAAC,CAAC;iBACD,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC;gBAClB,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,KAAK,EAAE,SAAS,CAAC,CAAC,GAAG,CAAC,CAAC;YACzD,CAAC,CAAC;iBACD,IAAI,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;YAE3B,MAAM,CAAC,KAAK,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC;iBACxB,IAAI,CAAC,UAAU,CAAC;gBACb,EAAE,CAAA,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC;oBAAC,MAAM,CAAC,EAAE,CAAC;gBAC9D,EAAE,CAAA,CAAC,CAAC,CAAC,KAAK,CAAC;oBAAC,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC;gBAC3B,MAAM,CAAC,EAAE,CAAC;YACd,CAAC,CAAC;iBACD,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC;gBAClB,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,KAAK,EAAE,SAAS,CAAC,CAAC,GAAG,CAAC,CAAC;YACzD,CAAC,CAAC;iBACD,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC;gBAClB,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,EAAE,GAAG,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,GAAG,CAAC;YAC3D,CAAC,CAAC;iBACD,IAAI,CAAC,aAAa,EAAE,OAAO,CAAC;iBAC5B,IAAI,CAAC,OAAO,EAAE,WAAW,CAAC;iBAC1B,IAAI,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;YAE3B,MAAM,CAAC,IAAI,EAAE,CAAC,MAAM,EAAE,CAAC;QAC3B,CAAC,CAAC;QAEF,cAAS,GAAG;YACR,IAAI,MAAM,GAAO,EAAE,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC;YACxC,IAAI,IAAI,GAAQ,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,OAAO,EAAE,CAAC;YACnD,IAAI,UAAU,GAAW,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC,CAAC,CAAC,CAAC,OAAO,EAAE,GAAG,IAAI,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC,CAAC,CAAC,CAAC,OAAO,EAAE,CAAC,GAAG,CAAC,CAAC;YAEnG,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,IAAI,IAAI,CAAC,IAAI,GAAG,UAAU,CAAC,EAAE,IAAI,IAAI,CAAC,IAAI,GAAG,UAAU,CAAC,CAAC,CAAC,CAAC;YAC9E,IAAI,CAAC,WAAW,EAAE,CAAC;QACvB,CAAC,CAAC;QAEF,qBAAgB,GAAG,UAAC,KAAS;YACzB,IAAI,KAAK,GAAG,EAAE,EAAE,CAAC,EAAE,MAAM,GAAG,EAAE,GAAG,IAAI,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,GAAG,EAAE,MAAM,GAAG,EAAE,CAAC;YAC/D,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;gBACpC,CAAC,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC;gBACb,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC;oBAAC,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,EAAE,CAAC;gBACzC,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,IAAI,CAAC,GAAG,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,EAAE,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,MAAM,CAAC,EAAE,GAAG,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;YACvG,CAAC;YAED,GAAG,CAAC,CAAC,IAAI,SAAS,IAAI,KAAK,CAAC,CAAC,CAAC;gBAC1B,MAAM,CAAC,IAAI,CAAC,EAAC,KAAK,EAAE,SAAS,EAAE,IAAI,EAAE,KAAK,CAAC,SAAS,CAAC,EAAC,CAAC,CAAC;YAC5D,CAAC;YACD,MAAM,CAAC,MAAM,CAAC;QAClB,CAAC,CAAA;QA3UG,IAAI,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QAC/B,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;YAAC,IAAI,GAAG,IAAI,CAAC,aAAa,CAAC,aAAa,CAAC,aAAa,CAAC,CAAC,CAAC;QAEpF,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC,WAAW,CAAC,CAAC;QACnC,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,UAAU,CAAC,CAAC;IACrC,CAAC;IApBc,iCAAmB,GAAG,EAAE,CAAC;IACzB,+CAAiC,GAAU,IAAI,CAAC;IAChD,8CAAgC,GAAU,IAAI,CAAC;IAE/C,iCAAmB,GAAU,EAAE,GAAG,IAAI,CAAC;IACvC,+BAAiB,GAAU,EAAE,GAAG,aAAa,CAAC,mBAAmB,CAAC;IAClE,8BAAgB,GAAU,EAAE,GAAG,aAAa,CAAC,iBAAiB,CAAC;IAC/D,+BAAiB,GAAU,CAAC,GAAG,aAAa,CAAC,gBAAgB,CAAC;IAE9D,2BAAa,GAAG,WAAW,CAAC;IAkV/C,oBAAC;AAAD,CAAC,AA/WD,CAA4B,KAAK,GA+WhC;ACpXD;IAAyB,8BAAK;IAQ1B,oBAAa,OAAY;QAR7B,iBAgCC;QAvBO,kBAAM,OAAO,CAAC,YAAY,CAAC,CAAC,CAAC;QAYjC,mBAAc,GAAG,cAAM,OAAA,KAAI,CAAC,WAAW,EAAhB,CAAgB,CAAC;QACxC,iBAAY,GAAG,cAAM,OAAA,KAAI,CAAC,SAAS,EAAd,CAAc,CAAC;QACpC,oBAAe,GAAG,cAAM,OAAA,KAAI,CAAC,YAAY,EAAjB,CAAiB,CAAC;QAE1C,mBAAc,GAAG,UAAC,GAAW;YACzB,EAAE,CAAA,CAAC,CAAC,IAAI,CAAC,YAAY,IAAI,GAAG,GAAG,CAAC,IAAI,GAAG,GAAG,IAAI,CAAC,YAAY,CAAC,MAAM,CAAC;gBAAC,MAAM,CAAC,IAAI,CAAC;YAChF,MAAM,CAAC,KAAI,CAAC,YAAY,CAAC,GAAG,CAAC,CAAC;QAClC,CAAC,CAAC;QAEF,uBAAkB,GAAG,cAAM,OAAA,KAAI,CAAC,eAAe,EAApB,CAAoB,CAAC;QAChD,kBAAa,GAAG,cAAM,OAAA,KAAI,CAAC,UAAU,EAAf,CAAe,CAAC;QApBlC,IAAI,KAAK,GAAQ,OAAO,CAAC,YAAY,CAAC,CAAC;QAEvC,EAAE,CAAA,CAAC,KAAK,CAAC,CAAA,CAAC;YACN,IAAI,CAAC,WAAW,GAAG,KAAK,CAAC,aAAa,CAAC,CAAC;YACxC,IAAI,CAAC,SAAS,GAAG,KAAK,CAAC,WAAW,CAAC,CAAC;YACpC,IAAI,CAAC,YAAY,GAAG,KAAK,CAAC,cAAc,CAAC,CAAC;YAC1C,EAAE,CAAA,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC;gBAAC,IAAI,CAAC,UAAU,GAAG,IAAI,SAAS,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC,CAAC;QACjF,CAAC;IACL,CAAC;IAaL,iBAAC;AAAD,CAAC,AAhCD,CAAyB,KAAK,GAgC7B;AC/BD;IAA2B,gCAAS;IAKhC,sBAAY,OAAe;QACvB,kBAAM,aAAa,CAAC,YAAY,CAAC,CAAC;QAoBtC,WAAM,GAAG,UAAC,cAAsB;YAE5B,IAAI,MAAM,GAAW,CAAC,CAAC,aAAa,CAAC,CAAC;YACtC,MAAM,CAAC,QAAQ,EAAE,CAAC;YAElB,EAAE,CAAA,CAAC,IAAI,CAAC,KAAK,CAAC,CAAA,CAAC;gBAEX,EAAE,CAAA,CAAC,IAAI,CAAC,KAAK,CAAC,QAAQ,EAAE,CAAC,CAAA,CAAC;oBACtB,IAAI,IAAI,GAAW,IAAI,CAAC,KAAK,CAAC,YAAY,EAAE,CAAC;oBAC7C,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,QAAQ,EAAE,GAAG,CAAC,IAAI,GAAG,IAAI,GAAG,EAAE,CAAC,CAAC,CAAC;gBAC7D,CAAC;gBACD,EAAE,CAAA,CAAC,IAAI,CAAC,KAAK,CAAC,SAAS,EAAE,CAAC,CAAA,CAAC;oBACvB,IAAI,IAAI,GAAW,IAAI,CAAC,KAAK,CAAC,aAAa,EAAE,CAAC;oBAC9C,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,SAAS,EAAE,GAAG,CAAC,IAAI,GAAG,IAAI,GAAG,EAAE,CAAC,CAAC,CAAC;gBAC/D,CAAC;gBACD,EAAE,CAAA,CAAC,IAAI,CAAC,KAAK,CAAC,kBAAkB,EAAE,CAAC;oBAAC,MAAM,CAAC,GAAG,CAAC,kBAAkB,EAAC,IAAI,CAAC,KAAK,CAAC,kBAAkB,EAAE,CAAC,CAAC;gBACnG,EAAE,CAAA,CAAC,IAAI,CAAC,KAAK,CAAC,aAAa,EAAE,CAAC;oBAAC,MAAM,CAAC,GAAG,CAAC,OAAO,EAAE,IAAI,CAAC,KAAK,CAAC,aAAa,EAAE,CAAC,CAAC;YACnF,CAAC;YAGD,cAAc,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;YAG9B,EAAE,CAAA,CAAC,IAAI,CAAC,UAAU,CAAC,CAAA,CAAC;gBAChB,GAAG,CAAA,CAAE,IAAI,CAAC,GAAC,CAAC,EAAE,CAAC,GAAC,IAAI,CAAC,UAAU,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;oBAC1C,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;gBACtC,CAAC;YACL,CAAC;QACL,CAAC,CAAA;QA9CG,IAAI,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QAC/B,EAAE,CAAA,CAAC,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;YAAC,IAAI,GAAG,IAAI,CAAC,aAAa,CAAC,aAAa,CAAC,YAAY,CAAC,CAAC,CAAC;QAElF,IAAI,UAAU,GAAU,IAAI,CAAC,YAAY,CAAC,CAAC;QAE3C,EAAE,CAAA,CAAC,UAAU,CAAC,CAAA,CAAC;YACX,IAAI,CAAC,UAAU,GAAG,EAAE,CAAC;YACrB,GAAG,CAAA,CAAE,IAAI,CAAC,GAAC,CAAC,EAAE,CAAC,GAAC,UAAU,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;gBACrC,IAAI,KAAK,GAAW,IAAI,CAAC,SAAS,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,CAAC;gBAClD,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,SAAS,CAAC,YAAY,CAAC,KAAK,CAAC,CAAC,CAAC;YACxD,CAAC;QACL,CAAC;QAED,EAAE,CAAA,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;YAAC,IAAI,CAAC,KAAK,GAAG,IAAI,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC;IAG/D,CAAC;IAgCL,mBAAC;AAAD,CAAC,AAxDD,CAA2B,SAAS,GAwDnC;ACxDD;IAAuB,4BAAK;IAIxB,kBAAa,OAAY;QAJ7B,iBAcC;QATO,kBAAM,OAAO,CAAC,UAAU,CAAC,CAAC,CAAC;QAM/B,kBAAa,GAAG,cAAM,OAAA,KAAI,CAAC,UAAU,EAAf,CAAe,CAAC;QAJlC,EAAE,CAAA,CAAC,OAAO,IAAI,OAAO,CAAC,UAAU,CAAC,CAAC;YAAC,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC,YAAY,CAAC,CAAC;IAE3F,CAAC;IAKL,eAAC;AAAD,CAAC,AAdD,CAAuB,KAAK,GAc3B;ACRD;IAAiC,sCAAS;IAOtC,4BAAY,OAAe;QACvB,kBAAM,aAAa,CAAC,kBAAkB,CAAC,CAAC;QAqB5C,WAAM,GAAG,UAAC,cAAsB;YAE5B,IAAI,CAAC,GAAkB,IAAI,CAAC,KAAK,CAAC;YAElC,IAAI,QAAQ,GAAW,CAAC,CAAC,aAAa,CAAC,CAAC;YACxC,QAAQ,CAAC,QAAQ,EAAE,CAAC;YAEpB,IAAI,QAAgB,CAAC;YACrB,EAAE,CAAA,CAAC,IAAI,CAAC,KAAK,CAAC;gBAAC,QAAQ,GAAG,CAAC,CAAC,OAAO,GAAG,IAAI,CAAC,KAAK,GAAG,QAAQ,CAAC,CAAC;YAC7D,IAAI;gBAAC,QAAQ,GAAG,CAAC,CAAC,aAAa,CAAC,CAAC;YACjC,QAAQ,CAAC,QAAQ,EAAE,CAAC;YACpB,QAAQ,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;YAE1B,IAAI,QAAQ,GAAW,CAAC,CAAC,aAAa,CAAC,CAAC;YACxC,QAAQ,CAAC,QAAQ,EAAE,CAAC;YACpB,QAAQ,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;YAG1B,EAAE,CAAC,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC,CAAC;gBACvB,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,IAAI,CAAC,eAAe,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;oBAEnD,IAAI,CAAC,eAAe,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;gBAC7C,CAAC;YACL,CAAC;YAED,cAAc,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;YAEhC,EAAE,CAAA,CAAC,IAAI,CAAC,gBAAgB,CAAC;gBAAC,QAAQ,CAAC,SAAS,CAAC,EAAC,WAAW,EAAE,IAAI,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,EAAE,KAAK,EAAC,CAAC,CAAC;YACzG,IAAI;gBAAC,QAAQ,CAAC,SAAS,CAAC,EAAC,WAAW,EAAE,IAAI,EAAE,WAAW,EAAE,SAAS,EAAC,CAAC,CAAC;QASzE,CAAC,CAAA;QAxDG,IAAI,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QAC/B,EAAE,CAAA,CAAC,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;YAAC,IAAI,GAAG,IAAI,CAAC,aAAa,CAAC,aAAa,CAAC,kBAAkB,CAAC,CAAC,CAAC;QAExF,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,OAAO,CAAC,CAAC;QAC3B,IAAI,CAAC,gBAAgB,GAAG,IAAI,CAAC,kBAAkB,CAAC,CAAC;QAEjD,IAAI,OAAO,GAAU,IAAI,CAAC,iBAAiB,CAAC,CAAC;QAE7C,EAAE,CAAA,CAAC,OAAO,CAAC,CAAA,CAAC;YACR,IAAI,CAAC,eAAe,GAAG,EAAE,CAAC;YAC1B,GAAG,CAAA,CAAE,IAAI,CAAC,GAAC,CAAC,EAAE,CAAC,GAAC,OAAO,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;gBAClC,IAAI,KAAK,GAAW,IAAI,CAAC,SAAS,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC;gBAC/C,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,SAAS,CAAC,YAAY,CAAC,KAAK,CAAC,CAAC,CAAC;YAC7D,CAAC;QACL,CAAC;QAED,EAAE,CAAA,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;YAAC,IAAI,CAAC,KAAK,GAAG,IAAI,cAAc,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC;IACrE,CAAC;IA0CL,yBAAC;AAAD,CAAC,AArED,CAAiC,SAAS,GAqEzC;AC3ED;IAA6B,kCAAK;IAE9B,wBAAa,OAAY;QACrB,kBAAM,OAAO,CAAC,gBAAgB,CAAC,CAAC,CAAC;IAGrC,CAAC;IAEL,qBAAC;AAAD,CAAC,AARD,CAA6B,KAAK,GAQjC;ACLD;IAA6B,kCAAS;IAOlC,wBAAY,OAAe;QACvB,kBAAM,aAAa,CAAC,cAAc,CAAC,CAAC;QAUxC,WAAM,GAAG,UAAC,cAAsB;YAE5B,IAAI,CAAC,GAAe,IAAI,CAAC,KAAK,CAAC;YAC/B,IAAI,MAAM,GAAW,KAAK,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC;YAEzC,IAAI,GAAG,GAAG,QAAQ,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;YAE1C,GAAG,CAAC,KAAK,CAAC,KAAK,GAAG,MAAM,CAAC;YACzB,EAAE,CAAA,CAAC,CAAC,IAAI,CAAC,CAAC,gBAAgB,EAAE,IAAI,IAAK,CAAC;gBAAC,GAAG,CAAC,YAAY,CAAC,QAAQ,EAAE,MAAM,CAAC,CAAC,CAAC,gBAAgB,EAAE,CAAC,CAAC,CAAC;YAChG,EAAE,CAAA,CAAC,CAAC,IAAI,CAAC,CAAC,kBAAkB,EAAE,CAAC;gBAAC,GAAG,CAAC,KAAK,CAAC,eAAe,GAAG,CAAC,CAAC,kBAAkB,EAAE,CAAC;YACnF,EAAE,CAAA,CAAC,CAAC,IAAI,CAAC,CAAC,iBAAiB,EAAE,CAAC;gBAAC,GAAG,CAAC,KAAK,CAAC,UAAU,GAAG,CAAC,CAAC,iBAAiB,EAAE,CAAC;YAE5E,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,eAAe,EAAE,CAAC,CAAC,CAAC;gBAE3B,IAAI,SAAS,GAAa,CAAC,CAAC,eAAe,EAAE,CAAC;gBAC9C,IAAI,IAAI,GAAW,OAAO,CAAC,mBAAmB,CAAC,CAAC,CAAC,kBAAkB,EAAE,CAAC,CAAC;gBACvE,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,SAAS,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;oBACxC,IAAI,GAAG,GAAG,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;oBACxC,GAAG,CAAC,YAAY,CAAC,OAAO,EAAE,SAAS,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC,CAAC;oBAC/C,GAAG,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC;gBACzB,CAAC;YACL,CAAC;YAGD,IAAI,MAAM,GAAG,CAAC,CAAC;YACf,IAAI,QAAQ,GAAG,CAAC,CAAC;YACjB,IAAI,SAAS,GAAG,CAAC,CAAC;YAClB,IAAI,OAAO,GAAG,CAAC,CAAC;YAEhB,EAAE,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC;gBACd,IAAI,OAAO,GAAG,QAAQ,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;gBAC9C,IAAI,SAAS,GAAG,QAAQ,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC;gBAE7C,EAAE,CAAA,CAAC,CAAC,IAAI,CAAC,CAAC,cAAc,EAAE,CAAC;oBAAC,SAAS,CAAC,KAAK,CAAC,eAAe,GAAG,CAAC,CAAC,cAAc,EAAE,CAAC;gBAEjF,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;oBAC1C,IAAI,OAAO,GAAG,QAAQ,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC;oBAC3C,OAAO,CAAC,KAAK,CAAC,OAAO,GAAG,MAAM,GAAG,KAAK,GAAG,QAAQ,GAAG,KAAK,GAAG,SAAS,GAAG,KAAK,GAAG,OAAO,GAAG,IAAI,CAAC;oBAC/F,OAAO,CAAC,WAAW,CAAC,QAAQ,CAAC,cAAc,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;oBAC7D,SAAS,CAAC,WAAW,CAAC,OAAO,CAAC,CAAC;gBACnC,CAAC;gBACD,GAAG,CAAC,WAAW,CAAC,SAAS,CAAC,CAAC;YAC/B,CAAC;YAGD,EAAE,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC;gBAEf,IAAI,IAAI,GAAG,QAAQ,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;gBAC3C,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,IAAI,CAAC,OAAO,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;oBAC3C,IAAI,EAAE,GAAG,QAAQ,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC;oBAEtC,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;wBAC9C,IAAI,EAAE,GAAG,QAAQ,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC;wBACtC,EAAE,CAAC,KAAK,CAAC,OAAO,GAAG,MAAM,GAAG,KAAK,GAAG,QAAQ,GAAG,KAAK,GAAG,SAAS,GAAG,KAAK,GAAG,OAAO,GAAG,IAAI,CAAC;wBAC1F,EAAE,CAAC,WAAW,CAAC,QAAQ,CAAC,cAAc,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;wBAC5D,EAAE,CAAC,WAAW,CAAC,EAAE,CAAC,CAAC;oBACvB,CAAC;oBAED,IAAI,CAAC,WAAW,CAAC,EAAE,CAAC,CAAC;gBACzB,CAAC;gBACD,GAAG,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;YAC1B,CAAC;YAED,cAAc,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;QAC/B,CAAC,CAAA;QAxEG,IAAI,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QAC/B,EAAE,CAAA,CAAC,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;YAAC,IAAI,GAAG,IAAI,CAAC,aAAa,CAAC,aAAa,CAAC,cAAc,CAAC,CAAC,CAAC;QAEpF,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,QAAQ,CAAC,CAAC;QAC7B,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC,SAAS,CAAC,CAAC;QAC/B,EAAE,CAAA,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;YAAC,IAAI,CAAC,KAAK,GAAG,IAAI,UAAU,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC;IACjE,CAAC;IAqEL,qBAAC;AAAD,CAAC,AArFD,CAA6B,SAAS,GAqFrC;ACzFD;IAAyB,8BAAK;IAQ1B,oBAAa,OAAY;QAR7B,iBA0BC;QAjBO,kBAAM,OAAO,CAAC,YAAY,CAAC,CAAC,CAAC;QAYjC,oBAAe,GAAG,cAAM,OAAA,KAAI,CAAC,YAAY,EAAjB,CAAiB,CAAC;QAC1C,uBAAkB,GAAG,cAAM,OAAA,KAAI,CAAC,eAAe,EAApB,CAAoB,CAAC;QAChD,qBAAgB,GAAG,cAAM,OAAA,KAAI,CAAC,aAAa,EAAlB,CAAkB,CAAC;QAC5C,mBAAc,GAAG,cAAM,OAAA,KAAI,CAAC,WAAW,EAAhB,CAAgB,CAAC;QACxC,sBAAiB,GAAG,cAAM,OAAA,KAAI,CAAC,cAAc,EAAnB,CAAmB,CAAC;QAd1C,IAAI,KAAK,GAAQ,OAAO,CAAC,YAAY,CAAC,CAAC;QACvC,EAAE,CAAA,CAAC,KAAK,CAAC,CAAA,CAAC;YACN,IAAI,CAAC,YAAY,GAAG,OAAO,CAAC,YAAY,CAAC,CAAC,cAAc,CAAC,CAAC;YAC1D,IAAI,CAAC,aAAa,GAAG,OAAO,CAAC,YAAY,CAAC,CAAC,eAAe,CAAC,CAAC;YAC5D,IAAI,CAAC,WAAW,GAAG,OAAO,CAAC,YAAY,CAAC,CAAC,aAAa,CAAC,CAAC;YACxD,IAAI,CAAC,eAAe,GAAG,OAAO,CAAC,YAAY,CAAC,CAAC,iBAAiB,CAAC,CAAC;YAChE,IAAI,CAAC,cAAc,GAAG,OAAO,CAAC,YAAY,CAAC,CAAC,gBAAgB,CAAC,CAAC;QAClE,CAAC;IACL,CAAC;IAOL,iBAAC;AAAD,CAAC,AA1BD,CAAyB,KAAK,GA0B7B;ACtBD;IAA4B,iCAAS;IAKjC,uBAAY,OAAe;QAL/B,iBAwCC;QAlCO,kBAAM,aAAa,CAAC,aAAa,CAAC,CAAC;QASvC,WAAM,GAAG,UAAC,cAAsB;YAE5B,IAAI,QAAQ,GAAS,QAAQ,CAAC,cAAc,CAAC,KAAI,CAAC,IAAI,CAAC,CAAC;YACxD,EAAE,CAAA,CAAC,KAAI,CAAC,KAAK,CAAC,CAAA,CAAC;gBACX,IAAI,OAAO,GAAoB,QAAQ,CAAC,aAAa,CAAC,MAAM,CAAC,CAAC;gBAC9D,EAAE,CAAA,CAAC,KAAI,CAAC,KAAK,CAAC,OAAO,EAAE,CAAC;oBAAC,OAAO,CAAC,KAAK,CAAC,IAAI,GAAG,KAAI,CAAC,KAAK,CAAC,OAAO,EAAE,CAAC;gBACnE,EAAE,CAAA,CAAC,KAAI,CAAC,KAAK,CAAC,WAAW,EAAE,IAAI,IAAI,CAAC;oBAAC,OAAO,CAAC,KAAK,CAAC,QAAQ,GAAG,KAAI,CAAC,KAAK,CAAC,WAAW,EAAE,GAAG,IAAI,CAAC;gBAC9F,EAAE,CAAA,CAAC,KAAI,CAAC,KAAK,CAAC,YAAY,EAAE,IAAI,IAAI,CAAC;oBAAC,OAAO,CAAC,KAAK,CAAC,cAAc,GAAC,WAAW,CAAC;gBAC/E,EAAE,CAAA,CAAC,KAAI,CAAC,KAAK,CAAC,QAAQ,EAAE,CAAC;oBAAC,OAAO,CAAC,KAAK,CAAC,KAAK,GAAG,KAAI,CAAC,KAAK,CAAC,QAAQ,EAAE,CAAC;gBACtE,EAAE,CAAA,CAAC,KAAI,CAAC,KAAK,CAAC,YAAY,EAAE,CAAC;oBAAC,OAAO,CAAC,KAAK,CAAC,SAAS,GAAG,KAAI,CAAC,KAAK,CAAC,YAAY,EAAE,GAAG,IAAI,CAAC;gBACzF,EAAE,CAAA,CAAC,KAAI,CAAC,KAAK,CAAC,eAAe,EAAE,CAAC;oBAAC,OAAO,CAAC,KAAK,CAAC,YAAY,GAAG,KAAI,CAAC,KAAK,CAAC,eAAe,EAAE,GAAG,IAAI,CAAC;gBAClG,EAAE,CAAA,CAAC,KAAI,CAAC,KAAK,CAAC,aAAa,EAAE,CAAC;oBAAC,OAAO,CAAC,KAAK,CAAC,UAAU,GAAG,KAAI,CAAC,KAAK,CAAC,aAAa,EAAE,GAAG,IAAI,CAAC;gBAC5F,EAAE,CAAA,CAAC,KAAI,CAAC,KAAK,CAAC,cAAc,EAAE,CAAC;oBAAC,OAAO,CAAC,KAAK,CAAC,WAAW,GAAG,KAAI,CAAC,KAAK,CAAC,cAAc,EAAE,GAAG,IAAI,CAAC;gBAC/F,EAAE,CAAA,CAAC,KAAI,CAAC,KAAK,CAAC,gBAAgB,EAAE,CAAC;oBAAC,OAAO,CAAC,KAAK,CAAC,UAAU,GAAG,KAAK,CAAC;gBAEnE,OAAO,CAAC,WAAW,CAAC,QAAQ,CAAC,CAAC;gBAC9B,cAAc,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;YACnC,CAAC;YAAC,IAAI,CAAC,CAAC;gBACJ,IAAI,OAAO,GAAoB,QAAQ,CAAC,aAAa,CAAC,MAAM,CAAC,CAAC;gBAE9D,OAAO,CAAC,WAAW,CAAC,QAAQ,CAAC,CAAC;gBAC9B,cAAc,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;YACnC,CAAC;QACL,CAAC,CAAA;QA/BG,IAAI,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QAC/B,EAAE,CAAA,CAAC,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;YAAC,IAAI,GAAG,IAAI,CAAC,aAAa,CAAC,aAAa,CAAC,aAAa,CAAC,CAAC,CAAC;QAEnF,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,MAAM,CAAC,CAAC;QAEzB,EAAE,CAAA,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;YAAC,IAAI,CAAC,KAAK,GAAG,IAAI,SAAS,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC;IAChE,CAAC;IA2BL,oBAAC;AAAD,CAAC,AAxCD,CAA4B,SAAS,GAwCpC;AC5CD;IAAwB,6BAAK;IAQzB,mBAAa,OAAY;QAR7B,iBA0BC;QAjBO,kBAAM,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC;QAYhC,YAAO,GAAG,cAAM,OAAA,KAAI,CAAC,IAAI,EAAT,CAAS,CAAC;QAC1B,gBAAW,GAAG,cAAM,OAAA,KAAI,CAAC,QAAQ,EAAb,CAAa,CAAC;QAClC,iBAAY,GAAG,cAAM,OAAA,KAAI,CAAC,SAAS,EAAd,CAAc,CAAC;QACpC,aAAQ,GAAG,cAAM,OAAA,KAAI,CAAC,KAAK,EAAV,CAAU,CAAC;QAC5B,qBAAgB,GAAG,cAAM,OAAA,KAAI,CAAC,aAAa,EAAlB,CAAkB,CAAC;QAdxC,IAAI,KAAK,GAAQ,OAAO,CAAC,WAAW,CAAC,CAAC;QACtC,EAAE,CAAA,CAAC,KAAK,CAAC,CAAA,CAAC;YACN,IAAI,CAAC,IAAI,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC;YAC1B,IAAI,CAAC,QAAQ,GAAG,KAAK,CAAC,UAAU,CAAC,CAAC;YAClC,IAAI,CAAC,SAAS,GAAG,KAAK,CAAC,WAAW,CAAC,CAAC;YACpC,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC,OAAO,CAAC,CAAC;YAC5B,IAAI,CAAC,aAAa,GAAG,KAAK,CAAC,eAAe,CAAC,CAAC;QAChD,CAAC;IACL,CAAC;IAOL,gBAAC;AAAD,CAAC,AA1BD,CAAwB,KAAK,GA0B5B"} \ No newline at end of file diff --git a/arbiter/arbiter-ui/src/main/resources/templates/ArbiterUI.html b/arbiter/arbiter-ui/src/main/resources/templates/ArbiterUI.html deleted file mode 100644 index a1b4e92a0..000000000 --- a/arbiter/arbiter-ui/src/main/resources/templates/ArbiterUI.html +++ /dev/null @@ -1,638 +0,0 @@ - - - - - - DL4J - Arbiter UI - - - - - - - - - - - - - - - - - - - - -
-
Deeplearning4J - Arbiter UI
- -
- - -
-
-
-

Summary

-
-
-
-
- -
-
-

Optimization Settings

-
-
-
- - -
-
Results
-
- - - - - - -
-
-
- -
-
-

Selected Result

-
-
-
-
- - \ No newline at end of file diff --git a/arbiter/arbiter-ui/src/test/java/org/deeplearning4j/arbiter/optimize/AssertTestsExtendBaseClass.java b/arbiter/arbiter-ui/src/test/java/org/deeplearning4j/arbiter/optimize/AssertTestsExtendBaseClass.java deleted file mode 100644 index fcf3066e2..000000000 --- a/arbiter/arbiter-ui/src/test/java/org/deeplearning4j/arbiter/optimize/AssertTestsExtendBaseClass.java +++ /dev/null @@ -1,50 +0,0 @@ -/* ****************************************************************************** - * Copyright (c) 2020 Konduit K.K. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ -package org.deeplearning4j.arbiter.optimize; - -import lombok.extern.slf4j.Slf4j; -import org.nd4j.common.tests.AbstractAssertTestsClass; -import org.deeplearning4j.BaseDL4JTest; - -import java.util.*; - -/** - * This class checks that all test classes (i.e., anything with one or more methods annotated with @Test) - * extends BaseDl4jTest - either directly or indirectly. - * Other than a small set of exceptions, all tests must extend this - * - * @author Alex Black - */ - -@Slf4j -public class AssertTestsExtendBaseClass extends AbstractAssertTestsClass { - - @Override - protected Set> getExclusions() { - //Set of classes that are exclusions to the rule (either run manually or have their own logging + timeouts) - return new HashSet<>(); - } - - @Override - protected String getPackageName() { - return "org.deeplearning4j.arbiter.optimize"; - } - - @Override - protected Class getBaseClass() { - return BaseDL4JTest.class; - } -} diff --git a/arbiter/arbiter-ui/src/test/java/org/deeplearning4j/arbiter/optimize/TestBasic.java b/arbiter/arbiter-ui/src/test/java/org/deeplearning4j/arbiter/optimize/TestBasic.java deleted file mode 100644 index b7502c84b..000000000 --- a/arbiter/arbiter-ui/src/test/java/org/deeplearning4j/arbiter/optimize/TestBasic.java +++ /dev/null @@ -1,791 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2015-2018 Skymind, Inc. - * - * This program and the accompanying materials are made available under the - * terms of the Apache License, Version 2.0 which is available at - * https://www.apache.org/licenses/LICENSE-2.0. - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - * SPDX-License-Identifier: Apache-2.0 - ******************************************************************************/ - -package org.deeplearning4j.arbiter.optimize; - -import io.netty.handler.codec.http.HttpResponseStatus; -import lombok.NonNull; -import lombok.extern.slf4j.Slf4j; -import org.deeplearning4j.BaseDL4JTest; -import org.deeplearning4j.core.storage.StatsStorage; -import org.deeplearning4j.arbiter.ComputationGraphSpace; -import org.deeplearning4j.arbiter.MultiLayerSpace; -import org.deeplearning4j.arbiter.conf.updater.SgdSpace; -import org.deeplearning4j.arbiter.layers.ConvolutionLayerSpace; -import org.deeplearning4j.arbiter.layers.DenseLayerSpace; -import org.deeplearning4j.arbiter.layers.OutputLayerSpace; -import org.deeplearning4j.arbiter.optimize.api.CandidateGenerator; -import org.deeplearning4j.arbiter.optimize.api.ParameterSpace; -import org.deeplearning4j.arbiter.optimize.api.data.DataProvider; -import org.deeplearning4j.arbiter.optimize.api.data.DataSource; -import org.deeplearning4j.arbiter.optimize.api.score.ScoreFunction; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxCandidatesCondition; -import org.deeplearning4j.arbiter.optimize.api.termination.MaxTimeCondition; -import org.deeplearning4j.arbiter.optimize.api.termination.TerminationCondition; -import org.deeplearning4j.arbiter.optimize.config.OptimizationConfiguration; -import org.deeplearning4j.arbiter.optimize.generator.RandomSearchGenerator; -import org.deeplearning4j.arbiter.optimize.parameter.continuous.ContinuousParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.discrete.DiscreteParameterSpace; -import org.deeplearning4j.arbiter.optimize.parameter.integer.IntegerParameterSpace; -import org.deeplearning4j.arbiter.optimize.runner.IOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.LocalOptimizationRunner; -import org.deeplearning4j.arbiter.optimize.runner.listener.StatusListener; -import org.deeplearning4j.arbiter.saver.local.FileModelSaver; -import org.deeplearning4j.arbiter.scoring.impl.EvaluationScoreFunction; -import org.deeplearning4j.arbiter.scoring.impl.TestSetLossScoreFunction; -import org.deeplearning4j.arbiter.task.ComputationGraphTaskCreator; -import org.deeplearning4j.arbiter.task.MultiLayerNetworkTaskCreator; -import org.deeplearning4j.arbiter.ui.listener.ArbiterStatusListener; -import org.deeplearning4j.datasets.iterator.EarlyTerminationDataSetIterator; -import org.deeplearning4j.datasets.iterator.impl.MnistDataSetIterator; -import org.deeplearning4j.nn.conf.inputs.InputType; -import org.deeplearning4j.nn.weights.WeightInit; -import org.deeplearning4j.ui.api.UIServer; -import org.deeplearning4j.ui.model.storage.InMemoryStatsStorage; - -import org.junit.jupiter.api.Test; -import org.nd4j.common.function.Function; -import org.nd4j.evaluation.classification.Evaluation; -import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.api.buffer.DataType; -import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; -import org.nd4j.linalg.factory.Nd4j; -import org.nd4j.linalg.lossfunctions.LossFunctions; - -import java.io.File; -import java.io.IOException; -import java.io.UnsupportedEncodingException; -import java.net.HttpURLConnection; -import java.net.URL; -import java.net.URLEncoder; -import java.util.*; -import java.util.concurrent.TimeUnit; - -import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.junit.jupiter.api.Assertions.assertTrue; - -/** - * Created by Alex on 19/07/2017. - */ -@Slf4j -public class TestBasic extends BaseDL4JTest { - - @Override - public long getTimeoutMilliseconds() { - return 3600_000L; - } - - @Test - //@Ignore - public void testBasicUiOnly() throws Exception { - - UIServer.getInstance(); - - Thread.sleep(1000_000); - } - - @Test - //@Ignore - public void testBasicMnist() throws Exception { - Nd4j.setDefaultDataTypes(DataType.FLOAT, DataType.FLOAT); - - MultiLayerSpace mls = getMultiLayerSpaceMnist(); - Map commands = new HashMap<>(); -// commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY, TestDataFactoryProviderMnist.class.getCanonicalName()); - - //Define configuration: - CandidateGenerator candidateGenerator = new RandomSearchGenerator(mls, commands); - DataProvider dataProvider = new MnistDataSetProvider(); - - - String modelSavePath = new File(System.getProperty("java.io.tmpdir"), "ArbiterUiTestBasicMnist\\").getAbsolutePath(); - - File f = new File(modelSavePath); - if (f.exists()) - f.delete(); - f.mkdir(); - if (!f.exists()) - throw new RuntimeException(); - - OptimizationConfiguration configuration = - new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).dataProvider(dataProvider) - .modelSaver(new FileModelSaver(modelSavePath)) - .scoreFunction(new TestSetLossScoreFunction(true)) - .terminationConditions(new MaxTimeCondition(120, TimeUnit.MINUTES), - new MaxCandidatesCondition(100)) - .build(); - - IOptimizationRunner runner = - new LocalOptimizationRunner(configuration, new MultiLayerNetworkTaskCreator()); - - StatsStorage ss = new InMemoryStatsStorage(); - StatusListener sl = new ArbiterStatusListener(ss); - runner.addListeners(sl); - - UIServer.getInstance().attach(ss); - - runner.execute(); - Thread.sleep(1000_000); - } - - private static MultiLayerSpace getMultiLayerSpaceMnist() { - return new MultiLayerSpace.Builder() - .updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.2))) - .l2(new ContinuousParameterSpace(0.0001, 0.05)) - .addLayer( - new ConvolutionLayerSpace.Builder().nIn(1) - .nOut(new IntegerParameterSpace(5, 30)) - .kernelSize(new DiscreteParameterSpace<>(new int[]{3, 3}, - new int[]{4, 4}, new int[]{5, 5})) - .stride(new DiscreteParameterSpace<>(new int[]{1, 1}, - new int[]{2, 2})) - .activation(new DiscreteParameterSpace<>(Activation.RELU, - Activation.SOFTPLUS, Activation.LEAKYRELU)) - .build()) - .addLayer(new DenseLayerSpace.Builder().nOut(new IntegerParameterSpace(32, 128)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, Activation.TANH)) - .build(), new IntegerParameterSpace(0, 1), true) //0 to 1 layers - .addLayer(new OutputLayerSpace.Builder().nOut(10).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build()) - .setInputType(InputType.convolutionalFlat(28, 28, 1)) - .build(); - } - - @Test - //@Ignore - public void testBasicMnistDataSource() throws InterruptedException { - ParameterSpace learningRateHyperparam = new ContinuousParameterSpace(0.0001, 0.1); - ParameterSpace layerSizeHyperparam = new IntegerParameterSpace(16, 256); - - MultiLayerSpace hyperparameterSpace = new MultiLayerSpace.Builder() - .weightInit(WeightInit.XAVIER) - .l2(0.0001) - .updater(new SgdSpace(learningRateHyperparam)) - .addLayer(new DenseLayerSpace.Builder() - .nIn(784) - .activation(Activation.LEAKYRELU) - .nOut(layerSizeHyperparam) - .build()) - .addLayer(new OutputLayerSpace.Builder() - .nOut(10) - .activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT) - .build()) - .build(); - CandidateGenerator candidateGenerator = new RandomSearchGenerator(hyperparameterSpace, null); - ScoreFunction scoreFunction = new EvaluationScoreFunction(Evaluation.Metric.ACCURACY); - TerminationCondition[] terminationConditions = { - new MaxTimeCondition(5, TimeUnit.MINUTES), - new MaxCandidatesCondition(2)}; - - String modelSavePath = new File(System.getProperty("java.io.tmpdir"), "ArbiterUiTestBasicMnist\\").getAbsolutePath(); - - File f = new File(modelSavePath); - if (f.exists()) - f.delete(); - f.mkdir(); - if (!f.exists()) - throw new RuntimeException(); - Class ds = MnistDataSource.class; - Properties dsp = new Properties(); - dsp.setProperty("minibatch", "8"); - OptimizationConfiguration configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).dataSource(ds, dsp) - .modelSaver(new FileModelSaver(modelSavePath)) - .scoreFunction(scoreFunction) - .terminationConditions(terminationConditions) - .build(); - - IOptimizationRunner runner = new LocalOptimizationRunner(configuration, new MultiLayerNetworkTaskCreator()); - - StatsStorage ss = new InMemoryStatsStorage(); - StatusListener sl = new ArbiterStatusListener(ss); - runner.addListeners(sl); - - UIServer.getInstance().attach(ss); - - runner.execute(); - Thread.sleep(90000); - } - - - @Test - //@Ignore - public void testBasicMnistCompGraph() throws Exception { - - ComputationGraphSpace cgs = new ComputationGraphSpace.Builder() - .updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.2))) - .l2(new ContinuousParameterSpace(0.0001, 0.05)) - .addInputs("in") - .addLayer("0", - new ConvolutionLayerSpace.Builder().nIn(1) - .nOut(new IntegerParameterSpace(5, 30)) - .kernelSize(new DiscreteParameterSpace<>(new int[]{3, 3}, - new int[]{4, 4}, new int[]{5, 5})) - .stride(new DiscreteParameterSpace<>(new int[]{1, 1}, - new int[]{2, 2})) - .activation(new DiscreteParameterSpace<>(Activation.RELU, - Activation.SOFTPLUS, Activation.LEAKYRELU)) - .build(), "in") - .addLayer("1", new DenseLayerSpace.Builder().nOut(new IntegerParameterSpace(32, 128)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, Activation.TANH)) - .build(), "0") - .addLayer("out", new OutputLayerSpace.Builder().nOut(10).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build(), "1") - .setOutputs("out") - .setInputTypes(InputType.convolutionalFlat(28, 28, 1)) - .build(); - - //Define configuration: - CandidateGenerator candidateGenerator = new RandomSearchGenerator(cgs); - DataProvider dataProvider = new MnistDataSetProvider(); - - - String modelSavePath = new File(System.getProperty("java.io.tmpdir"), "ArbiterUiTestBasicMnistCG\\").getAbsolutePath(); - - File f = new File(modelSavePath); - if (f.exists()) - f.delete(); - f.mkdir(); - if (!f.exists()) - throw new RuntimeException(); - - OptimizationConfiguration configuration = - new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).dataProvider(dataProvider) - .modelSaver(new FileModelSaver(modelSavePath)) - .scoreFunction(new TestSetLossScoreFunction(true)) - .terminationConditions(new MaxTimeCondition(120, TimeUnit.MINUTES), - new MaxCandidatesCondition(100)) - .build(); - - IOptimizationRunner runner = - new LocalOptimizationRunner(configuration, new ComputationGraphTaskCreator()); - - StatsStorage ss = new InMemoryStatsStorage(); - StatusListener sl = new ArbiterStatusListener(ss); - runner.addListeners(sl); - - UIServer.getInstance().attach(ss); - - runner.execute(); - Thread.sleep(100000); - } - - - @Test - //@Ignore - public void testCandidateGenerationExceptionsMnist() throws Exception { - - //Idea: Create a configuration that is not physically realizable, which should throw an exception - // during the candidate generation phase - //This exception should be visible in UI, but training should continue otherwise - - MultiLayerSpace mls = new MultiLayerSpace.Builder() - .updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.2))) - .l2(new ContinuousParameterSpace(0.0001, 0.05)) - .dropOut(new ContinuousParameterSpace(0.2, 0.7)) - .addLayer( - new ConvolutionLayerSpace.Builder().nIn(1) - .nOut(new IntegerParameterSpace(5, 5)) - .kernelSize(new DiscreteParameterSpace<>(new int[]{14, 14}, new int[]{30, 30})) - .stride(2, 2) - .activation(new DiscreteParameterSpace<>(Activation.RELU, Activation.SOFTPLUS, Activation.LEAKYRELU)) - .build()) - .addLayer(new DenseLayerSpace.Builder().nOut(new IntegerParameterSpace(32, 128)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, Activation.TANH)) - .build(), new IntegerParameterSpace(0, 1), true) //0 to 1 layers - .addLayer(new OutputLayerSpace.Builder().nOut(10).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build()) - .setInputType(InputType.convolutionalFlat(28, 28, 1)) - .build(); - Map commands = new HashMap<>(); -// commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY, TestDataFactoryProviderMnist.class.getCanonicalName()); - - //Define configuration: - CandidateGenerator candidateGenerator = new RandomSearchGenerator(mls, commands); - DataProvider dataProvider = new MnistDataSetProvider(); - - - String modelSavePath = new File(System.getProperty("java.io.tmpdir"), "ArbiterUiTestBasicMnist\\").getAbsolutePath(); - - File f = new File(modelSavePath); - if (f.exists()) - f.delete(); - f.mkdir(); - if (!f.exists()) - throw new RuntimeException(); - - OptimizationConfiguration configuration = - new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).dataProvider(dataProvider) - .modelSaver(new FileModelSaver(modelSavePath)) - .scoreFunction(new TestSetLossScoreFunction(true)) - .terminationConditions(new MaxTimeCondition(120, TimeUnit.MINUTES), - new MaxCandidatesCondition(100)) - .build(); - - IOptimizationRunner runner = - new LocalOptimizationRunner(configuration, new MultiLayerNetworkTaskCreator()); - - StatsStorage ss = new InMemoryStatsStorage(); - StatusListener sl = new ArbiterStatusListener(ss); - runner.addListeners(sl); - - UIServer.getInstance().attach(ss); - - runner.execute(); - Thread.sleep(1000_000); - } - - - @Test - //@Ignore - public void testCandidateExecutionExceptionsMnist() throws Exception { - //Idea: Create a configuration that will throw an exception in the *execution* stage - // How? let's set wrong nOut - //This exception should be visible in UI, but training should continue otherwise - - MultiLayerSpace mls = new MultiLayerSpace.Builder() - .updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.2))) - .l2(new ContinuousParameterSpace(0.0001, 0.05)) - .dropOut(new ContinuousParameterSpace(0.2, 0.7)) - .addLayer( - new ConvolutionLayerSpace.Builder().nIn(1) - .nOut(new IntegerParameterSpace(5, 5)) - .kernelSize(new DiscreteParameterSpace<>(new int[]{3, 3}, new int[]{4, 4})) - .stride(2, 2) - .activation(new DiscreteParameterSpace<>(Activation.RELU, Activation.SOFTPLUS, Activation.LEAKYRELU)) - .build()) - .addLayer(new DenseLayerSpace.Builder().nOut(new IntegerParameterSpace(32, 64)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, Activation.TANH)) - .build(), new IntegerParameterSpace(0, 1), true) //0 to 1 layers - .addLayer(new OutputLayerSpace.Builder().nOut(99).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build()) - .setInputType(InputType.convolutionalFlat(28, 28, 1)) - .build(); - Map commands = new HashMap<>(); -// commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY, TestDataFactoryProviderMnist.class.getCanonicalName()); - - //Define configuration: - CandidateGenerator candidateGenerator = new RandomSearchGenerator(mls, commands); - DataProvider dataProvider = new MnistDataSetProvider(); - - - String modelSavePath = new File(System.getProperty("java.io.tmpdir"), "ArbiterUiTestBasicMnist\\").getAbsolutePath(); - - File f = new File(modelSavePath); - if (f.exists()) - f.delete(); - f.mkdir(); - if (!f.exists()) - throw new RuntimeException(); - - OptimizationConfiguration configuration = - new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).dataProvider(dataProvider) - .modelSaver(new FileModelSaver(modelSavePath)) - .scoreFunction(new TestSetLossScoreFunction(true)) - .terminationConditions(new MaxTimeCondition(120, TimeUnit.MINUTES), - new MaxCandidatesCondition(100)) - .build(); - - IOptimizationRunner runner = - new LocalOptimizationRunner(configuration, new MultiLayerNetworkTaskCreator()); - - StatsStorage ss = new InMemoryStatsStorage(); - StatusListener sl = new ArbiterStatusListener(ss); - runner.addListeners(sl); - - UIServer.getInstance().attach(ss); - - runner.execute(); - Thread.sleep(1000_000); - } - - - @Test - //@Ignore - public void testExecutionExceptionMnistCompGraph() throws Exception { - - //Idea: Create a configuration that will throw an exception in the *execution* stage - // How? let's set wrong nOut - //This exception should be visible in UI, but training should continue otherwise - - ComputationGraphSpace cgs = new ComputationGraphSpace.Builder() - .updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.2))) - .l2(new ContinuousParameterSpace(0.0001, 0.05)) - .dropOut(new ContinuousParameterSpace(0.2, 0.7)) - .addInputs("in") - .addLayer("0", - new ConvolutionLayerSpace.Builder().nIn(1) - .nOut(new IntegerParameterSpace(5, 30)) - .kernelSize(new DiscreteParameterSpace<>(new int[]{3, 3}, - new int[]{4, 4}, new int[]{5, 5})) - .stride(new DiscreteParameterSpace<>(new int[]{1, 1}, - new int[]{2, 2})) - .activation(new DiscreteParameterSpace<>(Activation.RELU, - Activation.SOFTPLUS, Activation.LEAKYRELU)) - .build(), "in") - .addLayer("1", new DenseLayerSpace.Builder().nOut(new IntegerParameterSpace(32, 64)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, Activation.TANH)) - .build(), "0") - .addLayer("out", new OutputLayerSpace.Builder().nIn(99).nOut(10).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build(), "1") - .setOutputs("out") - .setInputTypes(InputType.convolutionalFlat(28, 28, 1)) - .build(); - - //Define configuration: - CandidateGenerator candidateGenerator = new RandomSearchGenerator(cgs); - DataProvider dataProvider = new MnistDataSetProvider(); - - - String modelSavePath = new File(System.getProperty("java.io.tmpdir"), "ArbiterUiTestBasicMnistCG\\").getAbsolutePath(); - - File f = new File(modelSavePath); - if (f.exists()) - f.delete(); - f.mkdir(); - if (!f.exists()) - throw new RuntimeException(); - - OptimizationConfiguration configuration = - new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).dataProvider(dataProvider) - .modelSaver(new FileModelSaver(modelSavePath)) - .scoreFunction(new TestSetLossScoreFunction(true)) - .terminationConditions(new MaxTimeCondition(120, TimeUnit.MINUTES), - new MaxCandidatesCondition(100)) - .build(); - - IOptimizationRunner runner = - new LocalOptimizationRunner(configuration, new ComputationGraphTaskCreator()); - - StatsStorage ss = new InMemoryStatsStorage(); - StatusListener sl = new ArbiterStatusListener(ss); - runner.addListeners(sl); - - UIServer.getInstance().attach(ss); - - runner.execute(); - Thread.sleep(1000_000); - } - - - /** - * Visualize multiple optimization sessions run one after another on single-session mode UI - * @throws InterruptedException if current thread has been interrupted - */ - @Test - //@Ignore - public void testBasicMnistMultipleSessions() throws InterruptedException { - - MultiLayerSpace mls = new MultiLayerSpace.Builder() - .updater(new SgdSpace(new ContinuousParameterSpace(0.0001, 0.2))) - .l2(new ContinuousParameterSpace(0.0001, 0.05)) - .dropOut(new ContinuousParameterSpace(0.2, 0.7)) - .addLayer( - new ConvolutionLayerSpace.Builder().nIn(1) - .nOut(new IntegerParameterSpace(5, 30)) - .kernelSize(new DiscreteParameterSpace<>(new int[]{3, 3}, - new int[]{4, 4}, new int[]{5, 5})) - .stride(new DiscreteParameterSpace<>(new int[]{1, 1}, - new int[]{2, 2})) - .activation(new DiscreteParameterSpace<>(Activation.RELU, - Activation.SOFTPLUS, Activation.LEAKYRELU)) - .build()) - .addLayer(new DenseLayerSpace.Builder().nOut(new IntegerParameterSpace(32, 128)) - .activation(new DiscreteParameterSpace<>(Activation.RELU, Activation.TANH)) - .build(), new IntegerParameterSpace(0, 1), true) //0 to 1 layers - .addLayer(new OutputLayerSpace.Builder().nOut(10).activation(Activation.SOFTMAX) - .lossFunction(LossFunctions.LossFunction.MCXENT).build()) - .setInputType(InputType.convolutionalFlat(28, 28, 1)) - .build(); - Map commands = new HashMap<>(); -// commands.put(DataSetIteratorFactoryProvider.FACTORY_KEY, TestDataFactoryProviderMnist.class.getCanonicalName()); - - //Define configuration: - CandidateGenerator candidateGenerator = new RandomSearchGenerator(mls, commands); - - Class ds = MnistDataSource.class; - Properties dsp = new Properties(); - dsp.setProperty("minibatch", "8"); - - String modelSavePath = new File(System.getProperty("java.io.tmpdir"), "ArbiterUiTestBasicMnist\\").getAbsolutePath(); - - File f = new File(modelSavePath); - if (f.exists()) - f.delete(); - f.mkdir(); - if (!f.exists()) - throw new RuntimeException(); - - OptimizationConfiguration configuration = - new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).dataSource(ds, dsp) - .modelSaver(new FileModelSaver(modelSavePath)) - .scoreFunction(new TestSetLossScoreFunction(true)) - .terminationConditions(new MaxTimeCondition(1, TimeUnit.MINUTES), - new MaxCandidatesCondition(3)) - .build(); - - IOptimizationRunner runner = - new LocalOptimizationRunner(configuration, new MultiLayerNetworkTaskCreator()); - - StatsStorage ss = new InMemoryStatsStorage(); - - - StatusListener sl = new ArbiterStatusListener(ss); - runner.addListeners(sl); - - UIServer.getInstance().attach(ss); - runner.execute(); - - - candidateGenerator = new RandomSearchGenerator(mls, commands); - configuration = new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).dataSource(ds, dsp) - .modelSaver(new FileModelSaver(modelSavePath)) - .scoreFunction(new TestSetLossScoreFunction(true)) - .terminationConditions(new MaxTimeCondition(1, TimeUnit.MINUTES), - new MaxCandidatesCondition(3)) - .build(); - - runner = new LocalOptimizationRunner(configuration, new MultiLayerNetworkTaskCreator()); - sl = new ArbiterStatusListener(ss); - runner.addListeners(sl); - - UIServer.getInstance().attach(ss); - - runner.execute(); - - Thread.sleep(1000_000); - } - - /** - * Auto-attach multiple optimization sessions to multi-session mode UI - * @throws IOException if could not connect to the server - */ - @Test - public void testUiMultiSessionAutoAttach() throws IOException { - - //Define configuration: - MultiLayerSpace mls = getMultiLayerSpaceMnist(); - CandidateGenerator candidateGenerator = new RandomSearchGenerator(mls); - - Class ds = MnistDataSource.class; - Properties dsp = new Properties(); - dsp.setProperty("minibatch", "8"); - - String modelSavePath = new File(System.getProperty("java.io.tmpdir"), "ArbiterUiTestMultiSessionAutoAttach\\") - .getAbsolutePath(); - - File f = new File(modelSavePath); - if (f.exists()) - f.delete(); - f.mkdir(); - if (!f.exists()) - throw new RuntimeException(); - - OptimizationConfiguration configuration = - new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).dataSource(ds, dsp) - .modelSaver(new FileModelSaver(modelSavePath)) - .scoreFunction(new TestSetLossScoreFunction(true)) - .terminationConditions(new MaxTimeCondition(10, TimeUnit.SECONDS), - new MaxCandidatesCondition(1)) - .build(); - - IOptimizationRunner runner = - new LocalOptimizationRunner(configuration, new MultiLayerNetworkTaskCreator()); - - // add 3 different sessions to the same execution - HashMap statsStorageForSession = new HashMap<>(); - for (int i = 0; i < 3; i++) { - StatsStorage ss = new InMemoryStatsStorage(); - @NonNull String sessionId = "sid" + i; - statsStorageForSession.put(sessionId, ss); - StatusListener sl = new ArbiterStatusListener(sessionId, ss); - runner.addListeners(sl); - } - - Function statsStorageProvider = statsStorageForSession::get; - UIServer uIServer = UIServer.getInstance(true, statsStorageProvider); - String serverAddress = uIServer.getAddress(); - - runner.execute(); - - for (String sessionId : statsStorageForSession.keySet()) { - /* - * Visiting /arbiter/:sessionId to auto-attach StatsStorage - */ - String sessionUrl = sessionUrl(uIServer.getAddress(), sessionId); - HttpURLConnection conn = (HttpURLConnection) new URL(sessionUrl).openConnection(); - conn.connect(); - - log.info("Checking auto-attaching Arbiter session at {}", sessionUrl(serverAddress, sessionId)); - assertEquals(HttpResponseStatus.OK.code(), conn.getResponseCode()); - assertTrue(uIServer.isAttached(statsStorageForSession.get(sessionId))); - } - } - - /** - * Attach multiple optimization sessions to multi-session mode UI by manually visiting session URL - * @throws Exception if an error occurred - */ - @Test - //@Ignore - public void testUiMultiSessionManualAttach() throws Exception { - Nd4j.setDefaultDataTypes(DataType.FLOAT, DataType.FLOAT); - - //Define configuration: - MultiLayerSpace mls = getMultiLayerSpaceMnist(); - CandidateGenerator candidateGenerator = new RandomSearchGenerator(mls); - - Class ds = MnistDataSource.class; - Properties dsp = new Properties(); - dsp.setProperty("minibatch", "8"); - - String modelSavePath = new File(System.getProperty("java.io.tmpdir"), "ArbiterUiTestBasicMnist\\") - .getAbsolutePath(); - - File f = new File(modelSavePath); - if (f.exists()) - f.delete(); - f.mkdir(); - if (!f.exists()) - throw new RuntimeException(); - - OptimizationConfiguration configuration = - new OptimizationConfiguration.Builder() - .candidateGenerator(candidateGenerator).dataSource(ds, dsp) - .modelSaver(new FileModelSaver(modelSavePath)) - .scoreFunction(new TestSetLossScoreFunction(true)) - .terminationConditions(new MaxTimeCondition(10, TimeUnit.MINUTES), - new MaxCandidatesCondition(10)) - .build(); - - - // parallel execution of multiple optimization sessions - HashMap statsStorageForSession = new HashMap<>(); - for (int i = 0; i < 3; i++) { - String sessionId = "sid" + i; - IOptimizationRunner runner = - new LocalOptimizationRunner(configuration, new MultiLayerNetworkTaskCreator()); - StatsStorage ss = new InMemoryStatsStorage(); - statsStorageForSession.put(sessionId, ss); - StatusListener sl = new ArbiterStatusListener(sessionId, ss); - runner.addListeners(sl); - // Asynchronous execution - new Thread(runner::execute).start(); - } - - Function statsStorageProvider = statsStorageForSession::get; - UIServer uIServer = UIServer.getInstance(true, statsStorageProvider); - String serverAddress = uIServer.getAddress(); - - for (String sessionId : statsStorageForSession.keySet()) { - log.info("Arbiter session can be attached at {}", sessionUrl(serverAddress, sessionId)); - } - - Thread.sleep(1000_000); - } - - - /** - * Get URL for arbiter session on given server address - * @param serverAddress server address, e.g.: http://localhost:9000 - * @param sessionId session ID (will be URL-encoded) - * @return URL - * @throws UnsupportedEncodingException if the character encoding is not supported - */ - private static String sessionUrl(String serverAddress, String sessionId) throws UnsupportedEncodingException { - return String.format("%s/arbiter/%s", serverAddress, URLEncoder.encode(sessionId, "UTF-8")); - } - - private static class MnistDataSetProvider implements DataProvider { - - @Override - public DataSetIterator trainData(Map dataParameters) { - try { - if (dataParameters == null || dataParameters.isEmpty()) { - return new MnistDataSetIterator(64, 10000, false, true, true, 123); - } - if (dataParameters.containsKey("batchsize")) { - int b = (Integer) dataParameters.get("batchsize"); - return new MnistDataSetIterator(b, 10000, false, true, true, 123); - } - return new MnistDataSetIterator(64, 10000, false, true, true, 123); - } catch (Exception e) { - throw new RuntimeException(e); - } - } - - @Override - public DataSetIterator testData(Map dataParameters) { - return trainData(dataParameters); - } - - @Override - public Class getDataType() { - return DataSetIterator.class; - } - - @Override - public String toString() { - return "MnistDataSetProvider()"; - } - } - - public static class MnistDataSource implements DataSource { - private int minibatch; - - public MnistDataSource() { - - } - - @Override - public void configure(Properties properties) { - this.minibatch = Integer.parseInt(properties.getProperty("minibatch", "16")); - } - - @Override - public Object trainData() { - try { - return new EarlyTerminationDataSetIterator(new MnistDataSetIterator(minibatch, true, 12345), 3); - } catch (Exception e) { - throw new RuntimeException(e); - } - } - - @Override - public Object testData() { - try { - return new EarlyTerminationDataSetIterator(new MnistDataSetIterator(minibatch, true, 12345), 3); - } catch (Exception e) { - throw new RuntimeException(e); - } - } - - @Override - public Class getDataType() { - return DataSetIterator.class; - } - } - -} diff --git a/arbiter/arbiter-ui/src/test/resources/logback.xml b/arbiter/arbiter-ui/src/test/resources/logback.xml deleted file mode 100644 index 410bdaae9..000000000 --- a/arbiter/arbiter-ui/src/test/resources/logback.xml +++ /dev/null @@ -1,51 +0,0 @@ - - - - - - logs/application.log - - %date - [%level] - from %logger in %thread - %n%message%n%xException%n - - - - - - %logger{15} - %message%n%xException{5} - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/arbiter/buildmultiplescalaversions.sh b/arbiter/buildmultiplescalaversions.sh deleted file mode 100644 index e04610a02..000000000 --- a/arbiter/buildmultiplescalaversions.sh +++ /dev/null @@ -1,53 +0,0 @@ -#! /bin/bash -################################################################################ -# Copyright (c) 2015-2018 Skymind, Inc. -# -# This program and the accompanying materials are made available under the -# terms of the Apache License, Version 2.0 which is available at -# https://www.apache.org/licenses/LICENSE-2.0. -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT -# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. -# -# SPDX-License-Identifier: Apache-2.0 -################################################################################ - -BASEDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" - -function echoError() { - (>&2 echo "$1") -} - -function scalaError() { - echoError "Changing Scala major version to 2.10 in the build did not change the state of your working copy, is Scala 2.11 still the default ?" - exit 2 -} - -function whatchanged() { - cd "$BASEDIR" - for i in $(git status -s --porcelain -- $(find ./ -mindepth 2 -name pom.xml)|awk '{print $2}'); do - echo "$(dirname $i)" - cd "$BASEDIR" - done -} - -set -eu -./change-scala-versions.sh 2.11 # should be idempotent, this is the default -mvn "$@" -./change-scala-versions.sh 2.10 -if [ -z "$(whatchanged)" ]; then - scalaError; -else - if [[ "${@#-pl}" = "$@" ]]; then - mvn -Dmaven.clean.skip=true -pl $(whatchanged| tr '\n' ',') -amd "$@" - else - # the arguments already tweak the project list ! don't tweak them more - # as this can lead to conflicts (excluding a project that's not part of - # the reactor) - mvn "$@" - fi -fi -./change-scala-versions.sh 2.11 # back to the default diff --git a/arbiter/contrib/formatter.xml b/arbiter/contrib/formatter.xml deleted file mode 100644 index d6cc96bf6..000000000 --- a/arbiter/contrib/formatter.xml +++ /dev/null @@ -1,353 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/arbiter/pom.xml b/arbiter/pom.xml deleted file mode 100644 index a3321c0ab..000000000 --- a/arbiter/pom.xml +++ /dev/null @@ -1,182 +0,0 @@ - - - - - - - - net.brutex.ai - deeplearning4j - 1.0.0-SNAPSHOT - - - 4.0.0 - - net.brutex.ai - arbiter - pom - - Arbiter - Model Evaluation and Testing - - - - Apache License, Version 2.0 - http://www.apache.org/licenses/LICENSE-2.0.txt - repo - - - - - arbiter-deeplearning4j - arbiter-core - arbiter-server - arbiter-ui - - - - - - org.apache.maven.plugins - maven-javadoc-plugin - - - generate-javadoc - prepare-package - - javadoc - - - - - - - - - - - net.alchim31.maven - scala-maven-plugin - ${maven-scala-plugin.version} - - - -deprecation - -explaintypes - -nobootcp - - - - - scala-compile-first - process-resources - - add-source - compile - - - - scala-test-compile - process-test-resources - - add-source - testCompile - - - - - - - - - - - test-nd4j-native - - - net.brutex.ai - nd4j-native - ${project.version} - test - - - net.brutex.ai - dl4j-test-resources - ${dl4j-test-resources.version} - test - - - - - - test-nd4j-cuda-10.2 - - - net.brutex.ai - nd4j-cuda-${cuda.version} - ${project.version} - test - - - net.brutex.ai - dl4j-test-resources - ${dl4j-test-resources.version} - test - - - - - only-eclipse - - - m2e.version - - - - - - - org.eclipse.m2e - lifecycle-mapping - 1.0.0 - - - - - - com.lewisd - lint-maven-plugin - [0.0.11,) - - check - - - - - - - - - - - - - - - - diff --git a/cavis-datavec/cavis-datavec-api/build.gradle b/cavis-datavec/cavis-datavec-api/build.gradle index ecad3eda0..c7f07f255 100644 --- a/cavis-datavec/cavis-datavec-api/build.gradle +++ b/cavis-datavec/cavis-datavec-api/build.gradle @@ -2,55 +2,10 @@ plugins { id 'java-library' id 'maven-publish' id 'signing' - id 'idea' } -ext { - buildTarget = rootProject.ext.buildTarget -} -idea { - module { - downloadJavadoc = true // defaults to false - downloadSources = true - } -} - -apply from: "../../chooseBackend.gradle" - -chipList.each { thisChip -> - configurations.register("${thisChip}TestImplementation") { - it.extendsFrom configurations.testImplementation - it.extendsFrom configurations.implementation - } - configurations.register("${thisChip}TestRuntime") { - it.extendsFrom configurations.testRuntimeOnly - it.extendsFrom configurations.api - it.extendsFrom configurations.implementation - it.extendsFrom configurations.testImplementation - } - - tasks.register("${thisChip}Test", Test) { - it.testClassesDirs = sourceSets.test.output.classesDirs - it.useJUnitPlatform() - it.classpath = configurations.getByName("${thisChip}TestRuntime") - it.classpath += sourceSets.test.output.classesDirs - it.classpath += sourceSets.main.output.classesDirs - it.ignoreFailures = true - it.testLogging { - events "PASSED", "SKIPPED", "FAILED", "STANDARD_OUT", "STANDARD_ERROR" - } - //it.jvmArgs("-Dorg.bytedeco.javacpp.logger.debug=true") - - // it.debug = true - } - - tasks.test.dependsOn "${thisChip}Test" -} - -test { - enabled = false -} +apply from: "${rootProject.projectDir.path}/createTestBackends.gradle" dependencies { testImplementation 'org.junit.jupiter:junit-jupiter-params' @@ -59,32 +14,6 @@ dependencies { testRuntimeOnly "net.brutex.ai:dl4j-test-resources:1.0.1-SNAPSHOT" - if(withCuda()) { - cudaTestRuntime platform(project(":cavis-common-platform")) - cudaTestRuntime project(":cavis-native:cavis-native-jcublas") - cudaTestRuntime group: "org.bytedeco", name: "openblas" - cudaTestRuntime group: "org.bytedeco", name: "openblas", classifier: buildTarget - cudaTestRuntime "org.bytedeco:cuda" - cudaTestRuntime (project(":cavis-native:cavis-native-lib")) { - capabilities{ - it.requireCapabilities "net.brutex.cavis-native:cavis-native-lib-cuda-support:1.0.0-SNAPSHOT" - } - } - } - - if(withCpu()) { - cpuTestRuntime project(":cavis-native:cavis-native-cpu") - cpuTestRuntime group: "org.bytedeco", name: "openblas" - cpuTestRuntime group: "org.bytedeco", name: "openblas", classifier: buildTarget - cpuTestRuntime (project(":cavis-native:cavis-native-lib")) { - capabilities{ - it.requireCapabilities "net.brutex.cavis-native:cavis-native-lib-cpu-support:1.0.0-SNAPSHOT" - } - } - } - - - implementation platform(project(':cavis-common-platform')) implementation project(':cavis-dnn:cavis-dnn-common') @@ -113,7 +42,6 @@ dependencies { testImplementation 'org.hamcrest:hamcrest-core:1.3' - implementation 'org.bytedeco:javacpp' } diff --git a/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/package-info.java b/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/package-info.java new file mode 100644 index 000000000..fe3929a3d --- /dev/null +++ b/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/package-info.java @@ -0,0 +1,6 @@ +/** + * This is the core data vectorisation API (cavis-datavec-api). The main concept is to have + * {@link org.datavec.api.Writable} forming a {@link org.datavec.api.Record}. + */ + +package org.datavec.api; \ No newline at end of file diff --git a/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/records/reader/RecordReader.java b/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/records/reader/RecordReader.java index 332358f74..a124ade3e 100644 --- a/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/records/reader/RecordReader.java +++ b/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/records/reader/RecordReader.java @@ -35,129 +35,130 @@ import java.util.List; public interface RecordReader extends AutoCloseable, Serializable, Configurable { - String NAME_SPACE = RecordReader.class.getName(); + String NAME_SPACE = RecordReader.class.getName(); - String APPEND_LABEL = NAME_SPACE + ".appendlabel"; - String LABELS = NAME_SPACE + ".labels"; + String APPEND_LABEL = NAME_SPACE + ".appendlabel"; + String LABELS = NAME_SPACE + ".labels"; - /** - * Called once at initialization. - * - * @param split the split that defines the range of records to read - * @throws IOException - * @throws InterruptedException - */ - void initialize(InputSplit split) throws IOException, InterruptedException; + /** + * Called once at initialization. + * + * @param split the split that defines the range of records to read + * @throws IOException + * @throws InterruptedException + */ + void initialize(InputSplit split) throws IOException, InterruptedException; - /** - * Called once at initialization. - * - * @param conf a configuration for initialization - * @param split the split that defines the range of records to read - * @throws IOException - * @throws InterruptedException - */ - void initialize(Configuration conf, InputSplit split) throws IOException, InterruptedException; + /** + * Called once at initialization. + * + * @param conf a configuration for initialization + * @param split the split that defines the range of records to read + * @throws IOException + * @throws InterruptedException + */ + void initialize(Configuration conf, InputSplit split) throws IOException, InterruptedException; - /** - * This method returns true, if next(int) signature is supported by this RecordReader implementation. - * - * @return - */ - boolean batchesSupported(); + /** + * This method returns true, if next(int) signature is supported by this RecordReader + * implementation. + * + * @return + */ + boolean batchesSupported(); - /** - * This method will be used, if batchesSupported() returns true. - * - * @param num - * @return - */ - List> next(int num); + /** + * This method will be used, if batchesSupported() returns true. + * + * @param num + * @return + */ + List> next(int num); - /** - * Get the next record - * - * @return - */ - List next(); + /** + * Get the next record + * + * @return + */ + List next(); + /** + * Whether there are anymore records + * + * @return + */ + boolean hasNext(); - /** - * Whether there are anymore records - * - * @return - */ - boolean hasNext(); + /** + * List of label strings + * + * @return + */ + List getLabels(); - /** - * List of label strings - * - * @return - */ - List getLabels(); + /** + * Reset record reader iterator + */ + void reset(); - /** - * Reset record reader iterator - */ - void reset(); + /** + * @return True if the record reader can be reset, false otherwise. Note that some record readers + * cannot be reset - for example, if they are backed by a non-resettable input split (such as + * certain types of streams) + */ + boolean resetSupported(); - /** - * @return True if the record reader can be reset, false otherwise. Note that some record readers cannot be reset - - * for example, if they are backed by a non-resettable input split (such as certain types of streams) - */ - boolean resetSupported(); - - /** - * Load the record from the given DataInputStream - * Unlike {@link #next()} the internal state of the RecordReader is not modified - * Implementations of this method should not close the DataInputStream - * - * @throws IOException if error occurs during reading from the input stream - */ - List record(URI uri, DataInputStream dataInputStream) throws IOException; + /** + * Load the record from the given DataInputStream Unlike {@link #next()} the internal state of the + * RecordReader is not modified Implementations of this method should not close the + * DataInputStream + * + * @throws IOException if error occurs during reading from the input stream + */ + List record(URI uri, DataInputStream dataInputStream) throws IOException; - /** - * Similar to {@link #next()}, but returns a {@link Record} object, that may include metadata such as the source - * of the data - * - * @return next record - */ - Record nextRecord(); + /** + * Similar to {@link #next()}, but returns a {@link Record} object, that may include metadata such + * as the source of the data + * + * @return next record + */ + Record nextRecord(); - /** - * Load a single record from the given {@link RecordMetaData} instance
- * Note: that for data that isn't splittable (i.e., text data that needs to be scanned/split), it is more efficient to - * load multiple records at once using {@link #loadFromMetaData(List)} - * - * @param recordMetaData Metadata for the record that we want to load from - * @return Single record for the given RecordMetaData instance - * @throws IOException If I/O error occurs during loading - */ - Record loadFromMetaData(RecordMetaData recordMetaData) throws IOException; + /** + * Load a single record from the given {@link RecordMetaData} instance
Note: that for data + * that isn't splittable (i.e., text data that needs to be scanned/split), it is more efficient to + * load multiple records at once using {@link #loadFromMetaData(List)} + * + * @param recordMetaData Metadata for the record that we want to load from + * @return Single record for the given RecordMetaData instance + * @throws IOException If I/O error occurs during loading + */ + Record loadFromMetaData(RecordMetaData recordMetaData) throws IOException; - /** - * Load multiple records from the given a list of {@link RecordMetaData} instances
- * - * @param recordMetaDatas Metadata for the records that we want to load from - * @return Multiple records for the given RecordMetaData instances - * @throws IOException If I/O error occurs during loading - */ - List loadFromMetaData(List recordMetaDatas) throws IOException; + /** + * Load multiple records from the given a list of {@link RecordMetaData} instances
+ * + * @param recordMetaDatas Metadata for the records that we want to load from + * @return Multiple records for the given RecordMetaData instances + * @throws IOException If I/O error occurs during loading + */ + List loadFromMetaData(List recordMetaDatas) throws IOException; - /** - * Get the record listeners for this record reader. - */ - List getListeners(); + /** + * Get the record listeners for this record reader. + */ + List getListeners(); - /** - * Set the record listeners for this record reader. - */ - void setListeners(RecordListener... listeners); + /** + * Set the record listeners for this record reader. + */ + void setListeners(RecordListener... listeners); - /** - * Set the record listeners for this record reader. - */ - void setListeners(Collection listeners); + /** + * Set the record listeners for this record reader. + */ + void setListeners(Collection listeners); } diff --git a/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/records/reader/impl/FileRecordReader.java b/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/records/reader/impl/FileRecordReader.java index fb010f258..33a79b0c2 100644 --- a/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/records/reader/impl/FileRecordReader.java +++ b/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/records/reader/impl/FileRecordReader.java @@ -40,202 +40,206 @@ import java.util.*; /** * File reader/writer - * - * @author Adam Gibson */ public class FileRecordReader extends BaseRecordReader { - protected Iterator locationsIterator; - protected Configuration conf; - protected URI currentUri; - protected List labels; - protected boolean appendLabel = false; - @Getter @Setter - protected String charset = StandardCharsets.UTF_8.name(); //Using String as StandardCharsets.UTF_8 is not serializable + protected Iterator locationsIterator; + protected Configuration conf; + protected URI currentUri; + protected List labels; + protected boolean appendLabel = false; + @Getter + @Setter + protected String charset = StandardCharsets.UTF_8.name(); //Using String as StandardCharsets.UTF_8 is not serializable - public FileRecordReader() {} + public FileRecordReader() { + } - @Override - public void initialize(InputSplit split) throws IOException, InterruptedException { - super.initialize(split); - doInitialize(split); - } + @Override + public void initialize(InputSplit split) throws IOException, InterruptedException { + super.initialize(split); + doInitialize(split); + } - protected void doInitialize(InputSplit split) { + protected void doInitialize(InputSplit split) { - if (labels == null && appendLabel) { - URI[] locations = split.locations(); - if (locations.length > 0) { - Set labels = new HashSet<>(); - for(URI u : locations){ - String[] pathSplit = u.toString().split("[/\\\\]"); - labels.add(pathSplit[pathSplit.length-2]); - } - this.labels = new ArrayList<>(labels); - Collections.sort(this.labels); - } + if (labels == null && appendLabel) { + URI[] locations = split.locations(); + if (locations.length > 0) { + Set labels = new HashSet<>(); + for (URI u : locations) { + String[] pathSplit = u.toString().split("[/\\\\]"); + labels.add(pathSplit[pathSplit.length - 2]); } - locationsIterator = split.locationsIterator(); + this.labels = new ArrayList<>(labels); + Collections.sort(this.labels); + } + } + locationsIterator = split.locationsIterator(); + } + + @Override + public void initialize(Configuration conf, InputSplit split) + throws IOException, InterruptedException { + appendLabel = conf.getBoolean(APPEND_LABEL, true); + doInitialize(split); + this.inputSplit = split; + this.conf = conf; + } + + @Override + public List next() { + return nextRecord().getRecord(); + } + + private List loadFromStream(URI uri, InputStream next, Charset charset) { + List ret = new ArrayList<>(); + try { + if (!(next instanceof BufferedInputStream)) { + next = new BufferedInputStream(next); + } + String s = org.apache.commons.io.IOUtils.toString(next, charset); + ret.add(new Text(s)); + if (appendLabel) { + int idx = getLabel(uri); + ret.add(new IntWritable(idx)); + } + } catch (IOException e) { + throw new IllegalStateException("Error reading from input stream: " + uri); + } + return ret; + } + + /** + * Return the current label. The index of the current file's parent directory in the label list + * + * @return The index of the current file's parent directory + */ + public int getCurrentLabel() { + return getLabel(currentUri); + } + + public int getLabel(URI uri) { + String s = uri.toString(); + int lastIdx = Math.max(s.lastIndexOf('/'), + s.lastIndexOf('\\')); //Note: if neither are found, -1 is fine here + String sub = s.substring(0, lastIdx); + int secondLastIdx = Math.max(sub.lastIndexOf('/'), sub.lastIndexOf('\\')); + String name = s.substring(secondLastIdx + 1, lastIdx); + return labels.indexOf(name); + } + + public List getLabels() { + return labels; + } + + public void setLabels(List labels) { + this.labels = labels; + } + + @Override + public boolean hasNext() { + return locationsIterator.hasNext(); + } + + @Override + public void close() throws IOException { + + } + + @Override + public void setConf(Configuration conf) { + this.conf = conf; + } + + @Override + public Configuration getConf() { + return conf; + } + + @Override + public List> next(int num) { + List> ret = new ArrayList<>(num); + int numBatches = 0; + while (hasNext() && numBatches < num) { + ret.add(next()); } - @Override - public void initialize(Configuration conf, InputSplit split) throws IOException, InterruptedException { - appendLabel = conf.getBoolean(APPEND_LABEL, true); - doInitialize(split); - this.inputSplit = split; - this.conf = conf; + return ret; + } + + @Override + public void reset() { + if (inputSplit == null) { + throw new UnsupportedOperationException("Cannot reset without first initializing"); + } + try { + doInitialize(inputSplit); + } catch (Exception e) { + throw new RuntimeException("Error during LineRecordReader reset", e); + } + } + + @Override + public boolean resetSupported() { + if (inputSplit != null) { + return inputSplit.resetSupported(); + } + return false; //reset() throws exception on reset() if inputSplit is null + } + + @Override + public List record(URI uri, DataInputStream dataInputStream) throws IOException { + invokeListeners(uri); + //Here: reading the entire file to a Text writable + BufferedReader br = new BufferedReader(new InputStreamReader(dataInputStream)); + StringBuilder sb = new StringBuilder(); + String line; + while ((line = br.readLine()) != null) { + sb.append(line).append("\n"); + } + return Collections.singletonList(new Text(sb.toString())); + } + + @Override + public Record nextRecord() { + URI next = locationsIterator.next(); + invokeListeners(next); + + List ret; + try (InputStream s = streamCreatorFn.apply(next)) { + ret = loadFromStream(next, s, Charset.forName(charset)); + } catch (IOException e) { + throw new RuntimeException("Error reading from stream for URI: " + next); } - @Override - public List next() { - return nextRecord().getRecord(); + return new org.datavec.api.records.impl.Record(ret, + new RecordMetaDataURI(next, FileRecordReader.class)); + } + + @Override + public Record loadFromMetaData(RecordMetaData recordMetaData) throws IOException { + return loadFromMetaData(Collections.singletonList(recordMetaData)).get(0); + } + + @Override + public List loadFromMetaData(List recordMetaDatas) throws IOException { + List out = new ArrayList<>(); + + for (RecordMetaData meta : recordMetaDatas) { + URI uri = meta.getURI(); + + List list; + try (InputStream s = streamCreatorFn.apply(uri)) { + list = loadFromStream(uri, s, Charset.forName(charset)); + } catch (IOException e) { + throw new RuntimeException("Error reading from stream for URI: " + uri); + } + + out.add(new org.datavec.api.records.impl.Record(list, meta)); } - private List loadFromStream(URI uri, InputStream next, Charset charset) { - List ret = new ArrayList<>(); - try { - if(!(next instanceof BufferedInputStream)){ - next = new BufferedInputStream(next); - } - String s = org.apache.commons.io.IOUtils.toString(next, charset); - ret.add(new Text(s)); - if (appendLabel) { - int idx = getLabel(uri); - ret.add(new IntWritable(idx)); - } - } catch (IOException e) { - throw new IllegalStateException("Error reading from input stream: " + uri); - } - return ret; - } - - /** - * Return the current label. - * The index of the current file's parent directory - * in the label list - * @return The index of the current file's parent directory - */ - public int getCurrentLabel() { - return getLabel(currentUri); - } - - public int getLabel(URI uri){ - String s = uri.toString(); - int lastIdx = Math.max(s.lastIndexOf('/'), s.lastIndexOf('\\')); //Note: if neither are found, -1 is fine here - String sub = s.substring(0, lastIdx); - int secondLastIdx = Math.max(sub.lastIndexOf('/'), sub.lastIndexOf('\\')); - String name = s.substring(secondLastIdx+1, lastIdx); - return labels.indexOf(name); - } - - public List getLabels() { - return labels; - } - - public void setLabels(List labels) { - this.labels = labels; - } - - @Override - public boolean hasNext() { - return locationsIterator.hasNext(); - } - - @Override - public void close() throws IOException { - - } - - @Override - public void setConf(Configuration conf) { - this.conf = conf; - } - - @Override - public Configuration getConf() { - return conf; - } - - @Override - public List> next(int num) { - List> ret = new ArrayList<>(num); - int numBatches = 0; - while (hasNext() && numBatches < num) { - ret.add(next()); - } - - return ret; - } - @Override - public void reset() { - if (inputSplit == null) - throw new UnsupportedOperationException("Cannot reset without first initializing"); - try { - doInitialize(inputSplit); - } catch (Exception e) { - throw new RuntimeException("Error during LineRecordReader reset", e); - } - } - - @Override - public boolean resetSupported() { - if(inputSplit != null){ - return inputSplit.resetSupported(); - } - return false; //reset() throws exception on reset() if inputSplit is null - } - - @Override - public List record(URI uri, DataInputStream dataInputStream) throws IOException { - invokeListeners(uri); - //Here: reading the entire file to a Text writable - BufferedReader br = new BufferedReader(new InputStreamReader(dataInputStream)); - StringBuilder sb = new StringBuilder(); - String line; - while ((line = br.readLine()) != null) { - sb.append(line).append("\n"); - } - return Collections.singletonList(new Text(sb.toString())); - } - - @Override - public Record nextRecord() { - URI next = locationsIterator.next(); - invokeListeners(next); - - List ret; - try(InputStream s = streamCreatorFn.apply(next)) { - ret = loadFromStream(next, s, Charset.forName(charset)); - } catch (IOException e){ - throw new RuntimeException("Error reading from stream for URI: " + next); - } - - return new org.datavec.api.records.impl.Record(ret,new RecordMetaDataURI(next, FileRecordReader.class)); - } - - @Override - public Record loadFromMetaData(RecordMetaData recordMetaData) throws IOException { - return loadFromMetaData(Collections.singletonList(recordMetaData)).get(0); - } - - @Override - public List loadFromMetaData(List recordMetaDatas) throws IOException { - List out = new ArrayList<>(); - - for (RecordMetaData meta : recordMetaDatas) { - URI uri = meta.getURI(); - - List list; - try(InputStream s = streamCreatorFn.apply(uri)) { - list = loadFromStream(uri, s, Charset.forName(charset)); - } catch (IOException e){ - throw new RuntimeException("Error reading from stream for URI: " + uri); - } - - out.add(new org.datavec.api.records.impl.Record(list, meta)); - } - - return out; - } + return out; + } } diff --git a/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/writable/WritableFactory.java b/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/writable/WritableFactory.java index 2b7d419ea..eba29e63c 100644 --- a/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/writable/WritableFactory.java +++ b/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/writable/WritableFactory.java @@ -32,95 +32,99 @@ import org.datavec.api.Writable; public class WritableFactory { - private static final WritableFactory INSTANCE = new WritableFactory(); + private static final WritableFactory INSTANCE = new WritableFactory(); - private final Map> map = new ConcurrentHashMap<>(); - private final Map> constructorMap = new ConcurrentHashMap<>(); + private final Map> map = new ConcurrentHashMap<>(); + private final Map> constructorMap = new ConcurrentHashMap<>(); - private WritableFactory() { - for (WritableType wt : WritableType.values()) { - if (wt.isCoreWritable()) { - registerWritableType((short) wt.ordinal(), wt.getWritableClass()); - } - } + private WritableFactory() { + for (WritableType wt : WritableType.values()) { + if (wt.isCoreWritable()) { + registerWritableType((short) wt.ordinal(), wt.getWritableClass()); + } + } + } + + /** + * @return Singleton WritableFactory instance + */ + public static WritableFactory getInstance() { + return INSTANCE; + } + + /** + * Register a writable class with a specific key (as a short). Note that key values must be unique + * for each type of Writable, as they are used as type information in certain types of + * serialisation. Consequently, an exception will be thrown If the key value is not unique or is + * already assigned.
Note that in general, this method needs to only be used for custom + * Writable types; Care should be taken to ensure that the given key does not change once + * assigned. + * + * @param writableTypeKey Key for the Writable + * @param writableClass Class for the given key. Must have a no-arg constructor + */ + public void registerWritableType(short writableTypeKey, + @NonNull Class writableClass) { + if (map.containsKey(writableTypeKey)) { + throw new UnsupportedOperationException( + "Key " + writableTypeKey + " is already registered to type " + + map.get(writableTypeKey) + " and cannot be registered to " + writableClass); } - /** - * @return Singleton WritableFactory instance - */ - public static WritableFactory getInstance() { - return INSTANCE; + Constructor c; + try { + c = writableClass.getDeclaredConstructor(); + } catch (NoSuchMethodException e) { + throw new RuntimeException("Cannot find no-arg constructor for class " + writableClass); } - /** - * Register a writable class with a specific key (as a short). Note that key values must be unique for each type of - * Writable, as they are used as type information in certain types of serialisation. Consequently, an exception will - * be thrown If the key value is not unique or is already assigned.
- * Note that in general, this method needs to only be used for custom Writable types; Care should be taken to ensure - * that the given key does not change once assigned. - * - * @param writableTypeKey Key for the Writable - * @param writableClass Class for the given key. Must have a no-arg constructor - */ - public void registerWritableType(short writableTypeKey, @NonNull Class writableClass) { - if (map.containsKey(writableTypeKey)) { - throw new UnsupportedOperationException("Key " + writableTypeKey + " is already registered to type " - + map.get(writableTypeKey) + " and cannot be registered to " + writableClass); - } + map.put(writableTypeKey, writableClass); + constructorMap.put(writableTypeKey, c); + } - Constructor c; - try { - c = writableClass.getDeclaredConstructor(); - } catch (NoSuchMethodException e) { - throw new RuntimeException("Cannot find no-arg constructor for class " + writableClass); - } - - map.put(writableTypeKey, writableClass); - constructorMap.put(writableTypeKey, c); + /** + * Create a new writable instance (using reflection) given the specified key + * + * @param writableTypeKey Key to create a new writable instance for + * @return A new (empty/default) Writable instance + */ + public Writable newWritable(short writableTypeKey) { + Constructor c = constructorMap.get(writableTypeKey); + if (c == null) { + throw new IllegalStateException("Unknown writable key: " + writableTypeKey); } - - /** - * Create a new writable instance (using reflection) given the specified key - * - * @param writableTypeKey Key to create a new writable instance for - * @return A new (empty/default) Writable instance - */ - public Writable newWritable(short writableTypeKey) { - Constructor c = constructorMap.get(writableTypeKey); - if (c == null) { - throw new IllegalStateException("Unknown writable key: " + writableTypeKey); - } - try { - return c.newInstance(); - } catch (Exception e) { - throw new RuntimeException("Could not create new Writable instance"); - } + try { + return c.newInstance(); + } catch (Exception e) { + throw new RuntimeException("Could not create new Writable instance"); } + } - /** - * A convenience method for writing a given Writable object to a DataOutput. The key is 1st written (a single short) - * followed by the value from writable. - * - * @param w Writable value - * @param dataOutput DataOutput to write both key and value to - * @throws IOException If an error occurs during writing to the DataOutput - */ - public void writeWithType(Writable w, DataOutput dataOutput) throws IOException { - w.writeType(dataOutput); - w.write(dataOutput); - } + /** + * A convenience method for writing a given Writable object to a DataOutput. The key is 1st + * written (a single short) followed by the value from writable. + * + * @param w Writable value + * @param dataOutput DataOutput to write both key and value to + * @throws IOException If an error occurs during writing to the DataOutput + */ + public void writeWithType(Writable w, DataOutput dataOutput) throws IOException { + w.writeType(dataOutput); + w.write(dataOutput); + } - /** - * Read a Writable From the DataInput, where the Writable was previously written using {@link #writeWithType(Writable, DataOutput)} - * - * @param dataInput DataInput to read the Writable from - * @return Writable from the DataInput - * @throws IOException In an error occurs during reading - */ - public Writable readWithType(DataInput dataInput) throws IOException { - Writable w = newWritable(dataInput.readShort()); - w.readFields(dataInput); - return w; - } + /** + * Read a Writable From the DataInput, where the Writable was previously written using + * {@link #writeWithType(Writable, DataOutput)} + * + * @param dataInput DataInput to read the Writable from + * @return Writable from the DataInput + * @throws IOException In an error occurs during reading + */ + public Writable readWithType(DataInput dataInput) throws IOException { + Writable w = newWritable(dataInput.readShort()); + w.readFields(dataInput); + return w; + } } diff --git a/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/writable/WritableType.java b/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/writable/WritableType.java index 3afbe4088..a889dfd39 100644 --- a/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/writable/WritableType.java +++ b/cavis-datavec/cavis-datavec-api/src/main/java/org/datavec/api/writable/WritableType.java @@ -23,72 +23,71 @@ package org.datavec.api.writable; import org.datavec.api.Writable; public enum WritableType { - Boolean, Byte, Double, Float, Int, Long, Null, Text, NDArray, Image,Arrow,Bytes; + Boolean, Byte, Double, Float, Int, Long, Null, Text, NDArray, Image, Arrow, Bytes; - //NOTE TO DEVELOPERS: - //In the current implementation, the order (ordinal idx) for the WritableType values matters. - //New writables can be added to the end of the list, but not between exiting types, as this will change the - //ordinal value for all writable types that follow, which will mess up serialization in some cases (like Spark - // sequence and map files) - //Alternatively, modify WritableType.typeIdx() to ensure backward compatibility + //NOTE TO DEVELOPERS: + //In the current implementation, the order (ordinal idx) for the WritableType values matters. + //New writables can be added to the end of the list, but not between exiting types, as this will change the + //ordinal value for all writable types that follow, which will mess up serialization in some cases (like Spark + // sequence and map files) + //Alternatively, modify WritableType.typeIdx() to ensure backward compatibility - /** - * - * @return True if Writable is defined in datavec-api, false otherwise - */ - public boolean isCoreWritable() { - switch (this) { - case Image: - case Arrow: - return false; - default: - return true; - } + /** + * @return True if Writable is defined in datavec-api, false otherwise + */ + public boolean isCoreWritable() { + switch (this) { + case Image: + case Arrow: + return false; + default: + return true; } + } - /** - * Return a unique type index for the given writable - * - * @return Type index for the writable - */ - public short typeIdx() { - return (short) this.ordinal(); - } + /** + * Return a unique type index for the given writable + * + * @return Type index for the writable + */ + public short typeIdx() { + return (short) this.ordinal(); + } - /** - * Return the class of the implementation corresponding to each WritableType. - * Note that if {@link #isCoreWritable()} returns false, null will be returned by this method. - * - * @return Class for the given WritableType - */ - public Class getWritableClass() { - switch (this) { - case Boolean: - return BooleanWritable.class; - case Byte: - return ByteWritable.class; - case Double: - return DoubleWritable.class; - case Float: - return FloatWritable.class; - case Int: - return IntWritable.class; - case Long: - return LongWritable.class; - case Null: - return NullWritable.class; - case Text: - return Text.class; - case NDArray: - return NDArrayWritable.class; - case Bytes: - return ByteWritable.class; - case Image: - case Arrow: - default: - return null; - } + /** + * Return the class of the implementation corresponding to each WritableType. Note that if + * {@link #isCoreWritable()} returns false, null will be returned by this method. + * + * @return Class for the given WritableType + */ + public Class getWritableClass() { + switch (this) { + case Boolean: + return BooleanWritable.class; + case Byte: + return ByteWritable.class; + case Double: + return DoubleWritable.class; + case Float: + return FloatWritable.class; + case Int: + return IntWritable.class; + case Long: + return LongWritable.class; + case Null: + return NullWritable.class; + case Text: + return Text.class; + case NDArray: + return NDArrayWritable.class; + case Bytes: + return ByteWritable.class; + case Image: + case Arrow: + default: + return null; } + } } diff --git a/cavis-full/build.gradle b/cavis-full/build.gradle index 03cf9e177..774c600f5 100644 --- a/cavis-full/build.gradle +++ b/cavis-full/build.gradle @@ -106,6 +106,17 @@ publishing { */ } } + + task printDeps { + doLast { + configurations.api.dependencies.each { dep -> + println "${dep.group} - ${dep.name} - ${dep.version}" + dep.artifacts.each { art -> + println " ${art.extension} - ${art.classifier}" + } + } + } + } } diff --git a/cavis-native/cavis-native-lib/build.gradle b/cavis-native/cavis-native-lib/build.gradle index 36fa1f765..0439110ce 100644 --- a/cavis-native/cavis-native-lib/build.gradle +++ b/cavis-native/cavis-native-lib/build.gradle @@ -424,6 +424,7 @@ tasks.withType(Javadoc) { options.addStringOption('Xdoclint:none', '-quiet') } +/* jar { manifest { attributes 'Class-Path': configurations.runtimeClasspath.collect { it.getName() }.join(' '), @@ -436,7 +437,7 @@ jar { } //archiveClassifier = "${javacppPlatform}${javacppPlatformExtension}-${chip}" } - +*/ javadoc { dependsOn "javacppPomProperties" failOnError = false @@ -457,6 +458,13 @@ javadoc { enabled = true } +artifacts { + chipList.each { thisChip -> + implementation(tasks.getByName("${thisChip}SupportJar")) + } +} + +/* artifacts { archives jar chipList.each { thisChip -> @@ -464,6 +472,8 @@ artifacts { } } + */ + publishing { publications { mavenJava(MavenPublication) { @@ -499,6 +509,19 @@ if( osdetector.os.startsWith("windows")) { } } + +task printDeps { + doLast { + configurations.apiElements.dependencies.each { dep -> + println "${dep.group} - ${dep.name} - ${dep.version}" + dep.artifacts.each { art -> + println " ${art.extension} - ${art.classifier}" + } + } + } +} + + /* def pomClosure = { name = 'Brutex AI - Native Components' diff --git a/chooseBackend.gradle b/chooseBackend.gradle index 258650a05..9e34b7552 100644 --- a/chooseBackend.gradle +++ b/chooseBackend.gradle @@ -19,13 +19,22 @@ * */ ext { - chip = (properties.CAVIS_CHIP ?: "cuda,cpu").toLowerCase() + chip = (properties.CAVIS_CHIP ?: "cuda,cpu").toLowerCase() //the default is to build for CPU and CUDA + testChip = (properties.CAVIS_TEST_CHIP ?: " ").toLowerCase() //the default is without specific backend chipList = chip.split(",") + testChipList = testChip.split(",") + /* just for usability */ withCuda = { -> return chip.contains("cuda") } withCpu = { -> return chip.contains("cpu") } + withCudaTest = { -> + return testChip.contains("cuda") + } + withCpuTest = { -> + return testChip.contains("cpu") + } } diff --git a/createTestBackends.gradle b/createTestBackends.gradle index cbe536802..a0cef6c24 100644 --- a/createTestBackends.gradle +++ b/createTestBackends.gradle @@ -24,7 +24,7 @@ ext { buildTarget = rootProject.ext.buildTarget apply from: new File("${project.rootProject.projectDir}/chooseBackend.gradle") - chipList.each { thisChip -> + testChipList.each { thisChip -> configurations.register("${thisChip}TestImplementation") { it.extendsFrom configurations.testImplementation, configurations.implementation @@ -79,7 +79,7 @@ ext { dependencies { - if (withCuda()) { + if (withCudaTest()) { cudaTestRuntime platform(projects.cavisCommonPlatform) cudaTestRuntime projects.cavisNative.cavisNativeJcublas cudaTestRuntime group: "org.bytedeco", name: "openblas" @@ -89,12 +89,12 @@ ext { cudaTestRuntime group: "org.bytedeco", name: "cuda", classifier: "${buildTarget}-redist" cudaTestRuntime(project(":cavis-native:cavis-native-lib")) { capabilities { - it.requireCapabilities "net.brutex.cavis-native:cavis-native-lib-cuda-support:1.0.0-SNAPSHOT" + it.requireCapabilities "net.brutex.cavis.native:cavis-native-lib-cuda-support:1.0.0-SNAPSHOT" } } } - if (withCpu()) { + if (withCpuTest()) { cpuTestRuntime platform(projects.cavisCommonPlatform) cpuTestRuntime projects.cavisNative.cavisNativeCpu cpuTestRuntime group: "org.bytedeco", name: "openblas" @@ -103,7 +103,7 @@ ext { cpuTestRuntime group: "org.bytedeco", name: "opencv", classifier: buildTarget cpuTestRuntime(project(":cavis-native:cavis-native-lib")) { capabilities { - it.requireCapabilities "net.brutex.cavis-native:cavis-native-lib-cpu-support:1.0.0-SNAPSHOT" + it.requireCapabilities "net.brutex.cavis.native:cavis-native-lib-cpu-support:1.0.0-SNAPSHOT" } } }