diff --git a/ADRs/0006 - Test architecture.md b/ADRs/0006 - Test architecture.md index 4703fa5da..df7914f56 100644 --- a/ADRs/0006 - Test architecture.md +++ b/ADRs/0006 - Test architecture.md @@ -12,7 +12,7 @@ DL4J was a junit 4 based code based for testing. It's now based on junit 5's jupiter API, which has support for [Tags](https://junit.org/junit5/docs/5.0.1/api/org/junit/jupiter/api/Tag.html). DL4j's code base has a number of different kinds of tests that fall in to several categories: -1. Long and flaky involving distributed systems (spark, parameter server) +1. Long and flaky involving distributed systems (spark, parameter-server) 2. Code that requires large downloads, but runs quickly 3. Quick tests that test basic functionality 4. Comprehensive integration tests that test several parts of a code base @@ -38,8 +38,10 @@ A few kinds of tags exist: 3. Distributed systems: spark, multi-threaded 4. Functional cross-cutting concerns: multi module tests, similar functionality (excludes time based) 5. Platform specific tests that can vary on different hardware: cpu, gpu -6. JVM crash: Tests with native code can crash the JVM for tests. It's useful to be able to turn those off when debugging.: jvm-crash - +6. JVM crash: (jvm-crash) Tests with native code can crash the JVM for tests. It's useful to be able to turn those off when debugging.: jvm-crash +7. RNG: (rng) for RNG related tests +8. Samediff:(samediff) samediff related tests +9. Training related functionality ## Consequences diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVLineSequenceRecordReaderTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVLineSequenceRecordReaderTest.java index b450983dc..cdf15de05 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVLineSequenceRecordReaderTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVLineSequenceRecordReaderTest.java @@ -26,6 +26,7 @@ import org.datavec.api.split.FileSplit; import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.tests.BaseND4JTest; @@ -38,8 +39,11 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import org.junit.jupiter.api.DisplayName; import java.nio.file.Path; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Csv Line Sequence Record Reader Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class CSVLineSequenceRecordReaderTest extends BaseND4JTest { @TempDir @@ -54,8 +58,8 @@ class CSVLineSequenceRecordReaderTest extends BaseND4JTest { FileUtils.writeStringToFile(source, str, StandardCharsets.UTF_8); SequenceRecordReader rr = new CSVLineSequenceRecordReader(); rr.initialize(new FileSplit(source)); - List> exp0 = Arrays.asList(Collections.singletonList(new Text("a")), Collections.singletonList(new Text("b")), Collections.singletonList(new Text("c"))); - List> exp1 = Arrays.asList(Collections.singletonList(new Text("1")), Collections.singletonList(new Text("2")), Collections.singletonList(new Text("3")), Collections.singletonList(new Text("4"))); + List> exp0 = Arrays.asList(Collections.singletonList(new Text("a")), Collections.singletonList(new Text("b")), Collections.singletonList(new Text("c"))); + List> exp1 = Arrays.asList(Collections.singletonList(new Text("1")), Collections.singletonList(new Text("2")), Collections.singletonList(new Text("3")), Collections.singletonList(new Text("4"))); for (int i = 0; i < 3; i++) { int count = 0; while (rr.hasNext()) { diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVMultiSequenceRecordReaderTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVMultiSequenceRecordReaderTest.java index 6148feae1..ab61550d0 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVMultiSequenceRecordReaderTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVMultiSequenceRecordReaderTest.java @@ -27,6 +27,7 @@ import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.tests.BaseND4JTest; @@ -41,8 +42,11 @@ import static org.junit.jupiter.api.Assertions.assertFalse; import org.junit.jupiter.api.DisplayName; import java.nio.file.Path; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Csv Multi Sequence Record Reader Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class CSVMultiSequenceRecordReaderTest extends BaseND4JTest { @TempDir diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVNLinesSequenceRecordReaderTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVNLinesSequenceRecordReaderTest.java index 184462c8c..dc494c76c 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVNLinesSequenceRecordReaderTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVNLinesSequenceRecordReaderTest.java @@ -26,6 +26,7 @@ import org.datavec.api.records.reader.impl.csv.CSVNLinesSequenceRecordReader; import org.datavec.api.records.reader.impl.csv.CSVRecordReader; import org.datavec.api.split.FileSplit; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.common.io.ClassPathResource; @@ -34,12 +35,15 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Csvn Lines Sequence Record Reader Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class CSVNLinesSequenceRecordReaderTest extends BaseND4JTest { @Test - @DisplayName("Test CSVN Lines Sequence Record Reader") + @DisplayName("Test CSV Lines Sequence Record Reader") void testCSVNLinesSequenceRecordReader() throws Exception { int nLinesPerSequence = 10; SequenceRecordReader seqRR = new CSVNLinesSequenceRecordReader(nLinesPerSequence); diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVRecordReaderTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVRecordReaderTest.java index c7e840c42..4defe93b6 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVRecordReaderTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVRecordReaderTest.java @@ -34,9 +34,12 @@ import org.datavec.api.writable.IntWritable; import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; import org.junit.jupiter.api.DisplayName; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.TagNames; + import java.io.File; import java.io.IOException; import java.nio.file.Files; @@ -50,6 +53,8 @@ import static org.junit.jupiter.api.Assertions.*; @DisplayName("Csv Record Reader Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class CSVRecordReaderTest extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVSequenceRecordReaderTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVSequenceRecordReaderTest.java index 2ce347893..248722652 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVSequenceRecordReaderTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVSequenceRecordReaderTest.java @@ -27,6 +27,7 @@ import org.datavec.api.split.InputSplit; import org.datavec.api.split.NumberedFileInputSplit; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.tests.BaseND4JTest; @@ -43,8 +44,11 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import org.junit.jupiter.api.DisplayName; import java.nio.file.Path; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Csv Sequence Record Reader Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class CSVSequenceRecordReaderTest extends BaseND4JTest { @TempDir diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVVariableSlidingWindowRecordReaderTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVVariableSlidingWindowRecordReaderTest.java index 148f8ff0b..bee315176 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVVariableSlidingWindowRecordReaderTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/CSVVariableSlidingWindowRecordReaderTest.java @@ -24,6 +24,7 @@ import org.datavec.api.records.reader.impl.csv.CSVRecordReader; import org.datavec.api.records.reader.impl.csv.CSVVariableSlidingWindowRecordReader; import org.datavec.api.split.FileSplit; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.common.io.ClassPathResource; @@ -32,8 +33,11 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Csv Variable Sliding Window Record Reader Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class CSVVariableSlidingWindowRecordReaderTest extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/FileBatchRecordReaderTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/FileBatchRecordReaderTest.java index f59a264df..f19fa2bec 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/FileBatchRecordReaderTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/FileBatchRecordReaderTest.java @@ -28,6 +28,7 @@ import org.datavec.api.records.reader.impl.filebatch.FileBatchRecordReader; import org.datavec.api.records.reader.impl.filebatch.FileBatchSequenceRecordReader; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.junit.jupiter.params.ParameterizedTest; @@ -42,9 +43,12 @@ import static org.junit.jupiter.api.Assertions.*; import org.junit.jupiter.api.DisplayName; import java.nio.file.Path; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4jBackend; @DisplayName("File Batch Record Reader Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class FileBatchRecordReaderTest extends BaseND4JTest { @TempDir Path testDir; diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/FileRecordReaderTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/FileRecordReaderTest.java index d914cd95f..fa9a5b42a 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/FileRecordReaderTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/FileRecordReaderTest.java @@ -25,6 +25,7 @@ import org.datavec.api.split.CollectionInputSplit; import org.datavec.api.split.FileSplit; import org.datavec.api.split.InputSplit; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.common.io.ClassPathResource; @@ -36,8 +37,11 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertFalse; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("File Record Reader Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class FileRecordReaderTest extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/JacksonLineRecordReaderTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/JacksonLineRecordReaderTest.java index f182bc9ee..fbeecf312 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/JacksonLineRecordReaderTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/JacksonLineRecordReaderTest.java @@ -28,10 +28,12 @@ import org.datavec.api.split.FileSplit; import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.shade.jackson.core.JsonFactory; import org.nd4j.shade.jackson.databind.ObjectMapper; import java.io.File; @@ -45,6 +47,8 @@ import java.nio.file.Path; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Jackson Line Record Reader Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class JacksonLineRecordReaderTest extends BaseND4JTest { @TempDir diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/JacksonRecordReaderTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/JacksonRecordReaderTest.java index aa5026207..ff5567302 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/JacksonRecordReaderTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/JacksonRecordReaderTest.java @@ -31,10 +31,12 @@ import org.datavec.api.writable.IntWritable; import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.shade.jackson.core.JsonFactory; import org.nd4j.shade.jackson.databind.ObjectMapper; import org.nd4j.shade.jackson.dataformat.xml.XmlFactory; @@ -51,6 +53,8 @@ import java.nio.file.Path; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Jackson Record Reader Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class JacksonRecordReaderTest extends BaseND4JTest { @TempDir diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/LibSvmRecordReaderTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/LibSvmRecordReaderTest.java index 9d3ae9663..e421e9ef8 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/LibSvmRecordReaderTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/LibSvmRecordReaderTest.java @@ -26,6 +26,7 @@ import org.datavec.api.split.FileSplit; import org.datavec.api.writable.DoubleWritable; import org.datavec.api.writable.IntWritable; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.common.io.ClassPathResource; @@ -35,9 +36,13 @@ import static org.datavec.api.records.reader.impl.misc.LibSvmRecordReader.*; import static org.junit.jupiter.api.Assertions.assertEquals; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.TagNames; + import static org.junit.jupiter.api.Assertions.assertThrows; @DisplayName("Lib Svm Record Reader Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class LibSvmRecordReaderTest extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/LineReaderTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/LineReaderTest.java index 2339c47df..3d197405c 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/LineReaderTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/LineReaderTest.java @@ -30,6 +30,7 @@ import org.datavec.api.split.InputSplit; import org.datavec.api.split.InputStreamInputSplit; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.tests.BaseND4JTest; @@ -47,8 +48,11 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import org.junit.jupiter.api.DisplayName; import java.nio.file.Path; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Line Reader Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class LineReaderTest extends BaseND4JTest { diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/RegexRecordReaderTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/RegexRecordReaderTest.java index dbf3ea379..fb0200ab5 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/RegexRecordReaderTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/RegexRecordReaderTest.java @@ -33,6 +33,7 @@ import org.datavec.api.split.NumberedFileInputSplit; import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.tests.BaseND4JTest; @@ -46,8 +47,11 @@ import static org.junit.jupiter.api.Assertions.assertFalse; import org.junit.jupiter.api.DisplayName; import java.nio.file.Path; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Regex Record Reader Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class RegexRecordReaderTest extends BaseND4JTest { @TempDir diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/SVMLightRecordReaderTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/SVMLightRecordReaderTest.java index c072cea97..57ccce4dd 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/SVMLightRecordReaderTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/SVMLightRecordReaderTest.java @@ -26,6 +26,7 @@ import org.datavec.api.split.FileSplit; import org.datavec.api.writable.DoubleWritable; import org.datavec.api.writable.IntWritable; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.common.io.ClassPathResource; @@ -35,9 +36,13 @@ import static org.datavec.api.records.reader.impl.misc.SVMLightRecordReader.*; import static org.junit.jupiter.api.Assertions.assertEquals; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.TagNames; + import static org.junit.jupiter.api.Assertions.assertThrows; @DisplayName("Svm Light Record Reader Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class SVMLightRecordReaderTest extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/TestCollectionRecordReaders.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/TestCollectionRecordReaders.java index decbf0275..acaba9ccb 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/TestCollectionRecordReaders.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/TestCollectionRecordReaders.java @@ -26,15 +26,18 @@ import org.datavec.api.records.reader.SequenceRecordReader; import org.datavec.api.records.reader.impl.collection.CollectionSequenceRecordReader; import org.datavec.api.writable.IntWritable; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import java.util.ArrayList; import java.util.Arrays; import java.util.List; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class TestCollectionRecordReaders extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/TestConcatenatingRecordReader.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/TestConcatenatingRecordReader.java index b39a678ce..04056f6e0 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/TestConcatenatingRecordReader.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/TestConcatenatingRecordReader.java @@ -23,12 +23,15 @@ package org.datavec.api.records.reader.impl; import org.datavec.api.records.reader.RecordReader; import org.datavec.api.records.reader.impl.csv.CSVRecordReader; import org.datavec.api.split.FileSplit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class TestConcatenatingRecordReader extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/TestSerialization.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/TestSerialization.java index 933d65103..b37d3f2a8 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/TestSerialization.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/TestSerialization.java @@ -37,9 +37,11 @@ import org.datavec.api.transform.TransformProcess; import org.datavec.api.transform.schema.Schema; import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.shade.jackson.core.JsonFactory; import org.nd4j.shade.jackson.databind.ObjectMapper; @@ -48,7 +50,8 @@ import java.util.ArrayList; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class TestSerialization extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/transform/TransformProcessRecordReaderTests.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/transform/TransformProcessRecordReaderTests.java index ee2c9b091..7782d8a52 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/transform/TransformProcessRecordReaderTests.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/reader/impl/transform/TransformProcessRecordReaderTests.java @@ -30,9 +30,11 @@ import org.datavec.api.writable.IntWritable; import org.datavec.api.writable.LongWritable; import org.datavec.api.writable.Writable; import org.joda.time.DateTimeZone; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.TagNames; import java.util.ArrayList; import java.util.Arrays; @@ -41,6 +43,8 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class TransformProcessRecordReaderTests extends BaseND4JTest { @Test @@ -74,11 +78,11 @@ public class TransformProcessRecordReaderTests extends BaseND4JTest { public void simpleTransformTestSequence() { List> sequence = new ArrayList<>(); //First window: - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L), new IntWritable(0), + sequence.add(Arrays.asList(new LongWritable(1451606400000L), new IntWritable(0), new IntWritable(0))); - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 100L), new IntWritable(1), + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 100L), new IntWritable(1), new IntWritable(0))); - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 200L), new IntWritable(2), + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 200L), new IntWritable(2), new IntWritable(0))); Schema schema = new SequenceSchema.Builder().addColumnTime("timecolumn", DateTimeZone.UTC) diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/writer/impl/CSVRecordWriterTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/writer/impl/CSVRecordWriterTest.java index c63240896..f9057f98f 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/writer/impl/CSVRecordWriterTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/writer/impl/CSVRecordWriterTest.java @@ -26,6 +26,7 @@ import org.datavec.api.split.partition.NumberOfRecordsPartitioner; import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; import java.io.File; @@ -34,8 +35,11 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Csv Record Writer Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class CSVRecordWriterTest extends BaseND4JTest { @BeforeEach diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/writer/impl/LibSvmRecordWriterTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/writer/impl/LibSvmRecordWriterTest.java index 66c9ab3d2..3d1ea3090 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/writer/impl/LibSvmRecordWriterTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/writer/impl/LibSvmRecordWriterTest.java @@ -29,8 +29,10 @@ import org.datavec.api.writable.DoubleWritable; import org.datavec.api.writable.IntWritable; import org.datavec.api.writable.NDArrayWritable; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.common.io.ClassPathResource; @@ -46,6 +48,8 @@ import org.junit.jupiter.api.extension.ExtendWith; import static org.junit.jupiter.api.Assertions.assertThrows; @DisplayName("Lib Svm Record Writer Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class LibSvmRecordWriterTest extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/records/writer/impl/SVMLightRecordWriterTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/records/writer/impl/SVMLightRecordWriterTest.java index 56a130465..5bab04d45 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/records/writer/impl/SVMLightRecordWriterTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/records/writer/impl/SVMLightRecordWriterTest.java @@ -26,8 +26,10 @@ import org.datavec.api.records.writer.impl.misc.SVMLightRecordWriter; import org.datavec.api.split.FileSplit; import org.datavec.api.split.partition.NumberOfRecordsPartitioner; import org.datavec.api.writable.*; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.common.io.ClassPathResource; @@ -43,6 +45,8 @@ import org.junit.jupiter.api.extension.ExtendWith; import static org.junit.jupiter.api.Assertions.assertThrows; @DisplayName("Svm Light Record Writer Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class SVMLightRecordWriterTest extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/split/InputSplitTests.java b/datavec/datavec-api/src/test/java/org/datavec/api/split/InputSplitTests.java index b854c9967..0841dfb89 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/split/InputSplitTests.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/split/InputSplitTests.java @@ -20,7 +20,9 @@ package org.datavec.api.split; +import org.junit.jupiter.api.Tag; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.shade.guava.io.Files; import org.datavec.api.io.filters.BalancedPathFilter; import org.datavec.api.io.filters.RandomPathFilter; @@ -42,6 +44,8 @@ import static org.junit.jupiter.api.Assertions.assertTrue; * * @author saudet */ +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class InputSplitTests extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/split/NumberedFileInputSplitTests.java b/datavec/datavec-api/src/test/java/org/datavec/api/split/NumberedFileInputSplitTests.java index 72c06bd5d..2677c58cc 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/split/NumberedFileInputSplitTests.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/split/NumberedFileInputSplitTests.java @@ -20,13 +20,16 @@ package org.datavec.api.split; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import java.net.URI; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class NumberedFileInputSplitTests extends BaseND4JTest { @Test public void testNumberedFileInputSplitBasic() { diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/split/TestStreamInputSplit.java b/datavec/datavec-api/src/test/java/org/datavec/api/split/TestStreamInputSplit.java index fc718ed56..5c845d155 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/split/TestStreamInputSplit.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/split/TestStreamInputSplit.java @@ -26,11 +26,13 @@ import org.datavec.api.records.reader.impl.csv.CSVSequenceRecordReader; import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.common.function.Function; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import java.io.FileInputStream; @@ -46,7 +48,8 @@ import java.util.Random; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotEquals; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class TestStreamInputSplit extends BaseND4JTest { diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/split/TransformSplitTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/split/TransformSplitTest.java index 253eb98f4..ec7094472 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/split/TransformSplitTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/split/TransformSplitTest.java @@ -19,6 +19,7 @@ */ package org.datavec.api.split; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; import java.net.URI; @@ -28,11 +29,14 @@ import static java.util.Arrays.asList; import static org.junit.jupiter.api.Assertions.assertArrayEquals; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.TagNames; /** * @author Ede Meijer */ @DisplayName("Transform Split Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class TransformSplitTest extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/split/parittion/PartitionerTests.java b/datavec/datavec-api/src/test/java/org/datavec/api/split/parittion/PartitionerTests.java index e1ed7b50b..d721d5a62 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/split/parittion/PartitionerTests.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/split/parittion/PartitionerTests.java @@ -20,7 +20,9 @@ package org.datavec.api.split.parittion; +import org.junit.jupiter.api.Tag; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.shade.guava.io.Files; import org.datavec.api.conf.Configuration; import org.datavec.api.split.FileSplit; @@ -33,7 +35,8 @@ import java.io.File; import java.io.OutputStream; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class PartitionerTests extends BaseND4JTest { @Test public void testRecordsPerFilePartition() { diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/transform/TestTransformProcess.java b/datavec/datavec-api/src/test/java/org/datavec/api/transform/TestTransformProcess.java index 7a968ddfe..b9d0e4c1e 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/transform/TestTransformProcess.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/transform/TestTransformProcess.java @@ -29,13 +29,16 @@ import org.datavec.api.writable.DoubleWritable; import org.datavec.api.writable.IntWritable; import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import java.util.*; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class TestTransformProcess extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/transform/condition/TestConditions.java b/datavec/datavec-api/src/test/java/org/datavec/api/transform/condition/TestConditions.java index f49e0c4d4..fd2eb7862 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/transform/condition/TestConditions.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/transform/condition/TestConditions.java @@ -27,14 +27,17 @@ import org.datavec.api.transform.condition.string.StringRegexColumnCondition; import org.datavec.api.transform.schema.Schema; import org.datavec.api.transform.transform.TestTransforms; import org.datavec.api.writable.*; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import java.util.*; import static org.junit.jupiter.api.Assertions.assertFalse; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class TestConditions extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/transform/filter/TestFilters.java b/datavec/datavec-api/src/test/java/org/datavec/api/transform/filter/TestFilters.java index 0b339bffa..65b4ee3e3 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/transform/filter/TestFilters.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/transform/filter/TestFilters.java @@ -27,8 +27,10 @@ import org.datavec.api.transform.schema.Schema; import org.datavec.api.writable.DoubleWritable; import org.datavec.api.writable.IntWritable; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import java.util.ArrayList; import java.util.Arrays; @@ -38,7 +40,8 @@ import java.util.List; import static java.util.Arrays.asList; import static org.junit.jupiter.api.Assertions.assertFalse; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class TestFilters extends BaseND4JTest { diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/transform/join/TestJoin.java b/datavec/datavec-api/src/test/java/org/datavec/api/transform/join/TestJoin.java index 6db425d9e..ea80ea9c9 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/transform/join/TestJoin.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/transform/join/TestJoin.java @@ -26,9 +26,11 @@ import org.datavec.api.writable.IntWritable; import org.datavec.api.writable.NullWritable; import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import java.nio.file.Path; import java.util.ArrayList; @@ -37,7 +39,8 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertThrows; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class TestJoin extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/transform/reduce/TestMultiOpReduce.java b/datavec/datavec-api/src/test/java/org/datavec/api/transform/reduce/TestMultiOpReduce.java index 8337dcdb1..ef939fd06 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/transform/reduce/TestMultiOpReduce.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/transform/reduce/TestMultiOpReduce.java @@ -33,14 +33,17 @@ import org.datavec.api.transform.ops.IAggregableReduceOp; import org.datavec.api.transform.schema.Schema; import org.datavec.api.writable.*; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import java.util.*; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.fail; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class TestMultiOpReduce extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/transform/reduce/TestReductions.java b/datavec/datavec-api/src/test/java/org/datavec/api/transform/reduce/TestReductions.java index f7aa89170..2199b1f2a 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/transform/reduce/TestReductions.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/transform/reduce/TestReductions.java @@ -24,14 +24,17 @@ import org.datavec.api.transform.ops.IAggregableReduceOp; import org.datavec.api.transform.reduce.impl.GeographicMidpointReduction; import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import java.util.Arrays; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class TestReductions extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/transform/schema/TestJsonYaml.java b/datavec/datavec-api/src/test/java/org/datavec/api/transform/schema/TestJsonYaml.java index 0f9263bb4..45f251924 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/transform/schema/TestJsonYaml.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/transform/schema/TestJsonYaml.java @@ -22,11 +22,15 @@ package org.datavec.api.transform.schema; import org.datavec.api.transform.metadata.ColumnMetaData; import org.joda.time.DateTimeZone; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JACKSON_SERDE) public class TestJsonYaml extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/transform/schema/TestSchemaMethods.java b/datavec/datavec-api/src/test/java/org/datavec/api/transform/schema/TestSchemaMethods.java index 1439cfc40..f3cb22ee1 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/transform/schema/TestSchemaMethods.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/transform/schema/TestSchemaMethods.java @@ -21,11 +21,14 @@ package org.datavec.api.transform.schema; import org.datavec.api.transform.ColumnType; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class TestSchemaMethods extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/transform/sequence/TestReduceSequenceByWindowFunction.java b/datavec/datavec-api/src/test/java/org/datavec/api/transform/sequence/TestReduceSequenceByWindowFunction.java index 1bb9ae62a..6e5b800ea 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/transform/sequence/TestReduceSequenceByWindowFunction.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/transform/sequence/TestReduceSequenceByWindowFunction.java @@ -33,8 +33,10 @@ import org.datavec.api.writable.LongWritable; import org.datavec.api.writable.NullWritable; import org.datavec.api.writable.Writable; import org.joda.time.DateTimeZone; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import java.util.ArrayList; import java.util.Arrays; @@ -42,7 +44,8 @@ import java.util.List; import java.util.concurrent.TimeUnit; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class TestReduceSequenceByWindowFunction extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/transform/sequence/TestSequenceSplit.java b/datavec/datavec-api/src/test/java/org/datavec/api/transform/sequence/TestSequenceSplit.java index c26eaec61..4113ec1d7 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/transform/sequence/TestSequenceSplit.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/transform/sequence/TestSequenceSplit.java @@ -27,8 +27,10 @@ import org.datavec.api.writable.LongWritable; import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; import org.joda.time.DateTimeZone; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import java.util.ArrayList; import java.util.Arrays; @@ -36,7 +38,8 @@ import java.util.List; import java.util.concurrent.TimeUnit; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class TestSequenceSplit extends BaseND4JTest { @Test @@ -46,13 +49,13 @@ public class TestSequenceSplit extends BaseND4JTest { .build(); List> inputSequence = new ArrayList<>(); - inputSequence.add(Arrays.asList((Writable) new LongWritable(0), new Text("t0"))); - inputSequence.add(Arrays.asList((Writable) new LongWritable(1000), new Text("t1"))); + inputSequence.add(Arrays.asList(new LongWritable(0), new Text("t0"))); + inputSequence.add(Arrays.asList(new LongWritable(1000), new Text("t1"))); //Second split: 74 seconds later - inputSequence.add(Arrays.asList((Writable) new LongWritable(75000), new Text("t2"))); - inputSequence.add(Arrays.asList((Writable) new LongWritable(100000), new Text("t3"))); + inputSequence.add(Arrays.asList(new LongWritable(75000), new Text("t2"))); + inputSequence.add(Arrays.asList(new LongWritable(100000), new Text("t3"))); //Third split: 1 minute and 1 milliseconds later - inputSequence.add(Arrays.asList((Writable) new LongWritable(160001), new Text("t4"))); + inputSequence.add(Arrays.asList(new LongWritable(160001), new Text("t4"))); SequenceSplit seqSplit = new SequenceSplitTimeSeparation("time", 1, TimeUnit.MINUTES); seqSplit.setInputSchema(schema); @@ -61,13 +64,13 @@ public class TestSequenceSplit extends BaseND4JTest { assertEquals(3, splits.size()); List> exp0 = new ArrayList<>(); - exp0.add(Arrays.asList((Writable) new LongWritable(0), new Text("t0"))); - exp0.add(Arrays.asList((Writable) new LongWritable(1000), new Text("t1"))); + exp0.add(Arrays.asList(new LongWritable(0), new Text("t0"))); + exp0.add(Arrays.asList(new LongWritable(1000), new Text("t1"))); List> exp1 = new ArrayList<>(); - exp1.add(Arrays.asList((Writable) new LongWritable(75000), new Text("t2"))); - exp1.add(Arrays.asList((Writable) new LongWritable(100000), new Text("t3"))); + exp1.add(Arrays.asList(new LongWritable(75000), new Text("t2"))); + exp1.add(Arrays.asList(new LongWritable(100000), new Text("t3"))); List> exp2 = new ArrayList<>(); - exp2.add(Arrays.asList((Writable) new LongWritable(160001), new Text("t4"))); + exp2.add(Arrays.asList(new LongWritable(160001), new Text("t4"))); assertEquals(exp0, splits.get(0)); assertEquals(exp1, splits.get(1)); diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/transform/sequence/TestWindowFunctions.java b/datavec/datavec-api/src/test/java/org/datavec/api/transform/sequence/TestWindowFunctions.java index ff45a3f3e..a10835299 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/transform/sequence/TestWindowFunctions.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/transform/sequence/TestWindowFunctions.java @@ -29,8 +29,10 @@ import org.datavec.api.writable.IntWritable; import org.datavec.api.writable.LongWritable; import org.datavec.api.writable.Writable; import org.joda.time.DateTimeZone; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import java.util.ArrayList; import java.util.Arrays; @@ -38,7 +40,8 @@ import java.util.List; import java.util.concurrent.TimeUnit; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class TestWindowFunctions extends BaseND4JTest { @Test @@ -49,15 +52,15 @@ public class TestWindowFunctions extends BaseND4JTest { //Create some data. List> sequence = new ArrayList<>(); //First window: - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L), new IntWritable(0))); - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 100L), new IntWritable(1))); - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 200L), new IntWritable(2))); + sequence.add(Arrays.asList(new LongWritable(1451606400000L), new IntWritable(0))); + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 100L), new IntWritable(1))); + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 200L), new IntWritable(2))); //Second window: - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 1000L), new IntWritable(3))); + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 1000L), new IntWritable(3))); //Third window: empty //Fourth window: - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 3000L), new IntWritable(4))); - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 3100L), new IntWritable(5))); + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 3000L), new IntWritable(4))); + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 3100L), new IntWritable(5))); Schema schema = new SequenceSchema.Builder().addColumnTime("timecolumn", DateTimeZone.UTC) .addColumnInteger("intcolumn").build(); @@ -100,15 +103,15 @@ public class TestWindowFunctions extends BaseND4JTest { //Create some data. List> sequence = new ArrayList<>(); //First window: - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L), new IntWritable(0))); - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 100L), new IntWritable(1))); - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 200L), new IntWritable(2))); + sequence.add(Arrays.asList(new LongWritable(1451606400000L), new IntWritable(0))); + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 100L), new IntWritable(1))); + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 200L), new IntWritable(2))); //Second window: - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 1000L), new IntWritable(3))); + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 1000L), new IntWritable(3))); //Third window: empty //Fourth window: - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 3000L), new IntWritable(4))); - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 3100L), new IntWritable(5))); + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 3000L), new IntWritable(4))); + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 3100L), new IntWritable(5))); Schema schema = new SequenceSchema.Builder().addColumnTime("timecolumn", DateTimeZone.UTC) .addColumnInteger("intcolumn").build(); @@ -150,15 +153,15 @@ public class TestWindowFunctions extends BaseND4JTest { //Create some data. List> sequence = new ArrayList<>(); //First window: - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L), new IntWritable(0))); - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 100L), new IntWritable(1))); - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 200L), new IntWritable(2))); + sequence.add(Arrays.asList(new LongWritable(1451606400000L), new IntWritable(0))); + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 100L), new IntWritable(1))); + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 200L), new IntWritable(2))); //Second window: - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 1000L), new IntWritable(3))); + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 1000L), new IntWritable(3))); //Third window: empty //Fourth window: - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 3000L), new IntWritable(4))); - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 3100L), new IntWritable(5))); + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 3000L), new IntWritable(4))); + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 3100L), new IntWritable(5))); Schema schema = new SequenceSchema.Builder().addColumnTime("timecolumn", DateTimeZone.UTC) .addColumnInteger("intcolumn").build(); @@ -188,13 +191,13 @@ public class TestWindowFunctions extends BaseND4JTest { //Create some data. List> sequence = new ArrayList<>(); //First window: - sequence.add(Arrays.asList((Writable) new LongWritable(0), new IntWritable(0))); - sequence.add(Arrays.asList((Writable) new LongWritable(100), new IntWritable(1))); - sequence.add(Arrays.asList((Writable) new LongWritable(200), new IntWritable(2))); - sequence.add(Arrays.asList((Writable) new LongWritable(1000), new IntWritable(3))); - sequence.add(Arrays.asList((Writable) new LongWritable(1500), new IntWritable(4))); - sequence.add(Arrays.asList((Writable) new LongWritable(2000), new IntWritable(5))); - sequence.add(Arrays.asList((Writable) new LongWritable(5000), new IntWritable(7))); + sequence.add(Arrays.asList(new LongWritable(0), new IntWritable(0))); + sequence.add(Arrays.asList(new LongWritable(100), new IntWritable(1))); + sequence.add(Arrays.asList(new LongWritable(200), new IntWritable(2))); + sequence.add(Arrays.asList(new LongWritable(1000), new IntWritable(3))); + sequence.add(Arrays.asList(new LongWritable(1500), new IntWritable(4))); + sequence.add(Arrays.asList(new LongWritable(2000), new IntWritable(5))); + sequence.add(Arrays.asList(new LongWritable(5000), new IntWritable(7))); Schema schema = new SequenceSchema.Builder().addColumnTime("timecolumn", DateTimeZone.UTC) @@ -207,32 +210,32 @@ public class TestWindowFunctions extends BaseND4JTest { //First window: -1000 to 1000 List> exp0 = new ArrayList<>(); - exp0.add(Arrays.asList((Writable) new LongWritable(0), new IntWritable(0))); - exp0.add(Arrays.asList((Writable) new LongWritable(100), new IntWritable(1))); - exp0.add(Arrays.asList((Writable) new LongWritable(200), new IntWritable(2))); + exp0.add(Arrays.asList(new LongWritable(0), new IntWritable(0))); + exp0.add(Arrays.asList(new LongWritable(100), new IntWritable(1))); + exp0.add(Arrays.asList(new LongWritable(200), new IntWritable(2))); //Second window: 0 to 2000 List> exp1 = new ArrayList<>(); - exp1.add(Arrays.asList((Writable) new LongWritable(0), new IntWritable(0))); - exp1.add(Arrays.asList((Writable) new LongWritable(100), new IntWritable(1))); - exp1.add(Arrays.asList((Writable) new LongWritable(200), new IntWritable(2))); - exp1.add(Arrays.asList((Writable) new LongWritable(1000), new IntWritable(3))); - exp1.add(Arrays.asList((Writable) new LongWritable(1500), new IntWritable(4))); + exp1.add(Arrays.asList(new LongWritable(0), new IntWritable(0))); + exp1.add(Arrays.asList(new LongWritable(100), new IntWritable(1))); + exp1.add(Arrays.asList(new LongWritable(200), new IntWritable(2))); + exp1.add(Arrays.asList(new LongWritable(1000), new IntWritable(3))); + exp1.add(Arrays.asList(new LongWritable(1500), new IntWritable(4))); //Third window: 1000 to 3000 List> exp2 = new ArrayList<>(); - exp2.add(Arrays.asList((Writable) new LongWritable(1000), new IntWritable(3))); - exp2.add(Arrays.asList((Writable) new LongWritable(1500), new IntWritable(4))); - exp2.add(Arrays.asList((Writable) new LongWritable(2000), new IntWritable(5))); + exp2.add(Arrays.asList(new LongWritable(1000), new IntWritable(3))); + exp2.add(Arrays.asList(new LongWritable(1500), new IntWritable(4))); + exp2.add(Arrays.asList(new LongWritable(2000), new IntWritable(5))); //Fourth window: 2000 to 4000 List> exp3 = new ArrayList<>(); - exp3.add(Arrays.asList((Writable) new LongWritable(2000), new IntWritable(5))); + exp3.add(Arrays.asList(new LongWritable(2000), new IntWritable(5))); //Fifth window: 3000 to 5000 List> exp4 = new ArrayList<>(); //Sixth window: 4000 to 6000 List> exp5 = new ArrayList<>(); - exp5.add(Arrays.asList((Writable) new LongWritable(5000), new IntWritable(7))); + exp5.add(Arrays.asList(new LongWritable(5000), new IntWritable(7))); //Seventh window: 5000 to 7000 List> exp6 = new ArrayList<>(); - exp6.add(Arrays.asList((Writable) new LongWritable(5000), new IntWritable(7))); + exp6.add(Arrays.asList(new LongWritable(5000), new IntWritable(7))); List>> windowsExp = Arrays.asList(exp0, exp1, exp2, exp3, exp4, exp5, exp6); @@ -250,13 +253,13 @@ public class TestWindowFunctions extends BaseND4JTest { //Create some data. List> sequence = new ArrayList<>(); //First window: - sequence.add(Arrays.asList((Writable) new LongWritable(0), new IntWritable(0))); - sequence.add(Arrays.asList((Writable) new LongWritable(100), new IntWritable(1))); - sequence.add(Arrays.asList((Writable) new LongWritable(200), new IntWritable(2))); - sequence.add(Arrays.asList((Writable) new LongWritable(1000), new IntWritable(3))); - sequence.add(Arrays.asList((Writable) new LongWritable(1500), new IntWritable(4))); - sequence.add(Arrays.asList((Writable) new LongWritable(2000), new IntWritable(5))); - sequence.add(Arrays.asList((Writable) new LongWritable(5000), new IntWritable(7))); + sequence.add(Arrays.asList(new LongWritable(0), new IntWritable(0))); + sequence.add(Arrays.asList(new LongWritable(100), new IntWritable(1))); + sequence.add(Arrays.asList(new LongWritable(200), new IntWritable(2))); + sequence.add(Arrays.asList(new LongWritable(1000), new IntWritable(3))); + sequence.add(Arrays.asList(new LongWritable(1500), new IntWritable(4))); + sequence.add(Arrays.asList(new LongWritable(2000), new IntWritable(5))); + sequence.add(Arrays.asList(new LongWritable(5000), new IntWritable(7))); Schema schema = new SequenceSchema.Builder().addColumnTime("timecolumn", DateTimeZone.UTC) @@ -272,31 +275,31 @@ public class TestWindowFunctions extends BaseND4JTest { //First window: -1000 to 1000 List> exp0 = new ArrayList<>(); - exp0.add(Arrays.asList((Writable) new LongWritable(0), new IntWritable(0))); - exp0.add(Arrays.asList((Writable) new LongWritable(100), new IntWritable(1))); - exp0.add(Arrays.asList((Writable) new LongWritable(200), new IntWritable(2))); + exp0.add(Arrays.asList(new LongWritable(0), new IntWritable(0))); + exp0.add(Arrays.asList(new LongWritable(100), new IntWritable(1))); + exp0.add(Arrays.asList(new LongWritable(200), new IntWritable(2))); //Second window: 0 to 2000 List> exp1 = new ArrayList<>(); - exp1.add(Arrays.asList((Writable) new LongWritable(0), new IntWritable(0))); - exp1.add(Arrays.asList((Writable) new LongWritable(100), new IntWritable(1))); - exp1.add(Arrays.asList((Writable) new LongWritable(200), new IntWritable(2))); - exp1.add(Arrays.asList((Writable) new LongWritable(1000), new IntWritable(3))); - exp1.add(Arrays.asList((Writable) new LongWritable(1500), new IntWritable(4))); + exp1.add(Arrays.asList(new LongWritable(0), new IntWritable(0))); + exp1.add(Arrays.asList(new LongWritable(100), new IntWritable(1))); + exp1.add(Arrays.asList(new LongWritable(200), new IntWritable(2))); + exp1.add(Arrays.asList(new LongWritable(1000), new IntWritable(3))); + exp1.add(Arrays.asList(new LongWritable(1500), new IntWritable(4))); //Third window: 1000 to 3000 List> exp2 = new ArrayList<>(); - exp2.add(Arrays.asList((Writable) new LongWritable(1000), new IntWritable(3))); - exp2.add(Arrays.asList((Writable) new LongWritable(1500), new IntWritable(4))); - exp2.add(Arrays.asList((Writable) new LongWritable(2000), new IntWritable(5))); + exp2.add(Arrays.asList(new LongWritable(1000), new IntWritable(3))); + exp2.add(Arrays.asList(new LongWritable(1500), new IntWritable(4))); + exp2.add(Arrays.asList(new LongWritable(2000), new IntWritable(5))); //Fourth window: 2000 to 4000 List> exp3 = new ArrayList<>(); - exp3.add(Arrays.asList((Writable) new LongWritable(2000), new IntWritable(5))); + exp3.add(Arrays.asList(new LongWritable(2000), new IntWritable(5))); //Fifth window: 3000 to 5000 -> Empty: excluded //Sixth window: 4000 to 6000 List> exp5 = new ArrayList<>(); - exp5.add(Arrays.asList((Writable) new LongWritable(5000), new IntWritable(7))); + exp5.add(Arrays.asList(new LongWritable(5000), new IntWritable(7))); //Seventh window: 5000 to 7000 List> exp6 = new ArrayList<>(); - exp6.add(Arrays.asList((Writable) new LongWritable(5000), new IntWritable(7))); + exp6.add(Arrays.asList(new LongWritable(5000), new IntWritable(7))); List>> windowsExp = Arrays.asList(exp0, exp1, exp2, exp3, exp5, exp6); diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/transform/serde/TestCustomTransformJsonYaml.java b/datavec/datavec-api/src/test/java/org/datavec/api/transform/serde/TestCustomTransformJsonYaml.java index 53b63bb49..b95ffe18b 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/transform/serde/TestCustomTransformJsonYaml.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/transform/serde/TestCustomTransformJsonYaml.java @@ -26,11 +26,17 @@ import org.datavec.api.transform.schema.Schema; import org.datavec.api.transform.serde.testClasses.CustomCondition; import org.datavec.api.transform.serde.testClasses.CustomFilter; import org.datavec.api.transform.serde.testClasses.CustomTransform; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.assertEquals; +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JACKSON_SERDE) +@Tag(TagNames.CUSTOM_FUNCTIONALITY) public class TestCustomTransformJsonYaml extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/transform/serde/TestYamlJsonSerde.java b/datavec/datavec-api/src/test/java/org/datavec/api/transform/serde/TestYamlJsonSerde.java index 84da1c272..2a96158ee 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/transform/serde/TestYamlJsonSerde.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/transform/serde/TestYamlJsonSerde.java @@ -64,14 +64,19 @@ import org.datavec.api.transform.transform.time.TimeMathOpTransform; import org.datavec.api.writable.comparator.DoubleWritableComparator; import org.joda.time.DateTimeFieldType; import org.joda.time.DateTimeZone; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import java.util.*; import java.util.concurrent.TimeUnit; import static org.junit.jupiter.api.Assertions.assertEquals; +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JACKSON_SERDE) public class TestYamlJsonSerde extends BaseND4JTest { public static YamlSerializer y = new YamlSerializer(); diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/transform/stringreduce/TestReduce.java b/datavec/datavec-api/src/test/java/org/datavec/api/transform/stringreduce/TestReduce.java index f7eaa85ad..0517e0c3f 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/transform/stringreduce/TestReduce.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/transform/stringreduce/TestReduce.java @@ -24,22 +24,26 @@ import org.datavec.api.transform.StringReduceOp; import org.datavec.api.transform.schema.Schema; import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import java.util.*; import static org.junit.jupiter.api.Assertions.assertEquals; +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class TestReduce extends BaseND4JTest { @Test public void testReducerDouble() { List> inputs = new ArrayList<>(); - inputs.add(Arrays.asList((Writable) new Text("1"), new Text("2"))); - inputs.add(Arrays.asList((Writable) new Text("1"), new Text("2"))); - inputs.add(Arrays.asList((Writable) new Text("1"), new Text("2"))); + inputs.add(Arrays.asList(new Text("1"), new Text("2"))); + inputs.add(Arrays.asList(new Text("1"), new Text("2"))); + inputs.add(Arrays.asList(new Text("1"), new Text("2"))); Map exp = new LinkedHashMap<>(); exp.put(StringReduceOp.MERGE, "12"); diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/transform/ui/TestUI.java b/datavec/datavec-api/src/test/java/org/datavec/api/transform/ui/TestUI.java index 6032e13a3..8233308f8 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/transform/ui/TestUI.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/transform/ui/TestUI.java @@ -37,10 +37,12 @@ import org.datavec.api.writable.Writable; import org.joda.time.DateTimeZone; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import java.nio.file.Path; @@ -49,7 +51,9 @@ import java.util.Arrays; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) +@Tag(TagNames.UI) public class TestUI extends BaseND4JTest { diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/util/ClassPathResourceTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/util/ClassPathResourceTest.java index b0a283563..10e431ce2 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/util/ClassPathResourceTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/util/ClassPathResourceTest.java @@ -20,6 +20,7 @@ package org.datavec.api.util; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; import java.io.BufferedReader; @@ -33,8 +34,11 @@ import static org.hamcrest.core.AnyOf.anyOf; import static org.hamcrest.core.IsEqual.equalTo; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Class Path Resource Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class ClassPathResourceTest extends BaseND4JTest { // File sizes are reported slightly different on Linux vs. Windows diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/util/TimeSeriesUtilsTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/util/TimeSeriesUtilsTest.java index 53dbbb5f7..4e35d06fe 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/util/TimeSeriesUtilsTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/util/TimeSeriesUtilsTest.java @@ -22,8 +22,10 @@ package org.datavec.api.util; import org.datavec.api.timeseries.util.TimeSeriesWritableUtils; import org.datavec.api.writable.DoubleWritable; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import java.util.ArrayList; import java.util.List; @@ -32,6 +34,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Time Series Utils Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class TimeSeriesUtilsTest extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/writable/RecordConverterTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/writable/RecordConverterTest.java index f84229ceb..a05897a92 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/writable/RecordConverterTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/writable/RecordConverterTest.java @@ -19,7 +19,9 @@ */ package org.datavec.api.writable; +import org.junit.jupiter.api.Tag; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.shade.guava.collect.Lists; import org.datavec.api.transform.schema.Schema; import org.datavec.api.util.ndarray.RecordConverter; @@ -36,6 +38,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Record Converter Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class RecordConverterTest extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/writable/TestNDArrayWritableAndSerialization.java b/datavec/datavec-api/src/test/java/org/datavec/api/writable/TestNDArrayWritableAndSerialization.java index 71149b9b2..b56dc9192 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/writable/TestNDArrayWritableAndSerialization.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/writable/TestNDArrayWritableAndSerialization.java @@ -21,15 +21,18 @@ package org.datavec.api.writable; import org.datavec.api.transform.metadata.NDArrayMetaData; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import java.io.*; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class TestNDArrayWritableAndSerialization extends BaseND4JTest { @Test diff --git a/datavec/datavec-api/src/test/java/org/datavec/api/writable/WritableTest.java b/datavec/datavec-api/src/test/java/org/datavec/api/writable/WritableTest.java index f3daccd04..1b97e8aef 100644 --- a/datavec/datavec-api/src/test/java/org/datavec/api/writable/WritableTest.java +++ b/datavec/datavec-api/src/test/java/org/datavec/api/writable/WritableTest.java @@ -20,8 +20,10 @@ package org.datavec.api.writable; import org.datavec.api.writable.batch.NDArrayRecordBatch; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataBuffer; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -37,6 +39,8 @@ import org.junit.jupiter.api.DisplayName; import static org.junit.jupiter.api.Assertions.*; @DisplayName("Writable Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class WritableTest extends BaseND4JTest { @Test diff --git a/datavec/datavec-arrow/src/test/java/org/datavec/arrow/ArrowConverterTest.java b/datavec/datavec-arrow/src/test/java/org/datavec/arrow/ArrowConverterTest.java index f019e8955..c21bd3e32 100644 --- a/datavec/datavec-arrow/src/test/java/org/datavec/arrow/ArrowConverterTest.java +++ b/datavec/datavec-arrow/src/test/java/org/datavec/arrow/ArrowConverterTest.java @@ -42,9 +42,11 @@ import org.datavec.api.writable.*; import org.datavec.arrow.recordreader.ArrowRecordReader; import org.datavec.arrow.recordreader.ArrowWritableRecordBatch; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.common.primitives.Pair; @@ -62,6 +64,8 @@ import org.junit.jupiter.api.extension.ExtendWith; @Slf4j @DisplayName("Arrow Converter Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class ArrowConverterTest extends BaseND4JTest { private static BufferAllocator bufferAllocator = new RootAllocator(Long.MAX_VALUE); @@ -142,8 +146,8 @@ class ArrowConverterTest extends BaseND4JTest { List fieldVectorsBatch = ArrowConverter.toArrowColumnsString(bufferAllocator, schema.build(), batch); List> batchRecords = ArrowConverter.toArrowWritables(fieldVectorsBatch, schema.build()); List> assertionBatch = new ArrayList<>(); - assertionBatch.add(Arrays.asList(new IntWritable(0), new IntWritable(0))); - assertionBatch.add(Arrays.asList(new IntWritable(1), new IntWritable(1))); + assertionBatch.add(Arrays.asList(new IntWritable(0), new IntWritable(0))); + assertionBatch.add(Arrays.asList(new IntWritable(1), new IntWritable(1))); assertEquals(assertionBatch, batchRecords); } @@ -156,11 +160,11 @@ class ArrowConverterTest extends BaseND4JTest { schema.addColumnTime(String.valueOf(i), TimeZone.getDefault()); single.add(String.valueOf(i)); } - List> input = Arrays.asList(Arrays.asList(new LongWritable(0), new LongWritable(1)), Arrays.asList(new LongWritable(2), new LongWritable(3))); + List> input = Arrays.asList(Arrays.asList(new LongWritable(0), new LongWritable(1)), Arrays.asList(new LongWritable(2), new LongWritable(3))); List fieldVector = ArrowConverter.toArrowColumns(bufferAllocator, schema.build(), input); ArrowWritableRecordBatch writableRecordBatch = new ArrowWritableRecordBatch(fieldVector, schema.build()); - List assertion = Arrays.asList(new LongWritable(4), new LongWritable(5)); - writableRecordBatch.set(1, Arrays.asList(new LongWritable(4), new LongWritable(5))); + List assertion = Arrays.asList(new LongWritable(4), new LongWritable(5)); + writableRecordBatch.set(1, Arrays.asList(new LongWritable(4), new LongWritable(5))); List recordTest = writableRecordBatch.get(1); assertEquals(assertion, recordTest); } @@ -174,11 +178,11 @@ class ArrowConverterTest extends BaseND4JTest { schema.addColumnInteger(String.valueOf(i)); single.add(String.valueOf(i)); } - List> input = Arrays.asList(Arrays.asList(new IntWritable(0), new IntWritable(1)), Arrays.asList(new IntWritable(2), new IntWritable(3))); + List> input = Arrays.asList(Arrays.asList(new IntWritable(0), new IntWritable(1)), Arrays.asList(new IntWritable(2), new IntWritable(3))); List fieldVector = ArrowConverter.toArrowColumns(bufferAllocator, schema.build(), input); ArrowWritableRecordBatch writableRecordBatch = new ArrowWritableRecordBatch(fieldVector, schema.build()); - List assertion = Arrays.asList(new IntWritable(4), new IntWritable(5)); - writableRecordBatch.set(1, Arrays.asList(new IntWritable(4), new IntWritable(5))); + List assertion = Arrays.asList(new IntWritable(4), new IntWritable(5)); + writableRecordBatch.set(1, Arrays.asList(new IntWritable(4), new IntWritable(5))); List recordTest = writableRecordBatch.get(1); assertEquals(assertion, recordTest); } diff --git a/datavec/datavec-arrow/src/test/java/org/datavec/arrow/RecordMapperTest.java b/datavec/datavec-arrow/src/test/java/org/datavec/arrow/RecordMapperTest.java index 5eec05c93..fbbc71f9f 100644 --- a/datavec/datavec-arrow/src/test/java/org/datavec/arrow/RecordMapperTest.java +++ b/datavec/datavec-arrow/src/test/java/org/datavec/arrow/RecordMapperTest.java @@ -33,6 +33,7 @@ import org.datavec.api.writable.IntWritable; import org.datavec.api.writable.Writable; import org.datavec.arrow.recordreader.ArrowRecordReader; import org.datavec.arrow.recordreader.ArrowRecordWriter; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.common.primitives.Triple; @@ -44,8 +45,11 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Record Mapper Test") +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class RecordMapperTest extends BaseND4JTest { @Test diff --git a/datavec/datavec-arrow/src/test/java/org/datavec/arrow/recordreader/ArrowWritableRecordTimeSeriesBatchTests.java b/datavec/datavec-arrow/src/test/java/org/datavec/arrow/recordreader/ArrowWritableRecordTimeSeriesBatchTests.java index 0831073f5..806de7fef 100644 --- a/datavec/datavec-arrow/src/test/java/org/datavec/arrow/recordreader/ArrowWritableRecordTimeSeriesBatchTests.java +++ b/datavec/datavec-arrow/src/test/java/org/datavec/arrow/recordreader/ArrowWritableRecordTimeSeriesBatchTests.java @@ -30,8 +30,10 @@ import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; import org.datavec.arrow.ArrowConverter; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import java.util.ArrayList; import java.util.Arrays; @@ -39,7 +41,8 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertFalse; - +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) public class ArrowWritableRecordTimeSeriesBatchTests extends BaseND4JTest { private static BufferAllocator bufferAllocator = new RootAllocator(Long.MAX_VALUE); diff --git a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/LabelGeneratorTest.java b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/LabelGeneratorTest.java index ced14a25e..13856c4ff 100644 --- a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/LabelGeneratorTest.java +++ b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/LabelGeneratorTest.java @@ -25,6 +25,7 @@ import org.datavec.api.split.FileSplit; import org.datavec.image.recordreader.ImageRecordReader; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.io.ClassPathResource; @@ -36,8 +37,12 @@ import static org.junit.jupiter.api.Assertions.assertTrue; import org.junit.jupiter.api.DisplayName; import java.nio.file.Path; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Label Generator Test") +@NativeTag +@Tag(TagNames.FILE_IO) class LabelGeneratorTest { diff --git a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/loader/LoaderTests.java b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/loader/LoaderTests.java index b35b6966f..29bd04511 100644 --- a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/loader/LoaderTests.java +++ b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/loader/LoaderTests.java @@ -23,7 +23,10 @@ package org.datavec.image.loader; import org.apache.commons.io.FilenameUtils; import org.datavec.api.records.reader.RecordReader; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.dataset.DataSet; import java.io.File; @@ -39,6 +42,8 @@ import static org.junit.jupiter.api.Assertions.assertTrue; /** * */ +@NativeTag +@Tag(TagNames.FILE_IO) public class LoaderTests { private static void ensureDataAvailable(){ @@ -81,7 +86,7 @@ public class LoaderTests { String subDir = "cifar/cifar-10-batches-bin/data_batch_1.bin"; String path = FilenameUtils.concat(System.getProperty("user.home"), subDir); byte[] fullDataExpected = new byte[3073]; - FileInputStream inExpected = new FileInputStream(new File(path)); + FileInputStream inExpected = new FileInputStream(path); inExpected.read(fullDataExpected); byte[] fullDataActual = new byte[3073]; @@ -94,7 +99,7 @@ public class LoaderTests { subDir = "cifar/cifar-10-batches-bin/test_batch.bin"; path = FilenameUtils.concat(System.getProperty("user.home"), subDir); fullDataExpected = new byte[3073]; - inExpected = new FileInputStream(new File(path)); + inExpected = new FileInputStream(path); inExpected.read(fullDataExpected); fullDataActual = new byte[3073]; diff --git a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/loader/TestImageLoader.java b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/loader/TestImageLoader.java index 1273b8b31..2494b1341 100644 --- a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/loader/TestImageLoader.java +++ b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/loader/TestImageLoader.java @@ -21,8 +21,11 @@ package org.datavec.image.loader; import org.datavec.image.data.Image; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.resources.Resources; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import java.awt.image.BufferedImage; @@ -34,7 +37,8 @@ import java.util.Random; import static org.junit.jupiter.api.Assertions.assertEquals; - +@NativeTag +@Tag(TagNames.FILE_IO) public class TestImageLoader { private static long seed = 10; diff --git a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/loader/TestNativeImageLoader.java b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/loader/TestNativeImageLoader.java index 6a6defe1a..286aa3608 100644 --- a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/loader/TestNativeImageLoader.java +++ b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/loader/TestNativeImageLoader.java @@ -31,10 +31,13 @@ import org.bytedeco.javacv.OpenCVFrameConverter; import org.datavec.image.data.Image; import org.datavec.image.data.ImageWritable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.resources.Resources; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -60,6 +63,8 @@ import static org.junit.jupiter.api.Assertions.fail; * @author saudet */ @Slf4j +@NativeTag +@Tag(TagNames.FILE_IO) public class TestNativeImageLoader { static final long seed = 10; static final Random rng = new Random(seed); diff --git a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/recordreader/FileBatchRecordReaderTest.java b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/recordreader/FileBatchRecordReaderTest.java index 1839befc7..8956cbaf9 100644 --- a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/recordreader/FileBatchRecordReaderTest.java +++ b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/recordreader/FileBatchRecordReaderTest.java @@ -28,9 +28,12 @@ import org.datavec.api.writable.NDArrayWritable; import org.datavec.api.writable.Writable; import org.datavec.image.loader.NativeImageLoader; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.loader.FileBatch; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.common.io.ClassPathResource; import java.io.File; @@ -41,6 +44,8 @@ import java.nio.file.Path; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("File Batch Record Reader Test") +@NativeTag +@Tag(TagNames.FILE_IO) class FileBatchRecordReaderTest { @TempDir diff --git a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/recordreader/TestImageRecordReader.java b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/recordreader/TestImageRecordReader.java index 70313ca7f..e8ca38e79 100644 --- a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/recordreader/TestImageRecordReader.java +++ b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/recordreader/TestImageRecordReader.java @@ -37,9 +37,12 @@ import org.datavec.api.writable.NDArrayWritable; import org.datavec.api.writable.Writable; import org.datavec.api.writable.batch.NDArrayRecordBatch; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -54,7 +57,8 @@ import java.util.List; import java.util.Random; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.FILE_IO) public class TestImageRecordReader { diff --git a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/recordreader/TestObjectDetectionRecordReader.java b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/recordreader/TestObjectDetectionRecordReader.java index 4c69b76cf..d68c33c1c 100644 --- a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/recordreader/TestObjectDetectionRecordReader.java +++ b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/recordreader/TestObjectDetectionRecordReader.java @@ -36,9 +36,12 @@ import org.datavec.image.transform.ImageTransform; import org.datavec.image.transform.PipelineImageTransform; import org.datavec.image.transform.ResizeImageTransform; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.linalg.indexing.BooleanIndexing; @@ -54,7 +57,8 @@ import java.util.Collections; import java.util.List; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.FILE_IO) public class TestObjectDetectionRecordReader { diff --git a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/recordreader/objdetect/TestVocLabelProvider.java b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/recordreader/objdetect/TestVocLabelProvider.java index 0a4e61660..ca68ff797 100644 --- a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/recordreader/objdetect/TestVocLabelProvider.java +++ b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/recordreader/objdetect/TestVocLabelProvider.java @@ -22,10 +22,13 @@ package org.datavec.image.recordreader.objdetect; import org.datavec.image.recordreader.objdetect.impl.VocLabelProvider; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import java.nio.file.Path; @@ -34,7 +37,8 @@ import java.util.Collections; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) public class TestVocLabelProvider { diff --git a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/transform/JsonYamlTest.java b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/transform/JsonYamlTest.java index 60d354d9e..cbf4797a8 100644 --- a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/transform/JsonYamlTest.java +++ b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/transform/JsonYamlTest.java @@ -20,6 +20,7 @@ package org.datavec.image.transform; import org.datavec.image.data.ImageWritable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import java.io.IOException; import java.util.List; @@ -28,8 +29,13 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Json Yaml Test") +@NativeTag +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JACKSON_SERDE) class JsonYamlTest { @Test diff --git a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/transform/ResizeImageTransformTest.java b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/transform/ResizeImageTransformTest.java index 47ce04ec3..b0c1de47d 100644 --- a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/transform/ResizeImageTransformTest.java +++ b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/transform/ResizeImageTransformTest.java @@ -22,12 +22,17 @@ package org.datavec.image.transform; import org.bytedeco.javacv.Frame; import org.datavec.image.data.ImageWritable; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import static org.junit.jupiter.api.Assertions.assertEquals; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Resize Image Transform Test") +@NativeTag +@Tag(TagNames.FILE_IO) class ResizeImageTransformTest { @BeforeEach diff --git a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/transform/TestImageTransform.java b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/transform/TestImageTransform.java index e337500ea..a03f368e0 100644 --- a/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/transform/TestImageTransform.java +++ b/datavec/datavec-data/datavec-data-image/src/test/java/org/datavec/image/transform/TestImageTransform.java @@ -24,6 +24,7 @@ import org.bytedeco.javacpp.indexer.UByteIndexer; import org.bytedeco.javacv.CanvasFrame; import org.bytedeco.javacv.Frame; import org.bytedeco.javacv.OpenCVFrameConverter; +import org.junit.jupiter.api.Tag; import org.nd4j.common.io.ClassPathResource; import org.nd4j.common.primitives.Pair; import org.datavec.image.data.ImageWritable; @@ -37,6 +38,8 @@ import java.util.List; import java.util.Random; import org.bytedeco.opencv.opencv_core.*; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.bytedeco.opencv.global.opencv_core.*; import static org.bytedeco.opencv.global.opencv_imgproc.*; @@ -46,6 +49,8 @@ import static org.junit.jupiter.api.Assertions.*; * * @author saudet */ +@NativeTag +@Tag(TagNames.FILE_IO) public class TestImageTransform { static final long seed = 10; static final Random rng = new Random(seed); diff --git a/datavec/datavec-excel/src/test/java/org/datavec/poi/excel/ExcelRecordReaderTest.java b/datavec/datavec-excel/src/test/java/org/datavec/poi/excel/ExcelRecordReaderTest.java index 97de530c9..c7a3fe12c 100644 --- a/datavec/datavec-excel/src/test/java/org/datavec/poi/excel/ExcelRecordReaderTest.java +++ b/datavec/datavec-excel/src/test/java/org/datavec/poi/excel/ExcelRecordReaderTest.java @@ -22,6 +22,7 @@ package org.datavec.poi.excel; import org.datavec.api.records.reader.RecordReader; import org.datavec.api.split.FileSplit; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.io.ClassPathResource; import java.util.List; @@ -29,8 +30,12 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Excel Record Reader Test") +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) class ExcelRecordReaderTest { @Test diff --git a/datavec/datavec-excel/src/test/java/org/datavec/poi/excel/ExcelRecordWriterTest.java b/datavec/datavec-excel/src/test/java/org/datavec/poi/excel/ExcelRecordWriterTest.java index bc706daa3..08de8b153 100644 --- a/datavec/datavec-excel/src/test/java/org/datavec/poi/excel/ExcelRecordWriterTest.java +++ b/datavec/datavec-excel/src/test/java/org/datavec/poi/excel/ExcelRecordWriterTest.java @@ -26,6 +26,7 @@ import org.datavec.api.transform.schema.Schema; import org.datavec.api.writable.IntWritable; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.primitives.Triple; @@ -36,8 +37,11 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import org.junit.jupiter.api.DisplayName; import java.nio.file.Path; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Excel Record Writer Test") +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) class ExcelRecordWriterTest { @TempDir diff --git a/datavec/datavec-jdbc/src/test/java/org/datavec/api/records/reader/impl/JDBCRecordReaderTest.java b/datavec/datavec-jdbc/src/test/java/org/datavec/api/records/reader/impl/JDBCRecordReaderTest.java index a3ab033b6..d0161ce29 100644 --- a/datavec/datavec-jdbc/src/test/java/org/datavec/api/records/reader/impl/JDBCRecordReaderTest.java +++ b/datavec/datavec-jdbc/src/test/java/org/datavec/api/records/reader/impl/JDBCRecordReaderTest.java @@ -47,17 +47,19 @@ import org.datavec.api.writable.IntWritable; import org.datavec.api.writable.LongWritable; import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; -import org.junit.jupiter.api.AfterEach; -import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.*; -import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; -import org.junit.jupiter.api.DisplayName; + import java.nio.file.Path; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.TagNames; + import static org.junit.jupiter.api.Assertions.assertThrows; @DisplayName("Jdbc Record Reader Test") +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) class JDBCRecordReaderTest { @TempDir diff --git a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/LocalTransformProcessRecordReaderTests.java b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/LocalTransformProcessRecordReaderTests.java index 2ec96607e..0360129d2 100644 --- a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/LocalTransformProcessRecordReaderTests.java +++ b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/LocalTransformProcessRecordReaderTests.java @@ -36,15 +36,18 @@ import org.datavec.api.writable.LongWritable; import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; import org.joda.time.DateTimeZone; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.TagNames; import java.util.ArrayList; import java.util.Arrays; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) public class LocalTransformProcessRecordReaderTests { @Test @@ -64,11 +67,11 @@ public class LocalTransformProcessRecordReaderTests { public void simpleTransformTestSequence() { List> sequence = new ArrayList<>(); //First window: - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L), new IntWritable(0), + sequence.add(Arrays.asList(new LongWritable(1451606400000L), new IntWritable(0), new IntWritable(0))); - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 100L), new IntWritable(1), + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 100L), new IntWritable(1), new IntWritable(0))); - sequence.add(Arrays.asList((Writable) new LongWritable(1451606400000L + 200L), new IntWritable(2), + sequence.add(Arrays.asList(new LongWritable(1451606400000L + 200L), new IntWritable(2), new IntWritable(0))); Schema schema = new SequenceSchema.Builder().addColumnTime("timecolumn", DateTimeZone.UTC) diff --git a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/analysis/TestAnalyzeLocal.java b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/analysis/TestAnalyzeLocal.java index 2ed08bd95..05ad1a662 100644 --- a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/analysis/TestAnalyzeLocal.java +++ b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/analysis/TestAnalyzeLocal.java @@ -30,8 +30,10 @@ import org.datavec.api.util.ndarray.RecordConverter; import org.datavec.api.writable.Writable; import org.datavec.local.transforms.AnalyzeLocal; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.common.io.ClassPathResource; @@ -40,7 +42,8 @@ import java.util.ArrayList; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) public class TestAnalyzeLocal { diff --git a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/functions/TestLineRecordReaderFunction.java b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/functions/TestLineRecordReaderFunction.java index 11d4672b1..93779f598 100644 --- a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/functions/TestLineRecordReaderFunction.java +++ b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/functions/TestLineRecordReaderFunction.java @@ -27,8 +27,10 @@ import org.datavec.api.records.reader.impl.csv.CSVRecordReader; import org.datavec.api.split.FileSplit; import org.datavec.api.writable.Writable; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import java.util.HashSet; @@ -38,7 +40,8 @@ import java.util.stream.Collectors; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) public class TestLineRecordReaderFunction { @Test diff --git a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/functions/TestNDArrayToWritablesFunction.java b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/functions/TestNDArrayToWritablesFunction.java index 37a86a2f3..cbf21bd9e 100644 --- a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/functions/TestNDArrayToWritablesFunction.java +++ b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/functions/TestNDArrayToWritablesFunction.java @@ -25,7 +25,10 @@ import org.datavec.api.writable.NDArrayWritable; import org.datavec.api.writable.Writable; import org.datavec.local.transforms.misc.NDArrayToWritablesFunction; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -34,7 +37,8 @@ import java.util.Arrays; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@NativeTag public class TestNDArrayToWritablesFunction { @Test @@ -50,7 +54,7 @@ public class TestNDArrayToWritablesFunction { @Test public void testNDArrayToWritablesArray() throws Exception { INDArray arr = Nd4j.arange(5); - List expected = Arrays.asList((Writable) new NDArrayWritable(arr)); + List expected = Arrays.asList(new NDArrayWritable(arr)); List actual = new NDArrayToWritablesFunction(true).apply(arr); assertEquals(expected, actual); } diff --git a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/functions/TestWritablesToNDArrayFunction.java b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/functions/TestWritablesToNDArrayFunction.java index 1cc2943f8..e233c6804 100644 --- a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/functions/TestWritablesToNDArrayFunction.java +++ b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/functions/TestWritablesToNDArrayFunction.java @@ -25,7 +25,10 @@ import org.datavec.api.writable.NDArrayWritable; import org.datavec.api.writable.Writable; import org.datavec.local.transforms.misc.WritablesToNDArrayFunction; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -34,7 +37,8 @@ import java.util.ArrayList; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@NativeTag public class TestWritablesToNDArrayFunction { @Test diff --git a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/functions/TestWritablesToStringFunctions.java b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/functions/TestWritablesToStringFunctions.java index fca45adb1..0bb465152 100644 --- a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/functions/TestWritablesToStringFunctions.java +++ b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/functions/TestWritablesToStringFunctions.java @@ -30,13 +30,16 @@ import org.datavec.api.writable.Writable; import org.datavec.local.transforms.misc.SequenceWritablesToStringFunction; import org.datavec.local.transforms.misc.WritablesToStringFunction; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.TagNames; import java.util.Arrays; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) public class TestWritablesToStringFunctions { @@ -44,7 +47,7 @@ public class TestWritablesToStringFunctions { @Test public void testWritablesToString() throws Exception { - List l = Arrays.asList(new DoubleWritable(1.5), new Text("someValue")); + List l = Arrays.asList(new DoubleWritable(1.5), new Text("someValue")); String expected = l.get(0).toString() + "," + l.get(1).toString(); assertEquals(expected, new WritablesToStringFunction(",").apply(l)); @@ -53,8 +56,8 @@ public class TestWritablesToStringFunctions { @Test public void testSequenceWritablesToString() throws Exception { - List> l = Arrays.asList(Arrays.asList(new DoubleWritable(1.5), new Text("someValue")), - Arrays.asList(new DoubleWritable(2.5), new Text("otherValue"))); + List> l = Arrays.asList(Arrays.asList(new DoubleWritable(1.5), new Text("someValue")), + Arrays.asList(new DoubleWritable(2.5), new Text("otherValue"))); String expected = l.get(0).get(0).toString() + "," + l.get(0).get(1).toString() + "\n" + l.get(1).get(0).toString() + "," + l.get(1).get(1).toString(); diff --git a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/transform/ExecutionTest.java b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/transform/ExecutionTest.java index 8284d22b7..534b8f44a 100644 --- a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/transform/ExecutionTest.java +++ b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/transform/ExecutionTest.java @@ -31,7 +31,10 @@ import org.datavec.api.transform.schema.SequenceSchema; import org.datavec.api.writable.*; import org.datavec.local.transforms.LocalTransformExecutor; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.linalg.ops.transforms.Transforms; @@ -42,6 +45,8 @@ import static java.time.Duration.ofMillis; import static org.junit.jupiter.api.Assertions.assertTimeout; @DisplayName("Execution Test") +@Tag(TagNames.FILE_IO) +@NativeTag class ExecutionTest { @Test @@ -71,18 +76,12 @@ class ExecutionTest { Schema schema = new Schema.Builder().addColumnInteger("col0").addColumnCategorical("col1", "state0", "state1", "state2").addColumnDouble("col2").addColumnFloat("col3").build(); TransformProcess tp = new TransformProcess.Builder(schema).categoricalToInteger("col1").doubleMathOp("col2", MathOp.Add, 10.0).floatMathOp("col3", MathOp.Add, 5f).build(); List> inputData = new ArrayList<>(); - inputData.add(Arrays.asList(new IntWritable(0), new Text("state2"), new DoubleWritable(0.1), new FloatWritable(0.3f))); - inputData.add(Arrays.asList(new IntWritable(1), new Text("state1"), new DoubleWritable(1.1), new FloatWritable(1.7f))); - inputData.add(Arrays.asList(new IntWritable(2), new Text("state0"), new DoubleWritable(2.1), new FloatWritable(3.6f))); + inputData.add(Arrays.asList(new IntWritable(0), new Text("state2"), new DoubleWritable(0.1), new FloatWritable(0.3f))); + inputData.add(Arrays.asList(new IntWritable(1), new Text("state1"), new DoubleWritable(1.1), new FloatWritable(1.7f))); + inputData.add(Arrays.asList(new IntWritable(2), new Text("state0"), new DoubleWritable(2.1), new FloatWritable(3.6f))); List> rdd = (inputData); List> out = new ArrayList<>(LocalTransformExecutor.execute(rdd, tp)); - Collections.sort(out, new Comparator>() { - - @Override - public int compare(List o1, List o2) { - return Integer.compare(o1.get(0).toInt(), o2.get(0).toInt()); - } - }); + Collections.sort(out, (o1, o2) -> Integer.compare(o1.get(0).toInt(), o2.get(0).toInt())); List> expected = new ArrayList<>(); expected.add(Arrays.asList(new IntWritable(0), new IntWritable(2), new DoubleWritable(10.1), new FloatWritable(5.3f))); expected.add(Arrays.asList(new IntWritable(1), new IntWritable(1), new DoubleWritable(11.1), new FloatWritable(6.7f))); @@ -95,9 +94,9 @@ class ExecutionTest { void testFilter() { Schema filterSchema = new Schema.Builder().addColumnDouble("col1").addColumnDouble("col2").addColumnDouble("col3").build(); List> inputData = new ArrayList<>(); - inputData.add(Arrays.asList(new IntWritable(0), new DoubleWritable(1), new DoubleWritable(0.1))); - inputData.add(Arrays.asList(new IntWritable(1), new DoubleWritable(3), new DoubleWritable(1.1))); - inputData.add(Arrays.asList(new IntWritable(2), new DoubleWritable(3), new DoubleWritable(2.1))); + inputData.add(Arrays.asList(new IntWritable(0), new DoubleWritable(1), new DoubleWritable(0.1))); + inputData.add(Arrays.asList(new IntWritable(1), new DoubleWritable(3), new DoubleWritable(1.1))); + inputData.add(Arrays.asList(new IntWritable(2), new DoubleWritable(3), new DoubleWritable(2.1))); TransformProcess transformProcess = new TransformProcess.Builder(filterSchema).filter(new DoubleColumnCondition("col1", ConditionOp.LessThan, 1)).build(); List> execute = LocalTransformExecutor.execute(inputData, transformProcess); assertEquals(2, execute.size()); @@ -110,31 +109,25 @@ class ExecutionTest { TransformProcess tp = new TransformProcess.Builder(schema).categoricalToInteger("col1").doubleMathOp("col2", MathOp.Add, 10.0).build(); List>> inputSequences = new ArrayList<>(); List> seq1 = new ArrayList<>(); - seq1.add(Arrays.asList(new IntWritable(0), new Text("state2"), new DoubleWritable(0.1))); - seq1.add(Arrays.asList(new IntWritable(1), new Text("state1"), new DoubleWritable(1.1))); - seq1.add(Arrays.asList(new IntWritable(2), new Text("state0"), new DoubleWritable(2.1))); + seq1.add(Arrays.asList(new IntWritable(0), new Text("state2"), new DoubleWritable(0.1))); + seq1.add(Arrays.asList(new IntWritable(1), new Text("state1"), new DoubleWritable(1.1))); + seq1.add(Arrays.asList(new IntWritable(2), new Text("state0"), new DoubleWritable(2.1))); List> seq2 = new ArrayList<>(); - seq2.add(Arrays.asList(new IntWritable(3), new Text("state0"), new DoubleWritable(3.1))); - seq2.add(Arrays.asList(new IntWritable(4), new Text("state1"), new DoubleWritable(4.1))); + seq2.add(Arrays.asList(new IntWritable(3), new Text("state0"), new DoubleWritable(3.1))); + seq2.add(Arrays.asList(new IntWritable(4), new Text("state1"), new DoubleWritable(4.1))); inputSequences.add(seq1); inputSequences.add(seq2); List>> rdd = (inputSequences); List>> out = LocalTransformExecutor.executeSequenceToSequence(rdd, tp); - Collections.sort(out, new Comparator>>() { - - @Override - public int compare(List> o1, List> o2) { - return -Integer.compare(o1.size(), o2.size()); - } - }); + Collections.sort(out, (o1, o2) -> -Integer.compare(o1.size(), o2.size())); List>> expectedSequence = new ArrayList<>(); List> seq1e = new ArrayList<>(); - seq1e.add(Arrays.asList(new IntWritable(0), new IntWritable(2), new DoubleWritable(10.1))); - seq1e.add(Arrays.asList(new IntWritable(1), new IntWritable(1), new DoubleWritable(11.1))); - seq1e.add(Arrays.asList(new IntWritable(2), new IntWritable(0), new DoubleWritable(12.1))); + seq1e.add(Arrays.asList(new IntWritable(0), new IntWritable(2), new DoubleWritable(10.1))); + seq1e.add(Arrays.asList(new IntWritable(1), new IntWritable(1), new DoubleWritable(11.1))); + seq1e.add(Arrays.asList(new IntWritable(2), new IntWritable(0), new DoubleWritable(12.1))); List> seq2e = new ArrayList<>(); - seq2e.add(Arrays.asList(new IntWritable(3), new IntWritable(0), new DoubleWritable(13.1))); - seq2e.add(Arrays.asList(new IntWritable(4), new IntWritable(1), new DoubleWritable(14.1))); + seq2e.add(Arrays.asList(new IntWritable(3), new IntWritable(0), new DoubleWritable(13.1))); + seq2e.add(Arrays.asList(new IntWritable(4), new IntWritable(1), new DoubleWritable(14.1))); expectedSequence.add(seq1e); expectedSequence.add(seq2e); assertEquals(expectedSequence, out); @@ -143,26 +136,26 @@ class ExecutionTest { @Test @DisplayName("Test Reduction Global") void testReductionGlobal() { - List> in = Arrays.asList(Arrays.asList(new Text("first"), new DoubleWritable(3.0)), Arrays.asList(new Text("second"), new DoubleWritable(5.0))); + List> in = Arrays.asList(Arrays.asList(new Text("first"), new DoubleWritable(3.0)), Arrays.asList(new Text("second"), new DoubleWritable(5.0))); List> inData = in; Schema s = new Schema.Builder().addColumnString("textCol").addColumnDouble("doubleCol").build(); TransformProcess tp = new TransformProcess.Builder(s).reduce(new Reducer.Builder(ReduceOp.TakeFirst).takeFirstColumns("textCol").meanColumns("doubleCol").build()).build(); List> outRdd = LocalTransformExecutor.execute(inData, tp); List> out = outRdd; - List> expOut = Collections.singletonList(Arrays.asList(new Text("first"), new DoubleWritable(4.0))); + List> expOut = Collections.singletonList(Arrays.asList(new Text("first"), new DoubleWritable(4.0))); assertEquals(expOut, out); } @Test @DisplayName("Test Reduction By Key") void testReductionByKey() { - List> in = Arrays.asList(Arrays.asList(new IntWritable(0), new Text("first"), new DoubleWritable(3.0)), Arrays.asList(new IntWritable(0), new Text("second"), new DoubleWritable(5.0)), Arrays.asList(new IntWritable(1), new Text("f"), new DoubleWritable(30.0)), Arrays.asList(new IntWritable(1), new Text("s"), new DoubleWritable(50.0))); + List> in = Arrays.asList(Arrays.asList(new IntWritable(0), new Text("first"), new DoubleWritable(3.0)), Arrays.asList(new IntWritable(0), new Text("second"), new DoubleWritable(5.0)), Arrays.asList(new IntWritable(1), new Text("f"), new DoubleWritable(30.0)), Arrays.asList(new IntWritable(1), new Text("s"), new DoubleWritable(50.0))); List> inData = in; Schema s = new Schema.Builder().addColumnInteger("intCol").addColumnString("textCol").addColumnDouble("doubleCol").build(); TransformProcess tp = new TransformProcess.Builder(s).reduce(new Reducer.Builder(ReduceOp.TakeFirst).keyColumns("intCol").takeFirstColumns("textCol").meanColumns("doubleCol").build()).build(); List> outRdd = LocalTransformExecutor.execute(inData, tp); List> out = outRdd; - List> expOut = Arrays.asList(Arrays.asList(new IntWritable(0), new Text("first"), new DoubleWritable(4.0)), Arrays.asList(new IntWritable(1), new Text("f"), new DoubleWritable(40.0))); + List> expOut = Arrays.asList(Arrays.asList(new IntWritable(0), new Text("first"), new DoubleWritable(4.0)), Arrays.asList(new IntWritable(1), new Text("f"), new DoubleWritable(40.0))); out = new ArrayList<>(out); Collections.sort(out, Comparator.comparingInt(o -> o.get(0).toInt())); assertEquals(expOut, out); diff --git a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/transform/join/TestJoin.java b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/transform/join/TestJoin.java index adb511603..3cfa9b0c1 100644 --- a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/transform/join/TestJoin.java +++ b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/transform/join/TestJoin.java @@ -28,12 +28,15 @@ import org.datavec.api.writable.*; import org.datavec.local.transforms.LocalTransformExecutor; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.TagNames; import java.util.*; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) public class TestJoin { @Test @@ -46,27 +49,27 @@ public class TestJoin { .addColumnDouble("amount").build(); List> infoList = new ArrayList<>(); - infoList.add(Arrays.asList(new LongWritable(12345), new Text("Customer12345"))); - infoList.add(Arrays.asList(new LongWritable(98765), new Text("Customer98765"))); - infoList.add(Arrays.asList(new LongWritable(50000), new Text("Customer50000"))); + infoList.add(Arrays.asList(new LongWritable(12345), new Text("Customer12345"))); + infoList.add(Arrays.asList(new LongWritable(98765), new Text("Customer98765"))); + infoList.add(Arrays.asList(new LongWritable(50000), new Text("Customer50000"))); List> purchaseList = new ArrayList<>(); - purchaseList.add(Arrays.asList(new LongWritable(1000000), new LongWritable(12345), + purchaseList.add(Arrays.asList(new LongWritable(1000000), new LongWritable(12345), new DoubleWritable(10.00))); - purchaseList.add(Arrays.asList(new LongWritable(1000001), new LongWritable(12345), + purchaseList.add(Arrays.asList(new LongWritable(1000001), new LongWritable(12345), new DoubleWritable(20.00))); - purchaseList.add(Arrays.asList(new LongWritable(1000002), new LongWritable(98765), + purchaseList.add(Arrays.asList(new LongWritable(1000002), new LongWritable(98765), new DoubleWritable(30.00))); Join join = new Join.Builder(Join.JoinType.RightOuter).setJoinColumns("customerID") .setSchemas(customerInfoSchema, purchasesSchema).build(); List> expected = new ArrayList<>(); - expected.add(Arrays.asList(new LongWritable(12345), new Text("Customer12345"), + expected.add(Arrays.asList(new LongWritable(12345), new Text("Customer12345"), new LongWritable(1000000), new DoubleWritable(10.00))); - expected.add(Arrays.asList(new LongWritable(12345), new Text("Customer12345"), + expected.add(Arrays.asList(new LongWritable(12345), new Text("Customer12345"), new LongWritable(1000001), new DoubleWritable(20.00))); - expected.add(Arrays.asList(new LongWritable(98765), new Text("Customer98765"), + expected.add(Arrays.asList(new LongWritable(98765), new Text("Customer98765"), new LongWritable(1000002), new DoubleWritable(30.00))); @@ -77,12 +80,7 @@ public class TestJoin { List> joined = LocalTransformExecutor.executeJoin(join, info, purchases); List> joinedList = new ArrayList<>(joined); //Sort by order ID (column 3, index 2) - Collections.sort(joinedList, new Comparator>() { - @Override - public int compare(List o1, List o2) { - return Long.compare(o1.get(2).toLong(), o2.get(2).toLong()); - } - }); + Collections.sort(joinedList, (o1, o2) -> Long.compare(o1.get(2).toLong(), o2.get(2).toLong())); assertEquals(expected, joinedList); assertEquals(3, joinedList.size()); @@ -110,12 +108,7 @@ public class TestJoin { List> joined2 = LocalTransformExecutor.executeJoin(join2, purchases, info); List> joinedList2 = new ArrayList<>(joined2); //Sort by order ID (column 0) - Collections.sort(joinedList2, new Comparator>() { - @Override - public int compare(List o1, List o2) { - return Long.compare(o1.get(0).toLong(), o2.get(0).toLong()); - } - }); + Collections.sort(joinedList2, (o1, o2) -> Long.compare(o1.get(0).toLong(), o2.get(0).toLong())); assertEquals(3, joinedList2.size()); assertEquals(expectedManyToOne, joinedList2); @@ -189,29 +182,26 @@ public class TestJoin { new ArrayList<>(LocalTransformExecutor.executeJoin(join, firstRDD, secondRDD)); //Sort output by column 0, then column 1, then column 2 for comparison to expected... - Collections.sort(out, new Comparator>() { - @Override - public int compare(List o1, List o2) { - Writable w1 = o1.get(0); - Writable w2 = o2.get(0); - if (w1 instanceof NullWritable) - return 1; - else if (w2 instanceof NullWritable) - return -1; - int c = Long.compare(w1.toLong(), w2.toLong()); - if (c != 0) - return c; - c = o1.get(1).toString().compareTo(o2.get(1).toString()); - if (c != 0) - return c; - w1 = o1.get(2); - w2 = o2.get(2); - if (w1 instanceof NullWritable) - return 1; - else if (w2 instanceof NullWritable) - return -1; - return Long.compare(w1.toLong(), w2.toLong()); - } + Collections.sort(out, (o1, o2) -> { + Writable w1 = o1.get(0); + Writable w2 = o2.get(0); + if (w1 instanceof NullWritable) + return 1; + else if (w2 instanceof NullWritable) + return -1; + int c = Long.compare(w1.toLong(), w2.toLong()); + if (c != 0) + return c; + c = o1.get(1).toString().compareTo(o2.get(1).toString()); + if (c != 0) + return c; + w1 = o1.get(2); + w2 = o2.get(2); + if (w1 instanceof NullWritable) + return 1; + else if (w2 instanceof NullWritable) + return -1; + return Long.compare(w1.toLong(), w2.toLong()); }); switch (jt) { diff --git a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/transform/rank/TestCalculateSortedRank.java b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/transform/rank/TestCalculateSortedRank.java index 39f3405a9..1be235d47 100644 --- a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/transform/rank/TestCalculateSortedRank.java +++ b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/transform/rank/TestCalculateSortedRank.java @@ -31,14 +31,17 @@ import org.datavec.api.writable.comparator.DoubleWritableComparator; import org.datavec.local.transforms.LocalTransformExecutor; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.TagNames; import java.util.ArrayList; import java.util.Arrays; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) public class TestCalculateSortedRank { @Test diff --git a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/transform/sequence/TestConvertToSequence.java b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/transform/sequence/TestConvertToSequence.java index 04a4a5c47..3987f2930 100644 --- a/datavec/datavec-local/src/test/java/org/datavec/local/transforms/transform/sequence/TestConvertToSequence.java +++ b/datavec/datavec-local/src/test/java/org/datavec/local/transforms/transform/sequence/TestConvertToSequence.java @@ -31,7 +31,9 @@ import org.datavec.api.writable.Writable; import org.datavec.arrow.recordreader.ArrowWritableRecordTimeSeriesBatch; import org.datavec.local.transforms.LocalTransformExecutor; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.TagNames; import java.util.Arrays; import java.util.Collections; @@ -39,7 +41,8 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) public class TestConvertToSequence { @Test @@ -48,12 +51,12 @@ public class TestConvertToSequence { Schema s = new Schema.Builder().addColumnsString("key1", "key2").addColumnLong("time").build(); List> allExamples = - Arrays.asList(Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(10)), - Arrays.asList(new Text("k1b"), new Text("k2b"), new LongWritable(10)), - Arrays.asList(new Text("k1a"), new Text("k2a"), + Arrays.asList(Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(10)), + Arrays.asList(new Text("k1b"), new Text("k2b"), new LongWritable(10)), + Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(-10)), - Arrays.asList(new Text("k1b"), new Text("k2b"), new LongWritable(5)), - Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(0))); + Arrays.asList(new Text("k1b"), new Text("k2b"), new LongWritable(5)), + Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(0))); TransformProcess tp = new TransformProcess.Builder(s) .convertToSequence(Arrays.asList("key1", "key2"), new NumericalColumnComparator("time")) @@ -75,13 +78,13 @@ public class TestConvertToSequence { } List> expSeq0 = Arrays.asList( - Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(-10)), - Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(0)), - Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(10))); + Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(-10)), + Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(0)), + Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(10))); List> expSeq1 = Arrays.asList( - Arrays.asList(new Text("k1b"), new Text("k2b"), new LongWritable(5)), - Arrays.asList(new Text("k1b"), new Text("k2b"), new LongWritable(10))); + Arrays.asList(new Text("k1b"), new Text("k2b"), new LongWritable(5)), + Arrays.asList(new Text("k1b"), new Text("k2b"), new LongWritable(10))); assertEquals(expSeq0, seq0); assertEquals(expSeq1, seq1); @@ -96,9 +99,9 @@ public class TestConvertToSequence { .build(); List> allExamples = Arrays.asList( - Arrays.asList(new Text("a"), new LongWritable(0)), - Arrays.asList(new Text("b"), new LongWritable(1)), - Arrays.asList(new Text("c"), new LongWritable(2))); + Arrays.asList(new Text("a"), new LongWritable(0)), + Arrays.asList(new Text("b"), new LongWritable(1)), + Arrays.asList(new Text("c"), new LongWritable(2))); TransformProcess tp = new TransformProcess.Builder(s) .convertToSequence() diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/TestKryoSerialization.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/TestKryoSerialization.java index a684fb61d..512c6054e 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/TestKryoSerialization.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/TestKryoSerialization.java @@ -25,8 +25,10 @@ import org.apache.spark.serializer.SerializerInstance; import org.datavec.api.records.reader.RecordReader; import org.datavec.api.records.reader.impl.csv.CSVRecordReader; import org.datavec.api.split.FileSplit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import java.nio.ByteBuffer; @@ -34,7 +36,10 @@ import java.nio.ByteBuffer; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertFalse; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) public class TestKryoSerialization extends BaseSparkTest { @Override diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestLineRecordReaderFunction.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestLineRecordReaderFunction.java index d7a906597..3a9c36dc7 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestLineRecordReaderFunction.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestLineRecordReaderFunction.java @@ -27,8 +27,10 @@ import org.datavec.api.records.reader.impl.csv.CSVRecordReader; import org.datavec.api.split.FileSplit; import org.datavec.api.writable.Writable; import org.datavec.spark.BaseSparkTest; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import java.util.HashSet; @@ -37,7 +39,10 @@ import java.util.Set; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) public class TestLineRecordReaderFunction extends BaseSparkTest { @Test diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestNDArrayToWritablesFunction.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestNDArrayToWritablesFunction.java index 4990cfe03..83a6912bf 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestNDArrayToWritablesFunction.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestNDArrayToWritablesFunction.java @@ -24,7 +24,10 @@ import org.datavec.api.writable.DoubleWritable; import org.datavec.api.writable.NDArrayWritable; import org.datavec.api.writable.Writable; import org.datavec.spark.transform.misc.NDArrayToWritablesFunction; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -33,7 +36,10 @@ import java.util.Arrays; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestNDArrayToWritablesFunction { @Test diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestPairSequenceRecordReaderBytesFunction.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestPairSequenceRecordReaderBytesFunction.java index 3ce9afe46..1f986de21 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestPairSequenceRecordReaderBytesFunction.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestPairSequenceRecordReaderBytesFunction.java @@ -39,10 +39,12 @@ import org.datavec.spark.functions.pairdata.PathToKeyConverter; import org.datavec.spark.functions.pairdata.PathToKeyConverterFilename; import org.datavec.spark.util.DataVecSparkUtil; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.TagNames; import scala.Tuple2; import java.io.File; @@ -53,7 +55,10 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.fail; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) public class TestPairSequenceRecordReaderBytesFunction extends BaseSparkTest { @Test diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestRecordReaderBytesFunction.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestRecordReaderBytesFunction.java index 0ccd52a35..68c9aca65 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestRecordReaderBytesFunction.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestRecordReaderBytesFunction.java @@ -37,10 +37,12 @@ import org.datavec.spark.BaseSparkTest; import org.datavec.spark.functions.data.FilesAsBytesFunction; import org.datavec.spark.functions.data.RecordReaderBytesFunction; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import java.nio.file.Files; @@ -51,7 +53,10 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.fail; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) public class TestRecordReaderBytesFunction extends BaseSparkTest { diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestRecordReaderFunction.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestRecordReaderFunction.java index 8d4090096..dc436ea8e 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestRecordReaderFunction.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestRecordReaderFunction.java @@ -32,10 +32,12 @@ import org.datavec.api.writable.Writable; import org.datavec.image.recordreader.ImageRecordReader; import org.datavec.spark.BaseSparkTest; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import java.nio.file.Path; @@ -45,7 +47,10 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.fail; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) public class TestRecordReaderFunction extends BaseSparkTest { @Test diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestSequenceRecordReaderBytesFunction.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestSequenceRecordReaderBytesFunction.java index 550f0f12a..3f1eb2d6d 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestSequenceRecordReaderBytesFunction.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestSequenceRecordReaderBytesFunction.java @@ -37,10 +37,12 @@ import org.datavec.spark.BaseSparkTest; import org.datavec.spark.functions.data.FilesAsBytesFunction; import org.datavec.spark.functions.data.SequenceRecordReaderBytesFunction; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import java.nio.file.Files; @@ -50,7 +52,10 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.fail; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) public class TestSequenceRecordReaderBytesFunction extends BaseSparkTest { diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestSequenceRecordReaderFunction.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestSequenceRecordReaderFunction.java index 48062a036..e14903273 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestSequenceRecordReaderFunction.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestSequenceRecordReaderFunction.java @@ -34,10 +34,12 @@ import org.datavec.api.writable.Writable; import org.datavec.codec.reader.CodecRecordReader; import org.datavec.spark.BaseSparkTest; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import java.nio.file.Path; @@ -46,7 +48,10 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.fail; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) public class TestSequenceRecordReaderFunction extends BaseSparkTest { diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestWritablesToNDArrayFunction.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestWritablesToNDArrayFunction.java index 62021a252..3a6a61b93 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestWritablesToNDArrayFunction.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestWritablesToNDArrayFunction.java @@ -22,7 +22,10 @@ package org.datavec.spark.functions; import org.datavec.api.writable.*; import org.datavec.spark.transform.misc.WritablesToNDArrayFunction; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -31,7 +34,10 @@ import java.util.ArrayList; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestWritablesToNDArrayFunction { @Test diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestWritablesToStringFunctions.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestWritablesToStringFunctions.java index 070bda4ed..011f673db 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestWritablesToStringFunctions.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/functions/TestWritablesToStringFunctions.java @@ -29,7 +29,9 @@ import org.datavec.api.writable.Writable; import org.datavec.spark.BaseSparkTest; import org.datavec.spark.transform.misc.SequenceWritablesToStringFunction; import org.datavec.spark.transform.misc.WritablesToStringFunction; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.TagNames; import scala.Tuple2; import java.util.ArrayList; @@ -37,7 +39,10 @@ import java.util.Arrays; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) public class TestWritablesToStringFunctions extends BaseSparkTest { @Test @@ -57,19 +62,9 @@ public class TestWritablesToStringFunctions extends BaseSparkTest { JavaSparkContext sc = getContext(); - JavaPairRDD left = sc.parallelize(leftMap).mapToPair(new PairFunction, String, String>() { - @Override - public Tuple2 call(Tuple2 stringStringTuple2) throws Exception { - return stringStringTuple2; - } - }); + JavaPairRDD left = sc.parallelize(leftMap).mapToPair((PairFunction, String, String>) stringStringTuple2 -> stringStringTuple2); - JavaPairRDD right = sc.parallelize(rightMap).mapToPair(new PairFunction, String, String>() { - @Override - public Tuple2 call(Tuple2 stringStringTuple2) throws Exception { - return stringStringTuple2; - } - }); + JavaPairRDD right = sc.parallelize(rightMap).mapToPair((PairFunction, String, String>) stringStringTuple2 -> stringStringTuple2); System.out.println(left.cogroup(right).collect()); } @@ -77,7 +72,7 @@ public class TestWritablesToStringFunctions extends BaseSparkTest { @Test public void testWritablesToString() throws Exception { - List l = Arrays.asList(new DoubleWritable(1.5), new Text("someValue")); + List l = Arrays.asList(new DoubleWritable(1.5), new Text("someValue")); String expected = l.get(0).toString() + "," + l.get(1).toString(); assertEquals(expected, new WritablesToStringFunction(",").call(l)); @@ -86,8 +81,8 @@ public class TestWritablesToStringFunctions extends BaseSparkTest { @Test public void testSequenceWritablesToString() throws Exception { - List> l = Arrays.asList(Arrays.asList(new DoubleWritable(1.5), new Text("someValue")), - Arrays.asList(new DoubleWritable(2.5), new Text("otherValue"))); + List> l = Arrays.asList(Arrays.asList(new DoubleWritable(1.5), new Text("someValue")), + Arrays.asList(new DoubleWritable(2.5), new Text("otherValue"))); String expected = l.get(0).get(0).toString() + "," + l.get(0).get(1).toString() + "\n" + l.get(1).get(0).toString() + "," + l.get(1).get(1).toString(); diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/storage/TestSparkStorageUtils.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/storage/TestSparkStorageUtils.java index f3964af6d..979150ff5 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/storage/TestSparkStorageUtils.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/storage/TestSparkStorageUtils.java @@ -21,6 +21,8 @@ package org.datavec.spark.storage; import com.sun.jna.Platform; +import org.junit.jupiter.api.Tag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.shade.guava.io.Files; import org.apache.spark.api.java.JavaPairRDD; import org.apache.spark.api.java.JavaRDD; @@ -37,7 +39,10 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) public class TestSparkStorageUtils extends BaseSparkTest { @Test @@ -46,11 +51,11 @@ public class TestSparkStorageUtils extends BaseSparkTest { return; } List> l = new ArrayList<>(); - l.add(Arrays.asList(new Text("zero"), new IntWritable(0), + l.add(Arrays.asList(new Text("zero"), new IntWritable(0), new DoubleWritable(0), new NDArrayWritable(Nd4j.valueArrayOf(10, 0.0)))); - l.add(Arrays.asList(new Text("one"), new IntWritable(11), + l.add(Arrays.asList(new Text("one"), new IntWritable(11), new DoubleWritable(11.0), new NDArrayWritable(Nd4j.valueArrayOf(10, 11.0)))); - l.add(Arrays.asList(new Text("two"), new IntWritable(22), + l.add(Arrays.asList(new Text("two"), new IntWritable(22), new DoubleWritable(22.0), new NDArrayWritable(Nd4j.valueArrayOf(10, 22.0)))); JavaRDD> rdd = sc.parallelize(l); @@ -92,17 +97,17 @@ public class TestSparkStorageUtils extends BaseSparkTest { } List>> l = new ArrayList<>(); l.add(Arrays.asList( - Arrays.asList(new Text("zero"), new IntWritable(0), + Arrays.asList(new Text("zero"), new IntWritable(0), new DoubleWritable(0), new NDArrayWritable(Nd4j.valueArrayOf(10, 0.0))), - Arrays.asList(new Text("one"), new IntWritable(1), + Arrays.asList(new Text("one"), new IntWritable(1), new DoubleWritable(1.0), new NDArrayWritable(Nd4j.valueArrayOf(10, 1.0))), - Arrays.asList(new Text("two"), new IntWritable(2), + Arrays.asList(new Text("two"), new IntWritable(2), new DoubleWritable(2.0), new NDArrayWritable(Nd4j.valueArrayOf(10, 2.0))))); l.add(Arrays.asList( - Arrays.asList(new Text("Bzero"), new IntWritable(10), + Arrays.asList(new Text("Bzero"), new IntWritable(10), new DoubleWritable(10), new NDArrayWritable(Nd4j.valueArrayOf(10, 10.0))), - Arrays.asList(new Text("Bone"), new IntWritable(11), + Arrays.asList(new Text("Bone"), new IntWritable(11), new DoubleWritable(11.0), new NDArrayWritable(Nd4j.valueArrayOf(10, 11.0))), Arrays.asList(new Text("Btwo"), new IntWritable(12), new DoubleWritable(12.0), new NDArrayWritable(Nd4j.valueArrayOf(10, 12.0))))); diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/DataFramesTests.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/DataFramesTests.java index 62237f0b4..05ae426ed 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/DataFramesTests.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/DataFramesTests.java @@ -30,14 +30,19 @@ import org.datavec.api.util.ndarray.RecordConverter; import org.datavec.api.writable.DoubleWritable; import org.datavec.api.writable.Writable; import org.datavec.spark.BaseSparkTest; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import java.util.*; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) public class DataFramesTests extends BaseSparkTest { @Test @@ -110,15 +115,15 @@ public class DataFramesTests extends BaseSparkTest { public void testNormalize() { List> data = new ArrayList<>(); - data.add(Arrays.asList(new DoubleWritable(1), new DoubleWritable(10))); - data.add(Arrays.asList(new DoubleWritable(2), new DoubleWritable(20))); - data.add(Arrays.asList(new DoubleWritable(3), new DoubleWritable(30))); + data.add(Arrays.asList(new DoubleWritable(1), new DoubleWritable(10))); + data.add(Arrays.asList(new DoubleWritable(2), new DoubleWritable(20))); + data.add(Arrays.asList(new DoubleWritable(3), new DoubleWritable(30))); List> expMinMax = new ArrayList<>(); - expMinMax.add(Arrays.asList(new DoubleWritable(0.0), new DoubleWritable(0.0))); - expMinMax.add(Arrays.asList(new DoubleWritable(0.5), new DoubleWritable(0.5))); - expMinMax.add(Arrays.asList(new DoubleWritable(1.0), new DoubleWritable(1.0))); + expMinMax.add(Arrays.asList(new DoubleWritable(0.0), new DoubleWritable(0.0))); + expMinMax.add(Arrays.asList(new DoubleWritable(0.5), new DoubleWritable(0.5))); + expMinMax.add(Arrays.asList(new DoubleWritable(1.0), new DoubleWritable(1.0))); double m1 = (1 + 2 + 3) / 3.0; double s1 = new StandardDeviation().evaluate(new double[] {1, 2, 3}); @@ -127,11 +132,11 @@ public class DataFramesTests extends BaseSparkTest { List> expStandardize = new ArrayList<>(); expStandardize.add( - Arrays.asList(new DoubleWritable((1 - m1) / s1), new DoubleWritable((10 - m2) / s2))); + Arrays.asList(new DoubleWritable((1 - m1) / s1), new DoubleWritable((10 - m2) / s2))); expStandardize.add( - Arrays.asList(new DoubleWritable((2 - m1) / s1), new DoubleWritable((20 - m2) / s2))); + Arrays.asList(new DoubleWritable((2 - m1) / s1), new DoubleWritable((20 - m2) / s2))); expStandardize.add( - Arrays.asList(new DoubleWritable((3 - m1) / s1), new DoubleWritable((30 - m2) / s2))); + Arrays.asList(new DoubleWritable((3 - m1) / s1), new DoubleWritable((30 - m2) / s2))); JavaRDD> rdd = sc.parallelize(data); @@ -178,13 +183,13 @@ public class DataFramesTests extends BaseSparkTest { List>> sequences = new ArrayList<>(); List> seq1 = new ArrayList<>(); - seq1.add(Arrays.asList(new DoubleWritable(1), new DoubleWritable(10), new DoubleWritable(100))); - seq1.add(Arrays.asList(new DoubleWritable(2), new DoubleWritable(20), new DoubleWritable(200))); - seq1.add(Arrays.asList(new DoubleWritable(3), new DoubleWritable(30), new DoubleWritable(300))); + seq1.add(Arrays.asList(new DoubleWritable(1), new DoubleWritable(10), new DoubleWritable(100))); + seq1.add(Arrays.asList(new DoubleWritable(2), new DoubleWritable(20), new DoubleWritable(200))); + seq1.add(Arrays.asList(new DoubleWritable(3), new DoubleWritable(30), new DoubleWritable(300))); List> seq2 = new ArrayList<>(); - seq2.add(Arrays.asList(new DoubleWritable(4), new DoubleWritable(40), new DoubleWritable(400))); - seq2.add(Arrays.asList(new DoubleWritable(5), new DoubleWritable(50), new DoubleWritable(500))); + seq2.add(Arrays.asList(new DoubleWritable(4), new DoubleWritable(40), new DoubleWritable(400))); + seq2.add(Arrays.asList(new DoubleWritable(5), new DoubleWritable(50), new DoubleWritable(500))); sequences.add(seq1); sequences.add(seq2); @@ -199,21 +204,21 @@ public class DataFramesTests extends BaseSparkTest { //Min/max normalization: List> expSeq1MinMax = new ArrayList<>(); - expSeq1MinMax.add(Arrays.asList(new DoubleWritable((1 - 1.0) / (5.0 - 1.0)), + expSeq1MinMax.add(Arrays.asList(new DoubleWritable((1 - 1.0) / (5.0 - 1.0)), new DoubleWritable((10 - 10.0) / (50.0 - 10.0)), new DoubleWritable((100 - 100.0) / (500.0 - 100.0)))); - expSeq1MinMax.add(Arrays.asList(new DoubleWritable((2 - 1.0) / (5.0 - 1.0)), + expSeq1MinMax.add(Arrays.asList(new DoubleWritable((2 - 1.0) / (5.0 - 1.0)), new DoubleWritable((20 - 10.0) / (50.0 - 10.0)), new DoubleWritable((200 - 100.0) / (500.0 - 100.0)))); - expSeq1MinMax.add(Arrays.asList(new DoubleWritable((3 - 1.0) / (5.0 - 1.0)), + expSeq1MinMax.add(Arrays.asList(new DoubleWritable((3 - 1.0) / (5.0 - 1.0)), new DoubleWritable((30 - 10.0) / (50.0 - 10.0)), new DoubleWritable((300 - 100.0) / (500.0 - 100.0)))); List> expSeq2MinMax = new ArrayList<>(); - expSeq2MinMax.add(Arrays.asList(new DoubleWritable((4 - 1.0) / (5.0 - 1.0)), + expSeq2MinMax.add(Arrays.asList(new DoubleWritable((4 - 1.0) / (5.0 - 1.0)), new DoubleWritable((40 - 10.0) / (50.0 - 10.0)), new DoubleWritable((400 - 100.0) / (500.0 - 100.0)))); - expSeq2MinMax.add(Arrays.asList(new DoubleWritable((5 - 1.0) / (5.0 - 1.0)), + expSeq2MinMax.add(Arrays.asList(new DoubleWritable((5 - 1.0) / (5.0 - 1.0)), new DoubleWritable((50 - 10.0) / (50.0 - 10.0)), new DoubleWritable((500 - 100.0) / (500.0 - 100.0)))); @@ -246,17 +251,17 @@ public class DataFramesTests extends BaseSparkTest { double s3 = new StandardDeviation().evaluate(new double[] {100, 200, 300, 400, 500}); List> expSeq1Std = new ArrayList<>(); - expSeq1Std.add(Arrays.asList(new DoubleWritable((1 - m1) / s1), new DoubleWritable((10 - m2) / s2), + expSeq1Std.add(Arrays.asList(new DoubleWritable((1 - m1) / s1), new DoubleWritable((10 - m2) / s2), new DoubleWritable((100 - m3) / s3))); - expSeq1Std.add(Arrays.asList(new DoubleWritable((2 - m1) / s1), new DoubleWritable((20 - m2) / s2), + expSeq1Std.add(Arrays.asList(new DoubleWritable((2 - m1) / s1), new DoubleWritable((20 - m2) / s2), new DoubleWritable((200 - m3) / s3))); - expSeq1Std.add(Arrays.asList(new DoubleWritable((3 - m1) / s1), new DoubleWritable((30 - m2) / s2), + expSeq1Std.add(Arrays.asList(new DoubleWritable((3 - m1) / s1), new DoubleWritable((30 - m2) / s2), new DoubleWritable((300 - m3) / s3))); List> expSeq2Std = new ArrayList<>(); - expSeq2Std.add(Arrays.asList(new DoubleWritable((4 - m1) / s1), new DoubleWritable((40 - m2) / s2), + expSeq2Std.add(Arrays.asList(new DoubleWritable((4 - m1) / s1), new DoubleWritable((40 - m2) / s2), new DoubleWritable((400 - m3) / s3))); - expSeq2Std.add(Arrays.asList(new DoubleWritable((5 - m1) / s1), new DoubleWritable((50 - m2) / s2), + expSeq2Std.add(Arrays.asList(new DoubleWritable((5 - m1) / s1), new DoubleWritable((50 - m2) / s2), new DoubleWritable((500 - m3) / s3))); diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/ExecutionTest.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/ExecutionTest.java index 6a1015197..a785b4938 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/ExecutionTest.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/ExecutionTest.java @@ -31,22 +31,24 @@ import org.datavec.api.writable.DoubleWritable; import org.datavec.api.writable.IntWritable; import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; -import org.datavec.api.writable.NDArrayWritable; -import org.datavec.spark.BaseSparkTest; import org.datavec.python.PythonTransform; +import org.datavec.spark.BaseSparkTest; import org.junit.jupiter.api.Disabled; -import org.junit.jupiter.api.Test; -import org.nd4j.linalg.api.ndarray.INDArray; -import org.nd4j.linalg.factory.Nd4j; -import java.util.*; -import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.junit.jupiter.api.Assertions.assertTrue; import org.junit.jupiter.api.DisplayName; -import org.junit.jupiter.api.extension.ExtendWith; +import org.junit.jupiter.api.Tag; +import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.TagNames; + +import java.util.*; + import static java.time.Duration.ofMillis; -import static org.junit.jupiter.api.Assertions.assertTimeout; +import static org.junit.jupiter.api.Assertions.*; @DisplayName("Execution Test") +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) class ExecutionTest extends BaseSparkTest { @Test @@ -55,22 +57,16 @@ class ExecutionTest extends BaseSparkTest { Schema schema = new Schema.Builder().addColumnInteger("col0").addColumnCategorical("col1", "state0", "state1", "state2").addColumnDouble("col2").build(); TransformProcess tp = new TransformProcess.Builder(schema).categoricalToInteger("col1").doubleMathOp("col2", MathOp.Add, 10.0).build(); List> inputData = new ArrayList<>(); - inputData.add(Arrays.asList(new IntWritable(0), new Text("state2"), new DoubleWritable(0.1))); - inputData.add(Arrays.asList(new IntWritable(1), new Text("state1"), new DoubleWritable(1.1))); - inputData.add(Arrays.asList(new IntWritable(2), new Text("state0"), new DoubleWritable(2.1))); + inputData.add(Arrays.asList(new IntWritable(0), new Text("state2"), new DoubleWritable(0.1))); + inputData.add(Arrays.asList(new IntWritable(1), new Text("state1"), new DoubleWritable(1.1))); + inputData.add(Arrays.asList(new IntWritable(2), new Text("state0"), new DoubleWritable(2.1))); JavaRDD> rdd = sc.parallelize(inputData); List> out = new ArrayList<>(SparkTransformExecutor.execute(rdd, tp).collect()); - Collections.sort(out, new Comparator>() { - - @Override - public int compare(List o1, List o2) { - return Integer.compare(o1.get(0).toInt(), o2.get(0).toInt()); - } - }); + Collections.sort(out, Comparator.comparingInt(o -> o.get(0).toInt())); List> expected = new ArrayList<>(); - expected.add(Arrays.asList(new IntWritable(0), new IntWritable(2), new DoubleWritable(10.1))); - expected.add(Arrays.asList(new IntWritable(1), new IntWritable(1), new DoubleWritable(11.1))); - expected.add(Arrays.asList(new IntWritable(2), new IntWritable(0), new DoubleWritable(12.1))); + expected.add(Arrays.asList(new IntWritable(0), new IntWritable(2), new DoubleWritable(10.1))); + expected.add(Arrays.asList(new IntWritable(1), new IntWritable(1), new DoubleWritable(11.1))); + expected.add(Arrays.asList(new IntWritable(2), new IntWritable(0), new DoubleWritable(12.1))); assertEquals(expected, out); } @@ -81,31 +77,25 @@ class ExecutionTest extends BaseSparkTest { TransformProcess tp = new TransformProcess.Builder(schema).categoricalToInteger("col1").doubleMathOp("col2", MathOp.Add, 10.0).build(); List>> inputSequences = new ArrayList<>(); List> seq1 = new ArrayList<>(); - seq1.add(Arrays.asList(new IntWritable(0), new Text("state2"), new DoubleWritable(0.1))); - seq1.add(Arrays.asList(new IntWritable(1), new Text("state1"), new DoubleWritable(1.1))); - seq1.add(Arrays.asList(new IntWritable(2), new Text("state0"), new DoubleWritable(2.1))); + seq1.add(Arrays.asList(new IntWritable(0), new Text("state2"), new DoubleWritable(0.1))); + seq1.add(Arrays.asList(new IntWritable(1), new Text("state1"), new DoubleWritable(1.1))); + seq1.add(Arrays.asList(new IntWritable(2), new Text("state0"), new DoubleWritable(2.1))); List> seq2 = new ArrayList<>(); - seq2.add(Arrays.asList(new IntWritable(3), new Text("state0"), new DoubleWritable(3.1))); - seq2.add(Arrays.asList(new IntWritable(4), new Text("state1"), new DoubleWritable(4.1))); + seq2.add(Arrays.asList(new IntWritable(4), new Text("state1"), new DoubleWritable(4.1))); + seq2.add(Arrays.asList(new IntWritable(3), new Text("state0"), new DoubleWritable(3.1))); inputSequences.add(seq1); inputSequences.add(seq2); JavaRDD>> rdd = sc.parallelize(inputSequences); List>> out = new ArrayList<>(SparkTransformExecutor.executeSequenceToSequence(rdd, tp).collect()); - Collections.sort(out, new Comparator>>() { - - @Override - public int compare(List> o1, List> o2) { - return -Integer.compare(o1.size(), o2.size()); - } - }); + Collections.sort(out, (o1, o2) -> -Integer.compare(o1.size(), o2.size())); List>> expectedSequence = new ArrayList<>(); List> seq1e = new ArrayList<>(); - seq1e.add(Arrays.asList(new IntWritable(0), new IntWritable(2), new DoubleWritable(10.1))); - seq1e.add(Arrays.asList(new IntWritable(1), new IntWritable(1), new DoubleWritable(11.1))); - seq1e.add(Arrays.asList(new IntWritable(2), new IntWritable(0), new DoubleWritable(12.1))); + seq1e.add(Arrays.asList(new IntWritable(0), new IntWritable(2), new DoubleWritable(10.1))); + seq1e.add(Arrays.asList(new IntWritable(1), new IntWritable(1), new DoubleWritable(11.1))); + seq1e.add(Arrays.asList(new IntWritable(2), new IntWritable(0), new DoubleWritable(12.1))); List> seq2e = new ArrayList<>(); - seq2e.add(Arrays.asList(new IntWritable(3), new IntWritable(0), new DoubleWritable(13.1))); - seq2e.add(Arrays.asList(new IntWritable(4), new IntWritable(1), new DoubleWritable(14.1))); + seq2e.add(Arrays.asList(new IntWritable(3), new IntWritable(0), new DoubleWritable(13.1))); + seq2e.add(Arrays.asList(new IntWritable(4), new IntWritable(1), new DoubleWritable(14.1))); expectedSequence.add(seq1e); expectedSequence.add(seq2e); assertEquals(expectedSequence, out); @@ -114,34 +104,28 @@ class ExecutionTest extends BaseSparkTest { @Test @DisplayName("Test Reduction Global") void testReductionGlobal() { - List> in = Arrays.asList(Arrays.asList(new Text("first"), new DoubleWritable(3.0)), Arrays.asList(new Text("second"), new DoubleWritable(5.0))); + List> in = Arrays.asList(Arrays.asList(new Text("first"), new DoubleWritable(3.0)), Arrays.asList(new Text("second"), new DoubleWritable(5.0))); JavaRDD> inData = sc.parallelize(in); Schema s = new Schema.Builder().addColumnString("textCol").addColumnDouble("doubleCol").build(); TransformProcess tp = new TransformProcess.Builder(s).reduce(new Reducer.Builder(ReduceOp.TakeFirst).takeFirstColumns("textCol").meanColumns("doubleCol").build()).build(); JavaRDD> outRdd = SparkTransformExecutor.execute(inData, tp); List> out = outRdd.collect(); - List> expOut = Collections.singletonList(Arrays.asList(new Text("first"), new DoubleWritable(4.0))); + List> expOut = Collections.singletonList(Arrays.asList(new Text("first"), new DoubleWritable(4.0))); assertEquals(expOut, out); } @Test @DisplayName("Test Reduction By Key") void testReductionByKey() { - List> in = Arrays.asList(Arrays.asList(new IntWritable(0), new Text("first"), new DoubleWritable(3.0)), Arrays.asList(new IntWritable(0), new Text("second"), new DoubleWritable(5.0)), Arrays.asList(new IntWritable(1), new Text("f"), new DoubleWritable(30.0)), Arrays.asList(new IntWritable(1), new Text("s"), new DoubleWritable(50.0))); + List> in = Arrays.asList(Arrays.asList(new IntWritable(0), new Text("first"), new DoubleWritable(3.0)), Arrays.asList(new IntWritable(0), new Text("second"), new DoubleWritable(5.0)), Arrays.asList(new IntWritable(1), new Text("f"), new DoubleWritable(30.0)), Arrays.asList(new IntWritable(1), new Text("s"), new DoubleWritable(50.0))); JavaRDD> inData = sc.parallelize(in); Schema s = new Schema.Builder().addColumnInteger("intCol").addColumnString("textCol").addColumnDouble("doubleCol").build(); TransformProcess tp = new TransformProcess.Builder(s).reduce(new Reducer.Builder(ReduceOp.TakeFirst).keyColumns("intCol").takeFirstColumns("textCol").meanColumns("doubleCol").build()).build(); JavaRDD> outRdd = SparkTransformExecutor.execute(inData, tp); List> out = outRdd.collect(); - List> expOut = Arrays.asList(Arrays.asList(new IntWritable(0), new Text("first"), new DoubleWritable(4.0)), Arrays.asList(new IntWritable(1), new Text("f"), new DoubleWritable(40.0))); + List> expOut = Arrays.asList(Arrays.asList(new IntWritable(0), new Text("first"), new DoubleWritable(4.0)), Arrays.asList(new IntWritable(1), new Text("f"), new DoubleWritable(40.0))); out = new ArrayList<>(out); - Collections.sort(out, new Comparator>() { - - @Override - public int compare(List o1, List o2) { - return Integer.compare(o1.get(0).toInt(), o2.get(0).toInt()); - } - }); + Collections.sort(out, (o1, o2) -> Integer.compare(o1.get(0).toInt(), o2.get(0).toInt())); assertEquals(expOut, out); } @@ -150,15 +134,15 @@ class ExecutionTest extends BaseSparkTest { void testUniqueMultiCol() { Schema schema = new Schema.Builder().addColumnInteger("col0").addColumnCategorical("col1", "state0", "state1", "state2").addColumnDouble("col2").build(); List> inputData = new ArrayList<>(); - inputData.add(Arrays.asList(new IntWritable(0), new Text("state2"), new DoubleWritable(0.1))); - inputData.add(Arrays.asList(new IntWritable(1), new Text("state1"), new DoubleWritable(1.1))); - inputData.add(Arrays.asList(new IntWritable(2), new Text("state0"), new DoubleWritable(2.1))); - inputData.add(Arrays.asList(new IntWritable(0), new Text("state2"), new DoubleWritable(0.1))); - inputData.add(Arrays.asList(new IntWritable(1), new Text("state1"), new DoubleWritable(1.1))); - inputData.add(Arrays.asList(new IntWritable(2), new Text("state0"), new DoubleWritable(2.1))); - inputData.add(Arrays.asList(new IntWritable(0), new Text("state2"), new DoubleWritable(0.1))); - inputData.add(Arrays.asList(new IntWritable(1), new Text("state1"), new DoubleWritable(1.1))); - inputData.add(Arrays.asList(new IntWritable(2), new Text("state0"), new DoubleWritable(2.1))); + inputData.add(Arrays.asList(new IntWritable(0), new Text("state2"), new DoubleWritable(0.1))); + inputData.add(Arrays.asList(new IntWritable(1), new Text("state1"), new DoubleWritable(1.1))); + inputData.add(Arrays.asList(new IntWritable(2), new Text("state0"), new DoubleWritable(2.1))); + inputData.add(Arrays.asList(new IntWritable(0), new Text("state2"), new DoubleWritable(0.1))); + inputData.add(Arrays.asList(new IntWritable(1), new Text("state1"), new DoubleWritable(1.1))); + inputData.add(Arrays.asList(new IntWritable(2), new Text("state0"), new DoubleWritable(2.1))); + inputData.add(Arrays.asList(new IntWritable(0), new Text("state2"), new DoubleWritable(0.1))); + inputData.add(Arrays.asList(new IntWritable(1), new Text("state1"), new DoubleWritable(1.1))); + inputData.add(Arrays.asList(new IntWritable(2), new Text("state0"), new DoubleWritable(2.1))); JavaRDD> rdd = sc.parallelize(inputData); Map> l = AnalyzeSpark.getUnique(Arrays.asList("col0", "col1"), schema, rdd); assertEquals(2, l.size()); @@ -180,58 +164,20 @@ class ExecutionTest extends BaseSparkTest { String pythonCode = "col1 = ['state0', 'state1', 'state2'].index(col1)\ncol2 += 10.0"; TransformProcess tp = new TransformProcess.Builder(schema).transform(PythonTransform.builder().code("first = np.sin(first)\nsecond = np.cos(second)").outputSchema(finalSchema).build()).build(); List> inputData = new ArrayList<>(); - inputData.add(Arrays.asList(new IntWritable(0), new Text("state2"), new DoubleWritable(0.1))); - inputData.add(Arrays.asList(new IntWritable(1), new Text("state1"), new DoubleWritable(1.1))); - inputData.add(Arrays.asList(new IntWritable(2), new Text("state0"), new DoubleWritable(2.1))); + inputData.add(Arrays.asList(new IntWritable(0), new Text("state2"), new DoubleWritable(0.1))); + inputData.add(Arrays.asList(new IntWritable(1), new Text("state1"), new DoubleWritable(1.1))); + inputData.add(Arrays.asList(new IntWritable(2), new Text("state0"), new DoubleWritable(2.1))); JavaRDD> rdd = sc.parallelize(inputData); List> out = new ArrayList<>(SparkTransformExecutor.execute(rdd, tp).collect()); - Collections.sort(out, new Comparator>() { - - @Override - public int compare(List o1, List o2) { - return Integer.compare(o1.get(0).toInt(), o2.get(0).toInt()); - } - }); + Collections.sort(out, Comparator.comparingInt(o -> o.get(0).toInt())); List> expected = new ArrayList<>(); - expected.add(Arrays.asList(new IntWritable(0), new IntWritable(2), new DoubleWritable(10.1))); - expected.add(Arrays.asList(new IntWritable(1), new IntWritable(1), new DoubleWritable(11.1))); - expected.add(Arrays.asList(new IntWritable(2), new IntWritable(0), new DoubleWritable(12.1))); + expected.add(Arrays.asList(new IntWritable(0), new IntWritable(2), new DoubleWritable(10.1))); + expected.add(Arrays.asList(new IntWritable(1), new IntWritable(1), new DoubleWritable(11.1))); + expected.add(Arrays.asList(new IntWritable(2), new IntWritable(0), new DoubleWritable(12.1))); assertEquals(expected, out); }); } - @Test - @Disabled("AB 2019/05/21 - Fine locally, timeouts on CI - Issue #7657 and #7771") - @DisplayName("Test Python Execution With ND Arrays") - void testPythonExecutionWithNDArrays() { - assertTimeout(ofMillis(60000), () -> { - long[] shape = new long[] { 3, 2 }; - Schema schema = new Schema.Builder().addColumnInteger("id").addColumnNDArray("col1", shape).addColumnNDArray("col2", shape).build(); - Schema finalSchema = new Schema.Builder().addColumnInteger("id").addColumnNDArray("col1", shape).addColumnNDArray("col2", shape).addColumnNDArray("col3", shape).build(); - String pythonCode = "col3 = col1 + col2"; - TransformProcess tp = new TransformProcess.Builder(schema).transform(PythonTransform.builder().code("first = np.sin(first)\nsecond = np.cos(second)").outputSchema(schema).build()).build(); - INDArray zeros = Nd4j.zeros(shape); - INDArray ones = Nd4j.ones(shape); - INDArray twos = ones.add(ones); - List> inputData = new ArrayList<>(); - inputData.add(Arrays.asList(new IntWritable(0), new NDArrayWritable(zeros), new NDArrayWritable(zeros))); - inputData.add(Arrays.asList(new IntWritable(1), new NDArrayWritable(zeros), new NDArrayWritable(ones))); - inputData.add(Arrays.asList(new IntWritable(2), new NDArrayWritable(ones), new NDArrayWritable(ones))); - JavaRDD> rdd = sc.parallelize(inputData); - List> out = new ArrayList<>(SparkTransformExecutor.execute(rdd, tp).collect()); - Collections.sort(out, new Comparator>() { - - @Override - public int compare(List o1, List o2) { - return Integer.compare(o1.get(0).toInt(), o2.get(0).toInt()); - } - }); - List> expected = new ArrayList<>(); - expected.add(Arrays.asList(new IntWritable(0), new NDArrayWritable(zeros), new NDArrayWritable(zeros), new NDArrayWritable(zeros))); - expected.add(Arrays.asList(new IntWritable(1), new NDArrayWritable(zeros), new NDArrayWritable(ones), new NDArrayWritable(ones))); - expected.add(Arrays.asList(new IntWritable(2), new NDArrayWritable(ones), new NDArrayWritable(ones), new NDArrayWritable(twos))); - }); - } @Test @DisplayName("Test First Digit Transform Benfords Law") diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/NormalizationTests.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/NormalizationTests.java index 769e7c775..32a34eb57 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/NormalizationTests.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/NormalizationTests.java @@ -28,7 +28,10 @@ import org.datavec.api.util.ndarray.RecordConverter; import org.datavec.api.writable.DoubleWritable; import org.datavec.api.writable.Writable; import org.datavec.spark.BaseSparkTest; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -43,7 +46,10 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class NormalizationTests extends BaseSparkTest { diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/analysis/TestAnalysis.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/analysis/TestAnalysis.java index 4fc4f3323..90713a7af 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/analysis/TestAnalysis.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/analysis/TestAnalysis.java @@ -38,7 +38,9 @@ import org.datavec.local.transforms.AnalyzeLocal; import org.datavec.spark.BaseSparkTest; import org.datavec.spark.transform.AnalyzeSpark; import org.joda.time.DateTimeZone; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.common.io.ClassPathResource; @@ -48,7 +50,10 @@ import java.nio.file.Files; import java.util.*; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) public class TestAnalysis extends BaseSparkTest { @Test diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/join/TestJoin.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/join/TestJoin.java index 29da7a0a4..d6a32e194 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/join/TestJoin.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/join/TestJoin.java @@ -27,12 +27,17 @@ import org.datavec.api.transform.schema.Schema; import org.datavec.api.writable.*; import org.datavec.spark.BaseSparkTest; import org.datavec.spark.transform.SparkTransformExecutor; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.TagNames; import java.util.*; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) public class TestJoin extends BaseSparkTest { @Test diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/rank/TestCalculateSortedRank.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/rank/TestCalculateSortedRank.java index 6ff564418..de6818e06 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/rank/TestCalculateSortedRank.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/rank/TestCalculateSortedRank.java @@ -30,24 +30,29 @@ import org.datavec.api.writable.Writable; import org.datavec.api.writable.comparator.DoubleWritableComparator; import org.datavec.spark.BaseSparkTest; import org.datavec.spark.transform.SparkTransformExecutor; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.TagNames; import java.util.ArrayList; import java.util.Arrays; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) public class TestCalculateSortedRank extends BaseSparkTest { @Test public void testCalculateSortedRank() { List> data = new ArrayList<>(); - data.add(Arrays.asList((Writable) new Text("0"), new DoubleWritable(0.0))); - data.add(Arrays.asList((Writable) new Text("3"), new DoubleWritable(0.3))); - data.add(Arrays.asList((Writable) new Text("2"), new DoubleWritable(0.2))); - data.add(Arrays.asList((Writable) new Text("1"), new DoubleWritable(0.1))); + data.add(Arrays.asList(new Text("0"), new DoubleWritable(0.0))); + data.add(Arrays.asList(new Text("3"), new DoubleWritable(0.3))); + data.add(Arrays.asList(new Text("2"), new DoubleWritable(0.2))); + data.add(Arrays.asList(new Text("1"), new DoubleWritable(0.1))); JavaRDD> rdd = sc.parallelize(data); diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/sequence/TestConvertToSequence.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/sequence/TestConvertToSequence.java index 7faca7235..3874cbaa3 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/sequence/TestConvertToSequence.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/transform/sequence/TestConvertToSequence.java @@ -29,7 +29,9 @@ import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; import org.datavec.spark.BaseSparkTest; import org.datavec.spark.transform.SparkTransformExecutor; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.TagNames; import java.util.Arrays; import java.util.Collections; @@ -37,7 +39,10 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) public class TestConvertToSequence extends BaseSparkTest { @Test @@ -45,13 +50,13 @@ public class TestConvertToSequence extends BaseSparkTest { Schema s = new Schema.Builder().addColumnsString("key1", "key2").addColumnLong("time").build(); - List> allExamples = - Arrays.asList(Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(10)), - Arrays.asList(new Text("k1b"), new Text("k2b"), new LongWritable(10)), - Arrays.asList(new Text("k1a"), new Text("k2a"), - new LongWritable(-10)), - Arrays.asList(new Text("k1b"), new Text("k2b"), new LongWritable(5)), - Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(0))); + List> allExamples; + allExamples = Arrays.asList(Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(10)), + Arrays.asList(new Text("k1b"), new Text("k2b"), new LongWritable(10)), + Arrays.asList(new Text("k1a"), new Text("k2a"), + new LongWritable(-10)), + Arrays.asList(new Text("k1b"), new Text("k2b"), new LongWritable(5)), + Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(0))); TransformProcess tp = new TransformProcess.Builder(s) .convertToSequence(Arrays.asList("key1", "key2"), new NumericalColumnComparator("time")) @@ -73,13 +78,13 @@ public class TestConvertToSequence extends BaseSparkTest { } List> expSeq0 = Arrays.asList( - Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(-10)), - Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(0)), - Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(10))); + Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(-10)), + Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(0)), + Arrays.asList(new Text("k1a"), new Text("k2a"), new LongWritable(10))); List> expSeq1 = Arrays.asList( - Arrays.asList(new Text("k1b"), new Text("k2b"), new LongWritable(5)), - Arrays.asList(new Text("k1b"), new Text("k2b"), new LongWritable(10))); + Arrays.asList(new Text("k1b"), new Text("k2b"), new LongWritable(5)), + Arrays.asList(new Text("k1b"), new Text("k2b"), new LongWritable(10))); assertEquals(expSeq0, seq0); assertEquals(expSeq1, seq1); @@ -94,9 +99,9 @@ public class TestConvertToSequence extends BaseSparkTest { .build(); List> allExamples = Arrays.asList( - Arrays.asList(new Text("a"), new LongWritable(0)), - Arrays.asList(new Text("b"), new LongWritable(1)), - Arrays.asList(new Text("c"), new LongWritable(2))); + Arrays.asList(new Text("a"), new LongWritable(0)), + Arrays.asList(new Text("b"), new LongWritable(1)), + Arrays.asList(new Text("c"), new LongWritable(2))); TransformProcess tp = new TransformProcess.Builder(s) .convertToSequence() diff --git a/datavec/datavec-spark/src/test/java/org/datavec/spark/util/TestSparkUtil.java b/datavec/datavec-spark/src/test/java/org/datavec/spark/util/TestSparkUtil.java index a2dd04ce0..92a4e968a 100644 --- a/datavec/datavec-spark/src/test/java/org/datavec/spark/util/TestSparkUtil.java +++ b/datavec/datavec-spark/src/test/java/org/datavec/spark/util/TestSparkUtil.java @@ -28,7 +28,9 @@ import org.datavec.api.writable.Text; import org.datavec.api.writable.Writable; import org.datavec.spark.BaseSparkTest; import org.datavec.spark.transform.utils.SparkUtils; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import java.io.FileInputStream; @@ -38,6 +40,9 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; +@Tag(TagNames.SPARK) +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) public class TestSparkUtil extends BaseSparkTest { @Test @@ -46,8 +51,8 @@ public class TestSparkUtil extends BaseSparkTest { return; } List> l = new ArrayList<>(); - l.add(Arrays.asList(new Text("abc"), new DoubleWritable(2.0), new IntWritable(-1))); - l.add(Arrays.asList(new Text("def"), new DoubleWritable(4.0), new IntWritable(-2))); + l.add(Arrays.asList(new Text("abc"), new DoubleWritable(2.0), new IntWritable(-1))); + l.add(Arrays.asList(new Text("def"), new DoubleWritable(4.0), new IntWritable(-2))); File f = File.createTempFile("testSparkUtil", "txt"); f.deleteOnExit(); diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/RandomTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/RandomTests.java index 493aab237..e19d5a956 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/RandomTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/RandomTests.java @@ -27,8 +27,11 @@ import org.deeplearning4j.nn.conf.MultiLayerConfiguration; import org.deeplearning4j.nn.conf.NeuralNetConfiguration; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.resources.Resources; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.linalg.factory.Nd4j; @@ -39,6 +42,8 @@ import java.nio.file.Files; import java.util.concurrent.CountDownLatch; @Disabled +@NativeTag +@Tag(TagNames.RNG) public class RandomTests extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/MnistFetcherTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/MnistFetcherTest.java index 575ff2ec6..0e98af1e1 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/MnistFetcherTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/MnistFetcherTest.java @@ -23,11 +23,11 @@ import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.datasets.base.MnistFetcher; import org.deeplearning4j.common.resources.DL4JResources; import org.deeplearning4j.datasets.iterator.impl.MnistDataSetIterator; -import org.junit.jupiter.api.AfterAll; -import org.junit.jupiter.api.BeforeAll; -import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.*; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.ops.impl.reduce.longer.MatchCondition; import org.nd4j.linalg.dataset.DataSet; @@ -41,10 +41,13 @@ import java.util.Set; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertFalse; import static org.junit.jupiter.api.Assertions.assertTrue; -import org.junit.jupiter.api.DisplayName; + import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Mnist Fetcher Test") +@NativeTag +@Tag(TagNames.FILE_IO) +@Tag(TagNames.NDARRAY_ETL) class MnistFetcherTest extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/TestDataSets.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/TestDataSets.java index b6978c969..f0647f304 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/TestDataSets.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/TestDataSets.java @@ -23,8 +23,14 @@ package org.deeplearning4j.datasets; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.datasets.fetchers.Cifar10Fetcher; import org.deeplearning4j.datasets.fetchers.TinyImageNetFetcher; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; +@NativeTag +@Tag(TagNames.FILE_IO) +@Tag(TagNames.NDARRAY_ETL) public class TestDataSets extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/datavec/RecordReaderDataSetiteratorTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/datavec/RecordReaderDataSetiteratorTest.java index beab329c3..4153d52cc 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/datavec/RecordReaderDataSetiteratorTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/datavec/RecordReaderDataSetiteratorTest.java @@ -20,8 +20,11 @@ package org.deeplearning4j.datasets.datavec; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4jBackend; import org.nd4j.shade.guava.io.Files; import lombok.extern.slf4j.Slf4j; @@ -76,6 +79,7 @@ import static org.junit.jupiter.api.Assertions.assertThrows; @Slf4j @DisplayName("Record Reader Data Setiterator Test") @Disabled +@NativeTag class RecordReaderDataSetiteratorTest extends BaseDL4JTest { @Override @@ -148,6 +152,7 @@ class RecordReaderDataSetiteratorTest extends BaseDL4JTest { @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") @DisplayName("Test Sequence Record Reader") + @Tag(TagNames.NDARRAY_INDEXING) void testSequenceRecordReader(Nd4jBackend backend) throws Exception { File rootDir = temporaryFolder.toFile(); // need to manually extract diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/datavec/RecordReaderMultiDataSetIteratorTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/datavec/RecordReaderMultiDataSetIteratorTest.java index 2e763a765..db010c2ea 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/datavec/RecordReaderMultiDataSetIteratorTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/datavec/RecordReaderMultiDataSetIteratorTest.java @@ -21,6 +21,8 @@ package org.deeplearning4j.datasets.datavec; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.shade.guava.io.Files; import org.apache.commons.io.FileUtils; import org.apache.commons.io.FilenameUtils; @@ -70,6 +72,7 @@ import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Record Reader Multi Data Set Iterator Test") @Disabled +@Tag(TagNames.FILE_IO) class RecordReaderMultiDataSetIteratorTest extends BaseDL4JTest { @TempDir diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/fetchers/SvhnDataFetcherTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/fetchers/SvhnDataFetcherTest.java index d66ef3d46..56759fc07 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/fetchers/SvhnDataFetcherTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/fetchers/SvhnDataFetcherTest.java @@ -21,6 +21,7 @@ package org.deeplearning4j.datasets.fetchers; import org.deeplearning4j.BaseDL4JTest; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import java.io.File; @@ -28,11 +29,15 @@ import static org.junit.jupiter.api.Assertions.assertTrue; import static org.junit.jupiter.api.Assumptions.assumeTrue; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; /** * @author saudet */ @DisplayName("Svhn Data Fetcher Test") +@Tag(TagNames.FILE_IO) +@NativeTag class SvhnDataFetcherTest extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/AsyncDataSetIteratorTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/AsyncDataSetIteratorTest.java index 3c29cfe10..aa9e6a825 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/AsyncDataSetIteratorTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/AsyncDataSetIteratorTest.java @@ -26,6 +26,7 @@ import org.deeplearning4j.datasets.iterator.tools.VariableTimeseriesGenerator; import org.deeplearning4j.nn.util.TestDataSetConsumer; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.factory.Nd4j; import java.util.ArrayList; @@ -40,6 +41,7 @@ import static org.junit.jupiter.api.Assertions.assertThrows; @Slf4j @DisplayName("Async Data Set Iterator Test") +@NativeTag class AsyncDataSetIteratorTest extends BaseDL4JTest { private ExistingDataSetIterator backIterator; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/AsyncMultiDataSetIteratorTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/AsyncMultiDataSetIteratorTest.java index 523e8fdcd..70a1307a4 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/AsyncMultiDataSetIteratorTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/AsyncMultiDataSetIteratorTest.java @@ -24,6 +24,7 @@ import lombok.val; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.datasets.iterator.tools.VariableMultiTimeseriesGenerator; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.dataset.api.MultiDataSet; import static org.junit.jupiter.api.Assertions.assertEquals; import org.junit.jupiter.api.DisplayName; @@ -84,6 +85,7 @@ import org.junit.jupiter.api.extension.ExtendWith; } */ @DisplayName("Async Multi Data Set Iterator Test") +@NativeTag class AsyncMultiDataSetIteratorTest extends BaseDL4JTest { /** diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/CombinedPreProcessorTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/CombinedPreProcessorTests.java index 36ac3c338..3d4286b53 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/CombinedPreProcessorTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/CombinedPreProcessorTests.java @@ -22,6 +22,7 @@ package org.deeplearning4j.datasets.iterator; import org.deeplearning4j.BaseDL4JTest; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.api.MultiDataSet; import org.nd4j.linalg.dataset.api.MultiDataSetPreProcessor; @@ -30,6 +31,7 @@ import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.assertEquals; +@NativeTag public class CombinedPreProcessorTests extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/DataSetIteratorTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/DataSetIteratorTest.java index 9e8114712..126abac3d 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/DataSetIteratorTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/DataSetIteratorTest.java @@ -41,7 +41,10 @@ import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.optimize.listeners.CollectScoresIterationListener; import org.deeplearning4j.optimize.listeners.ScoreIterationListener; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -57,6 +60,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Data Set Iterator Test") +@Tag(TagNames.FILE_IO) +@NativeTag class DataSetIteratorTest extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/DataSetSplitterTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/DataSetSplitterTests.java index f62037f6d..6816c18aa 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/DataSetSplitterTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/DataSetSplitterTests.java @@ -23,7 +23,10 @@ package org.deeplearning4j.datasets.iterator; import lombok.val; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.datasets.iterator.tools.DataSetGenerator; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.linalg.exception.ND4JIllegalStateException; import org.nd4j.linalg.factory.Nd4j; @@ -34,6 +37,8 @@ import java.util.Random; import static org.junit.jupiter.api.Assertions.*; +@NativeTag +@Tag(TagNames.FILE_IO) public class DataSetSplitterTests extends BaseDL4JTest { @Test public void testSplitter_1() throws Exception { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/DummyBlockDataSetIteratorTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/DummyBlockDataSetIteratorTests.java index 96efd4728..c0db1401c 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/DummyBlockDataSetIteratorTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/DummyBlockDataSetIteratorTests.java @@ -25,7 +25,9 @@ import lombok.val; import lombok.var; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.datasets.iterator.tools.SimpleVariableGenerator; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.dataset.api.DataSet; import java.util.ArrayList; @@ -36,6 +38,7 @@ import static org.junit.jupiter.api.Assertions.assertNotNull; import static org.junit.jupiter.api.Assertions.assertTrue; @Slf4j +@Tag(TagNames.JAVA_ONLY) public class DummyBlockDataSetIteratorTests extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/EarlyTerminationDataSetIteratorTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/EarlyTerminationDataSetIteratorTest.java index 0627eacf2..65fff53a3 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/EarlyTerminationDataSetIteratorTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/EarlyTerminationDataSetIteratorTest.java @@ -23,6 +23,7 @@ import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.datasets.iterator.impl.MnistDataSetIterator; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; @@ -35,6 +36,7 @@ import static org.junit.jupiter.api.Assertions.*; import org.junit.jupiter.api.DisplayName; @DisplayName("Early Termination Data Set Iterator Test") +@NativeTag class EarlyTerminationDataSetIteratorTest extends BaseDL4JTest { int minibatchSize = 10; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/EarlyTerminationMultiDataSetIteratorTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/EarlyTerminationMultiDataSetIteratorTest.java index 929f802ff..8413f57f7 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/EarlyTerminationMultiDataSetIteratorTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/EarlyTerminationMultiDataSetIteratorTest.java @@ -22,7 +22,11 @@ package org.deeplearning4j.datasets.iterator; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.datasets.iterator.impl.MnistDataSetIterator; import org.junit.jupiter.api.DisplayName; +import org.junit.jupiter.api.Tag; +import org.junit.jupiter.api.Tags; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.dataset.adapter.MultiDataSetIteratorAdapter; import org.nd4j.linalg.dataset.api.MultiDataSet; import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator; @@ -34,6 +38,8 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.*; @DisplayName("Early Termination Multi Data Set Iterator Test") +@NativeTag +@Tag(TagNames.FILE_IO) class EarlyTerminationMultiDataSetIteratorTest extends BaseDL4JTest { int minibatchSize = 5; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/JointMultiDataSetIteratorTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/JointMultiDataSetIteratorTests.java index c5871ee60..3a48641d8 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/JointMultiDataSetIteratorTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/JointMultiDataSetIteratorTests.java @@ -24,12 +24,17 @@ import lombok.extern.slf4j.Slf4j; import lombok.val; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.datasets.iterator.tools.DataSetGenerator; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Timeout; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag +@Tag(TagNames.FILE_IO) public class JointMultiDataSetIteratorTests extends BaseDL4JTest { @Test () diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/JointParallelDataSetIteratorTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/JointParallelDataSetIteratorTest.java index de5573c56..0846a0112 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/JointParallelDataSetIteratorTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/JointParallelDataSetIteratorTest.java @@ -24,7 +24,10 @@ import lombok.val; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.datasets.iterator.parallel.JointParallelDataSetIterator; import org.deeplearning4j.datasets.iterator.tools.SimpleVariableGenerator; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.dataset.api.DataSet; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.linalg.dataset.api.iterator.enums.InequalityHandling; @@ -36,6 +39,8 @@ import org.junit.jupiter.api.extension.ExtendWith; @Slf4j @DisplayName("Joint Parallel Data Set Iterator Test") +@NativeTag +@Tag(TagNames.FILE_IO) class JointParallelDataSetIteratorTest extends BaseDL4JTest { /** diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/LoaderIteratorTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/LoaderIteratorTests.java index da97c5cd7..9ccf3ef48 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/LoaderIteratorTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/LoaderIteratorTests.java @@ -23,10 +23,13 @@ package org.deeplearning4j.datasets.iterator; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.datasets.iterator.loader.DataSetLoaderIterator; import org.deeplearning4j.datasets.iterator.loader.MultiDataSetLoaderIterator; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.loader.Loader; import org.nd4j.common.loader.LocalFileSourceFactory; import org.nd4j.common.loader.Source; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.dataset.api.MultiDataSet; @@ -41,11 +44,12 @@ import java.util.Random; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@NativeTag +@Tag(TagNames.FILE_IO) public class LoaderIteratorTests extends BaseDL4JTest { @Test - public void testDSLoaderIter(){ + public void testDSLoaderIter() { for(boolean r : new boolean[]{false, true}) { List l = Arrays.asList("3", "0", "1"); diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/MultiDataSetSplitterTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/MultiDataSetSplitterTests.java index d8e2a39dd..5601b682e 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/MultiDataSetSplitterTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/MultiDataSetSplitterTests.java @@ -24,7 +24,10 @@ import lombok.val; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.datasets.iterator.tools.DataSetGenerator; import org.deeplearning4j.datasets.iterator.tools.MultiDataSetGenerator; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator; import org.nd4j.linalg.exception.ND4JIllegalStateException; @@ -33,7 +36,8 @@ import java.util.List; import java.util.Random; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.FILE_IO) public class MultiDataSetSplitterTests extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/MultipleEpochsIteratorTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/MultipleEpochsIteratorTest.java index 5c586285f..a8baa825a 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/MultipleEpochsIteratorTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/MultipleEpochsIteratorTest.java @@ -26,8 +26,11 @@ import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.datasets.datavec.RecordReaderDataSetIterator; import org.deeplearning4j.nn.util.TestDataSetConsumer; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.linalg.factory.Nd4j; @@ -40,6 +43,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Multiple Epochs Iterator Test") +@NativeTag +@Tag(TagNames.FILE_IO) class MultipleEpochsIteratorTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/RandomDataSetIteratorTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/RandomDataSetIteratorTest.java index 3bd2a9770..e744d3cb4 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/RandomDataSetIteratorTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/RandomDataSetIteratorTest.java @@ -20,7 +20,10 @@ package org.deeplearning4j.datasets.iterator; import org.deeplearning4j.BaseDL4JTest; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.dataset.api.MultiDataSet; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; @@ -33,6 +36,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Random Data Set Iterator Test") +@NativeTag +@Tag(TagNames.FILE_IO) class RandomDataSetIteratorTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/SamplingTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/SamplingTest.java index fc256c51c..0d40b1054 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/SamplingTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/SamplingTest.java @@ -21,7 +21,10 @@ package org.deeplearning4j.datasets.iterator; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.datasets.iterator.impl.MnistDataSetIterator; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import static org.junit.jupiter.api.Assertions.assertEquals; import org.junit.jupiter.api.DisplayName; @@ -31,6 +34,9 @@ import org.junit.jupiter.api.extension.ExtendWith; * @author Adam Gibson */ @DisplayName("Sampling Test") +@NativeTag +@Tag(TagNames.FILE_IO) +@Tag(TagNames.NDARRAY_ETL) class SamplingTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/TestAsyncIterator.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/TestAsyncIterator.java index 57c4c8243..49ab99495 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/TestAsyncIterator.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/TestAsyncIterator.java @@ -23,7 +23,10 @@ package org.deeplearning4j.datasets.iterator; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.datasets.iterator.impl.IrisDataSetIterator; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.dataset.api.DataSetPreProcessor; @@ -36,6 +39,9 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.*; @Disabled +@NativeTag +@Tag(TagNames.FILE_IO) +@Tag(TagNames.NDARRAY_ETL) public class TestAsyncIterator extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/TestEmnistDataSetIterator.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/TestEmnistDataSetIterator.java index 09bdfa9bd..117291658 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/TestEmnistDataSetIterator.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/TestEmnistDataSetIterator.java @@ -24,8 +24,11 @@ import lombok.extern.slf4j.Slf4j; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.datasets.iterator.impl.EmnistDataSetIterator; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -34,6 +37,9 @@ import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag +@Tag(TagNames.FILE_IO) +@Tag(TagNames.NDARRAY_ETL) public class TestEmnistDataSetIterator extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/TestFileIterators.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/TestFileIterators.java index cb3cab8d2..61a40a77a 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/TestFileIterators.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/TestFileIterators.java @@ -25,9 +25,12 @@ import org.deeplearning4j.datasets.iterator.file.FileDataSetIterator; import org.deeplearning4j.datasets.iterator.file.FileMultiDataSetIterator; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.dataset.api.MultiDataSet; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; @@ -42,6 +45,9 @@ import static org.junit.jupiter.api.Assertions.assertArrayEquals; import static org.junit.jupiter.api.Assertions.assertEquals; @Disabled +@NativeTag +@Tag(TagNames.FILE_IO) +@Tag(TagNames.NDARRAY_ETL) public class TestFileIterators extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/tools/DataSetGenerator.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/tools/DataSetGenerator.java index f472701c9..3ab97e477 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/tools/DataSetGenerator.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/datasets/iterator/tools/DataSetGenerator.java @@ -30,7 +30,7 @@ import org.nd4j.linalg.factory.Nd4j; import java.util.List; import java.util.concurrent.atomic.AtomicLong; -public class DataSetGenerator implements DataSetIterator{ +public class DataSetGenerator implements DataSetIterator { protected final int[] shapeFeatures; protected final int[] shapeLabels; protected final long totalBatches; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/earlystopping/TestEarlyStopping.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/earlystopping/TestEarlyStopping.java index c506b78bd..c9f03b902 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/earlystopping/TestEarlyStopping.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/earlystopping/TestEarlyStopping.java @@ -51,9 +51,12 @@ import org.deeplearning4j.optimize.api.BaseTrainingListener; import org.deeplearning4j.optimize.listeners.ScoreIterationListener; import org.deeplearning4j.optimize.solvers.BaseOptimizer; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.evaluation.classification.Evaluation; import org.nd4j.evaluation.classification.ROCBinary; import org.nd4j.evaluation.regression.RegressionEvaluation.Metric; @@ -79,6 +82,11 @@ import java.util.concurrent.TimeUnit; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag +@Tag(TagNames.FILE_IO) +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) public class TestEarlyStopping extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/earlystopping/TestEarlyStoppingCompGraph.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/earlystopping/TestEarlyStoppingCompGraph.java index 1a02ffd7f..b04b3d62b 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/earlystopping/TestEarlyStoppingCompGraph.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/earlystopping/TestEarlyStoppingCompGraph.java @@ -45,7 +45,10 @@ import org.deeplearning4j.nn.conf.layers.variational.VariationalAutoencoder; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.optimize.listeners.ScoreIterationListener; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.evaluation.classification.Evaluation; import org.nd4j.evaluation.regression.RegressionEvaluation.Metric; import org.nd4j.linalg.activations.Activation; @@ -67,6 +70,11 @@ import java.util.concurrent.TimeUnit; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag +@Tag(TagNames.FILE_IO) +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) public class TestEarlyStoppingCompGraph extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/EvalJsonTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/EvalJsonTest.java index fc98ff5bb..f8bcfcb7b 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/EvalJsonTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/EvalJsonTest.java @@ -20,7 +20,10 @@ package org.deeplearning4j.eval; import org.deeplearning4j.BaseDL4JTest; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.evaluation.curves.Histogram; import org.nd4j.evaluation.curves.PrecisionRecallCurve; import org.nd4j.evaluation.curves.RocCurve; @@ -33,6 +36,11 @@ import org.junit.jupiter.api.extension.ExtendWith; import static org.junit.jupiter.api.Assertions.*; @DisplayName("Eval Json Test") +@NativeTag +@Tag(TagNames.EVAL_METRICS) +@Tag(TagNames.JACKSON_SERDE) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) class EvalJsonTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/EvalTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/EvalTest.java index cb74ab199..723fbc18b 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/EvalTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/EvalTest.java @@ -44,7 +44,10 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.optimize.listeners.EvaluativeListener; import org.deeplearning4j.optimize.listeners.ScoreIterationListener; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.ops.random.impl.BernoulliDistribution; @@ -63,6 +66,11 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Eval Test") +@NativeTag +@Tag(TagNames.EVAL_METRICS) +@Tag(TagNames.JACKSON_SERDE) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) class EvalTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/EvaluationToolsTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/EvaluationToolsTests.java index 70271cd95..09fd51696 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/EvaluationToolsTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/EvaluationToolsTests.java @@ -29,7 +29,10 @@ import org.deeplearning4j.nn.conf.layers.DenseLayer; import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.api.DataSet; @@ -40,7 +43,11 @@ import org.nd4j.linalg.lossfunctions.LossFunctions; import java.util.Arrays; import java.util.Random; - +@NativeTag +@Tag(TagNames.EVAL_METRICS) +@Tag(TagNames.JACKSON_SERDE) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) public class EvaluationToolsTests extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/ROCTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/ROCTest.java index adf9aa54e..5fa6da135 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/ROCTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/ROCTest.java @@ -28,7 +28,10 @@ import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.junit.jupiter.api.DisplayName; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.evaluation.curves.RocCurve; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; @@ -44,6 +47,11 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.assertEquals; @DisplayName("Roc Test") +@NativeTag +@Tag(TagNames.EVAL_METRICS) +@Tag(TagNames.JACKSON_SERDE) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) class ROCTest extends BaseDL4JTest { private static Map expTPR; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/RegressionEvalTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/RegressionEvalTest.java index db5e7d7fa..c858ad0b0 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/RegressionEvalTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/eval/RegressionEvalTest.java @@ -28,7 +28,10 @@ import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -43,6 +46,11 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Regression Eval Test") +@NativeTag +@Tag(TagNames.EVAL_METRICS) +@Tag(TagNames.JACKSON_SERDE) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) class RegressionEvalTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/exceptions/TestInvalidConfigurations.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/exceptions/TestInvalidConfigurations.java index 128b62e91..16cacfd5c 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/exceptions/TestInvalidConfigurations.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/exceptions/TestInvalidConfigurations.java @@ -30,7 +30,10 @@ import org.deeplearning4j.nn.conf.inputs.InputType; import org.deeplearning4j.nn.conf.layers.*; import org.deeplearning4j.nn.conf.preprocessor.CnnToFeedForwardPreProcessor; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.factory.Nd4j; @@ -38,6 +41,10 @@ import static org.junit.jupiter.api.Assertions.assertThrows; import static org.junit.jupiter.api.Assertions.fail; @Slf4j +@NativeTag +@Tag(TagNames.EVAL_METRICS) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) public class TestInvalidConfigurations extends BaseDL4JTest { public static MultiLayerNetwork getDensePlusOutput(int nIn, int nOut) { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/exceptions/TestInvalidInput.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/exceptions/TestInvalidInput.java index 7d958355a..52a139167 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/exceptions/TestInvalidInput.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/exceptions/TestInvalidInput.java @@ -29,7 +29,10 @@ import org.deeplearning4j.nn.conf.inputs.InputType; import org.deeplearning4j.nn.conf.layers.*; import org.deeplearning4j.nn.conf.layers.recurrent.SimpleRnn; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -39,6 +42,10 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag +@Tag(TagNames.EVAL_METRICS) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) public class TestInvalidInput extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/exceptions/TestRecordReaders.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/exceptions/TestRecordReaders.java index 7d5e13501..b9521d7d5 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/exceptions/TestRecordReaders.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/exceptions/TestRecordReaders.java @@ -29,7 +29,10 @@ import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.datasets.datavec.RecordReaderDataSetIterator; import org.deeplearning4j.datasets.datavec.SequenceRecordReaderDataSetIterator; import org.deeplearning4j.exception.DL4JException; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.dataset.api.DataSet; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; @@ -39,7 +42,10 @@ import java.util.Collection; import static junit.framework.TestCase.fail; import static org.junit.jupiter.api.Assertions.assertTrue; - +@NativeTag +@Tag(TagNames.EVAL_METRICS) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) public class TestRecordReaders extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/AttentionLayerTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/AttentionLayerTest.java index 4dee21804..f6559040b 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/AttentionLayerTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/AttentionLayerTest.java @@ -33,7 +33,10 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -48,6 +51,10 @@ import org.junit.jupiter.api.DisplayName; @Disabled @DisplayName("Attention Layer Test") +@NativeTag +@Tag(TagNames.EVAL_METRICS) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) class AttentionLayerTest extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/BNGradientCheckTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/BNGradientCheckTest.java index f728f3f29..1eba038b3 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/BNGradientCheckTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/BNGradientCheckTest.java @@ -33,7 +33,10 @@ import org.deeplearning4j.nn.conf.layers.*; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -58,6 +61,10 @@ import org.junit.jupiter.api.extension.ExtendWith; /** */ @DisplayName("Bn Gradient Check Test") +@NativeTag +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) class BNGradientCheckTest extends BaseDL4JTest { static { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/CNN1DGradientCheckTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/CNN1DGradientCheckTest.java index f85a426d2..917f3aa99 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/CNN1DGradientCheckTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/CNN1DGradientCheckTest.java @@ -34,7 +34,10 @@ import org.deeplearning4j.nn.modelimport.keras.KerasModelImport; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.util.Convolution1DUtils; import org.deeplearning4j.util.ConvolutionUtils; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -51,6 +54,10 @@ import org.junit.jupiter.api.extension.ExtendWith; @Slf4j @DisplayName("Cnn 1 D Gradient Check Test") +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag class CNN1DGradientCheckTest extends BaseDL4JTest { private static final boolean PRINT_RESULTS = true; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/CNN3DGradientCheckTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/CNN3DGradientCheckTest.java index 122f3ff86..b6c1cd933 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/CNN3DGradientCheckTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/CNN3DGradientCheckTest.java @@ -32,7 +32,10 @@ import org.deeplearning4j.nn.conf.layers.convolutional.Cropping3D; import org.deeplearning4j.nn.conf.preprocessor.Cnn3DToFeedForwardPreProcessor; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataBuffer; import org.nd4j.linalg.api.buffer.DataType; @@ -48,6 +51,10 @@ import org.junit.jupiter.api.extension.ExtendWith; @Log @DisplayName("Cnn 3 D Gradient Check Test") +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag class CNN3DGradientCheckTest extends BaseDL4JTest { private static final boolean PRINT_RESULTS = true; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/CNNGradientCheckTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/CNNGradientCheckTest.java index c3882065d..e9917893c 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/CNNGradientCheckTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/CNNGradientCheckTest.java @@ -36,11 +36,14 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; @@ -64,6 +67,10 @@ import org.junit.jupiter.api.extension.ExtendWith; import org.nd4j.shade.guava.collect.Lists; @DisplayName("Cnn Gradient Check Test") +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag class CNNGradientCheckTest extends BaseDL4JTest { private static final boolean PRINT_RESULTS = true; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/CapsnetGradientCheckTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/CapsnetGradientCheckTest.java index 0c42f45a9..2f3e0b05b 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/CapsnetGradientCheckTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/CapsnetGradientCheckTest.java @@ -34,7 +34,10 @@ import org.deeplearning4j.nn.conf.layers.PrimaryCapsules; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInitDistribution; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.impl.ActivationSoftmax; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -47,6 +50,10 @@ import org.junit.jupiter.api.extension.ExtendWith; @Disabled @DisplayName("Capsnet Gradient Check Test") +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag class CapsnetGradientCheckTest extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/DropoutGradientCheck.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/DropoutGradientCheck.java index 7ca1064b3..d3dc18df6 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/DropoutGradientCheck.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/DropoutGradientCheck.java @@ -35,7 +35,10 @@ import org.deeplearning4j.nn.conf.layers.DenseLayer; import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -47,6 +50,10 @@ import org.nd4j.linalg.lossfunctions.LossFunctions.LossFunction; import static org.junit.jupiter.api.Assertions.assertTrue; @Slf4j +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag public class DropoutGradientCheck extends BaseDL4JTest { private static final boolean PRINT_RESULTS = true; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/GlobalPoolingGradientCheckTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/GlobalPoolingGradientCheckTests.java index 214cb895e..54936aa17 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/GlobalPoolingGradientCheckTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/GlobalPoolingGradientCheckTests.java @@ -31,7 +31,10 @@ import org.deeplearning4j.nn.conf.inputs.InputType; import org.deeplearning4j.nn.conf.layers.*; import org.deeplearning4j.nn.conf.layers.recurrent.SimpleRnn; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -42,7 +45,10 @@ import org.nd4j.linalg.lossfunctions.LossFunctions; import java.util.Random; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag public class GlobalPoolingGradientCheckTests extends BaseDL4JTest { static { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/GradientCheckTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/GradientCheckTests.java index 37667dc9f..e5e546f2b 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/GradientCheckTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/GradientCheckTests.java @@ -37,7 +37,10 @@ import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -58,6 +61,10 @@ import static org.deeplearning4j.gradientcheck.GradientCheckUtil.checkGradients; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag public class GradientCheckTests extends BaseDL4JTest { private static final boolean PRINT_RESULTS = true; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/GradientCheckTestsComputationGraph.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/GradientCheckTestsComputationGraph.java index d8bd9ee0d..b5f3b8390 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/GradientCheckTestsComputationGraph.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/GradientCheckTestsComputationGraph.java @@ -42,7 +42,10 @@ import org.deeplearning4j.nn.conf.preprocessor.RnnToFeedForwardPreProcessor; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -59,6 +62,10 @@ import java.util.Random; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) public class GradientCheckTestsComputationGraph extends BaseDL4JTest { public static final boolean PRINT_RESULTS = true; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/GradientCheckTestsMasking.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/GradientCheckTestsMasking.java index 1e8faae70..0f18b335b 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/GradientCheckTestsMasking.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/GradientCheckTestsMasking.java @@ -33,7 +33,10 @@ import org.deeplearning4j.nn.conf.layers.*; import org.deeplearning4j.nn.conf.layers.recurrent.SimpleRnn; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -51,6 +54,10 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; import static org.nd4j.linalg.indexing.NDArrayIndex.*; +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag public class GradientCheckTestsMasking extends BaseDL4JTest { private static final boolean PRINT_RESULTS = true; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/LRNGradientCheckTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/LRNGradientCheckTests.java index 3ab2efd59..3721c40fc 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/LRNGradientCheckTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/LRNGradientCheckTests.java @@ -30,7 +30,10 @@ import org.deeplearning4j.nn.conf.layers.ConvolutionLayer; import org.deeplearning4j.nn.conf.layers.LocalResponseNormalization; import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -42,6 +45,10 @@ import java.util.Random; import static org.junit.jupiter.api.Assertions.assertTrue; +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag public class LRNGradientCheckTests extends BaseDL4JTest { private static final boolean PRINT_RESULTS = true; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/LSTMGradientCheckTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/LSTMGradientCheckTests.java index 00fef6150..708d7a6e9 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/LSTMGradientCheckTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/LSTMGradientCheckTests.java @@ -31,7 +31,10 @@ import org.deeplearning4j.nn.conf.inputs.InputType; import org.deeplearning4j.nn.conf.layers.*; import org.deeplearning4j.nn.conf.preprocessor.RnnToCnnPreProcessor; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -43,6 +46,10 @@ import java.util.Random; import static org.junit.jupiter.api.Assertions.assertTrue; +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag public class LSTMGradientCheckTests extends BaseDL4JTest { private static final boolean PRINT_RESULTS = true; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/LossFunctionGradientCheck.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/LossFunctionGradientCheck.java index e09197d69..a411243a2 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/LossFunctionGradientCheck.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/LossFunctionGradientCheck.java @@ -34,7 +34,10 @@ import org.deeplearning4j.nn.conf.layers.DenseLayer; import org.deeplearning4j.nn.conf.layers.LossLayer; import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.activations.impl.ActivationIdentity; import org.nd4j.linalg.api.buffer.DataType; @@ -62,6 +65,11 @@ import static org.nd4j.linalg.indexing.NDArrayIndex.all; import static org.nd4j.linalg.indexing.NDArrayIndex.point; @Slf4j +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag +@Tag(TagNames.LOSS_FUNCTIONS) public class LossFunctionGradientCheck extends BaseDL4JTest { static { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/NoBiasGradientCheckTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/NoBiasGradientCheckTests.java index c9e65579b..279756e9d 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/NoBiasGradientCheckTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/NoBiasGradientCheckTests.java @@ -28,7 +28,10 @@ import org.deeplearning4j.nn.conf.distribution.NormalDistribution; import org.deeplearning4j.nn.conf.inputs.InputType; import org.deeplearning4j.nn.conf.layers.*; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -40,6 +43,10 @@ import org.nd4j.linalg.lossfunctions.LossFunctions.LossFunction; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag public class NoBiasGradientCheckTests extends BaseDL4JTest { private static final boolean PRINT_RESULTS = true; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/OutputLayerGradientChecks.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/OutputLayerGradientChecks.java index 12a1340e2..3253d5802 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/OutputLayerGradientChecks.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/OutputLayerGradientChecks.java @@ -28,7 +28,10 @@ import org.deeplearning4j.nn.conf.NeuralNetConfiguration; import org.deeplearning4j.nn.conf.distribution.NormalDistribution; import org.deeplearning4j.nn.conf.layers.*; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -44,6 +47,11 @@ import java.util.Random; import static org.junit.jupiter.api.Assertions.assertTrue; + +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag public class OutputLayerGradientChecks extends BaseDL4JTest { private static final boolean PRINT_RESULTS = true; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/RnnGradientChecks.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/RnnGradientChecks.java index bcfa02f30..69ae75016 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/RnnGradientChecks.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/RnnGradientChecks.java @@ -36,7 +36,10 @@ import org.deeplearning4j.nn.conf.layers.recurrent.TimeDistributed; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -48,6 +51,10 @@ import java.util.Random; import static org.junit.jupiter.api.Assertions.assertTrue; +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag public class RnnGradientChecks extends BaseDL4JTest { private static final boolean PRINT_RESULTS = true; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/UtilLayerGradientChecks.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/UtilLayerGradientChecks.java index 25d594d9a..014029830 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/UtilLayerGradientChecks.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/UtilLayerGradientChecks.java @@ -35,7 +35,10 @@ import org.deeplearning4j.nn.conf.layers.util.MaskLayer; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -50,6 +53,11 @@ import java.util.Set; import static org.junit.jupiter.api.Assertions.assertTrue; +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag + public class UtilLayerGradientChecks extends BaseDL4JTest { static { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/VaeGradientCheckTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/VaeGradientCheckTests.java index ec9fdab25..4bfe39170 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/VaeGradientCheckTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/VaeGradientCheckTests.java @@ -29,7 +29,10 @@ import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.conf.layers.variational.*; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.activations.impl.ActivationTanH; import org.nd4j.linalg.api.buffer.DataType; @@ -45,6 +48,11 @@ import java.util.Arrays; import static org.junit.jupiter.api.Assertions.assertTrue; +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag + public class VaeGradientCheckTests extends BaseDL4JTest { private static final boolean PRINT_RESULTS = false; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/YoloGradientCheckTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/YoloGradientCheckTests.java index 61874113b..68de9caf0 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/YoloGradientCheckTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/gradientcheck/YoloGradientCheckTests.java @@ -36,6 +36,7 @@ import org.deeplearning4j.nn.conf.layers.SubsamplingLayer; import org.deeplearning4j.nn.conf.layers.objdetect.Yolo2OutputLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; @@ -43,6 +44,8 @@ import org.junit.jupiter.api.io.TempDir; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; @@ -67,6 +70,11 @@ import java.util.stream.Stream; import static org.junit.jupiter.api.Assertions.assertArrayEquals; import static org.junit.jupiter.api.Assertions.assertTrue; +@Tag(TagNames.NDARRAY_ETL) +@Tag(TagNames.TRAINING) +@Tag(TagNames.DL4J_OLD_API) +@Tag(TagNames.FILE_IO) +@NativeTag public class YoloGradientCheckTests extends BaseDL4JTest { static { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/adapters/ArgmaxAdapterTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/adapters/ArgmaxAdapterTest.java index f27969ee7..f0c0d819c 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/adapters/ArgmaxAdapterTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/adapters/ArgmaxAdapterTest.java @@ -21,13 +21,18 @@ package org.deeplearning4j.nn.adapters; import lombok.val; import org.deeplearning4j.BaseDL4JTest; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.*; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Argmax Adapter Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class ArgmaxAdapterTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/adapters/Regression2dAdapterTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/adapters/Regression2dAdapterTest.java index f92a0ce60..06b1fcae6 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/adapters/Regression2dAdapterTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/adapters/Regression2dAdapterTest.java @@ -21,7 +21,10 @@ package org.deeplearning4j.nn.adapters; import lombok.val; import org.deeplearning4j.BaseDL4JTest; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.common.util.ArrayUtil; import static org.junit.jupiter.api.Assertions.*; @@ -31,6 +34,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Regression 2 d Adapter Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class Regression2dAdapterTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/ComputationGraphConfigurationTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/ComputationGraphConfigurationTest.java index 2f142f1a3..12de3949e 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/ComputationGraphConfigurationTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/ComputationGraphConfigurationTest.java @@ -41,7 +41,10 @@ import org.deeplearning4j.nn.conf.misc.TestGraphVertex; import org.deeplearning4j.nn.conf.preprocessor.CnnToFeedForwardPreProcessor; import org.deeplearning4j.nn.conf.preprocessor.FeedForwardToCnnPreProcessor; import org.deeplearning4j.nn.graph.ComputationGraph; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -53,6 +56,8 @@ import org.junit.jupiter.api.extension.ExtendWith; @Slf4j @DisplayName("Computation Graph Configuration Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class ComputationGraphConfigurationTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/JsonTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/JsonTest.java index 98bafa5fa..991a16d19 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/JsonTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/JsonTest.java @@ -22,7 +22,10 @@ package org.deeplearning4j.nn.conf; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.nn.conf.layers.DenseLayer; import org.deeplearning4j.nn.conf.layers.LossLayer; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.lossfunctions.ILossFunction; import org.nd4j.linalg.lossfunctions.impl.*; @@ -31,6 +34,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Json Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class JsonTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/MultiLayerNeuralNetConfigurationTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/MultiLayerNeuralNetConfigurationTest.java index 09a274b63..c3f285f4d 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/MultiLayerNeuralNetConfigurationTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/MultiLayerNeuralNetConfigurationTest.java @@ -33,8 +33,11 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.optimize.listeners.ScoreIterationListener; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.linalg.learning.config.Adam; @@ -50,6 +53,8 @@ import org.junit.jupiter.api.extension.ExtendWith; @Slf4j @DisplayName("Multi Layer Neural Net Configuration Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class MultiLayerNeuralNetConfigurationTest extends BaseDL4JTest { @TempDir diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/MultiNeuralNetConfLayerBuilderTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/MultiNeuralNetConfLayerBuilderTest.java index 63983a424..23342e18b 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/MultiNeuralNetConfLayerBuilderTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/MultiNeuralNetConfLayerBuilderTest.java @@ -28,7 +28,10 @@ import org.deeplearning4j.nn.conf.layers.SubsamplingLayer.PoolingType; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.params.DefaultParamInitializer; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.convolution.Convolution; @@ -44,6 +47,8 @@ import org.junit.jupiter.api.extension.ExtendWith; * @author Jeffrey Tang. */ @DisplayName("Multi Neural Net Conf Layer Builder Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class MultiNeuralNetConfLayerBuilderTest extends BaseDL4JTest { int numIn = 10; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/NeuralNetConfigurationTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/NeuralNetConfigurationTest.java index 6e13497ff..2f799679b 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/NeuralNetConfigurationTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/NeuralNetConfigurationTest.java @@ -36,7 +36,10 @@ import org.deeplearning4j.nn.weights.*; import org.deeplearning4j.optimize.api.ConvexOptimizer; import org.deeplearning4j.optimize.solvers.StochasticGradientDescent; import org.deeplearning4j.optimize.stepfunctions.NegativeDefaultStepFunction; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.ops.impl.scalar.LeakyReLU; @@ -53,6 +56,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Neural Net Configuration Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class NeuralNetConfigurationTest extends BaseDL4JTest { final DataSet trainingSet = createData(); diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/constraints/TestConstraints.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/constraints/TestConstraints.java index fda02a451..470dbfaa1 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/constraints/TestConstraints.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/constraints/TestConstraints.java @@ -41,7 +41,10 @@ import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -54,6 +57,8 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestConstraints extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/dropout/TestDropout.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/dropout/TestDropout.java index cd63d4c5e..ef3ff355f 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/dropout/TestDropout.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/dropout/TestDropout.java @@ -34,7 +34,10 @@ import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.ops.impl.reduce.longer.MatchCondition; import org.nd4j.linalg.dataset.DataSet; @@ -55,6 +58,8 @@ import static org.junit.jupiter.api.Assertions.assertTrue; import static org.nd4j.linalg.indexing.NDArrayIndex.all; import static org.nd4j.linalg.indexing.NDArrayIndex.point; +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestDropout extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/graph/ElementWiseVertexTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/graph/ElementWiseVertexTest.java index 73c2385d1..550fb0d15 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/graph/ElementWiseVertexTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/graph/ElementWiseVertexTest.java @@ -30,7 +30,10 @@ import org.deeplearning4j.nn.gradient.Gradient; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.weights.WeightInit; import org.junit.jupiter.api.Assertions; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.activations.impl.ActivationSigmoid; import org.nd4j.linalg.activations.impl.ActivationTanH; @@ -48,6 +51,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Element Wise Vertex Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class ElementWiseVertexTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/graph/ShiftVertexTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/graph/ShiftVertexTest.java index 3db72291b..6631c426d 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/graph/ShiftVertexTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/graph/ShiftVertexTest.java @@ -30,7 +30,10 @@ import org.deeplearning4j.nn.gradient.Gradient; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.weights.WeightInit; import org.junit.jupiter.api.Assertions; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.activations.BaseActivationFunction; import org.nd4j.linalg.activations.impl.ActivationSigmoid; @@ -47,6 +50,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Shift Vertex Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class ShiftVertexTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/layers/LayerBuilderTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/layers/LayerBuilderTest.java index 807a3861a..f9568b9d7 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/layers/LayerBuilderTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/layers/LayerBuilderTest.java @@ -24,7 +24,10 @@ import org.deeplearning4j.nn.conf.GradientNormalization; import org.deeplearning4j.nn.conf.NeuralNetConfiguration; import org.deeplearning4j.nn.conf.dropout.Dropout; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.activations.IActivation; import org.nd4j.linalg.activations.impl.ActivationSoftmax; @@ -42,6 +45,8 @@ import org.junit.jupiter.api.extension.ExtendWith; * @author Jeffrey Tang. */ @DisplayName("Layer Builder Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class LayerBuilderTest extends BaseDL4JTest { final double DELTA = 1e-15; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/layers/LayerConfigTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/layers/LayerConfigTest.java index 71d867701..5da010a68 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/layers/LayerConfigTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/layers/LayerConfigTest.java @@ -29,7 +29,10 @@ import org.deeplearning4j.nn.conf.distribution.UniformDistribution; import org.deeplearning4j.nn.conf.dropout.Dropout; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInitDistribution; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.learning.config.AdaDelta; import org.nd4j.linalg.learning.config.Adam; @@ -151,6 +154,8 @@ import org.junit.jupiter.api.extension.ExtendWith; */ @DisplayName("Layer Config Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class LayerConfigTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/layers/LayerConfigValidationTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/layers/LayerConfigValidationTest.java index dc0837911..f42a7ca2f 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/layers/LayerConfigValidationTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/layers/LayerConfigValidationTest.java @@ -35,7 +35,10 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.nn.weights.WeightInitDistribution; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.learning.config.Adam; import org.nd4j.linalg.learning.config.Nesterovs; @@ -52,6 +55,8 @@ import org.junit.jupiter.api.extension.ExtendWith; import static org.junit.jupiter.api.Assertions.assertThrows; @DisplayName("Layer Config Validation Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class LayerConfigValidationTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/preprocessor/CNNProcessorTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/preprocessor/CNNProcessorTest.java index a79583eaa..9e083f7d9 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/preprocessor/CNNProcessorTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/preprocessor/CNNProcessorTest.java @@ -27,7 +27,10 @@ import org.deeplearning4j.nn.conf.layers.ConvolutionLayer; import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -42,6 +45,8 @@ import org.junit.jupiter.api.extension.ExtendWith; /** */ @DisplayName("Cnn Processor Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class CNNProcessorTest extends BaseDL4JTest { private static int rows = 28; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/preprocessor/TestPreProcessors.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/preprocessor/TestPreProcessors.java index 28d9558cd..99f0417e3 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/preprocessor/TestPreProcessors.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/conf/preprocessor/TestPreProcessors.java @@ -34,7 +34,10 @@ import org.deeplearning4j.nn.layers.convolution.ConvolutionLayer; import org.deeplearning4j.nn.layers.feedforward.dense.DenseLayer; import org.deeplearning4j.nn.modelimport.keras.preprocessors.ReshapePreprocessor; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -45,6 +48,8 @@ import java.util.Arrays; import static org.junit.jupiter.api.Assertions.*; +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestPreProcessors extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/dtypes/DTypeTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/dtypes/DTypeTests.java index 400f8f199..0752670b9 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/dtypes/DTypeTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/dtypes/DTypeTests.java @@ -144,7 +144,10 @@ import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.nn.weights.WeightInitDistribution; import org.junit.AfterClass; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.activations.impl.ActivationSoftmax; import org.nd4j.linalg.api.buffer.DataType; @@ -171,6 +174,8 @@ import java.util.Set; @Slf4j @Disabled +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class DTypeTests extends BaseDL4JTest { protected static Set> seenLayers = new HashSet<>(); diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/ComputationGraphTestRNN.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/ComputationGraphTestRNN.java index 2bddca70a..899a18993 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/ComputationGraphTestRNN.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/ComputationGraphTestRNN.java @@ -39,7 +39,10 @@ import org.deeplearning4j.nn.conf.preprocessor.RnnToFeedForwardPreProcessor; import org.deeplearning4j.nn.gradient.Gradient; import org.deeplearning4j.nn.layers.recurrent.BaseRecurrentLayer; import org.deeplearning4j.nn.layers.recurrent.GravesLSTM; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -58,6 +61,8 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class ComputationGraphTestRNN extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestCompGraphCNN.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestCompGraphCNN.java index bd5a1ccfa..a9aee733b 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestCompGraphCNN.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestCompGraphCNN.java @@ -32,7 +32,10 @@ import org.deeplearning4j.nn.conf.layers.*; import org.deeplearning4j.nn.weights.WeightInit; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -48,6 +51,8 @@ import static org.junit.jupiter.api.Assertions.*; //@Disabled +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestCompGraphCNN extends BaseDL4JTest { protected ComputationGraphConfiguration conf; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestCompGraphUnsupervised.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestCompGraphUnsupervised.java index a17979bf2..51cb46f5c 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestCompGraphUnsupervised.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestCompGraphUnsupervised.java @@ -32,7 +32,10 @@ import org.deeplearning4j.nn.conf.layers.variational.GaussianReconstructionDistr import org.deeplearning4j.nn.conf.layers.variational.VariationalAutoencoder; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -49,6 +52,8 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotEquals; +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestCompGraphUnsupervised extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestComputationGraphNetwork.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestComputationGraphNetwork.java index 20cd7766a..fbf5dadc7 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestComputationGraphNetwork.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestComputationGraphNetwork.java @@ -63,6 +63,8 @@ import org.deeplearning4j.optimize.listeners.ScoreIterationListener; import org.deeplearning4j.util.ModelSerializer; import org.junit.jupiter.api.*; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.activations.impl.ActivationIdentity; import org.nd4j.linalg.api.buffer.DataType; @@ -93,6 +95,8 @@ import static org.deeplearning4j.nn.conf.layers.recurrent.Bidirectional.Mode.CON import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestComputationGraphNetwork extends BaseDL4JTest { private static ComputationGraphConfiguration getIrisGraphConfiguration() { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestSetGetParameters.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestSetGetParameters.java index ec5c47894..6ad77de04 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestSetGetParameters.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestSetGetParameters.java @@ -24,7 +24,10 @@ import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.nn.conf.ComputationGraphConfiguration; import org.deeplearning4j.nn.conf.NeuralNetConfiguration; import org.deeplearning4j.nn.conf.layers.*; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -33,7 +36,8 @@ import org.nd4j.linalg.lossfunctions.LossFunctions.LossFunction; import java.util.Map; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestSetGetParameters extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestVariableLengthTSCG.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestVariableLengthTSCG.java index b11d783dc..4c02886b2 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestVariableLengthTSCG.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/TestVariableLengthTSCG.java @@ -35,7 +35,10 @@ import org.deeplearning4j.nn.conf.preprocessor.RnnToFeedForwardPreProcessor; import org.deeplearning4j.nn.gradient.Gradient; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -50,7 +53,8 @@ import java.util.Random; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotEquals; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestVariableLengthTSCG extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/graphnodes/TestGraphNodes.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/graphnodes/TestGraphNodes.java index de4010554..12653f6ea 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/graphnodes/TestGraphNodes.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/graph/graphnodes/TestGraphNodes.java @@ -40,7 +40,10 @@ import org.deeplearning4j.nn.graph.vertex.GraphVertex; import org.deeplearning4j.nn.graph.vertex.impl.*; import org.deeplearning4j.nn.transferlearning.TransferLearning; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.api.MultiDataSet; @@ -57,6 +60,8 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.*; +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestGraphNodes extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/ActivationLayerTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/ActivationLayerTest.java index bf69c638b..e7d9e0417 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/ActivationLayerTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/ActivationLayerTest.java @@ -34,7 +34,10 @@ import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.activations.impl.ActivationELU; import org.nd4j.linalg.activations.impl.ActivationRationalTanh; @@ -53,6 +56,9 @@ import org.junit.jupiter.api.extension.ExtendWith; /** */ @DisplayName("Activation Layer Test") +@NativeTag +@Tag(TagNames.CUSTOM_FUNCTIONALITY) +@Tag(TagNames.DL4J_OLD_API) class ActivationLayerTest extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/AutoEncoderTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/AutoEncoderTest.java index 05f40cf77..645945344 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/AutoEncoderTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/AutoEncoderTest.java @@ -30,7 +30,10 @@ import org.deeplearning4j.nn.conf.layers.DenseLayer; import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.api.MultiDataSet; import org.nd4j.linalg.factory.Nd4j; @@ -39,6 +42,9 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Auto Encoder Test") +@NativeTag +@Tag(TagNames.CUSTOM_FUNCTIONALITY) +@Tag(TagNames.DL4J_OLD_API) class AutoEncoderTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/BaseLayerTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/BaseLayerTest.java index 9e3bf4df1..ef2ddac52 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/BaseLayerTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/BaseLayerTest.java @@ -29,7 +29,10 @@ import org.deeplearning4j.nn.conf.layers.DenseLayer; import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -41,6 +44,9 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Base Layer Test") +@NativeTag +@Tag(TagNames.CUSTOM_FUNCTIONALITY) +@Tag(TagNames.DL4J_OLD_API) class BaseLayerTest extends BaseDL4JTest { protected INDArray weight = Nd4j.create(new double[] { 0.10, -0.20, -0.15, 0.05 }, new int[] { 2, 2 }); diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/CenterLossOutputLayerTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/CenterLossOutputLayerTest.java index 778bc332d..f58ef892e 100755 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/CenterLossOutputLayerTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/CenterLossOutputLayerTest.java @@ -34,7 +34,10 @@ import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.optimize.listeners.ScoreIterationListener; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; @@ -49,6 +52,9 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Center Loss Output Layer Test") +@NativeTag +@Tag(TagNames.CUSTOM_FUNCTIONALITY) +@Tag(TagNames.DL4J_OLD_API) class CenterLossOutputLayerTest extends BaseDL4JTest { private ComputationGraph getGraph(int numLabels, double lambda) { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/DropoutLayerTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/DropoutLayerTest.java index 679b0ac47..14ae31f6a 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/DropoutLayerTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/DropoutLayerTest.java @@ -35,7 +35,10 @@ import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.conf.preprocessor.CnnToFeedForwardPreProcessor; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -54,6 +57,9 @@ import org.junit.jupiter.api.extension.ExtendWith; /** */ @DisplayName("Dropout Layer Test") +@NativeTag +@Tag(TagNames.CUSTOM_FUNCTIONALITY) +@Tag(TagNames.DL4J_OLD_API) class DropoutLayerTest extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/FrozenLayerTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/FrozenLayerTest.java index 09d467f8d..5ba47d148 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/FrozenLayerTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/FrozenLayerTest.java @@ -30,7 +30,10 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.transferlearning.FineTuneConfiguration; import org.deeplearning4j.nn.transferlearning.TransferLearning; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -44,6 +47,9 @@ import org.junit.jupiter.api.extension.ExtendWith; @Slf4j @DisplayName("Frozen Layer Test") +@NativeTag +@Tag(TagNames.CUSTOM_FUNCTIONALITY) +@Tag(TagNames.DL4J_OLD_API) class FrozenLayerTest extends BaseDL4JTest { /* diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/FrozenLayerWithBackpropTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/FrozenLayerWithBackpropTest.java index 925645781..093c5da91 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/FrozenLayerWithBackpropTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/FrozenLayerWithBackpropTest.java @@ -33,7 +33,10 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.transferlearning.FineTuneConfiguration; import org.deeplearning4j.nn.transferlearning.TransferLearning; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -49,6 +52,9 @@ import org.junit.jupiter.api.extension.ExtendWith; @Slf4j @DisplayName("Frozen Layer With Backprop Test") +@NativeTag +@Tag(TagNames.CUSTOM_FUNCTIONALITY) +@Tag(TagNames.DL4J_OLD_API) class FrozenLayerWithBackpropTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/OutputLayerTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/OutputLayerTest.java index 9827c350e..5d3c9e7c8 100755 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/OutputLayerTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/OutputLayerTest.java @@ -35,7 +35,10 @@ import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; import org.deeplearning4j.optimize.api.TrainingListener; import org.deeplearning4j.optimize.listeners.ScoreIterationListener; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -53,6 +56,9 @@ import org.junit.jupiter.api.extension.ExtendWith; @Slf4j @DisplayName("Output Layer Test") +@NativeTag +@Tag(TagNames.CUSTOM_FUNCTIONALITY) +@Tag(TagNames.DL4J_OLD_API) class OutputLayerTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/RepeatVectorTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/RepeatVectorTest.java index fddc7c150..7da5c0ec3 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/RepeatVectorTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/RepeatVectorTest.java @@ -25,7 +25,10 @@ import org.deeplearning4j.nn.conf.NeuralNetConfiguration; import org.deeplearning4j.nn.conf.layers.misc.RepeatVector; import org.deeplearning4j.nn.gradient.Gradient; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -37,6 +40,9 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Repeat Vector Test") +@NativeTag +@Tag(TagNames.CUSTOM_FUNCTIONALITY) +@Tag(TagNames.DL4J_OLD_API) class RepeatVectorTest extends BaseDL4JTest { private int REPEAT = 4; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/SeedTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/SeedTest.java index c30f867d2..acc1dfe10 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/SeedTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/SeedTest.java @@ -24,7 +24,10 @@ import org.deeplearning4j.datasets.iterator.impl.IrisDataSetIterator; import org.deeplearning4j.nn.api.Layer; import org.deeplearning4j.nn.conf.NeuralNetConfiguration; import org.deeplearning4j.nn.conf.layers.AutoEncoder; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -38,6 +41,10 @@ import org.junit.jupiter.api.extension.ExtendWith; /** */ @DisplayName("Seed Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) +@Tag(TagNames.FILE_IO) +@Tag(TagNames.RNG) class SeedTest extends BaseDL4JTest { private DataSetIterator irisIter = new IrisDataSetIterator(50, 50); diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/TestDropout.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/TestDropout.java index 8e912bef8..2f9a0ce88 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/TestDropout.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/TestDropout.java @@ -20,31 +20,32 @@ package org.deeplearning4j.nn.layers; -import lombok.val; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.nn.conf.MultiLayerConfiguration; import org.deeplearning4j.nn.conf.NeuralNetConfiguration; -import org.deeplearning4j.nn.conf.distribution.UniformDistribution; -import org.deeplearning4j.nn.conf.layers.DenseLayer; import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; -import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.api.iter.NdIndexIterator; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.linalg.learning.config.Sgd; import org.nd4j.linalg.lossfunctions.LossFunctions; -import java.lang.reflect.Field; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.fail; +@NativeTag +@Tag(TagNames.DL4J_OLD_API) +@Tag(TagNames.FILE_IO) +@Tag(TagNames.RNG) public class TestDropout extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/capsule/CapsNetMNISTTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/capsule/CapsNetMNISTTest.java index 5a5d08b8f..647bde5c2 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/capsule/CapsNetMNISTTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/capsule/CapsNetMNISTTest.java @@ -34,7 +34,10 @@ import org.deeplearning4j.nn.conf.layers.LossLayer; import org.deeplearning4j.nn.conf.layers.PrimaryCapsules; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.evaluation.classification.Evaluation; import org.nd4j.linalg.activations.impl.ActivationSoftmax; import org.nd4j.linalg.api.buffer.DataType; @@ -45,6 +48,8 @@ import org.junit.jupiter.api.extension.ExtendWith; @Disabled("AB - ignored due to excessive runtime. Keep for manual debugging when required") @DisplayName("Caps Net MNIST Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class CapsNetMNISTTest extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/capsule/CapsuleLayerTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/capsule/CapsuleLayerTest.java index 9a131f49a..e7f9f369c 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/capsule/CapsuleLayerTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/capsule/CapsuleLayerTest.java @@ -29,7 +29,10 @@ import org.deeplearning4j.nn.conf.NeuralNetConfiguration; import org.deeplearning4j.nn.conf.inputs.InputType; import org.deeplearning4j.nn.conf.layers.CapsuleLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -37,6 +40,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Capsule Layer Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class CapsuleLayerTest extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/capsule/CapsuleStrengthLayerTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/capsule/CapsuleStrengthLayerTest.java index e9276da71..a5b59200d 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/capsule/CapsuleStrengthLayerTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/capsule/CapsuleStrengthLayerTest.java @@ -27,7 +27,10 @@ import org.deeplearning4j.nn.conf.NeuralNetConfiguration; import org.deeplearning4j.nn.conf.inputs.InputType; import org.deeplearning4j.nn.conf.layers.CapsuleStrengthLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -35,6 +38,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Capsule Strength Layer Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class CapsuleStrengthLayerTest extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/capsule/PrimaryCapsulesTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/capsule/PrimaryCapsulesTest.java index 0a4e03add..78d1b1fc0 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/capsule/PrimaryCapsulesTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/capsule/PrimaryCapsulesTest.java @@ -29,7 +29,10 @@ import org.deeplearning4j.nn.conf.NeuralNetConfiguration; import org.deeplearning4j.nn.conf.inputs.InputType; import org.deeplearning4j.nn.conf.layers.PrimaryCapsules; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -37,6 +40,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Primary Capsules Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class PrimaryCapsulesTest extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/ConvDataFormatTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/ConvDataFormatTests.java index 5b6e4b77f..47783194e 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/ConvDataFormatTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/ConvDataFormatTests.java @@ -38,11 +38,14 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.workspace.ArrayType; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; import org.deeplearning4j.util.ConvolutionUtils; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; @@ -59,7 +62,8 @@ import java.util.stream.Stream; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class ConvDataFormatTests extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/Convolution3DTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/Convolution3DTest.java index 31c0e8d5d..fd9574445 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/Convolution3DTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/Convolution3DTest.java @@ -27,7 +27,10 @@ import org.deeplearning4j.nn.conf.GradientNormalization; import org.deeplearning4j.nn.conf.NeuralNetConfiguration; import org.deeplearning4j.nn.conf.layers.Convolution3D; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; @@ -42,6 +45,8 @@ import org.junit.jupiter.api.extension.ExtendWith; * @author Max Pumperla */ @DisplayName("Convolution 3 D Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class Convolution3DTest extends BaseDL4JTest { private int nExamples = 1; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/ConvolutionLayerSetupTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/ConvolutionLayerSetupTest.java index 3f30c3ade..0db84bfc3 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/ConvolutionLayerSetupTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/ConvolutionLayerSetupTest.java @@ -36,8 +36,11 @@ import org.deeplearning4j.nn.conf.preprocessor.FeedForwardToCnnPreProcessor; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.params.BatchNormalizationParamInitializer; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -60,6 +63,8 @@ import org.junit.jupiter.api.extension.ExtendWith; * @author Adam Gibson */ @DisplayName("Convolution Layer Setup Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class ConvolutionLayerSetupTest extends BaseDL4JTest { @TempDir diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/ConvolutionLayerTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/ConvolutionLayerTest.java index 76ee15bf9..1f659fa06 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/ConvolutionLayerTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/ConvolutionLayerTest.java @@ -40,7 +40,10 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.nn.weights.WeightInitNormal; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.enums.RnnDataFormat; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.activations.impl.ActivationSoftmax; @@ -69,6 +72,8 @@ import static org.junit.jupiter.api.Assertions.assertThrows; * @author Adam Gibson */ @DisplayName("Convolution Layer Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class ConvolutionLayerTest extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/LocallyConnectedLayerTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/LocallyConnectedLayerTest.java index e3a2886b6..db73245ff 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/LocallyConnectedLayerTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/LocallyConnectedLayerTest.java @@ -35,7 +35,10 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataBuffer; import org.nd4j.linalg.api.buffer.DataType; @@ -57,6 +60,8 @@ import org.junit.jupiter.api.extension.ExtendWith; * @author Max Pumperla */ @DisplayName("Locally Connected Layer Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class LocallyConnectedLayerTest extends BaseDL4JTest { @BeforeEach diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/SpaceToDepthTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/SpaceToDepthTest.java index 14259e0bb..8c9b4aac5 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/SpaceToDepthTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/SpaceToDepthTest.java @@ -24,7 +24,10 @@ import org.deeplearning4j.nn.conf.layers.SpaceToDepthLayer; import org.deeplearning4j.nn.api.Layer; import org.deeplearning4j.nn.conf.GradientNormalization; import org.deeplearning4j.nn.conf.NeuralNetConfiguration; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; @@ -35,6 +38,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Space To Depth Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class SpaceToDepthTest extends BaseDL4JTest { private int mb = 1; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/SubsamplingLayerTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/SubsamplingLayerTest.java index d16aeda08..25da3b545 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/SubsamplingLayerTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/SubsamplingLayerTest.java @@ -33,7 +33,10 @@ import org.deeplearning4j.nn.gradient.Gradient; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.params.DefaultParamInitializer; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -52,6 +55,8 @@ import static org.junit.jupiter.api.Assertions.assertThrows; * @author Adam Gibson */ @DisplayName("Subsampling Layer Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class SubsamplingLayerTest extends BaseDL4JTest { private int nExamples = 1; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/TestConvolutionModes.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/TestConvolutionModes.java index 6cc561ceb..3d9232e09 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/TestConvolutionModes.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/TestConvolutionModes.java @@ -35,7 +35,10 @@ import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.util.ConvolutionUtils; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -48,6 +51,8 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestConvolutionModes extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/Upsampling1DTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/Upsampling1DTest.java index cea528a36..3571d167a 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/Upsampling1DTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/Upsampling1DTest.java @@ -27,7 +27,10 @@ import org.deeplearning4j.nn.conf.GradientNormalization; import org.deeplearning4j.nn.conf.NeuralNetConfiguration; import org.deeplearning4j.nn.conf.layers.Upsampling1D; import org.deeplearning4j.nn.gradient.Gradient; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; @@ -44,6 +47,8 @@ import org.junit.jupiter.api.extension.ExtendWith; * @author Max Pumperla */ @DisplayName("Upsampling 1 D Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class Upsampling1DTest extends BaseDL4JTest { private int nExamples = 1; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/Upsampling2DTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/Upsampling2DTest.java index cb424b780..1fae34297 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/Upsampling2DTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/convolution/Upsampling2DTest.java @@ -27,7 +27,10 @@ import org.deeplearning4j.nn.conf.GradientNormalization; import org.deeplearning4j.nn.conf.NeuralNetConfiguration; import org.deeplearning4j.nn.conf.layers.Upsampling2D; import org.deeplearning4j.nn.gradient.Gradient; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; @@ -43,6 +46,8 @@ import org.junit.jupiter.api.extension.ExtendWith; * @author Max Pumperla */ @DisplayName("Upsampling 2 D Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class Upsampling2DTest extends BaseDL4JTest { private int nExamples = 1; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/custom/TestCustomActivation.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/custom/TestCustomActivation.java index 2af9576fc..b1be86a47 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/custom/TestCustomActivation.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/custom/TestCustomActivation.java @@ -26,7 +26,10 @@ import org.deeplearning4j.nn.conf.NeuralNetConfiguration; import org.deeplearning4j.nn.conf.layers.DenseLayer; import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.layers.custom.testclasses.CustomActivation; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.activations.IActivation; import org.nd4j.linalg.learning.config.Sgd; @@ -40,6 +43,9 @@ import java.util.Collection; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; +@NativeTag +@Tag(TagNames.DL4J_OLD_API) +@Tag(TagNames.CUSTOM_FUNCTIONALITY) public class TestCustomActivation extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/custom/TestCustomLayers.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/custom/TestCustomLayers.java index 47a4338a8..3db1efe4a 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/custom/TestCustomLayers.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/custom/TestCustomLayers.java @@ -33,7 +33,10 @@ import org.deeplearning4j.nn.layers.custom.testclasses.CustomOutputLayer; import org.deeplearning4j.nn.layers.custom.testclasses.CustomOutputLayerImpl; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -50,6 +53,9 @@ import java.util.Set; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; +@NativeTag +@Tag(TagNames.DL4J_OLD_API) +@Tag(TagNames.CUSTOM_FUNCTIONALITY) public class TestCustomLayers extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/feedforward/dense/DenseTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/feedforward/dense/DenseTest.java index c07b50fe8..c1b1de017 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/feedforward/dense/DenseTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/feedforward/dense/DenseTest.java @@ -29,7 +29,10 @@ import org.deeplearning4j.nn.conf.layers.DenseLayer; import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -42,6 +45,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Dense Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class DenseTest extends BaseDL4JTest { private int numSamples = 150; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/feedforward/embedding/EmbeddingLayerTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/feedforward/embedding/EmbeddingLayerTest.java index 940aa4e1b..b546af346 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/feedforward/embedding/EmbeddingLayerTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/feedforward/embedding/EmbeddingLayerTest.java @@ -37,7 +37,10 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.params.DefaultParamInitializer; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.nn.weights.embeddings.EmbeddingInitializer; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.activations.impl.ActivationIdentity; import org.nd4j.linalg.api.buffer.DataType; @@ -54,6 +57,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Embedding Layer Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class EmbeddingLayerTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/normalization/BatchNormalizationTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/normalization/BatchNormalizationTest.java index b69ea4241..09d2ffb82 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/normalization/BatchNormalizationTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/normalization/BatchNormalizationTest.java @@ -43,7 +43,10 @@ import org.deeplearning4j.nn.updater.MultiLayerUpdater; import org.deeplearning4j.nn.updater.UpdaterBlock; import org.deeplearning4j.nn.weights.WeightInit; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.buffer.util.DataTypeUtil; @@ -75,6 +78,8 @@ import org.junit.jupiter.api.extension.ExtendWith; */ @Slf4j @DisplayName("Batch Normalization Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class BatchNormalizationTest extends BaseDL4JTest { static { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/normalization/LocalResponseTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/normalization/LocalResponseTest.java index 7c7accec3..f939135e4 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/normalization/LocalResponseTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/normalization/LocalResponseTest.java @@ -35,7 +35,10 @@ import org.deeplearning4j.nn.gradient.Gradient; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -52,6 +55,8 @@ import org.junit.jupiter.api.extension.ExtendWith; /** */ @DisplayName("Local Response Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class LocalResponseTest extends BaseDL4JTest { private INDArray x = Nd4j.create(new double[] { 0.88128096, -0.96666986, -0.61832994, 0.26418415, 0.05694608, 0.2950289, 0.99222249, 0.24541704, 0.4219842, 0.96430975, 0.19299535, -0.06658337, -0.27603117, 0.24216647, 0.21834095, 0.03863283, -0.82313406, -0.37236378, -0.77667993, 0.66295379, -0.34406275, -0.25924176, 0.26652309, -0.58964926, -0.46907067, 0.34666502, 0.81208313, -0.17042427, -0.22470538, 0.8348338, 0.50494033, 0.45004508, 0.58735144, -0.87217808, -0.74788797, -0.04363599, 0.72276866, 0.52476895, -0.52383977, 0.1311436, 0.2628099, 0.77274454, 0.86400729, -0.35246921, -0.03399619, -0.502312, 0.42834607, 0.85534132, 0.90083021, 0.24571614, 0.63058525, -0.82919437, 0.57236177, -0.0913529, -0.7102778, 0.81631756, -0.89004314, 0.43995622, -0.26112801, -0.76135367, 0.65180862, -0.54667377, 0.94908774, 0.59298772, 0.36457643, 0.58892179, -0.52951556, 0.31559938, -0.55268252, 0.8272332, 0.37911707, -0.96299696, -0.40717798, 0.43324658, 0.2589654, -0.15605508, 0.96334064, -0.31666604, 0.19781154, 0.09908111, 0.64796048, -0.99037546, 0.67919868, 0.43810204 }, new int[] { 2, 7, 3, 2 }); diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/objdetect/TestYolo2OutputLayer.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/objdetect/TestYolo2OutputLayer.java index 24f0b06fb..89deea8dd 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/objdetect/TestYolo2OutputLayer.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/objdetect/TestYolo2OutputLayer.java @@ -28,7 +28,10 @@ import org.deeplearning4j.nn.conf.GradientNormalization; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.common.io.ClassPathResource; import org.datavec.image.recordreader.objdetect.ObjectDetectionRecordReader; @@ -69,7 +72,8 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.*; import static org.nd4j.linalg.indexing.NDArrayIndex.*; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestYolo2OutputLayer extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/ocnn/OCNNOutputLayerTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/ocnn/OCNNOutputLayerTest.java index 2c6907137..12f6e0ee3 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/ocnn/OCNNOutputLayerTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/ocnn/OCNNOutputLayerTest.java @@ -30,8 +30,11 @@ import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.optimize.listeners.ScoreIterationListener; import org.deeplearning4j.util.ModelSerializer; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.impl.ActivationIdentity; import org.nd4j.linalg.activations.impl.ActivationReLU; import org.nd4j.linalg.activations.impl.ActivationSigmoid; @@ -56,6 +59,9 @@ import java.nio.file.Path; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Ocnn Output Layer Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) +@Tag(TagNames.FILE_IO) class OCNNOutputLayerTest extends BaseDL4JTest { private static final boolean PRINT_RESULTS = true; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/pooling/GlobalPoolingMaskingTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/pooling/GlobalPoolingMaskingTests.java index a5096cf2f..c2bcc6c47 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/pooling/GlobalPoolingMaskingTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/pooling/GlobalPoolingMaskingTests.java @@ -29,7 +29,10 @@ import org.deeplearning4j.nn.conf.layers.*; import org.deeplearning4j.nn.conf.layers.GlobalPoolingLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -44,7 +47,8 @@ import java.util.Random; import static org.junit.jupiter.api.Assertions.assertArrayEquals; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.nd4j.linalg.indexing.NDArrayIndex.*; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class GlobalPoolingMaskingTests extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/BidirectionalTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/BidirectionalTest.java index 349d15f14..d197a2760 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/BidirectionalTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/BidirectionalTest.java @@ -44,11 +44,14 @@ import org.deeplearning4j.nn.updater.graph.ComputationGraphUpdater; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.util.ModelSerializer; import org.deeplearning4j.util.TimeSeriesUtils; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.enums.RnnDataFormat; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.activations.Activation; @@ -78,6 +81,8 @@ import org.junit.jupiter.api.extension.ExtendWith; @Slf4j @DisplayName("Bidirectional Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class BidirectionalTest extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/GravesBidirectionalLSTMTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/GravesBidirectionalLSTMTest.java index a32cc417a..1463d21a5 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/GravesBidirectionalLSTMTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/GravesBidirectionalLSTMTest.java @@ -34,11 +34,14 @@ import org.deeplearning4j.nn.params.GravesLSTMParamInitializer; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; import org.junit.jupiter.api.DisplayName; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.common.primitives.Pair; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.activations.impl.ActivationSigmoid; @@ -57,6 +60,8 @@ import java.util.stream.Stream; import static org.junit.jupiter.api.Assertions.*; @DisplayName("Graves Bidirectional LSTM Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class GravesBidirectionalLSTMTest extends BaseDL4JTest { private double score = 0.0; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/GravesLSTMTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/GravesLSTMTest.java index 1aef56056..8b324fcf0 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/GravesLSTMTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/GravesLSTMTest.java @@ -30,7 +30,10 @@ import org.deeplearning4j.nn.gradient.Gradient; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.params.GravesLSTMParamInitializer; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -47,6 +50,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Graves LSTM Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class GravesLSTMTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/MaskZeroLayerTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/MaskZeroLayerTest.java index 4499356c6..08e4455d0 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/MaskZeroLayerTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/MaskZeroLayerTest.java @@ -29,11 +29,14 @@ import org.deeplearning4j.nn.conf.layers.LSTM; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; import org.deeplearning4j.optimize.api.TrainingListener; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; @@ -52,6 +55,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Mask Zero Layer Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class MaskZeroLayerTest extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/RnnDataFormatTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/RnnDataFormatTests.java index 56af75755..669067628 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/RnnDataFormatTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/RnnDataFormatTests.java @@ -39,11 +39,14 @@ import org.deeplearning4j.nn.conf.layers.recurrent.SimpleRnn; import org.deeplearning4j.nn.conf.layers.util.MaskZeroLayer; import org.deeplearning4j.nn.gradient.Gradient; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; @@ -60,6 +63,8 @@ import java.util.stream.Stream; import static org.junit.jupiter.api.Assertions.assertEquals; @AllArgsConstructor +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class RnnDataFormatTests extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestLastTimeStepLayer.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestLastTimeStepLayer.java index 2ce14ad0f..0b65b1eef 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestLastTimeStepLayer.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestLastTimeStepLayer.java @@ -33,11 +33,14 @@ import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.conf.layers.recurrent.LastTimeStep; import org.deeplearning4j.nn.conf.layers.recurrent.SimpleRnn; import org.deeplearning4j.nn.graph.ComputationGraph; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.enums.RnnDataFormat; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; @@ -59,7 +62,8 @@ import static org.nd4j.linalg.activations.Activation.IDENTITY; import static org.nd4j.linalg.activations.Activation.TANH; import static org.nd4j.linalg.lossfunctions.LossFunctions.LossFunction.MSE; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestLastTimeStepLayer extends BaseDL4JTest { public static Stream params() { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestRecurrentWeightInit.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestRecurrentWeightInit.java index 74cfd2010..153a23cc3 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestRecurrentWeightInit.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestRecurrentWeightInit.java @@ -27,11 +27,15 @@ import org.deeplearning4j.nn.conf.layers.GravesLSTM; import org.deeplearning4j.nn.conf.layers.LSTM; import org.deeplearning4j.nn.conf.layers.recurrent.SimpleRnn; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import static org.junit.jupiter.api.Assertions.assertTrue; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestRecurrentWeightInit extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestRnnLayers.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestRnnLayers.java index 6e4ad3dda..f8102c57d 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestRnnLayers.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestRnnLayers.java @@ -35,11 +35,14 @@ import org.deeplearning4j.nn.conf.layers.recurrent.SimpleRnn; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.enums.RnnDataFormat; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.activations.Activation; @@ -60,7 +63,8 @@ import java.util.stream.Stream; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestRnnLayers extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestSimpleRnn.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestSimpleRnn.java index 1c6dad73d..77a1235ab 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestSimpleRnn.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestSimpleRnn.java @@ -28,11 +28,14 @@ import org.deeplearning4j.nn.conf.RNNFormat; import org.deeplearning4j.nn.conf.layers.recurrent.SimpleRnn; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; @@ -51,7 +54,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.nd4j.linalg.indexing.NDArrayIndex.all; import static org.nd4j.linalg.indexing.NDArrayIndex.interval; import static org.nd4j.linalg.indexing.NDArrayIndex.point; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestSimpleRnn extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestTimeDistributed.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestTimeDistributed.java index 54a908cce..b38e3e909 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestTimeDistributed.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/recurrent/TestTimeDistributed.java @@ -36,11 +36,14 @@ import org.deeplearning4j.nn.conf.layers.recurrent.SimpleRnn; import org.deeplearning4j.nn.conf.layers.recurrent.TimeDistributed; import org.deeplearning4j.nn.conf.layers.variational.VariationalAutoencoder; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; @@ -57,7 +60,8 @@ import java.util.List; import java.util.stream.Stream; import static org.junit.jupiter.api.Assertions.assertEquals; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestTimeDistributed extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/SameDiffCustomLayerTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/SameDiffCustomLayerTests.java index c9dc7bc5b..6c821f866 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/SameDiffCustomLayerTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/SameDiffCustomLayerTests.java @@ -37,10 +37,13 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.autodiff.samediff.SDVariable; import org.nd4j.autodiff.samediff.SameDiff; import org.nd4j.common.base.Preconditions; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -53,6 +56,9 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.assertThrows; @Slf4j +@NativeTag +@Tag(TagNames.SAMEDIFF) +@Tag(TagNames.CUSTOM_FUNCTIONALITY) public class SameDiffCustomLayerTests extends BaseDL4JTest { private DataType initialType; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffConv.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffConv.java index e1510e56a..00bc6c721 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffConv.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffConv.java @@ -35,7 +35,10 @@ import org.deeplearning4j.nn.layers.samediff.testlayers.SameDiffConv; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.params.ConvolutionParamInitializer; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -51,6 +54,10 @@ import static org.junit.jupiter.api.Assertions.*; import static org.junit.Assume.assumeTrue; @Slf4j +@NativeTag +@Tag(TagNames.SAMEDIFF) +@Tag(TagNames.CUSTOM_FUNCTIONALITY) +@Tag(TagNames.DL4J_OLD_API) public class TestSameDiffConv extends BaseDL4JTest { private static final boolean PRINT_RESULTS = true; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffDense.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffDense.java index a28230d48..13017e23e 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffDense.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffDense.java @@ -35,7 +35,10 @@ import org.deeplearning4j.nn.layers.samediff.testlayers.SameDiffDense; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.params.DefaultParamInitializer; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -51,6 +54,10 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag +@Tag(TagNames.SAMEDIFF) +@Tag(TagNames.CUSTOM_FUNCTIONALITY) +@Tag(TagNames.DL4J_OLD_API) public class TestSameDiffDense extends BaseDL4JTest { private static final boolean PRINT_RESULTS = true; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffDenseVertex.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffDenseVertex.java index fd7ec1d32..862a5acaa 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffDenseVertex.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffDenseVertex.java @@ -32,7 +32,10 @@ import org.deeplearning4j.nn.gradient.Gradient; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.layers.samediff.testlayers.SameDiffDenseVertex; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -46,6 +49,10 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j +@NativeTag +@Tag(TagNames.SAMEDIFF) +@Tag(TagNames.CUSTOM_FUNCTIONALITY) +@Tag(TagNames.DL4J_OLD_API) public class TestSameDiffDenseVertex extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffLambda.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffLambda.java index 4afbc7e37..1ff851b11 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffLambda.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffLambda.java @@ -34,7 +34,10 @@ import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.layers.samediff.testlayers.SameDiffSimpleLambdaLayer; import org.deeplearning4j.nn.layers.samediff.testlayers.SameDiffSimpleLambdaVertex; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -47,6 +50,10 @@ import org.nd4j.linalg.lossfunctions.LossFunctions; import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j +@NativeTag +@Tag(TagNames.SAMEDIFF) +@Tag(TagNames.CUSTOM_FUNCTIONALITY) +@Tag(TagNames.DL4J_OLD_API) public class TestSameDiffLambda extends BaseDL4JTest { private static final boolean PRINT_RESULTS = true; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffOutput.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffOutput.java index 0207341b5..7aa13f11c 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffOutput.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/samediff/TestSameDiffOutput.java @@ -31,7 +31,10 @@ import org.deeplearning4j.nn.layers.samediff.testlayers.SameDiffMSELossLayer; import org.deeplearning4j.nn.layers.samediff.testlayers.SameDiffMSEOutputLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -42,6 +45,10 @@ import org.nd4j.linalg.lossfunctions.LossFunctions; import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j +@NativeTag +@Tag(TagNames.SAMEDIFF) +@Tag(TagNames.CUSTOM_FUNCTIONALITY) +@Tag(TagNames.DL4J_OLD_API) public class TestSameDiffOutput extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/variational/TestReconstructionDistributions.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/variational/TestReconstructionDistributions.java index 934ba63a8..5b1c12633 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/variational/TestReconstructionDistributions.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/variational/TestReconstructionDistributions.java @@ -30,7 +30,10 @@ import org.deeplearning4j.nn.conf.layers.variational.BernoulliReconstructionDist import org.deeplearning4j.nn.conf.layers.variational.ExponentialReconstructionDistribution; import org.deeplearning4j.nn.conf.layers.variational.GaussianReconstructionDistribution; import org.deeplearning4j.nn.conf.layers.variational.ReconstructionDistribution; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -44,6 +47,10 @@ import java.util.Random; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag +@Tag(TagNames.RNG) +@Tag(TagNames.CUSTOM_FUNCTIONALITY) +@Tag(TagNames.DL4J_OLD_API) public class TestReconstructionDistributions extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/variational/TestVAE.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/variational/TestVAE.java index e61614a1b..ff82e1ef9 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/variational/TestVAE.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/layers/variational/TestVAE.java @@ -32,7 +32,10 @@ import org.deeplearning4j.nn.conf.weightnoise.WeightNoise; import org.deeplearning4j.nn.gradient.Gradient; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.activations.impl.ActivationTanH; import org.nd4j.linalg.api.ndarray.INDArray; @@ -51,6 +54,10 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.*; +@NativeTag +@Tag(TagNames.RNG) +@Tag(TagNames.CUSTOM_FUNCTIONALITY) +@Tag(TagNames.DL4J_OLD_API) public class TestVAE extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/CloseNetworkTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/CloseNetworkTests.java index c041154ba..aba191181 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/CloseNetworkTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/CloseNetworkTests.java @@ -28,7 +28,10 @@ import org.deeplearning4j.nn.conf.inputs.InputType; import org.deeplearning4j.nn.conf.layers.*; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -36,7 +39,10 @@ import org.nd4j.linalg.factory.Nd4j; import org.nd4j.linalg.learning.config.Adam; import static org.junit.jupiter.api.Assertions.assertTrue; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) +@Tag(TagNames.FILE_IO) +@Tag(TagNames.WORKSPACES) public class CloseNetworkTests extends BaseDL4JTest { public static MultiLayerNetwork getTestNet() { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/LargeNetTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/LargeNetTest.java index da01cb60c..8e99809cb 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/LargeNetTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/LargeNetTest.java @@ -28,7 +28,10 @@ import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataBuffer; import org.nd4j.linalg.api.buffer.DataType; @@ -41,6 +44,10 @@ import org.junit.jupiter.api.extension.ExtendWith; @Disabled @DisplayName("Large Net Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) +@Tag(TagNames.FILE_IO) +@Tag(TagNames.WORKSPACES) class LargeNetTest extends BaseDL4JTest { @Disabled diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/TestLrChanges.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/TestLrChanges.java index 77f3a2342..0a01d5efa 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/TestLrChanges.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/TestLrChanges.java @@ -29,7 +29,10 @@ import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.conf.weightnoise.DropConnect; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -43,7 +46,9 @@ import org.nd4j.linalg.schedule.ExponentialSchedule; import org.nd4j.linalg.schedule.ScheduleType; import static org.junit.jupiter.api.Assertions.assertEquals; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) +@Tag(TagNames.WORKSPACES) public class TestLrChanges extends BaseDL4JTest { @Test @@ -61,7 +66,7 @@ public class TestLrChanges extends BaseDL4JTest { MultiLayerNetwork net = new MultiLayerNetwork(conf); net.init(); - for( int i=0; i<10; i++ ){ + for( int i = 0; i < 10; i++) { net.fit(Nd4j.rand(10,10), Nd4j.rand(10,10)); } diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/TestMemoryReports.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/TestMemoryReports.java index 6ae911f69..4d4f4c0bb 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/TestMemoryReports.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/TestMemoryReports.java @@ -35,7 +35,10 @@ import org.deeplearning4j.nn.conf.memory.MemoryReport; import org.deeplearning4j.nn.conf.memory.MemoryType; import org.deeplearning4j.nn.conf.memory.MemoryUseMode; import org.deeplearning4j.nn.conf.preprocessor.FeedForwardToCnnPreProcessor; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -50,7 +53,9 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertArrayEquals; import static org.junit.jupiter.api.Assertions.assertEquals; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) +@Tag(TagNames.WORKSPACES) public class TestMemoryReports extends BaseDL4JTest { public static List> getTestLayers() { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/TestNetConversion.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/TestNetConversion.java index cd1ca1a28..04663963f 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/TestNetConversion.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/TestNetConversion.java @@ -29,7 +29,10 @@ import org.deeplearning4j.nn.conf.layers.*; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -38,6 +41,8 @@ import org.nd4j.linalg.lossfunctions.LossFunctions; import static org.junit.jupiter.api.Assertions.assertEquals; +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestNetConversion extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/WorkspaceTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/WorkspaceTests.java index c6f1cfc48..7fa8095d4 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/WorkspaceTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/misc/WorkspaceTests.java @@ -35,7 +35,10 @@ import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.optimize.listeners.ScoreIterationListener; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.memory.MemoryWorkspace; import org.nd4j.linalg.api.memory.conf.WorkspaceConfiguration; @@ -56,6 +59,10 @@ import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag +@Tag(TagNames.DL4J_OLD_API) +@Tag(TagNames.FILE_IO) +@Tag(TagNames.WORKSPACES) public class WorkspaceTests extends BaseDL4JTest { @BeforeEach diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/mkldnn/ValidateMKLDNN.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/mkldnn/ValidateMKLDNN.java index 10b2e6ca3..9cd15eba6 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/mkldnn/ValidateMKLDNN.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/mkldnn/ValidateMKLDNN.java @@ -35,7 +35,10 @@ import org.deeplearning4j.nn.gradient.Gradient; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -51,7 +54,8 @@ import java.util.Collections; import static junit.framework.TestCase.*; import static org.junit.Assume.assumeTrue; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class ValidateMKLDNN extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/BackPropMLPTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/BackPropMLPTest.java index d93938555..7995ebd26 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/BackPropMLPTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/BackPropMLPTest.java @@ -30,7 +30,10 @@ import org.deeplearning4j.nn.gradient.Gradient; import org.deeplearning4j.nn.params.DefaultParamInitializer; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.optimize.listeners.ScoreIterationListener; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.iter.NdIndexIterator; @@ -51,6 +54,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Back Prop MLP Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class BackPropMLPTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/MultiLayerTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/MultiLayerTest.java index 2d5639d09..11c61929b 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/MultiLayerTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/MultiLayerTest.java @@ -54,6 +54,8 @@ import org.deeplearning4j.optimize.listeners.ScoreIterationListener; import org.deeplearning4j.util.ModelSerializer; import org.junit.jupiter.api.*;import org.junit.jupiter.api.Test; import org.junit.jupiter.api.*; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -86,6 +88,8 @@ import static org.junit.jupiter.api.Assertions.assertThrows; @Slf4j @DisplayName("Multi Layer Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class MultiLayerTest extends BaseDL4JTest { private static OpExecutioner.ProfilingMode origMode; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/MultiLayerTestRNN.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/MultiLayerTestRNN.java index 6f1b3f732..c241f52c6 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/MultiLayerTestRNN.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/MultiLayerTestRNN.java @@ -42,7 +42,10 @@ import org.deeplearning4j.nn.layers.recurrent.LSTM; import org.deeplearning4j.nn.layers.recurrent.SimpleRnn; import org.deeplearning4j.nn.params.GravesLSTMParamInitializer; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -60,6 +63,8 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class MultiLayerTestRNN extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/TestMasking.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/TestMasking.java index 420417296..486f47dcb 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/TestMasking.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/TestMasking.java @@ -38,7 +38,10 @@ import org.deeplearning4j.nn.conf.preprocessor.CnnToRnnPreProcessor; import org.deeplearning4j.nn.conf.preprocessor.RnnToCnnPreProcessor; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.buffer.util.DataTypeUtil; @@ -55,7 +58,8 @@ import org.nd4j.linalg.lossfunctions.impl.*; import java.util.Collections; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestMasking extends BaseDL4JTest { static { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/TestSetGetParameters.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/TestSetGetParameters.java index 30b9fdba7..fffe686e0 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/TestSetGetParameters.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/TestSetGetParameters.java @@ -25,7 +25,10 @@ import org.deeplearning4j.nn.conf.MultiLayerConfiguration; import org.deeplearning4j.nn.conf.NeuralNetConfiguration; import org.deeplearning4j.nn.conf.distribution.NormalDistribution; import org.deeplearning4j.nn.conf.layers.*; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -34,7 +37,8 @@ import org.nd4j.linalg.lossfunctions.LossFunctions.LossFunction; import java.util.Map; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestSetGetParameters extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/TestVariableLengthTS.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/TestVariableLengthTS.java index b113006ec..8cd027c56 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/TestVariableLengthTS.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/multilayer/TestVariableLengthTS.java @@ -35,7 +35,10 @@ import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.nn.workspace.ArrayType; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; import org.deeplearning4j.util.TimeSeriesUtils; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.ops.CustomOp; @@ -54,7 +57,8 @@ import java.util.Map; import java.util.Random; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestVariableLengthTS extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/rl/TestMultiModelGradientApplication.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/rl/TestMultiModelGradientApplication.java index 410abf970..edade0145 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/rl/TestMultiModelGradientApplication.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/rl/TestMultiModelGradientApplication.java @@ -30,7 +30,10 @@ import org.deeplearning4j.nn.gradient.Gradient; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -43,7 +46,8 @@ import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotEquals; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestMultiModelGradientApplication extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/updater/TestGradientNormalization.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/updater/TestGradientNormalization.java index 02616d66d..0ecdeaca7 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/updater/TestGradientNormalization.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/updater/TestGradientNormalization.java @@ -30,7 +30,10 @@ import org.deeplearning4j.nn.conf.layers.DenseLayer; import org.deeplearning4j.nn.gradient.DefaultGradient; import org.deeplearning4j.nn.gradient.Gradient; import org.deeplearning4j.nn.params.DefaultParamInitializer; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.shape.Shape; import org.nd4j.linalg.factory.Nd4j; @@ -39,7 +42,8 @@ import org.nd4j.linalg.learning.config.NoOp; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestGradientNormalization extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/updater/TestUpdaters.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/updater/TestUpdaters.java index 28e27511b..f74eb7a26 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/updater/TestUpdaters.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/updater/TestUpdaters.java @@ -39,7 +39,10 @@ import org.deeplearning4j.nn.params.DefaultParamInitializer; import org.deeplearning4j.nn.params.PretrainParamInitializer; import org.deeplearning4j.nn.updater.graph.ComputationGraphUpdater; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -56,7 +59,8 @@ import java.util.*; import static org.junit.jupiter.api.Assertions.*; import static org.nd4j.linalg.indexing.NDArrayIndex.interval; import static org.nd4j.linalg.indexing.NDArrayIndex.point; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestUpdaters extends BaseDL4JTest { protected int nIn = 3; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/updater/custom/TestCustomUpdater.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/updater/custom/TestCustomUpdater.java index 703d56eb2..97ab4e56d 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/updater/custom/TestCustomUpdater.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/updater/custom/TestCustomUpdater.java @@ -27,7 +27,10 @@ import org.deeplearning4j.nn.conf.layers.BaseLayer; import org.deeplearning4j.nn.conf.layers.DenseLayer; import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -36,7 +39,9 @@ import org.nd4j.linalg.lossfunctions.LossFunctions; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) +@Tag(TagNames.CUSTOM_FUNCTIONALITY) public class TestCustomUpdater extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/weights/LegacyWeightInitTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/weights/LegacyWeightInitTest.java index b9e9f3376..7eadb3131 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/weights/LegacyWeightInitTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/weights/LegacyWeightInitTest.java @@ -22,9 +22,9 @@ package org.deeplearning4j.nn.weights; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.nn.conf.distribution.*; import org.deeplearning4j.nn.conf.serde.JsonMappers; -import org.junit.jupiter.api.AfterEach; -import org.junit.jupiter.api.BeforeEach; -import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.*; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.rng.Random; import org.nd4j.linalg.factory.Nd4j; @@ -34,10 +34,12 @@ import java.io.IOException; import java.util.Arrays; import java.util.List; import static org.junit.jupiter.api.Assertions.*; -import org.junit.jupiter.api.DisplayName; + import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Legacy Weight Init Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class LegacyWeightInitTest extends BaseDL4JTest { private RandomFactory prevFactory; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/weights/WeightInitIdentityTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/weights/WeightInitIdentityTest.java index 8dd8b9c2f..36187f768 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/weights/WeightInitIdentityTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/weights/WeightInitIdentityTest.java @@ -27,7 +27,10 @@ import org.deeplearning4j.nn.conf.inputs.InputType; import org.deeplearning4j.nn.conf.layers.*; import org.deeplearning4j.nn.graph.ComputationGraph; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.impl.ActivationIdentity; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -37,6 +40,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Weight Init Identity Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class WeightInitIdentityTest extends BaseDL4JTest { /** diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/weights/WeightInitUtilTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/weights/WeightInitUtilTest.java index 47dbfcbe7..c1d063bb9 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/weights/WeightInitUtilTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/nn/weights/WeightInitUtilTest.java @@ -24,7 +24,10 @@ import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.nn.conf.distribution.Distributions; import org.deeplearning4j.nn.conf.distribution.GaussianDistribution; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.rng.distribution.Distribution; import org.nd4j.linalg.factory.Nd4j; @@ -33,6 +36,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Weight Init Util Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class WeightInitUtilTest extends BaseDL4JTest { protected int fanIn = 3; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/BackTrackLineSearchTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/BackTrackLineSearchTest.java index 6e2542c07..ea8eb9e82 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/BackTrackLineSearchTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/BackTrackLineSearchTest.java @@ -36,7 +36,10 @@ import org.deeplearning4j.optimize.solvers.BackTrackLineSearch; import org.deeplearning4j.optimize.stepfunctions.DefaultStepFunction; import org.deeplearning4j.optimize.stepfunctions.NegativeDefaultStepFunction; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -54,6 +57,9 @@ import org.junit.jupiter.api.extension.ExtendWith; * @author Adam Gibson */ @DisplayName("Back Track Line Search Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) +@Tag(TagNames.FILE_IO) class BackTrackLineSearchTest extends BaseDL4JTest { private DataSetIterator irisIter; diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/TestOptimizers.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/TestOptimizers.java index 5c774c3f4..9afb5ffc7 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/TestOptimizers.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/TestOptimizers.java @@ -42,7 +42,10 @@ import org.deeplearning4j.optimize.solvers.LBFGS; import org.deeplearning4j.optimize.solvers.LineGradientDescent; import org.deeplearning4j.optimize.solvers.StochasticGradientDescent; import org.deeplearning4j.optimize.stepfunctions.NegativeDefaultStepFunction; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -67,6 +70,9 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.assertTrue; +@NativeTag +@Tag(TagNames.DL4J_OLD_API) +@Tag(TagNames.TRAINING) public class TestOptimizers extends BaseDL4JTest { //For debugging. diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/accumulation/EncodedGradientsAccumulatorTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/accumulation/EncodedGradientsAccumulatorTest.java index 8cbeaf234..60d7ac59f 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/accumulation/EncodedGradientsAccumulatorTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/accumulation/EncodedGradientsAccumulatorTest.java @@ -25,7 +25,10 @@ import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.optimize.solvers.accumulation.EncodedGradientsAccumulator; import org.deeplearning4j.optimize.solvers.accumulation.EncodingHandler; import org.deeplearning4j.optimize.solvers.accumulation.encoding.threshold.FixedThresholdAlgorithm; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.concurrency.AffinityManager; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.ops.util.PrintAffinity; @@ -38,6 +41,8 @@ import org.junit.jupiter.api.extension.ExtendWith; @Slf4j @DisplayName("Encoded Gradients Accumulator Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class EncodedGradientsAccumulatorTest extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/accumulation/IndexedTailTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/accumulation/IndexedTailTest.java index 28cd85b35..2ed4d4ef4 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/accumulation/IndexedTailTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/accumulation/IndexedTailTest.java @@ -25,7 +25,10 @@ import org.apache.commons.lang3.RandomUtils; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.optimize.solvers.accumulation.IndexedTail; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import java.util.ArrayList; import java.util.concurrent.atomic.AtomicInteger; @@ -35,6 +38,8 @@ import org.junit.jupiter.api.extension.ExtendWith; @Slf4j @DisplayName("Indexed Tail Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class IndexedTailTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/accumulation/ThresholdAlgorithmTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/accumulation/ThresholdAlgorithmTests.java index 390093217..a114ee092 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/accumulation/ThresholdAlgorithmTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimize/solver/accumulation/ThresholdAlgorithmTests.java @@ -24,7 +24,10 @@ import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.optimize.solvers.accumulation.encoding.ThresholdAlgorithm; import org.deeplearning4j.optimize.solvers.accumulation.encoding.ThresholdAlgorithmReducer; import org.deeplearning4j.optimize.solvers.accumulation.encoding.threshold.AdaptiveThresholdAlgorithm; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -32,6 +35,8 @@ import java.lang.reflect.Field; import static org.junit.jupiter.api.Assertions.assertEquals; +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class ThresholdAlgorithmTests extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimizer/listener/ScoreStatTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimizer/listener/ScoreStatTest.java index 1edd152c2..536697a4c 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimizer/listener/ScoreStatTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimizer/listener/ScoreStatTest.java @@ -22,13 +22,18 @@ package org.deeplearning4j.optimizer.listener; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.optimize.listeners.CollectScoresIterationListener; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import java.util.List; import static org.junit.jupiter.api.Assertions.*; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Score Stat Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class ScoreStatTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimizer/listener/TestCheckpointListener.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimizer/listener/TestCheckpointListener.java index fc273a4a4..9ed25912a 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimizer/listener/TestCheckpointListener.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimizer/listener/TestCheckpointListener.java @@ -30,9 +30,12 @@ import org.deeplearning4j.optimize.listeners.Checkpoint; import org.deeplearning4j.optimize.listeners.CheckpointListener; import org.deeplearning4j.util.ModelSerializer; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.linalg.lossfunctions.LossFunctions; @@ -47,7 +50,8 @@ import java.util.Set; import java.util.concurrent.TimeUnit; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestCheckpointListener extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimizer/listener/TestFailureListener.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimizer/listener/TestFailureListener.java index f8a40034a..8c662cec1 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimizer/listener/TestFailureListener.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/optimizer/listener/TestFailureListener.java @@ -28,7 +28,10 @@ import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.optimize.listeners.FailureTestingListener; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.linalg.learning.config.Adam; @@ -44,6 +47,9 @@ import static org.junit.jupiter.api.Assertions.assertNotNull; * They should be run manually, not as part of standard unit test run. */ @Disabled +@NativeTag +@Tag(TagNames.DL4J_OLD_API) +@Tag(TagNames.MANUAL) public class TestFailureListener extends BaseDL4JTest { @Disabled diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/AsyncIteratorTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/AsyncIteratorTest.java index 4cc240643..d020dcb33 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/AsyncIteratorTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/AsyncIteratorTest.java @@ -21,13 +21,18 @@ package org.deeplearning4j.parallelism; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.core.parallelism.AsyncIterator; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import java.util.ArrayList; import static org.junit.jupiter.api.Assertions.assertEquals; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Async Iterator Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class AsyncIteratorTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/FancyBlockingQueueTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/FancyBlockingQueueTests.java index 82dfedaeb..a33292bb1 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/FancyBlockingQueueTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/FancyBlockingQueueTests.java @@ -24,7 +24,10 @@ import lombok.extern.slf4j.Slf4j; import org.apache.commons.lang3.RandomUtils; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.optimize.solvers.accumulation.FancyBlockingQueue; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.util.concurrent.LinkedBlockingQueue; import java.util.concurrent.atomic.AtomicLong; @@ -32,6 +35,8 @@ import java.util.concurrent.atomic.AtomicLong; import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class FancyBlockingQueueTests extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/MultiBooleanTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/MultiBooleanTest.java index 54a3a099e..13ee9d69b 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/MultiBooleanTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/MultiBooleanTest.java @@ -21,13 +21,18 @@ package org.deeplearning4j.parallelism; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.datasets.iterator.parallel.MultiBoolean; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import static org.junit.jupiter.api.Assertions.assertFalse; import static org.junit.jupiter.api.Assertions.assertTrue; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Multi Boolean Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class MultiBooleanTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/ParallelExistingMiniBatchDataSetIteratorTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/ParallelExistingMiniBatchDataSetIteratorTest.java index bbdd861eb..eb03506e4 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/ParallelExistingMiniBatchDataSetIteratorTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/ParallelExistingMiniBatchDataSetIteratorTest.java @@ -21,6 +21,7 @@ package org.deeplearning4j.parallelism; import lombok.extern.slf4j.Slf4j; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.io.ClassPathResource; import org.deeplearning4j.BaseDL4JTest; @@ -28,6 +29,8 @@ import org.deeplearning4j.datasets.iterator.callbacks.DataSetDeserializer; import org.deeplearning4j.datasets.iterator.parallel.FileSplitParallelDataSetIterator; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.common.primitives.Pair; import java.io.File; @@ -127,6 +130,8 @@ import org.junit.jupiter.api.extension.ExtendWith; } */ @DisplayName("Parallel Existing Mini Batch Data Set Iterator Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class ParallelExistingMiniBatchDataSetIteratorTest extends BaseDL4JTest { @TempDir diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/RandomTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/RandomTests.java index 97a1cb799..cc9b21a44 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/RandomTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/parallelism/RandomTests.java @@ -32,7 +32,10 @@ import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.conf.layers.SubsamplingLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.linalg.learning.config.Nesterovs; @@ -43,6 +46,9 @@ import java.util.concurrent.CopyOnWriteArrayList; import static org.junit.jupiter.api.Assertions.assertEquals; +@NativeTag +@Tag(TagNames.DL4J_OLD_API) +@Tag(TagNames.RNG) public class RandomTests extends BaseDL4JTest { /** diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/perf/listener/SystemPollingTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/perf/listener/SystemPollingTest.java index 8d9bf2ed2..486178f1e 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/perf/listener/SystemPollingTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/perf/listener/SystemPollingTest.java @@ -25,8 +25,11 @@ import org.deeplearning4j.core.listener.HardwareMetric; import org.deeplearning4j.core.listener.SystemPolling; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import java.io.File; import static org.junit.jupiter.api.Assertions.assertEquals; @@ -37,6 +40,8 @@ import org.junit.jupiter.api.extension.ExtendWith; @Disabled("AB 2019/05/24 - Failing on CI - \"Could not initialize class oshi.jna.platform.linux.Libc\" - Issue #7657") @DisplayName("System Polling Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) class SystemPollingTest extends BaseDL4JTest { @TempDir diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/perf/listener/TestHardWareMetric.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/perf/listener/TestHardWareMetric.java index 7c6056482..c5abceeb6 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/perf/listener/TestHardWareMetric.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/perf/listener/TestHardWareMetric.java @@ -23,13 +23,18 @@ package org.deeplearning4j.perf.listener; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.core.listener.HardwareMetric; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import oshi.json.SystemInfo; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotNull; @Disabled("AB 2019/05/24 - Failing on CI - \"Could not initialize class oshi.jna.platform.linux.Libc\" - Issue #7657") +@NativeTag +@Tag(TagNames.JACKSON_SERDE) public class TestHardWareMetric extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/MiscRegressionTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/MiscRegressionTests.java index 686501ff8..3a3728c74 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/MiscRegressionTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/MiscRegressionTests.java @@ -30,8 +30,11 @@ import org.deeplearning4j.nn.conf.graph.LayerVertex; import org.deeplearning4j.nn.conf.layers.DenseLayer; import org.deeplearning4j.nn.conf.layers.Layer; import org.deeplearning4j.nn.conf.layers.misc.FrozenLayer; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import java.nio.charset.StandardCharsets; @@ -40,7 +43,8 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotNull; import static org.junit.jupiter.api.Assertions.assertTrue; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class MiscRegressionTests extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest050.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest050.java index 5a6567fa7..69038a1e7 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest050.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest050.java @@ -33,8 +33,11 @@ import org.deeplearning4j.nn.weights.WeightInitRelu; import org.deeplearning4j.nn.weights.WeightInitXavier; import org.deeplearning4j.util.ModelSerializer; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.impl.ActivationLReLU; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.factory.Nd4j; @@ -49,7 +52,8 @@ import org.nd4j.common.resources.Resources; import java.io.File; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class RegressionTest050 extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest060.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest060.java index da6976b6a..bec283ae4 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest060.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest060.java @@ -37,7 +37,10 @@ import org.deeplearning4j.nn.weights.WeightInitDistribution; import org.deeplearning4j.nn.weights.WeightInitRelu; import org.deeplearning4j.nn.weights.WeightInitXavier; import org.deeplearning4j.util.ModelSerializer; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.impl.ActivationLReLU; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.factory.Nd4j; @@ -52,7 +55,8 @@ import org.nd4j.common.resources.Resources; import java.io.File; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class RegressionTest060 extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest071.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest071.java index e2ef4b233..650d3cd09 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest071.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest071.java @@ -37,7 +37,10 @@ import org.deeplearning4j.nn.weights.WeightInitDistribution; import org.deeplearning4j.nn.weights.WeightInitRelu; import org.deeplearning4j.nn.weights.WeightInitXavier; import org.deeplearning4j.util.ModelSerializer; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.impl.ActivationIdentity; import org.nd4j.linalg.activations.impl.ActivationLReLU; import org.nd4j.linalg.api.buffer.DataType; @@ -53,7 +56,8 @@ import org.nd4j.common.resources.Resources; import java.io.File; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class RegressionTest071 extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest080.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest080.java index b2af73f06..8045ab8cc 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest080.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest080.java @@ -37,7 +37,10 @@ import org.deeplearning4j.nn.weights.WeightInitDistribution; import org.deeplearning4j.nn.weights.WeightInitRelu; import org.deeplearning4j.nn.weights.WeightInitXavier; import org.deeplearning4j.util.ModelSerializer; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.impl.*; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.factory.Nd4j; @@ -52,7 +55,8 @@ import org.nd4j.common.resources.Resources; import java.io.File; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class RegressionTest080 extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest100a.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest100a.java index dccc94487..572669849 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest100a.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest100a.java @@ -36,7 +36,10 @@ import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInitXavier; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.impl.ActivationIdentity; import org.nd4j.linalg.activations.impl.ActivationLReLU; import org.nd4j.linalg.activations.impl.ActivationSoftmax; @@ -57,6 +60,8 @@ import static org.junit.jupiter.api.Assertions.*; @Slf4j @Disabled +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class RegressionTest100a extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest100b3.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest100b3.java index fce6cae1c..c92131d57 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest100b3.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest100b3.java @@ -35,7 +35,10 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInitXavier; import org.deeplearning4j.regressiontest.customlayer100a.CustomLayer; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.impl.*; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -52,6 +55,8 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.*; @Disabled +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class RegressionTest100b3 extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest100b4.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest100b4.java index fb11070c1..259eb6408 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest100b4.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest100b4.java @@ -55,7 +55,10 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInitXavier; import org.deeplearning4j.regressiontest.customlayer100a.CustomLayer; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.impl.ActivationIdentity; import org.nd4j.linalg.activations.impl.ActivationLReLU; import org.nd4j.linalg.activations.impl.ActivationReLU; @@ -72,6 +75,8 @@ import org.nd4j.linalg.lossfunctions.impl.LossMAE; import org.nd4j.linalg.lossfunctions.impl.LossMCXENT; import org.nd4j.common.resources.Resources; @Disabled +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class RegressionTest100b4 extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest100b6.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest100b6.java index 9e2dad7fe..ae5684734 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest100b6.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/RegressionTest100b6.java @@ -36,7 +36,10 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInitXavier; import org.deeplearning4j.regressiontest.customlayer100a.CustomLayer; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.impl.*; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -54,6 +57,8 @@ import java.io.FileInputStream; import static org.junit.jupiter.api.Assertions.*; @Disabled +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class RegressionTest100b6 extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/TestDistributionDeserializer.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/TestDistributionDeserializer.java index e4403e5de..ec4ee2caf 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/TestDistributionDeserializer.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/regressiontest/TestDistributionDeserializer.java @@ -23,12 +23,18 @@ package org.deeplearning4j.regressiontest; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.nn.conf.NeuralNetConfiguration; import org.deeplearning4j.nn.conf.distribution.*; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.shade.jackson.databind.ObjectMapper; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; +@NativeTag +@Tag(TagNames.DL4J_OLD_API) +@Tag(TagNames.JACKSON_SERDE) public class TestDistributionDeserializer extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/samediff/CompareTrainingImplementations.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/samediff/CompareTrainingImplementations.java index 396fbe778..a97da82ed 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/samediff/CompareTrainingImplementations.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/samediff/CompareTrainingImplementations.java @@ -30,10 +30,13 @@ import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.autodiff.samediff.SDVariable; import org.nd4j.autodiff.samediff.SameDiff; import org.nd4j.autodiff.samediff.TrainingConfig; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.evaluation.classification.Evaluation; import org.nd4j.evaluation.regression.RegressionEvaluation; import org.nd4j.linalg.activations.Activation; @@ -57,6 +60,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.fail; @Slf4j +@NativeTag +@Tag(TagNames.SAMEDIFF) public class CompareTrainingImplementations extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/ui/UiConnectionInfoTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/ui/UiConnectionInfoTest.java index cf8984bfa..a8e8ec3af 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/ui/UiConnectionInfoTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/ui/UiConnectionInfoTest.java @@ -22,12 +22,18 @@ package org.deeplearning4j.ui; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.core.ui.UiConnectionInfo; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import static org.junit.jupiter.api.Assertions.assertEquals; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; @DisplayName("Ui Connection Info Test") +@NativeTag +@Tag(TagNames.DL4J_OLD_API) +@Tag(TagNames.UI) class UiConnectionInfoTest extends BaseDL4JTest { @BeforeEach diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/ArrayUtilTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/ArrayUtilTest.java index a35377962..a9c3ecdf0 100755 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/ArrayUtilTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/ArrayUtilTest.java @@ -20,7 +20,10 @@ package org.deeplearning4j.util; import org.deeplearning4j.BaseDL4JTest; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.common.util.ArrayUtil; import java.util.Arrays; import static org.junit.jupiter.api.Assertions.assertEquals; @@ -30,6 +33,7 @@ import org.junit.jupiter.api.extension.ExtendWith; /** */ @DisplayName("Array Util Test") +@Tag(TagNames.JAVA_ONLY) class ArrayUtilTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/CrashReportingUtilTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/CrashReportingUtilTest.java index 7f7ee4382..094d443af 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/CrashReportingUtilTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/CrashReportingUtilTest.java @@ -34,11 +34,11 @@ import org.deeplearning4j.nn.conf.layers.SubsamplingLayer; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.optimize.listeners.ScoreIterationListener; -import org.junit.jupiter.api.AfterEach; +import org.junit.jupiter.api.*; -import org.junit.jupiter.api.Disabled; -import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; @@ -46,11 +46,14 @@ import org.nd4j.linalg.learning.config.NoOp; import org.nd4j.linalg.lossfunctions.LossFunctions; import java.io.File; import static org.junit.jupiter.api.Assertions.*; -import org.junit.jupiter.api.DisplayName; + import java.nio.file.Path; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Crash Reporting Util Test") +@NativeTag +@Tag(TagNames.JAVA_ONLY) +@Tag(TagNames.FILE_IO) class CrashReportingUtilTest extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/ModelGuesserTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/ModelGuesserTest.java index 88570b4d3..bc70310d7 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/ModelGuesserTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/ModelGuesserTest.java @@ -32,9 +32,12 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.dataset.api.preprocessor.Normalizer; @@ -54,6 +57,8 @@ import org.junit.jupiter.api.extension.ExtendWith; @Disabled @DisplayName("Model Guesser Test") +@NativeTag +@Tag(TagNames.FILE_IO) class ModelGuesserTest extends BaseDL4JTest { @TempDir diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/ModelSerializerTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/ModelSerializerTest.java index 8a769886d..2f19499d1 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/ModelSerializerTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/ModelSerializerTest.java @@ -34,8 +34,11 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -59,6 +62,8 @@ import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Model Serializer Test") @Disabled +@NativeTag +@Tag(TagNames.FILE_IO) class ModelSerializerTest extends BaseDL4JTest { @TempDir diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/ModelValidatorTests.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/ModelValidatorTests.java index ae696d86b..a0aa6cdb2 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/ModelValidatorTests.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/ModelValidatorTests.java @@ -30,9 +30,12 @@ import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.learning.config.Adam; import org.nd4j.common.validation.ValidationResult; @@ -54,7 +57,8 @@ import java.util.zip.ZipOutputStream; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.FILE_IO) public class ModelValidatorTests extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/MovingWindowMatrixTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/MovingWindowMatrixTest.java index 6c0557619..59b74f467 100755 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/MovingWindowMatrixTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/MovingWindowMatrixTest.java @@ -21,7 +21,10 @@ package org.deeplearning4j.util; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.core.util.MovingWindowMatrix; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import java.util.List; @@ -30,6 +33,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Moving Window Matrix Test") +@NativeTag +@Tag(TagNames.NDARRAY_ETL) class MovingWindowMatrixTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/SerializationUtilsTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/SerializationUtilsTest.java index fe708f04c..87a8256fa 100755 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/SerializationUtilsTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/SerializationUtilsTest.java @@ -22,8 +22,11 @@ package org.deeplearning4j.util; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.datasets.iterator.impl.IrisDataSetIterator; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.common.util.SerializationUtils; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; @@ -34,6 +37,8 @@ import java.nio.file.Path; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Serialization Utils Test") +@NativeTag +@Tag(TagNames.FILE_IO) class SerializationUtilsTest extends BaseDL4JTest { @TempDir diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/TestUIDProvider.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/TestUIDProvider.java index 04a5b8742..b9a210a38 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/TestUIDProvider.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/TestUIDProvider.java @@ -22,10 +22,14 @@ package org.deeplearning4j.util; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.core.util.UIDProvider; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.FILE_IO) public class TestUIDProvider extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/TimeSeriesUtilsTest.java b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/TimeSeriesUtilsTest.java index 2c8e1dfb7..36beb47e3 100644 --- a/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/TimeSeriesUtilsTest.java +++ b/deeplearning4j/deeplearning4j-core/src/test/java/org/deeplearning4j/util/TimeSeriesUtilsTest.java @@ -20,7 +20,10 @@ package org.deeplearning4j.util; import org.deeplearning4j.BaseDL4JTest; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -29,6 +32,8 @@ import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; @DisplayName("Time Series Utils Test") +@NativeTag +@Tag(TagNames.FILE_IO) class TimeSeriesUtilsTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-cuda/pom.xml b/deeplearning4j/deeplearning4j-cuda/pom.xml index 1555915d7..3e929b025 100644 --- a/deeplearning4j/deeplearning4j-cuda/pom.xml +++ b/deeplearning4j/deeplearning4j-cuda/pom.xml @@ -80,14 +80,10 @@ org.junit.jupiter junit-jupiter-api - ${junit.version} - test org.junit.jupiter junit-jupiter-engine - ${junit.version} - test org.deeplearning4j @@ -95,6 +91,12 @@ ${project.version} test + + org.nd4j + nd4j-common-tests + ${project.version} + test + diff --git a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/CuDNNTestUtils.java b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/CuDNNTestUtils.java index 473449dbb..9674dee67 100644 --- a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/CuDNNTestUtils.java +++ b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/CuDNNTestUtils.java @@ -27,6 +27,7 @@ import org.deeplearning4j.nn.layers.normalization.BatchNormalization; import org.deeplearning4j.nn.layers.normalization.LocalResponseNormalization; import org.deeplearning4j.nn.layers.recurrent.LSTM; import org.nd4j.common.base.Preconditions; +import org.nd4j.common.tests.tags.NativeTag; import java.lang.reflect.Field; @@ -35,6 +36,7 @@ import java.lang.reflect.Field; * * @author Alex Black */ +@NativeTag public class CuDNNTestUtils { private CuDNNTestUtils(){ } diff --git a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/TestDataTypes.java b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/TestDataTypes.java index f055ea0f6..7bcb3aa37 100644 --- a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/TestDataTypes.java +++ b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/TestDataTypes.java @@ -26,7 +26,6 @@ import org.deeplearning4j.datasets.iterator.impl.MnistDataSetIterator; import org.deeplearning4j.nn.conf.ConvolutionMode; import org.deeplearning4j.nn.conf.MultiLayerConfiguration; import org.deeplearning4j.nn.conf.NeuralNetConfiguration; -import org.deeplearning4j.nn.conf.distribution.NormalDistribution; import org.deeplearning4j.nn.conf.inputs.InputType; import org.deeplearning4j.nn.conf.layers.BatchNormalization; import org.deeplearning4j.nn.conf.layers.ConvolutionLayer; @@ -34,28 +33,24 @@ import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.conf.layers.SubsamplingLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; -import org.junit.AfterClass; -import org.junit.BeforeClass; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.activations.Activation; -import org.nd4j.linalg.api.buffer.DataBuffer; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; -import org.nd4j.linalg.api.ops.executioner.OpExecutioner; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.factory.Nd4j; -import org.nd4j.linalg.learning.config.Adam; import org.nd4j.linalg.learning.config.Sgd; import org.nd4j.linalg.lossfunctions.LossFunctions; import java.lang.reflect.Field; import java.util.HashMap; -import java.util.List; import java.util.Map; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag public class TestDataTypes extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/ValidateCuDNN.java b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/ValidateCuDNN.java index cb2d27c9f..4b59b06ae 100644 --- a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/ValidateCuDNN.java +++ b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/ValidateCuDNN.java @@ -34,6 +34,7 @@ import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.cuda.util.CuDNNValidationUtil; import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.activations.IActivation; import org.nd4j.linalg.activations.impl.ActivationELU; import org.nd4j.linalg.activations.impl.ActivationIdentity; @@ -54,6 +55,7 @@ import java.util.Collections; import java.util.List; @Slf4j +@NativeTag public class ValidateCuDNN extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/convolution/ConvDataFormatTests.java b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/convolution/ConvDataFormatTests.java index eab97fd66..4e226b280 100644 --- a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/convolution/ConvDataFormatTests.java +++ b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/convolution/ConvDataFormatTests.java @@ -40,34 +40,44 @@ import org.deeplearning4j.nn.workspace.ArrayType; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; import org.junit.jupiter.api.Test; +import org.junit.jupiter.params.ParameterizedTest; +import org.junit.jupiter.params.provider.Arguments; +import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.common.primitives.Pair; +import org.nd4j.linalg.factory.Nd4jBackend; import java.util.ArrayList; import java.util.List; import java.util.Map; +import java.util.stream.Stream; import static org.junit.jupiter.api.Assertions.assertEquals; -@RunWith(Parameterized.class) +@NativeTag public class ConvDataFormatTests extends BaseDL4JTest { - private final DataType dataType; + - public ConvDataFormatTests(DataType dataType){ - this.dataType = dataType; + public static Stream params() { + List args = new ArrayList<>(); + for(Nd4jBackend nd4jBackend : BaseNd4jTestWithBackends.BACKENDS) { + for(DataType dataType : new DataType[]{DataType.FLOAT, DataType.DOUBLE}) { + args.add(Arguments.of(dataType,nd4jBackend)); + } + } + + return args.stream(); } - @Parameterized.Parameters(name = "{0}") - public static Object[] params(){ - return new DataType[]{DataType.FLOAT, DataType.DOUBLE}; - } - - @Test - public void testConv2d() { + @ParameterizedTest + @MethodSource("params") + public void testConv2d(DataType dataType, Nd4jBackend backend) { try { for (boolean helpers : new boolean[]{false, true}) { for (ConvolutionMode cm : new ConvolutionMode[]{ConvolutionMode.Truncate, ConvolutionMode.Same}) { @@ -76,15 +86,15 @@ public class ConvDataFormatTests extends BaseDL4JTest { String msg = helpers ? "With helpers (" + cm + ")" : "No helpers (" + cm + ")"; System.out.println(" --- " + msg + " ---"); - INDArray inNCHW = Nd4j.rand(this.dataType, 2, 3, 12, 12); + INDArray inNCHW = Nd4j.rand(dataType, 2, 3, 12, 12); INDArray labels = TestUtils.randomOneHot(2, 10); TestCase tc = TestCase.builder() .msg(msg) - .net1(getConv2dNet(CNN2DFormat.NCHW, true, cm)) - .net2(getConv2dNet(CNN2DFormat.NCHW, false, cm)) - .net3(getConv2dNet(CNN2DFormat.NHWC, true, cm)) - .net4(getConv2dNet(CNN2DFormat.NHWC, false, cm)) + .net1(getConv2dNet(dataType,CNN2DFormat.NCHW, true, cm)) + .net2(getConv2dNet(dataType,CNN2DFormat.NCHW, false, cm)) + .net3(getConv2dNet(dataType,CNN2DFormat.NHWC, true, cm)) + .net4(getConv2dNet(dataType,CNN2DFormat.NHWC, false, cm)) .inNCHW(inNCHW) .labelsNCHW(labels) .labelsNHWC(labels) @@ -100,8 +110,9 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - @Test - public void testSubsampling2d() { + @ParameterizedTest + @MethodSource("params") + public void testSubsampling2d(DataType dataType,Nd4jBackend backend) { try { for (boolean helpers : new boolean[]{false, true}) { for (ConvolutionMode cm : new ConvolutionMode[]{ConvolutionMode.Truncate, ConvolutionMode.Same}) { @@ -110,15 +121,15 @@ public class ConvDataFormatTests extends BaseDL4JTest { String msg = helpers ? "With helpers (" + cm + ")" : "No helpers (" + cm + ")"; System.out.println(" --- " + msg + " ---"); - INDArray inNCHW = Nd4j.rand(this.dataType, 2, 3, 12, 12); + INDArray inNCHW = Nd4j.rand(dataType, 2, 3, 12, 12); INDArray labels = TestUtils.randomOneHot(2, 10); TestCase tc = TestCase.builder() .msg(msg) - .net1(getSubsampling2dNet(CNN2DFormat.NCHW, true, cm)) - .net2(getSubsampling2dNet(CNN2DFormat.NCHW, false, cm)) - .net3(getSubsampling2dNet(CNN2DFormat.NHWC, true, cm)) - .net4(getSubsampling2dNet(CNN2DFormat.NHWC, false, cm)) + .net1(getSubsampling2dNet(dataType,CNN2DFormat.NCHW, true, cm)) + .net2(getSubsampling2dNet(dataType,CNN2DFormat.NCHW, false, cm)) + .net3(getSubsampling2dNet(dataType,CNN2DFormat.NHWC, true, cm)) + .net4(getSubsampling2dNet(dataType,CNN2DFormat.NHWC, false, cm)) .inNCHW(inNCHW) .labelsNCHW(labels) .labelsNHWC(labels) @@ -134,8 +145,9 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - @Test - public void testDepthwiseConv2d() { + @ParameterizedTest + @MethodSource("params") + public void testDepthwiseConv2d(DataType dataType,Nd4jBackend backend) { try { for (boolean helpers : new boolean[]{false, true}) { for (ConvolutionMode cm : new ConvolutionMode[]{ConvolutionMode.Truncate, ConvolutionMode.Same}) { @@ -144,15 +156,15 @@ public class ConvDataFormatTests extends BaseDL4JTest { String msg = helpers ? "With helpers (" + cm + ")" : "No helpers (" + cm + ")"; System.out.println(" --- " + msg + " ---"); - INDArray inNCHW = Nd4j.rand(this.dataType, 2, 3, 12, 12); + INDArray inNCHW = Nd4j.rand(dataType, 2, 3, 12, 12); INDArray labels = TestUtils.randomOneHot(2, 10); TestCase tc = TestCase.builder() .msg(msg) - .net1(getDepthwiseConv2dNet(CNN2DFormat.NCHW, true, cm)) - .net2(getDepthwiseConv2dNet(CNN2DFormat.NCHW, false, cm)) - .net3(getDepthwiseConv2dNet(CNN2DFormat.NHWC, true, cm)) - .net4(getDepthwiseConv2dNet(CNN2DFormat.NHWC, false, cm)) + .net1(getDepthwiseConv2dNet(dataType,CNN2DFormat.NCHW, true, cm)) + .net2(getDepthwiseConv2dNet(dataType,CNN2DFormat.NCHW, false, cm)) + .net3(getDepthwiseConv2dNet(dataType,CNN2DFormat.NHWC, true, cm)) + .net4(getDepthwiseConv2dNet(dataType,CNN2DFormat.NHWC, false, cm)) .inNCHW(inNCHW) .labelsNCHW(labels) .labelsNHWC(labels) @@ -168,8 +180,9 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - @Test - public void testSeparableConv2d() { + @ParameterizedTest + @MethodSource("params") + public void testSeparableConv2d(DataType dataType, Nd4jBackend backend) { try { for (boolean helpers : new boolean[]{false, true}) { for (ConvolutionMode cm : new ConvolutionMode[]{ConvolutionMode.Truncate, ConvolutionMode.Same}) { @@ -178,15 +191,15 @@ public class ConvDataFormatTests extends BaseDL4JTest { String msg = helpers ? "With helpers (" + cm + ")" : "No helpers (" + cm + ")"; System.out.println(" --- " + msg + " ---"); - INDArray inNCHW = Nd4j.rand(this.dataType, 2, 3, 12, 12); + INDArray inNCHW = Nd4j.rand(dataType, 2, 3, 12, 12); INDArray labels = TestUtils.randomOneHot(2, 10); TestCase tc = TestCase.builder() .msg(msg) - .net1(getSeparableConv2dNet(CNN2DFormat.NCHW, true, cm)) - .net2(getSeparableConv2dNet(CNN2DFormat.NCHW, false, cm)) - .net3(getSeparableConv2dNet(CNN2DFormat.NHWC, true, cm)) - .net4(getSeparableConv2dNet(CNN2DFormat.NHWC, false, cm)) + .net1(getSeparableConv2dNet(dataType,CNN2DFormat.NCHW, true, cm)) + .net2(getSeparableConv2dNet(dataType,CNN2DFormat.NCHW, false, cm)) + .net3(getSeparableConv2dNet(dataType,CNN2DFormat.NHWC, true, cm)) + .net4(getSeparableConv2dNet(dataType,CNN2DFormat.NHWC, false, cm)) .inNCHW(inNCHW) .labelsNCHW(labels) .labelsNHWC(labels) @@ -201,8 +214,9 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - @Test - public void testDeconv2d() { + @ParameterizedTest + @MethodSource("params") + public void testDeconv2d(DataType dataType,Nd4jBackend backend) { try { for (boolean helpers : new boolean[]{false, true}) { for (ConvolutionMode cm : new ConvolutionMode[]{ConvolutionMode.Truncate, ConvolutionMode.Same}) { @@ -211,15 +225,15 @@ public class ConvDataFormatTests extends BaseDL4JTest { String msg = helpers ? "With helpers (" + cm + ")" : "No helpers (" + cm + ")"; System.out.println(" --- " + msg + " ---"); - INDArray inNCHW = Nd4j.rand(this.dataType, 2, 3, 12, 12); + INDArray inNCHW = Nd4j.rand(dataType, 2, 3, 12, 12); INDArray labels = TestUtils.randomOneHot(2, 10); TestCase tc = TestCase.builder() .msg(msg) - .net1(getDeconv2DNet2dNet(CNN2DFormat.NCHW, true, cm)) - .net2(getDeconv2DNet2dNet(CNN2DFormat.NCHW, false, cm)) - .net3(getDeconv2DNet2dNet(CNN2DFormat.NHWC, true, cm)) - .net4(getDeconv2DNet2dNet(CNN2DFormat.NHWC, false, cm)) + .net1(getDeconv2DNet2dNet(dataType,CNN2DFormat.NCHW, true, cm)) + .net2(getDeconv2DNet2dNet(dataType,CNN2DFormat.NCHW, false, cm)) + .net3(getDeconv2DNet2dNet(dataType,CNN2DFormat.NHWC, true, cm)) + .net4(getDeconv2DNet2dNet(dataType,CNN2DFormat.NHWC, false, cm)) .inNCHW(inNCHW) .labelsNCHW(labels) .labelsNHWC(labels) @@ -235,8 +249,9 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - @Test - public void testLRN() { + @ParameterizedTest + @MethodSource("params") + public void testLRN(DataType dataType,Nd4jBackend backend) { try { for (boolean helpers : new boolean[]{false, true}) { for (ConvolutionMode cm : new ConvolutionMode[]{ConvolutionMode.Truncate, ConvolutionMode.Same}) { @@ -245,15 +260,15 @@ public class ConvDataFormatTests extends BaseDL4JTest { String msg = helpers ? "With helpers (" + cm + ")" : "No helpers (" + cm + ")"; System.out.println(" --- " + msg + " ---"); - INDArray inNCHW = Nd4j.rand(this.dataType, 2, 3, 12, 12); + INDArray inNCHW = Nd4j.rand(dataType, 2, 3, 12, 12); INDArray labels = TestUtils.randomOneHot(2, 10); TestCase tc = TestCase.builder() .msg(msg) - .net1(getLrnLayer(CNN2DFormat.NCHW, true, cm)) - .net2(getLrnLayer(CNN2DFormat.NCHW, false, cm)) - .net3(getLrnLayer(CNN2DFormat.NHWC, true, cm)) - .net4(getLrnLayer(CNN2DFormat.NHWC, false, cm)) + .net1(getLrnLayer(dataType,CNN2DFormat.NCHW, true, cm)) + .net2(getLrnLayer(dataType,CNN2DFormat.NCHW, false, cm)) + .net3(getLrnLayer(dataType,CNN2DFormat.NHWC, true, cm)) + .net4(getLrnLayer(dataType,CNN2DFormat.NHWC, false, cm)) .inNCHW(inNCHW) .labelsNCHW(labels) .labelsNHWC(labels) @@ -269,8 +284,9 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - @Test - public void testZeroPaddingLayer(){ + @ParameterizedTest + @MethodSource("params") + public void testZeroPaddingLayer(DataType dataType,Nd4jBackend backend) { try { for (boolean helpers : new boolean[]{false, true}) { Nd4j.getRandom().setSeed(12345); @@ -278,15 +294,15 @@ public class ConvDataFormatTests extends BaseDL4JTest { String msg = helpers ? "With helpers" : "No helpers"; System.out.println(" --- " + msg + " ---"); - INDArray inNCHW = Nd4j.rand(this.dataType, 2, 3, 12, 12); + INDArray inNCHW = Nd4j.rand(dataType, 2, 3, 12, 12); INDArray labels = TestUtils.randomOneHot(2, 10); TestCase tc = TestCase.builder() .msg(msg) - .net1(getZeroPaddingNet(CNN2DFormat.NCHW, true)) - .net2(getZeroPaddingNet(CNN2DFormat.NCHW, false)) - .net3(getZeroPaddingNet(CNN2DFormat.NHWC, true)) - .net4(getZeroPaddingNet(CNN2DFormat.NHWC, false)) + .net1(getZeroPaddingNet(dataType,CNN2DFormat.NCHW, true)) + .net2(getZeroPaddingNet(dataType,CNN2DFormat.NCHW, false)) + .net3(getZeroPaddingNet(dataType,CNN2DFormat.NHWC, true)) + .net4(getZeroPaddingNet(dataType,CNN2DFormat.NHWC, false)) .inNCHW(inNCHW) .labelsNCHW(labels) .labelsNHWC(labels) @@ -301,8 +317,9 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - @Test - public void testCropping2DLayer(){ + @ParameterizedTest + @MethodSource("params") + public void testCropping2DLayer(DataType dataType,Nd4jBackend backend) { try { for (boolean helpers : new boolean[]{false, true}) { Nd4j.getRandom().setSeed(12345); @@ -310,15 +327,15 @@ public class ConvDataFormatTests extends BaseDL4JTest { String msg = helpers ? "With helpers" : "No helpers"; System.out.println(" --- " + msg + " ---"); - INDArray inNCHW = Nd4j.rand(this.dataType, 2, 3, 12, 12); + INDArray inNCHW = Nd4j.rand(dataType, 2, 3, 12, 12); INDArray labels = TestUtils.randomOneHot(2, 10); TestCase tc = TestCase.builder() .msg(msg) - .net1(getCropping2dNet(CNN2DFormat.NCHW, true)) - .net2(getCropping2dNet(CNN2DFormat.NCHW, false)) - .net3(getCropping2dNet(CNN2DFormat.NHWC, true)) - .net4(getCropping2dNet(CNN2DFormat.NHWC, false)) + .net1(getCropping2dNet(dataType,CNN2DFormat.NCHW, true)) + .net2(getCropping2dNet(dataType,CNN2DFormat.NCHW, false)) + .net3(getCropping2dNet(dataType,CNN2DFormat.NHWC, true)) + .net4(getCropping2dNet(dataType,CNN2DFormat.NHWC, false)) .inNCHW(inNCHW) .labelsNCHW(labels) .labelsNHWC(labels) @@ -333,8 +350,9 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - @Test - public void testUpsampling2d(){ + @ParameterizedTest + @MethodSource("params") + public void testUpsampling2d(DataType dataType,Nd4jBackend backend) { try { for (boolean helpers : new boolean[]{false, true}) { Nd4j.getRandom().setSeed(12345); @@ -342,15 +360,15 @@ public class ConvDataFormatTests extends BaseDL4JTest { String msg = helpers ? "With helpers" : "No helpers"; System.out.println(" --- " + msg + " ---"); - INDArray inNCHW = Nd4j.rand(this.dataType, 2, 3, 12, 12); + INDArray inNCHW = Nd4j.rand(dataType, 2, 3, 12, 12); INDArray labels = TestUtils.randomOneHot(2, 10); TestCase tc = TestCase.builder() .msg(msg) - .net1(getUpsamplingNet(CNN2DFormat.NCHW, true)) - .net2(getUpsamplingNet(CNN2DFormat.NCHW, false)) - .net3(getUpsamplingNet(CNN2DFormat.NHWC, true)) - .net4(getUpsamplingNet(CNN2DFormat.NHWC, false)) + .net1(getUpsamplingNet(dataType,CNN2DFormat.NCHW, true)) + .net2(getUpsamplingNet(dataType,CNN2DFormat.NCHW, false)) + .net3(getUpsamplingNet(dataType,CNN2DFormat.NHWC, true)) + .net4(getUpsamplingNet(dataType,CNN2DFormat.NHWC, false)) .inNCHW(inNCHW) .labelsNCHW(labels) .labelsNHWC(labels) @@ -365,8 +383,9 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - @Test - public void testBatchNormNet(){ + @ParameterizedTest + @MethodSource("params") + public void testBatchNormNet(DataType dataType,Nd4jBackend backend) { try { for(boolean useLogStd : new boolean[]{true, false}) { for (boolean helpers : new boolean[]{false, true}) { @@ -375,15 +394,15 @@ public class ConvDataFormatTests extends BaseDL4JTest { String msg = (helpers ? "With helpers" : "No helpers") + " - " + (useLogStd ? "logstd" : "std"); System.out.println(" --- " + msg + " ---"); - INDArray inNCHW = Nd4j.rand(this.dataType, 2, 3, 12, 12); + INDArray inNCHW = Nd4j.rand(dataType, 2, 3, 12, 12); INDArray labels = TestUtils.randomOneHot(2, 10); TestCase tc = TestCase.builder() .msg(msg) - .net1(getBatchNormNet(useLogStd, CNN2DFormat.NCHW, true)) - .net2(getBatchNormNet(useLogStd, CNN2DFormat.NCHW, false)) - .net3(getBatchNormNet(useLogStd, CNN2DFormat.NHWC, true)) - .net4(getBatchNormNet(useLogStd, CNN2DFormat.NHWC, false)) + .net1(getBatchNormNet(dataType,useLogStd, CNN2DFormat.NCHW, true)) + .net2(getBatchNormNet(dataType,useLogStd, CNN2DFormat.NCHW, false)) + .net3(getBatchNormNet(dataType,useLogStd, CNN2DFormat.NHWC, true)) + .net4(getBatchNormNet(dataType,useLogStd, CNN2DFormat.NHWC, false)) .inNCHW(inNCHW) .labelsNCHW(labels) .labelsNHWC(labels) @@ -399,8 +418,9 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - @Test - public void testCnnLossLayer() { + @ParameterizedTest + @MethodSource("params") + public void testCnnLossLayer(DataType dataType,Nd4jBackend backend) { try { for (boolean helpers : new boolean[]{false, true}) { Nd4j.getRandom().setSeed(12345); @@ -408,8 +428,8 @@ public class ConvDataFormatTests extends BaseDL4JTest { String msg = helpers ? "With helpers" : "No helpers"; System.out.println(" --- " + msg + " ---"); - INDArray inNCHW = Nd4j.rand(this.dataType, 2, 3, 12, 12); - INDArray labelsNHWC = TestUtils.randomOneHot(this.dataType,2*6*6, 3); + INDArray inNCHW = Nd4j.rand(dataType, 2, 3, 12, 12); + INDArray labelsNHWC = TestUtils.randomOneHot(dataType,2*6*6, 3); labelsNHWC = labelsNHWC.reshape(2,6,6,3); INDArray labelsNCHW = labelsNHWC.permute(0,3,1,2).dup(); @@ -436,8 +456,9 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - @Test - public void testSpaceToDepthNet(){ + @ParameterizedTest + @MethodSource("params") + public void testSpaceToDepthNet(DataType dataType,Nd4jBackend backend) { try { for (boolean helpers : new boolean[]{false, true}) { Nd4j.getRandom().setSeed(12345); @@ -445,15 +466,15 @@ public class ConvDataFormatTests extends BaseDL4JTest { String msg = helpers ? "With helpers" : "No helpers"; System.out.println(" --- " + msg + " ---"); - INDArray inNCHW = Nd4j.rand(this.dataType, 2, 3, 12, 12); + INDArray inNCHW = Nd4j.rand(dataType, 2, 3, 12, 12); INDArray labels = TestUtils.randomOneHot(2, 10); TestCase tc = TestCase.builder() .msg(msg) - .net1(getSpaceToDepthNet(CNN2DFormat.NCHW, true)) - .net2(getSpaceToDepthNet(CNN2DFormat.NCHW, false)) - .net3(getSpaceToDepthNet(CNN2DFormat.NHWC, true)) - .net4(getSpaceToDepthNet(CNN2DFormat.NHWC, false)) + .net1(getSpaceToDepthNet(dataType,CNN2DFormat.NCHW, true)) + .net2(getSpaceToDepthNet(dataType,CNN2DFormat.NCHW, false)) + .net3(getSpaceToDepthNet(dataType,CNN2DFormat.NHWC, true)) + .net4(getSpaceToDepthNet(dataType,CNN2DFormat.NHWC, false)) .inNCHW(inNCHW) .labelsNCHW(labels) .labelsNHWC(labels) @@ -468,8 +489,9 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - @Test - public void testSpaceToBatchNet(){ + @ParameterizedTest + @MethodSource("params") + public void testSpaceToBatchNet(DataType dataType,Nd4jBackend backend) { try { for (boolean helpers : new boolean[]{false, true}) { Nd4j.getRandom().setSeed(12345); @@ -477,15 +499,15 @@ public class ConvDataFormatTests extends BaseDL4JTest { String msg = helpers ? "With helpers" : "No helpers"; System.out.println(" --- " + msg + " ---"); - INDArray inNCHW = Nd4j.rand(this.dataType, 2, 3, 16, 16); + INDArray inNCHW = Nd4j.rand(dataType, 2, 3, 16, 16); INDArray labels = TestUtils.randomOneHot(8, 10); TestCase tc = TestCase.builder() .msg(msg) - .net1(getSpaceToBatchNet(CNN2DFormat.NCHW, true)) - .net2(getSpaceToBatchNet(CNN2DFormat.NCHW, false)) - .net3(getSpaceToBatchNet(CNN2DFormat.NHWC, true)) - .net4(getSpaceToBatchNet(CNN2DFormat.NHWC, false)) + .net1(getSpaceToBatchNet(dataType,CNN2DFormat.NCHW, true)) + .net2(getSpaceToBatchNet(dataType,CNN2DFormat.NCHW, false)) + .net3(getSpaceToBatchNet(dataType,CNN2DFormat.NHWC, true)) + .net4(getSpaceToBatchNet(dataType,CNN2DFormat.NHWC, false)) .inNCHW(inNCHW) .labelsNCHW(labels) .labelsNHWC(labels) @@ -500,8 +522,9 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - @Test - public void testLocallyConnected() { + @ParameterizedTest + @MethodSource("params") + public void testLocallyConnected(DataType dataType,Nd4jBackend backend) { try { for (boolean helpers : new boolean[]{false, true}) { for (ConvolutionMode cm : new ConvolutionMode[]{ConvolutionMode.Truncate, ConvolutionMode.Same}) { @@ -510,15 +533,15 @@ public class ConvDataFormatTests extends BaseDL4JTest { String msg = helpers ? "With helpers (" + cm + ")" : "No helpers (" + cm + ")"; System.out.println(" --- " + msg + " ---"); - INDArray inNCHW = Nd4j.rand(this.dataType, 2, 3, 12, 12); + INDArray inNCHW = Nd4j.rand(dataType, 2, 3, 12, 12); INDArray labels = TestUtils.randomOneHot(2, 10); TestCase tc = TestCase.builder() .msg(msg) - .net1(getLocallyConnectedNet(CNN2DFormat.NCHW, true, cm)) - .net2(getLocallyConnectedNet(CNN2DFormat.NCHW, false, cm)) - .net3(getLocallyConnectedNet(CNN2DFormat.NHWC, true, cm)) - .net4(getLocallyConnectedNet(CNN2DFormat.NHWC, false, cm)) + .net1(getLocallyConnectedNet(dataType,CNN2DFormat.NCHW, true, cm)) + .net2(getLocallyConnectedNet(dataType,CNN2DFormat.NCHW, false, cm)) + .net3(getLocallyConnectedNet(dataType,CNN2DFormat.NHWC, true, cm)) + .net4(getLocallyConnectedNet(dataType,CNN2DFormat.NHWC, false, cm)) .inNCHW(inNCHW) .labelsNCHW(labels) .labelsNHWC(labels) @@ -534,8 +557,9 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - @Test - public void testGlobalPooling() { + @ParameterizedTest + @MethodSource("params") + public void testGlobalPooling(DataType dataType,Nd4jBackend backend) { try { for (boolean helpers : new boolean[]{false, true}) { for (PoolingType pt : PoolingType.values()) { @@ -544,15 +568,15 @@ public class ConvDataFormatTests extends BaseDL4JTest { String msg = helpers ? "With helpers (" + pt + ")" : "No helpers (" + pt + ")"; System.out.println(" --- " + msg + " ---"); - INDArray inNCHW = Nd4j.rand(this.dataType, 2, 3, 12, 12); + INDArray inNCHW = Nd4j.rand(dataType, 2, 3, 12, 12); INDArray labels = TestUtils.randomOneHot(2, 10); TestCase tc = TestCase.builder() .msg(msg) - .net1(getGlobalPoolingNet(CNN2DFormat.NCHW, pt, true)) - .net2(getGlobalPoolingNet(CNN2DFormat.NCHW, pt, false)) - .net3(getGlobalPoolingNet(CNN2DFormat.NHWC, pt, true)) - .net4(getGlobalPoolingNet(CNN2DFormat.NHWC, pt, false)) + .net1(getGlobalPoolingNet(dataType,CNN2DFormat.NCHW, pt, true)) + .net2(getGlobalPoolingNet(dataType,CNN2DFormat.NCHW, pt, false)) + .net3(getGlobalPoolingNet(dataType,CNN2DFormat.NHWC, pt, true)) + .net4(getGlobalPoolingNet(dataType,CNN2DFormat.NHWC, pt, false)) .inNCHW(inNCHW) .labelsNCHW(labels) .labelsNHWC(labels) @@ -567,9 +591,9 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - private MultiLayerNetwork getConv2dNet(CNN2DFormat format, boolean setOnLayerAlso, ConvolutionMode cm) { + private MultiLayerNetwork getConv2dNet(DataType dataType,CNN2DFormat format, boolean setOnLayerAlso, ConvolutionMode cm) { if (setOnLayerAlso) { - return getNetWithLayer(new ConvolutionLayer.Builder() + return getNetWithLayer(dataType,new ConvolutionLayer.Builder() .kernelSize(3, 3) .stride(2, 2) .activation(Activation.TANH) @@ -578,7 +602,7 @@ public class ConvDataFormatTests extends BaseDL4JTest { .helperAllowFallback(false) .build(), format, cm, null); } else { - return getNetWithLayer(new ConvolutionLayer.Builder() + return getNetWithLayer(dataType,new ConvolutionLayer.Builder() .kernelSize(3, 3) .stride(2, 2) .activation(Activation.TANH) @@ -588,16 +612,16 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - private MultiLayerNetwork getSubsampling2dNet(CNN2DFormat format, boolean setOnLayerAlso, ConvolutionMode cm) { + private MultiLayerNetwork getSubsampling2dNet(DataType dataType,CNN2DFormat format, boolean setOnLayerAlso, ConvolutionMode cm) { if (setOnLayerAlso) { - return getNetWithLayer(new SubsamplingLayer.Builder() + return getNetWithLayer(dataType,new SubsamplingLayer.Builder() .kernelSize(2, 2) .stride(1, 1) .dataFormat(format) .helperAllowFallback(false) .build(), format, cm, null); } else { - return getNetWithLayer(new SubsamplingLayer.Builder() + return getNetWithLayer(dataType,new SubsamplingLayer.Builder() .kernelSize(2, 2) .stride(1, 1) .helperAllowFallback(false) @@ -605,9 +629,9 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - private MultiLayerNetwork getSeparableConv2dNet(CNN2DFormat format, boolean setOnLayerAlso, ConvolutionMode cm) { + private MultiLayerNetwork getSeparableConv2dNet(DataType dataType,CNN2DFormat format, boolean setOnLayerAlso, ConvolutionMode cm) { if (setOnLayerAlso) { - return getNetWithLayer(new SeparableConvolution2D.Builder() + return getNetWithLayer(dataType,new SeparableConvolution2D.Builder() .kernelSize(3, 3) .stride(2, 2) .activation(Activation.TANH) @@ -616,7 +640,7 @@ public class ConvDataFormatTests extends BaseDL4JTest { .helperAllowFallback(false) .build(), format, cm, null); } else { - return getNetWithLayer(new SeparableConvolution2D.Builder() + return getNetWithLayer(dataType,new SeparableConvolution2D.Builder() .kernelSize(3, 3) .stride(2, 2) .activation(Activation.TANH) @@ -626,9 +650,9 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - private MultiLayerNetwork getDepthwiseConv2dNet(CNN2DFormat format, boolean setOnLayerAlso, ConvolutionMode cm) { + private MultiLayerNetwork getDepthwiseConv2dNet(DataType dataType,CNN2DFormat format, boolean setOnLayerAlso, ConvolutionMode cm) { if (setOnLayerAlso) { - return getNetWithLayer(new DepthwiseConvolution2D.Builder() + return getNetWithLayer(dataType,new DepthwiseConvolution2D.Builder() .depthMultiplier(2) .kernelSize(3, 3) .stride(2, 2) @@ -638,7 +662,7 @@ public class ConvDataFormatTests extends BaseDL4JTest { .helperAllowFallback(false) .build(), format, cm, null); } else { - return getNetWithLayer(new DepthwiseConvolution2D.Builder() + return getNetWithLayer(dataType,new DepthwiseConvolution2D.Builder() .depthMultiplier(2) .kernelSize(3, 3) .stride(2, 2) @@ -649,58 +673,58 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - private MultiLayerNetwork getLrnLayer(CNN2DFormat format, boolean setOnLayerAlso, ConvolutionMode cm) { + private MultiLayerNetwork getLrnLayer(DataType dataType,CNN2DFormat format, boolean setOnLayerAlso, ConvolutionMode cm) { if (setOnLayerAlso) { - return getNetWithLayer(new LocalResponseNormalization.Builder() + return getNetWithLayer(dataType,new LocalResponseNormalization.Builder() .dataFormat(format) .helperAllowFallback(false) .build(), format, cm, null); } else { - return getNetWithLayer(new LocalResponseNormalization.Builder() + return getNetWithLayer(dataType,new LocalResponseNormalization.Builder() .helperAllowFallback(false) .build(), format, cm, null); } } - private MultiLayerNetwork getZeroPaddingNet(CNN2DFormat format, boolean setOnLayerAlso) { + private MultiLayerNetwork getZeroPaddingNet(DataType dataType,CNN2DFormat format, boolean setOnLayerAlso) { if (setOnLayerAlso) { - return getNetWithLayer(new ZeroPaddingLayer.Builder(2,2) + return getNetWithLayer(dataType,new ZeroPaddingLayer.Builder(2,2) .dataFormat(format).build(), format, ConvolutionMode.Same, null); } else { - return getNetWithLayer(new ZeroPaddingLayer.Builder(2,2).build(), + return getNetWithLayer(dataType,new ZeroPaddingLayer.Builder(2,2).build(), format, ConvolutionMode.Same, null); } } - private MultiLayerNetwork getCropping2dNet(CNN2DFormat format, boolean setOnLayerAlso) { + private MultiLayerNetwork getCropping2dNet(DataType dataType,CNN2DFormat format, boolean setOnLayerAlso) { if (setOnLayerAlso) { - return getNetWithLayer(new Cropping2D.Builder(2,2) + return getNetWithLayer(dataType,new Cropping2D.Builder(2,2) .dataFormat(format).build(), format, ConvolutionMode.Same, null); } else { - return getNetWithLayer(new Cropping2D.Builder(2,2) + return getNetWithLayer(dataType,new Cropping2D.Builder(2,2) .build(), format, ConvolutionMode.Same, null); } } - private MultiLayerNetwork getUpsamplingNet(CNN2DFormat format, boolean setOnLayerAlso) { + private MultiLayerNetwork getUpsamplingNet(DataType dataType,CNN2DFormat format, boolean setOnLayerAlso) { if (setOnLayerAlso) { - return getNetWithLayer(new Upsampling2D.Builder(2) + return getNetWithLayer(dataType,new Upsampling2D.Builder(2) .dataFormat(format).build(), format, ConvolutionMode.Same, null); } else { - return getNetWithLayer(new Upsampling2D.Builder(2) + return getNetWithLayer(dataType,new Upsampling2D.Builder(2) .build(), format, ConvolutionMode.Same, null); } } - private MultiLayerNetwork getDeconv2DNet2dNet(CNN2DFormat format, boolean setOnLayerAlso, ConvolutionMode cm) { + private MultiLayerNetwork getDeconv2DNet2dNet(DataType dataType,CNN2DFormat format, boolean setOnLayerAlso, ConvolutionMode cm) { if (setOnLayerAlso) { - return getNetWithLayer(new Deconvolution2D.Builder().nOut(2) + return getNetWithLayer(dataType,new Deconvolution2D.Builder().nOut(2) .activation(Activation.TANH) .kernelSize(2,2) .stride(2,2) .build(), format, cm, null); } else { - return getNetWithLayer(new Deconvolution2D.Builder().nOut(2) + return getNetWithLayer(dataType,new Deconvolution2D.Builder().nOut(2) .activation(Activation.TANH) .kernelSize(2,2) .stride(2,2) @@ -708,50 +732,50 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - private MultiLayerNetwork getBatchNormNet(boolean logStdev, CNN2DFormat format, boolean setOnLayerAlso) { + private MultiLayerNetwork getBatchNormNet(DataType dataType,boolean logStdev, CNN2DFormat format, boolean setOnLayerAlso) { if (setOnLayerAlso) { - return getNetWithLayer(new BatchNormalization.Builder() + return getNetWithLayer(dataType,new BatchNormalization.Builder() .useLogStd(logStdev) .dataFormat(format) .helperAllowFallback(false) .nOut(3).build(), format, ConvolutionMode.Same, null); } else { - return getNetWithLayer(new BatchNormalization.Builder() + return getNetWithLayer(dataType,new BatchNormalization.Builder() .useLogStd(logStdev) .helperAllowFallback(false) .nOut(3).build(), format, ConvolutionMode.Same, null); } } - private MultiLayerNetwork getSpaceToDepthNet(CNN2DFormat format, boolean setOnLayerAlso) { + private MultiLayerNetwork getSpaceToDepthNet(DataType dataType,CNN2DFormat format, boolean setOnLayerAlso) { if (setOnLayerAlso) { - return getNetWithLayer(new SpaceToDepthLayer.Builder() + return getNetWithLayer(dataType,new SpaceToDepthLayer.Builder() .blocks(2) .dataFormat(format) .build(), format, ConvolutionMode.Same, null); } else { - return getNetWithLayer(new SpaceToDepthLayer.Builder() + return getNetWithLayer(dataType,new SpaceToDepthLayer.Builder() .blocks(2) .build(), format, ConvolutionMode.Same, null); } } - private MultiLayerNetwork getSpaceToBatchNet(CNN2DFormat format, boolean setOnLayerAlso) { + private MultiLayerNetwork getSpaceToBatchNet(DataType dataType,CNN2DFormat format, boolean setOnLayerAlso) { if (setOnLayerAlso) { - return getNetWithLayer(new SpaceToBatchLayer.Builder() + return getNetWithLayer(dataType,new SpaceToBatchLayer.Builder() .blocks(2, 2) .dataFormat(format) .build(), format, ConvolutionMode.Same, InputType.convolutional(16, 16, 3, format)); } else { - return getNetWithLayer(new SpaceToBatchLayer.Builder() + return getNetWithLayer(dataType,new SpaceToBatchLayer.Builder() .blocks(2, 2) .build(), format, ConvolutionMode.Same, InputType.convolutional(16, 16, 3, format)); } } - private MultiLayerNetwork getLocallyConnectedNet(CNN2DFormat format, boolean setOnLayerAlso, ConvolutionMode cm) { + private MultiLayerNetwork getLocallyConnectedNet(DataType dataType,CNN2DFormat format, boolean setOnLayerAlso, ConvolutionMode cm) { if (setOnLayerAlso) { - return getNetWithLayer(new LocallyConnected2D.Builder() + return getNetWithLayer(dataType,new LocallyConnected2D.Builder() .kernelSize(3, 3) .stride(2, 2) .activation(Activation.TANH) @@ -759,7 +783,7 @@ public class ConvDataFormatTests extends BaseDL4JTest { .nOut(3) .build(), format, cm, null); } else { - return getNetWithLayer(new LocallyConnected2D.Builder() + return getNetWithLayer(dataType,new LocallyConnected2D.Builder() .kernelSize(3, 3) .stride(2, 2) .activation(Activation.TANH) @@ -768,13 +792,13 @@ public class ConvDataFormatTests extends BaseDL4JTest { } } - private MultiLayerNetwork getGlobalPoolingNet(CNN2DFormat format, PoolingType pt, boolean setOnLayerAlso) { + private MultiLayerNetwork getGlobalPoolingNet(DataType dataType,CNN2DFormat format, PoolingType pt, boolean setOnLayerAlso) { if (setOnLayerAlso) { - return getNetWithLayer(new GlobalPoolingLayer.Builder(pt) + return getNetWithLayer(dataType,new GlobalPoolingLayer.Builder(pt) .poolingDimensions(format == CNN2DFormat.NCHW ? new int[]{2,3} : new int[]{1,2}) .build(), format, ConvolutionMode.Same, null); } else { - return getNetWithLayer(new GlobalPoolingLayer.Builder(pt) + return getNetWithLayer(dataType,new GlobalPoolingLayer.Builder(pt) .build(), format, ConvolutionMode.Same, null); } } @@ -805,9 +829,9 @@ public class ConvDataFormatTests extends BaseDL4JTest { return net; } - private MultiLayerNetwork getNetWithLayer(Layer layer, CNN2DFormat format, ConvolutionMode cm, InputType inputType) { + private MultiLayerNetwork getNetWithLayer(DataType dataType,Layer layer, CNN2DFormat format, ConvolutionMode cm, InputType inputType) { NeuralNetConfiguration.ListBuilder builder = new NeuralNetConfiguration.Builder() - .dataType(this.dataType) + .dataType(dataType) .seed(12345) .convolutionMode(cm) .list() @@ -879,13 +903,13 @@ public class ConvDataFormatTests extends BaseDL4JTest { INDArray l0_3 = tc.net3.feedForward(inNHWC).get(tc.testLayerIdx + 1); INDArray l0_4 = tc.net4.feedForward(inNHWC).get(tc.testLayerIdx + 1); - assertEquals(tc.msg, l0_1, l0_2); + assertEquals(l0_1, l0_2, tc.msg); if(l0_1.rank() == 4) { - assertEquals(tc.msg, l0_1, l0_3.permute(0, 3, 1, 2)); - assertEquals(tc.msg, l0_1, l0_4.permute(0, 3, 1, 2)); + assertEquals(l0_1, l0_3.permute(0, 3, 1, 2), tc.msg); + assertEquals(l0_1, l0_4.permute(0, 3, 1, 2), tc.msg); } else { - assertEquals(tc.msg, l0_1, l0_3); - assertEquals(tc.msg, l0_1, l0_4); + assertEquals(l0_1, l0_3, tc.msg); + assertEquals(l0_1, l0_4, tc.msg); } @@ -894,13 +918,13 @@ public class ConvDataFormatTests extends BaseDL4JTest { INDArray out3 = tc.net3.output(inNHWC); INDArray out4 = tc.net4.output(inNHWC); - assertEquals(tc.msg, out1, out2); + assertEquals(out1, out2, tc.msg); if(!tc.nhwcOutput) { - assertEquals(tc.msg, out1, out3); - assertEquals(tc.msg, out1, out4); + assertEquals(out1, out3, tc.msg); + assertEquals(out1, out4, tc.msg); } else { - assertEquals(tc.msg, out1, out3.permute(0,3,1,2)); //NHWC to NCHW - assertEquals(tc.msg, out1, out4.permute(0,3,1,2)); + assertEquals(out1, out3.permute(0,3,1,2), tc.msg); //NHWC to NCHW + assertEquals(out1, out4.permute(0,3,1,2), tc.msg); } //Test backprop @@ -910,29 +934,29 @@ public class ConvDataFormatTests extends BaseDL4JTest { Pair p4 = tc.net4.calculateGradients(inNHWC, tc.labelsNHWC, null, null); //Inpput gradients - assertEquals(tc.msg, p1.getSecond(), p2.getSecond()); - assertEquals(tc.msg, p1.getSecond(), p3.getSecond().permute(0,3,1,2)); //Input gradients for NHWC input are also in NHWC format - assertEquals(tc.msg, p1.getSecond(), p4.getSecond().permute(0,3,1,2)); + assertEquals(p1.getSecond(), p2.getSecond(), tc.msg); + assertEquals(p1.getSecond(), p3.getSecond().permute(0,3,1,2), tc.msg); //Input gradients for NHWC input are also in NHWC format + assertEquals(p1.getSecond(), p4.getSecond().permute(0,3,1,2), tc.msg); List diff12 = differentGrads(p1.getFirst(), p2.getFirst()); List diff13 = differentGrads(p1.getFirst(), p3.getFirst()); List diff14 = differentGrads(p1.getFirst(), p4.getFirst()); - assertEquals(tc.msg + " " + diff12, 0, diff12.size()); - assertEquals(tc.msg + " " + diff13, 0, diff13.size()); - assertEquals(tc.msg + " " + diff14, 0, diff14.size()); + assertEquals(0, diff12.size(),tc.msg + " " + diff12); + assertEquals( 0, diff13.size(),tc.msg + " " + diff13); + assertEquals(0, diff14.size(),tc.msg + " " + diff14); - assertEquals(tc.msg, p1.getFirst().gradientForVariable(), p2.getFirst().gradientForVariable()); - assertEquals(tc.msg, p1.getFirst().gradientForVariable(), p3.getFirst().gradientForVariable()); - assertEquals(tc.msg, p1.getFirst().gradientForVariable(), p4.getFirst().gradientForVariable()); + assertEquals(p1.getFirst().gradientForVariable(), p2.getFirst().gradientForVariable(), tc.msg); + assertEquals(p1.getFirst().gradientForVariable(), p3.getFirst().gradientForVariable(), tc.msg); + assertEquals(p1.getFirst().gradientForVariable(), p4.getFirst().gradientForVariable(), tc.msg); tc.net1.fit(inNCHW, tc.labelsNCHW); tc.net2.fit(inNCHW, tc.labelsNCHW); tc.net3.fit(inNHWC, tc.labelsNHWC); tc.net4.fit(inNHWC, tc.labelsNHWC); - assertEquals(tc.msg, tc.net1.params(), tc.net2.params()); - assertEquals(tc.msg, tc.net1.params(), tc.net3.params()); - assertEquals(tc.msg, tc.net1.params(), tc.net4.params()); + assertEquals(tc.net1.params(), tc.net2.params(), tc.msg); + assertEquals(tc.net1.params(), tc.net3.params(), tc.msg); + assertEquals(tc.net1.params(), tc.net4.params(), tc.msg); //Test serialization MultiLayerNetwork net1a = TestUtils.testModelSerialization(tc.net1); @@ -952,14 +976,14 @@ public class ConvDataFormatTests extends BaseDL4JTest { } out1 = tc.net1.output(inNCHW); - assertEquals(tc.msg, out1, net1a.output(inNCHW)); - assertEquals(tc.msg, out1, net2a.output(inNCHW)); + assertEquals(out1, net1a.output(inNCHW), tc.msg); + assertEquals(out1, net2a.output(inNCHW), tc.msg); if(!tc.nhwcOutput) { - assertEquals(tc.msg, out1, net3a.output(inNHWC)); - assertEquals(tc.msg, out1, net4a.output(inNHWC)); + assertEquals(out1, net3a.output(inNHWC), tc.msg); + assertEquals(out1, net4a.output(inNHWC), tc.msg); } else { - assertEquals(tc.msg, out1, net3a.output(inNHWC).permute(0,3,1,2)); //NHWC to NCHW - assertEquals(tc.msg, out1, net4a.output(inNHWC).permute(0,3,1,2)); + assertEquals(out1, net3a.output(inNHWC).permute(0,3,1,2), tc.msg); //NHWC to NCHW + assertEquals(out1, net4a.output(inNHWC).permute(0,3,1,2), tc.msg); } } @@ -997,6 +1021,7 @@ public class ConvDataFormatTests extends BaseDL4JTest { return this; } + @Override public InputType getOutputType(InputType inputType) { InputType.InputTypeConvolutional c = (InputType.InputTypeConvolutional) inputType; diff --git a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/convolution/TestConvolution.java b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/convolution/TestConvolution.java index e11f6d1f3..cf533e147 100644 --- a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/convolution/TestConvolution.java +++ b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/convolution/TestConvolution.java @@ -46,6 +46,7 @@ import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.resources.Resources; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; @@ -59,6 +60,7 @@ import org.nd4j.common.primitives.Pair; import java.io.File; import java.lang.reflect.Field; +import java.nio.file.Path; import java.util.Arrays; import java.util.List; import java.util.Map; @@ -70,8 +72,6 @@ import static org.junit.jupiter.api.Assertions.*; */ public class TestConvolution extends BaseDL4JTest { - @Rule - public TemporaryFolder testDir = new TemporaryFolder(); @Override public long getTimeoutMilliseconds() { @@ -176,7 +176,7 @@ public class TestConvolution extends BaseDL4JTest { INDArray outCudnn = layerCudnn.activate(in, false, LayerWorkspaceMgr.noWorkspaces()); INDArray outStd = layerStandard.activate(in, false, LayerWorkspaceMgr.noWorkspaces()); - assertEquals(msg, outStd, outCudnn); + assertEquals(outStd, outCudnn, msg); //Check backprop: @@ -190,13 +190,13 @@ public class TestConvolution extends BaseDL4JTest { INDArray epsOutStd = pStd.getSecond(); INDArray epsOutCudnn = pCudnn.getSecond(); - assertTrue(msg, epsOutStd.equalsWithEps(epsOutCudnn, 1e-4)); + assertTrue(epsOutStd.equalsWithEps(epsOutCudnn, 1e-4), msg); if (conv) { INDArray gradStd = pStd.getFirst().gradient(); INDArray gradCudnn = pCudnn.getFirst().gradient(); - assertTrue(msg, gradStd.equalsWithEps(gradCudnn, 1e-4)); + assertTrue(gradStd.equalsWithEps(gradCudnn, 1e-4), msg); } } } @@ -205,8 +205,8 @@ public class TestConvolution extends BaseDL4JTest { @Test - public void validateXceptionImport() throws Exception { - File dir = testDir.newFolder(); + public void validateXceptionImport(@TempDir Path testDir) throws Exception { + File dir = testDir.toFile(); File fSource = Resources.asFile("modelimport/keras/examples/xception/xception_tf_keras_2.h5"); File fExtracted = new File(dir, "xception_tf_keras_2.h5" ); FileUtils.copyFile(fSource, fExtracted); @@ -226,8 +226,8 @@ public class TestConvolution extends BaseDL4JTest { assertEquals(withCudnn.keySet(), noCudnn.keySet()); - for(String s : withCudnn.keySet()){ - assertEquals(s, withCudnn.get(s), noCudnn.get(s)); + for(String s : withCudnn.keySet()) { + assertEquals(withCudnn.get(s), noCudnn.get(s), s); } } diff --git a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/gradientcheck/CNNGradientCheckTest.java b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/gradientcheck/CNNGradientCheckTest.java index 6bedc0389..911668162 100644 --- a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/gradientcheck/CNNGradientCheckTest.java +++ b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/gradientcheck/CNNGradientCheckTest.java @@ -36,7 +36,9 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.nn.workspace.LayerWorkspaceMgr; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -47,13 +49,14 @@ import org.nd4j.linalg.lossfunctions.LossFunctions; import java.util.Arrays; import static org.deeplearning4j.nn.conf.ConvolutionMode.Same; import static org.deeplearning4j.nn.conf.ConvolutionMode.Truncate; -import static org.junit.jupiter.api.Assertions; +import static org.junit.jupiter.api.Assertions.*; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.extension.ExtendWith; /** * Created by nyghtowl on 9/1/15. */ +@NativeTag @DisplayName("Cnn Gradient Check Test") class CNNGradientCheckTest extends BaseDL4JTest { @@ -115,7 +118,7 @@ class CNNGradientCheckTest extends BaseDL4JTest { double scoreAfter = mln.score(); // Can't test in 'characteristic mode of operation' if not learning String msg = name + " - score did not (sufficiently) decrease during learning - activationFn=" + afn + ", lossFn=" + lf + ", outputActivation=" + outputActivation + ", doLearningFirst= " + doLearningFirst + " (before=" + scoreBefore + ", scoreAfter=" + scoreAfter + ")"; - assertTrue(msg, scoreAfter < 0.8 * scoreBefore); + assertTrue(scoreAfter < 0.8 * scoreBefore, msg); } if (PRINT_RESULTS) { System.out.println(name + " - activationFn=" + afn + ", lossFn=" + lf + ", outputActivation=" + outputActivation + ", doLearningFirst=" + doLearningFirst); @@ -174,7 +177,7 @@ class CNNGradientCheckTest extends BaseDL4JTest { double scoreAfter = mln.score(); // Can't test in 'characteristic mode of operation' if not learning String msg = testName + "- score did not (sufficiently) decrease during learning - activationFn=" + afn + ", lossFn=" + lf + ", outputActivation=" + outputActivation + ", doLearningFirst=" + doLearningFirst + " (before=" + scoreBefore + ", scoreAfter=" + scoreAfter + ")"; - assertTrue(msg, scoreAfter < 0.8 * scoreBefore); + assertTrue(scoreAfter < 0.8 * scoreBefore, msg); } if (PRINT_RESULTS) { System.out.println(testName + "- activationFn=" + afn + ", lossFn=" + lf + ", outputActivation=" + outputActivation + ", doLearningFirst=" + doLearningFirst); @@ -218,7 +221,7 @@ class CNNGradientCheckTest extends BaseDL4JTest { // System.out.println("Layer " + j + " # params: " + net.getLayer(j).numParams()); } boolean gradOK = GradientCheckUtil.checkGradients(net, DEFAULT_EPS, DEFAULT_MAX_REL_ERROR, DEFAULT_MIN_ABS_ERROR, PRINT_RESULTS, RETURN_ON_FIRST_FAILURE, input, labels); - assertTrue(msg, gradOK); + assertTrue(gradOK, msg); TestUtils.testModelSerialization(net); } } @@ -256,7 +259,7 @@ class CNNGradientCheckTest extends BaseDL4JTest { // System.out.println("Layer " + j + " # params: " + net.getLayer(j).numParams()); } boolean gradOK = GradientCheckUtil.checkGradients(net, DEFAULT_EPS, DEFAULT_MAX_REL_ERROR, DEFAULT_MIN_ABS_ERROR, PRINT_RESULTS, RETURN_ON_FIRST_FAILURE, input, labels); - assertTrue(msg, gradOK); + assertTrue(gradOK, msg); TestUtils.testModelSerialization(net); } } @@ -290,7 +293,7 @@ class CNNGradientCheckTest extends BaseDL4JTest { // System.out.println("Layer " + j + " # params: " + net.getLayer(j).numParams()); } boolean gradOK = GradientCheckUtil.checkGradients(net, DEFAULT_EPS, DEFAULT_MAX_REL_ERROR, DEFAULT_MIN_ABS_ERROR, PRINT_RESULTS, RETURN_ON_FIRST_FAILURE, input, labels); - assertTrue(msg, gradOK); + assertTrue(gradOK, msg); TestUtils.testModelSerialization(net); } } @@ -328,7 +331,7 @@ class CNNGradientCheckTest extends BaseDL4JTest { // System.out.println("Layer " + j + " # params: " + net.getLayer(j).numParams()); } boolean gradOK = GradientCheckUtil.checkGradients(net, DEFAULT_EPS, DEFAULT_MAX_REL_ERROR, DEFAULT_MIN_ABS_ERROR, PRINT_RESULTS, RETURN_ON_FIRST_FAILURE, input, labels); - assertTrue(msg, gradOK); + assertTrue(gradOK, msg); TestUtils.testModelSerialization(net); } } @@ -364,7 +367,7 @@ class CNNGradientCheckTest extends BaseDL4JTest { String msg = "PoolingType=" + poolingType + ", minibatch=" + minibatchSize + ", activationFn=" + afn; System.out.println(msg); boolean gradOK = GradientCheckUtil.checkGradients(net, DEFAULT_EPS, DEFAULT_MAX_REL_ERROR, DEFAULT_MIN_ABS_ERROR, PRINT_RESULTS, RETURN_ON_FIRST_FAILURE, input, labels); - assertTrue(msg, gradOK); + assertTrue(gradOK, msg); TestUtils.testModelSerialization(net); } } @@ -401,7 +404,7 @@ class CNNGradientCheckTest extends BaseDL4JTest { String msg = "PoolingType=" + poolingType + ", minibatch=" + minibatchSize + ", activationFn=" + afn; System.out.println(msg); boolean gradOK = GradientCheckUtil.checkGradients(net, DEFAULT_EPS, DEFAULT_MAX_REL_ERROR, DEFAULT_MIN_ABS_ERROR, PRINT_RESULTS, RETURN_ON_FIRST_FAILURE, input, labels); - assertTrue(msg, gradOK); + assertTrue(gradOK, msg); TestUtils.testModelSerialization(net); } } @@ -436,7 +439,7 @@ class CNNGradientCheckTest extends BaseDL4JTest { String msg = "Minibatch=" + minibatchSize + ", inDepth=" + inputDepth + ", height=" + height + ", kernelSize=" + k; System.out.println(msg); boolean gradOK = GradientCheckUtil.checkGradients(net, DEFAULT_EPS, DEFAULT_MAX_REL_ERROR, DEFAULT_MIN_ABS_ERROR, PRINT_RESULTS, RETURN_ON_FIRST_FAILURE, input, labels); - assertTrue(msg, gradOK); + assertTrue(gradOK, msg); TestUtils.testModelSerialization(net); } } @@ -473,7 +476,7 @@ class CNNGradientCheckTest extends BaseDL4JTest { String msg = "Minibatch=" + minibatchSize + ", inDepth=" + inputDepth + ", height=" + height + ", kernelSize=" + k + ", stride = " + stride + ", convLayer first = " + convFirst; System.out.println(msg); boolean gradOK = GradientCheckUtil.checkGradients(new GradientCheckUtil.MLNConfig().net(net).input(input).labels(labels).subset(true).maxPerParam(128)); - assertTrue(msg, gradOK); + assertTrue(gradOK, msg); TestUtils.testModelSerialization(net); } } @@ -516,7 +519,7 @@ class CNNGradientCheckTest extends BaseDL4JTest { // System.out.println("Layer " + j + " # params: " + net.getLayer(j).numParams()); } boolean gradOK = GradientCheckUtil.checkGradients(net, DEFAULT_EPS, DEFAULT_MAX_REL_ERROR, DEFAULT_MIN_ABS_ERROR, PRINT_RESULTS, RETURN_ON_FIRST_FAILURE, input, labels); - assertTrue(msg, gradOK); + assertTrue(gradOK, msg); TestUtils.testModelSerialization(net); } } @@ -559,7 +562,7 @@ class CNNGradientCheckTest extends BaseDL4JTest { String msg = " - mb=" + minibatchSize + ", k=" + k + ", s=" + s + ", d=" + d + ", cm=" + cm; System.out.println(msg); boolean gradOK = GradientCheckUtil.checkGradients(new GradientCheckUtil.MLNConfig().net(net).input(input).labels(labels).subset(true).maxPerParam(100)); - assertTrue(msg, gradOK); + assertTrue(gradOK, msg); TestUtils.testModelSerialization(net); } } @@ -597,7 +600,7 @@ class CNNGradientCheckTest extends BaseDL4JTest { String msg = " - mb=" + minibatchSize + ", k=" + k + ", nIn=" + nIn + ", depthMul=" + depthMultiplier + ", s=" + s + ", cm=" + cm; System.out.println(msg); boolean gradOK = GradientCheckUtil.checkGradients(new GradientCheckUtil.MLNConfig().net(net).input(input).labels(labels).subset(true).maxPerParam(256)); - assertTrue(msg, gradOK); + assertTrue(gradOK, msg); TestUtils.testModelSerialization(net); } } @@ -640,7 +643,7 @@ class CNNGradientCheckTest extends BaseDL4JTest { String msg = " - mb=" + minibatchSize + ", k=" + k + ", s=" + s + ", d=" + d + ", cm=" + cm; System.out.println(msg); boolean gradOK = GradientCheckUtil.checkGradients(new GradientCheckUtil.MLNConfig().net(net).input(input).labels(labels).subset(true).maxPerParam(50)); - assertTrue(msg, gradOK); + assertTrue(gradOK, msg); TestUtils.testModelSerialization(net); } } @@ -688,7 +691,7 @@ class CNNGradientCheckTest extends BaseDL4JTest { String msg = (subsampling ? "subsampling" : "conv") + " - mb=" + minibatchSize + ", k=" + k + ", s=" + s + ", d=" + d + ", cm=" + cm; System.out.println(msg); boolean gradOK = GradientCheckUtil.checkGradients(net, DEFAULT_EPS, DEFAULT_MAX_REL_ERROR, DEFAULT_MIN_ABS_ERROR, PRINT_RESULTS, RETURN_ON_FIRST_FAILURE, input, labels); - assertTrue(msg, gradOK); + assertTrue(gradOK, msg); TestUtils.testModelSerialization(net); } } @@ -727,7 +730,7 @@ class CNNGradientCheckTest extends BaseDL4JTest { System.out.println(msg); } boolean gradOK = GradientCheckUtil.checkGradients(new GradientCheckUtil.MLNConfig().net(net).input(input).labels(labels).subset(true).maxPerParam(160)); - assertTrue(msg, gradOK); + assertTrue(gradOK, msg); TestUtils.testModelSerialization(net); } } diff --git a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/gradientcheck/CuDNNGradientChecks.java b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/gradientcheck/CuDNNGradientChecks.java index 8782fbb6c..94329ccc1 100644 --- a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/gradientcheck/CuDNNGradientChecks.java +++ b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/gradientcheck/CuDNNGradientChecks.java @@ -49,6 +49,7 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.junit.jupiter.api.Test; import org.nd4j.common.function.Consumer; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.buffer.util.DataTypeUtil; @@ -70,6 +71,7 @@ import static org.junit.jupiter.api.Assertions.assertTrue; * Created by Alex on 09/09/2016. */ @Slf4j +@NativeTag public class CuDNNGradientChecks extends BaseDL4JTest { private static final boolean PRINT_RESULTS = true; @@ -171,7 +173,7 @@ public class CuDNNGradientChecks extends BaseDL4JTest { String msg = name + " - score did not (sufficiently) decrease during learning - activationFn=" + afn + ", doLearningFirst= " + doLearningFirst + " (before=" + scoreBefore + ", scoreAfter=" + scoreAfter + ")"; - assertTrue(msg, scoreAfter < 0.8 * scoreBefore); + assertTrue(scoreAfter < 0.8 * scoreBefore, msg); } if (PRINT_RESULTS) { @@ -255,7 +257,7 @@ public class CuDNNGradientChecks extends BaseDL4JTest { boolean gradOK = GradientCheckUtil.checkGradients(mln, DEFAULT_EPS, DEFAULT_MAX_REL_ERROR, DEFAULT_MIN_ABS_ERROR, PRINT_RESULTS, RETURN_ON_FIRST_FAILURE, input, labels); - assertTrue(name, gradOK); + assertTrue(gradOK, name); } } } @@ -589,7 +591,7 @@ public class CuDNNGradientChecks extends BaseDL4JTest { boolean gradOK = GradientCheckUtil.checkGradients(net, DEFAULT_EPS, DEFAULT_MAX_REL_ERROR, DEFAULT_MIN_ABS_ERROR, PRINT_RESULTS, RETURN_ON_FIRST_FAILURE, input, labels); - assertTrue(msg, gradOK); + assertTrue(gradOK, msg); } } } @@ -671,7 +673,7 @@ public class CuDNNGradientChecks extends BaseDL4JTest { .exitOnFirstError(RETURN_ON_FIRST_FAILURE) .input(f).labels(l).callEachIter(c)); - assertTrue(msg, gradOK); + assertTrue(gradOK, msg); TestUtils.testModelSerialization(mln); } } diff --git a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/lstm/ValidateCudnnDropout.java b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/lstm/ValidateCudnnDropout.java index 51bd7adc3..3905215f0 100644 --- a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/lstm/ValidateCudnnDropout.java +++ b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/lstm/ValidateCudnnDropout.java @@ -23,6 +23,7 @@ package org.deeplearning4j.cuda.lstm; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.cuda.dropout.CudnnDropoutHelper; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.ops.impl.reduce.longer.MatchCondition; @@ -32,6 +33,7 @@ import org.nd4j.linalg.indexing.conditions.Conditions; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; +@NativeTag public class ValidateCudnnDropout extends BaseDL4JTest { @Override @@ -58,8 +60,8 @@ public class ValidateCudnnDropout extends BaseDL4JTest { // System.out.println(countZero); // System.out.println(countNonDropped); - assertTrue(String.valueOf(countZero), countZero >= 5 && countZero <= 90); - assertTrue(String.valueOf(countNonDropped), countNonDropped >= 5 && countNonDropped <= 95); + assertTrue(countZero >= 5 && countZero <= 90, String.valueOf(countZero)); + assertTrue(countNonDropped >= 5 && countNonDropped <= 95, String.valueOf(countNonDropped)); assertEquals(100, countZero + countNonDropped); //Test repeatability: diff --git a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/lstm/ValidateCudnnLSTM.java b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/lstm/ValidateCudnnLSTM.java index 7dae3adaf..d4d450bc9 100644 --- a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/lstm/ValidateCudnnLSTM.java +++ b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/lstm/ValidateCudnnLSTM.java @@ -43,6 +43,7 @@ import org.nd4j.linalg.lossfunctions.LossFunctions; import java.lang.reflect.Field; import java.util.Map; import java.util.Random; +import java.util.function.Supplier; import static org.junit.jupiter.api.Assertions.*; @@ -220,7 +221,7 @@ public class ValidateCudnnLSTM extends BaseDL4JTest { mln1.fit(new DataSet(input, labels)); mln2.fit(new DataSet(input, labels)); - assertEquals("Iteration: " + x, mln1.params(), mln2.params()); + assertEquals("Iteration: " + x, mln1.params(), (Supplier) mln2.params()); } } @@ -348,7 +349,7 @@ public class ValidateCudnnLSTM extends BaseDL4JTest { INDArray step1 = mln1.rnnTimeStep(input); INDArray step2 = mln2.rnnTimeStep(input); - assertEquals("Step: " + x, step1, step2); + assertEquals("Step: " + x, step1, (Supplier) step2); } assertEquals(mln1.params(), mln2.params()); diff --git a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/util/CuDNNValidationUtil.java b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/util/CuDNNValidationUtil.java index 5750b2d1b..d96b3e124 100644 --- a/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/util/CuDNNValidationUtil.java +++ b/deeplearning4j/deeplearning4j-cuda/src/test/java/org/deeplearning4j/cuda/util/CuDNNValidationUtil.java @@ -127,7 +127,7 @@ public class CuDNNValidationUtil { System.out.println(p1); System.out.println(p2); } - assertTrue(s + " - param changed during forward pass: " + p, maxRE < t.maxRE); + assertTrue(maxRE < t.maxRE, s + " - param changed during forward pass: " + p); } for( int i=0; i()).setTokenizerFactory(tokenizerFactory).setIterator(iter) + .setStopWords(new ArrayList<>()).setTokenizerFactory(tokenizerFactory).setIterator(iter) .allowParallelTokenization(false) // .labels(labels) // .cleanup(true) diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/bagofwords/vectorizer/TfidfVectorizerTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/bagofwords/vectorizer/TfidfVectorizerTest.java index 2d5ce3bb7..b8874a563 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/bagofwords/vectorizer/TfidfVectorizerTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/bagofwords/vectorizer/TfidfVectorizerTest.java @@ -25,6 +25,7 @@ import lombok.val; import org.deeplearning4j.BaseDL4JTest; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Timeout; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.io.ClassPathResource; @@ -42,6 +43,8 @@ import org.deeplearning4j.text.tokenization.tokenizer.Tokenizer; import org.deeplearning4j.text.tokenization.tokenizerfactory.DefaultTokenizerFactory; import org.deeplearning4j.text.tokenization.tokenizerfactory.TokenizerFactory; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.exception.ND4JIllegalStateException; @@ -61,6 +64,8 @@ import static org.junit.jupiter.api.Assertions.*; * @author Adam Gibson */ @Slf4j +@Tag(TagNames.FILE_IO) +@NativeTag public class TfidfVectorizerTest extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/iterator/TestBertIterator.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/iterator/TestBertIterator.java index d9e24d10b..f9a0222aa 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/iterator/TestBertIterator.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/iterator/TestBertIterator.java @@ -28,8 +28,11 @@ import org.deeplearning4j.iterator.provider.CollectionLabeledPairSentenceProvide import org.deeplearning4j.iterator.provider.CollectionLabeledSentenceProvider; import org.deeplearning4j.text.tokenization.tokenizerfactory.BertWordPieceTokenizerFactory; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Timeout; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.api.MultiDataSet; @@ -49,6 +52,8 @@ import static org.junit.jupiter.api.Assertions.*; @Disabled("Permissions issues on CI") +@Tag(TagNames.FILE_IO) +@NativeTag public class TestBertIterator extends BaseDL4JTest { private static File pathToVocab = Resources.asFile("other/vocab.txt"); diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/iterator/TestCnnSentenceDataSetIterator.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/iterator/TestCnnSentenceDataSetIterator.java index 1a274766a..a57f671a5 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/iterator/TestCnnSentenceDataSetIterator.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/iterator/TestCnnSentenceDataSetIterator.java @@ -22,6 +22,9 @@ package org.deeplearning4j.iterator; import org.deeplearning4j.BaseDL4JTest; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.common.io.ClassPathResource; import org.deeplearning4j.iterator.provider.CollectionLabeledSentenceProvider; @@ -38,7 +41,8 @@ import java.util.Arrays; import java.util.List; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@NativeTag public class TestCnnSentenceDataSetIterator extends BaseDL4JTest { @BeforeEach diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/embeddings/inmemory/InMemoryLookupTableTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/embeddings/inmemory/InMemoryLookupTableTest.java index 586390759..c4fd0065a 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/embeddings/inmemory/InMemoryLookupTableTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/embeddings/inmemory/InMemoryLookupTableTest.java @@ -24,8 +24,7 @@ import lombok.val; import org.deeplearning4j.BaseDL4JTest; -import org.junit.jupiter.api.Disabled; -import org.junit.jupiter.api.Timeout; +import org.junit.jupiter.api.*; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.io.ClassPathResource; import org.deeplearning4j.models.sequencevectors.iterators.AbstractSequenceIterator; @@ -38,9 +37,9 @@ import org.deeplearning4j.text.sentenceiterator.BasicLineIterator; import org.deeplearning4j.text.tokenization.tokenizer.preprocessor.CommonPreprocessor; import org.deeplearning4j.text.tokenization.tokenizerfactory.DefaultTokenizerFactory; import org.deeplearning4j.text.tokenization.tokenizerfactory.TokenizerFactory; -import org.junit.jupiter.api.BeforeEach; -import org.junit.jupiter.api.Test; import org.nd4j.common.resources.Resources; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import java.nio.file.Path; @@ -48,6 +47,8 @@ import java.nio.file.Path; import static org.junit.jupiter.api.Assertions.*; @Disabled("Permissions issues on CI") +@Tag(TagNames.FILE_IO) +@NativeTag public class InMemoryLookupTableTest extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/embeddings/loader/WordVectorSerializerTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/embeddings/loader/WordVectorSerializerTest.java index 422d6525b..d4b93b3ff 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/embeddings/loader/WordVectorSerializerTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/embeddings/loader/WordVectorSerializerTest.java @@ -36,9 +36,12 @@ import org.deeplearning4j.models.word2vec.Word2Vec; import org.deeplearning4j.models.word2vec.wordstore.inmemory.AbstractCache; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -57,6 +60,8 @@ import static org.junit.jupiter.api.Assertions.assertTrue; import static org.junit.jupiter.api.Assertions.fail; @Slf4j +@Tag(TagNames.FILE_IO) +@NativeTag public class WordVectorSerializerTest extends BaseDL4JTest { private AbstractCache cache; diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/embeddings/reader/impl/FlatModelUtilsTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/embeddings/reader/impl/FlatModelUtilsTest.java index 8ffd88219..4a4bfddea 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/embeddings/reader/impl/FlatModelUtilsTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/embeddings/reader/impl/FlatModelUtilsTest.java @@ -27,7 +27,10 @@ import org.deeplearning4j.models.word2vec.VocabWord; import org.deeplearning4j.models.word2vec.Word2Vec; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.ops.transforms.Transforms; import org.slf4j.Logger; @@ -38,6 +41,8 @@ import java.util.Collection; import static org.junit.jupiter.api.Assertions.assertEquals; @Disabled +@Tag(TagNames.FILE_IO) +@NativeTag public class FlatModelUtilsTest extends BaseDL4JTest { private Word2Vec vec; private static final Logger log = LoggerFactory.getLogger(FlatModelUtilsTest.class); diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/embeddings/wordvectors/WordVectorsImplTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/embeddings/wordvectors/WordVectorsImplTest.java index 4e604c07a..dc4864c10 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/embeddings/wordvectors/WordVectorsImplTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/embeddings/wordvectors/WordVectorsImplTest.java @@ -20,6 +20,9 @@ package org.deeplearning4j.models.embeddings.wordvectors; +import org.junit.jupiter.api.Tag; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.shade.guava.collect.Lists; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.models.embeddings.WeightLookupTable; @@ -33,7 +36,8 @@ import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.mockito.Mockito.when; - +@Tag(TagNames.FILE_IO) +@NativeTag public class WordVectorsImplTest extends BaseDL4JTest { private VocabCache vocabCache; private WeightLookupTable weightLookupTable; diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/fasttext/FastTextTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/fasttext/FastTextTest.java index 17d26a674..3d2a1d999 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/fasttext/FastTextTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/fasttext/FastTextTest.java @@ -28,12 +28,15 @@ import org.deeplearning4j.text.sentenceiterator.BasicLineIterator; import org.deeplearning4j.text.sentenceiterator.SentenceIterator; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.primitives.Pair; import org.nd4j.common.resources.Resources; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import java.io.FileNotFoundException; @@ -47,6 +50,8 @@ import static org.junit.jupiter.api.Assertions.*; @Slf4j @Disabled +@Tag(TagNames.FILE_IO) +@NativeTag public class FastTextTest extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/paragraphvectors/ParagraphVectorsTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/paragraphvectors/ParagraphVectorsTest.java index 100f2ef7c..eea5f53e6 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/paragraphvectors/ParagraphVectorsTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/paragraphvectors/ParagraphVectorsTest.java @@ -33,8 +33,11 @@ import org.deeplearning4j.models.sequencevectors.transformers.impl.iterables.Bas import org.deeplearning4j.text.sentenceiterator.*; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Timeout; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.common.io.ClassPathResource; import org.deeplearning4j.models.embeddings.inmemory.InMemoryLookupTable; @@ -75,6 +78,8 @@ import static org.junit.jupiter.api.Assertions.*; @Slf4j @Disabled("Permissions issues on CI") +@Tag(TagNames.FILE_IO) +@NativeTag public class ParagraphVectorsTest extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/SequenceVectorsTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/SequenceVectorsTest.java index 260ad9c8b..c6c50b01b 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/SequenceVectorsTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/SequenceVectorsTest.java @@ -56,8 +56,11 @@ import org.deeplearning4j.text.tokenization.tokenizerfactory.DefaultTokenizerFac import org.deeplearning4j.text.tokenization.tokenizerfactory.TokenizerFactory; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.linalg.heartbeat.Heartbeat; import org.slf4j.Logger; @@ -72,6 +75,8 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.*; @Disabled +@Tag(TagNames.FILE_IO) +@NativeTag public class SequenceVectorsTest extends BaseDL4JTest { protected static final Logger logger = LoggerFactory.getLogger(SequenceVectorsTest.class); diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/graph/walkers/impl/PopularityWalkerTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/graph/walkers/impl/PopularityWalkerTest.java index 50001500c..b1ecfc31c 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/graph/walkers/impl/PopularityWalkerTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/graph/walkers/impl/PopularityWalkerTest.java @@ -31,13 +31,17 @@ import org.deeplearning4j.models.sequencevectors.graph.walkers.GraphWalker; import org.deeplearning4j.models.sequencevectors.sequence.Sequence; import org.deeplearning4j.models.word2vec.VocabWord; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.util.concurrent.atomic.AtomicBoolean; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@NativeTag public class PopularityWalkerTest extends BaseDL4JTest { private static Graph graph; diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/graph/walkers/impl/RandomWalkerTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/graph/walkers/impl/RandomWalkerTest.java index 7c150a610..441de3d2c 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/graph/walkers/impl/RandomWalkerTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/graph/walkers/impl/RandomWalkerTest.java @@ -32,12 +32,16 @@ import org.deeplearning4j.models.sequencevectors.graph.walkers.GraphWalker; import org.deeplearning4j.models.sequencevectors.sequence.Sequence; import org.deeplearning4j.models.word2vec.VocabWord; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@NativeTag public class RandomWalkerTest extends BaseDL4JTest { private static IGraph graph; diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/graph/walkers/impl/WeightedWalkerTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/graph/walkers/impl/WeightedWalkerTest.java index 7cf36eb9e..57bfd674a 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/graph/walkers/impl/WeightedWalkerTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/graph/walkers/impl/WeightedWalkerTest.java @@ -29,11 +29,15 @@ import org.deeplearning4j.models.sequencevectors.graph.walkers.GraphWalker; import org.deeplearning4j.models.sequencevectors.sequence.Sequence; import org.deeplearning4j.models.word2vec.VocabWord; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotEquals; - +@Tag(TagNames.FILE_IO) +@NativeTag public class WeightedWalkerTest extends BaseDL4JTest { private static Graph basicGraph; diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/serialization/AbstractElementFactoryTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/serialization/AbstractElementFactoryTest.java index ee7d33022..3b6aedb11 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/serialization/AbstractElementFactoryTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/serialization/AbstractElementFactoryTest.java @@ -23,10 +23,14 @@ package org.deeplearning4j.models.sequencevectors.serialization; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.models.word2vec.VocabWord; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@NativeTag public class AbstractElementFactoryTest extends BaseDL4JTest { @BeforeEach diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/serialization/VocabWordFactoryTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/serialization/VocabWordFactoryTest.java index 6ad958e79..d4ca621f0 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/serialization/VocabWordFactoryTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/serialization/VocabWordFactoryTest.java @@ -23,10 +23,14 @@ package org.deeplearning4j.models.sequencevectors.serialization; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.models.word2vec.VocabWord; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@NativeTag public class VocabWordFactoryTest extends BaseDL4JTest { @BeforeEach diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/transformers/impl/GraphTransformerTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/transformers/impl/GraphTransformerTest.java index e0cb1c5cc..d0051f7bd 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/transformers/impl/GraphTransformerTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/transformers/impl/GraphTransformerTest.java @@ -30,12 +30,16 @@ import org.deeplearning4j.models.sequencevectors.graph.walkers.impl.RandomWalker import org.deeplearning4j.models.sequencevectors.sequence.Sequence; import org.deeplearning4j.models.word2vec.VocabWord; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.util.Iterator; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@NativeTag public class GraphTransformerTest extends BaseDL4JTest { private static IGraph graph; diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/transformers/impl/iterables/ParallelTransformerIteratorTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/transformers/impl/iterables/ParallelTransformerIteratorTest.java index 01c5e8bd7..2ef5e3a6b 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/transformers/impl/iterables/ParallelTransformerIteratorTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/sequencevectors/transformers/impl/iterables/ParallelTransformerIteratorTest.java @@ -33,11 +33,10 @@ import org.deeplearning4j.text.sentenceiterator.MutipleEpochsSentenceIterator; import org.deeplearning4j.text.sentenceiterator.SentenceIterator; import org.deeplearning4j.text.tokenization.tokenizerfactory.DefaultTokenizerFactory; import org.deeplearning4j.text.tokenization.tokenizerfactory.TokenizerFactory; -import org.junit.jupiter.api.BeforeEach; -import org.junit.jupiter.api.Disabled; -import org.junit.jupiter.api.Test; -import org.junit.jupiter.api.Timeout; +import org.junit.jupiter.api.*; import org.nd4j.common.resources.Resources; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.io.InputStream; import java.util.Iterator; @@ -48,6 +47,8 @@ import static org.junit.jupiter.api.Assertions.assertNotEquals; @Slf4j @Disabled("Permissions issues on CI") +@Tag(TagNames.FILE_IO) +@NativeTag public class ParallelTransformerIteratorTest extends BaseDL4JTest { private TokenizerFactory factory = new DefaultTokenizerFactory(); diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/Word2VecTestsSmall.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/Word2VecTestsSmall.java index bd59aa1a9..a81377fc2 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/Word2VecTestsSmall.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/Word2VecTestsSmall.java @@ -35,7 +35,10 @@ import org.deeplearning4j.text.documentiterator.LabelAwareIterator; import org.deeplearning4j.text.tokenization.tokenizer.preprocessor.CommonPreprocessor; import org.deeplearning4j.text.tokenization.tokenizerfactory.DefaultTokenizerFactory; import org.deeplearning4j.util.ModelSerializer; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Timeout; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -59,6 +62,8 @@ import static org.junit.jupiter.api.Assertions.assertTrue; @Slf4j +@Tag(TagNames.FILE_IO) +@NativeTag public class Word2VecTestsSmall extends BaseDL4JTest { WordVectors word2vec; diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/Word2VecVisualizationTests.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/Word2VecVisualizationTests.java index f14ddbed5..e80325c7c 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/Word2VecVisualizationTests.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/Word2VecVisualizationTests.java @@ -25,9 +25,14 @@ import org.deeplearning4j.models.embeddings.loader.WordVectorSerializer; import org.deeplearning4j.models.embeddings.wordvectors.WordVectors; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; @Disabled +@Tag(TagNames.FILE_IO) +@NativeTag public class Word2VecVisualizationTests extends BaseDL4JTest { private static WordVectors vectors; diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/iterator/Word2VecDataSetIteratorTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/iterator/Word2VecDataSetIteratorTest.java index a18e13c5b..b6e26cc5c 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/iterator/Word2VecDataSetIteratorTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/iterator/Word2VecDataSetIteratorTest.java @@ -33,7 +33,10 @@ import org.deeplearning4j.text.tokenization.tokenizer.preprocessor.CommonPreproc import org.deeplearning4j.text.tokenization.tokenizerfactory.DefaultTokenizerFactory; import org.deeplearning4j.text.tokenization.tokenizerfactory.TokenizerFactory; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.common.resources.Resources; @@ -45,7 +48,8 @@ import java.util.List; import java.util.concurrent.atomic.AtomicInteger; import static org.junit.jupiter.api.Assertions.assertArrayEquals; - +@Tag(TagNames.FILE_IO) +@NativeTag public class Word2VecDataSetIteratorTest extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/wordstore/VocabConstructorTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/wordstore/VocabConstructorTest.java index 4d247f499..79e49b8e8 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/wordstore/VocabConstructorTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/wordstore/VocabConstructorTest.java @@ -24,8 +24,7 @@ import lombok.val; import org.deeplearning4j.BaseDL4JTest; -import org.junit.jupiter.api.Disabled; -import org.junit.jupiter.api.Timeout; +import org.junit.jupiter.api.*; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.io.ClassPathResource; import org.deeplearning4j.models.sequencevectors.interfaces.SequenceIterator; @@ -41,9 +40,9 @@ import org.deeplearning4j.text.tokenization.tokenizer.Tokenizer; import org.deeplearning4j.text.tokenization.tokenizer.preprocessor.CommonPreprocessor; import org.deeplearning4j.text.tokenization.tokenizerfactory.DefaultTokenizerFactory; import org.deeplearning4j.text.tokenization.tokenizerfactory.TokenizerFactory; -import org.junit.jupiter.api.BeforeEach; -import org.junit.jupiter.api.Test; import org.nd4j.common.resources.Resources; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -55,6 +54,8 @@ import java.util.concurrent.atomic.AtomicBoolean; import static org.junit.jupiter.api.Assertions.*; @Disabled("Permissions issues on CI") +@Tag(TagNames.FILE_IO) +@NativeTag public class VocabConstructorTest extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/wordstore/VocabularyHolderTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/wordstore/VocabularyHolderTest.java index 41c1fc0ba..da6333c4e 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/wordstore/VocabularyHolderTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/models/word2vec/wordstore/VocabularyHolderTest.java @@ -22,10 +22,14 @@ package org.deeplearning4j.models.word2vec.wordstore; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.models.word2vec.wordstore.inmemory.InMemoryLookupCache; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@NativeTag public class VocabularyHolderTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/AsyncLabelAwareIteratorTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/AsyncLabelAwareIteratorTest.java index 81c03d385..e99a00ae3 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/AsyncLabelAwareIteratorTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/AsyncLabelAwareIteratorTest.java @@ -24,13 +24,18 @@ import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.text.sentenceiterator.BasicLineIterator; import org.deeplearning4j.text.sentenceiterator.SentenceIterator; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Timeout; import org.nd4j.common.resources.Resources; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.assertEquals; @Disabled("Permissions issues on CI") +@Tag(TagNames.FILE_IO) +@NativeTag public class AsyncLabelAwareIteratorTest extends BaseDL4JTest { @Test() @Timeout(30000) diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/BasicLabelAwareIteratorTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/BasicLabelAwareIteratorTest.java index 16e96c0a7..cc2e58dab 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/BasicLabelAwareIteratorTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/BasicLabelAwareIteratorTest.java @@ -27,13 +27,18 @@ import org.deeplearning4j.text.sentenceiterator.BasicLineIterator; import org.deeplearning4j.text.sentenceiterator.SentenceIterator; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.resources.Resources; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import static org.junit.jupiter.api.Assertions.assertEquals; @Disabled("Permissions issues on CI") +@Tag(TagNames.FILE_IO) +@NativeTag public class BasicLabelAwareIteratorTest extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/DefaultDocumentIteratorTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/DefaultDocumentIteratorTest.java index 06cdb5fcb..6a123ca78 100755 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/DefaultDocumentIteratorTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/DefaultDocumentIteratorTest.java @@ -24,14 +24,18 @@ import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.text.tokenization.tokenizer.Tokenizer; import org.deeplearning4j.text.tokenization.tokenizerfactory.DefaultTokenizerFactory; import org.deeplearning4j.text.tokenization.tokenizerfactory.TokenizerFactory; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import java.io.InputStream; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@NativeTag public class DefaultDocumentIteratorTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/FileDocumentIteratorTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/FileDocumentIteratorTest.java index 9e4edffa2..ea7b18b31 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/FileDocumentIteratorTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/FileDocumentIteratorTest.java @@ -27,12 +27,11 @@ import org.apache.commons.io.IOUtils; import org.deeplearning4j.BaseDL4JTest; -import org.junit.jupiter.api.Timeout; +import org.junit.jupiter.api.*; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.io.ClassPathResource; -import org.junit.jupiter.api.BeforeEach; -import org.junit.jupiter.api.Disabled; -import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import java.io.InputStream; @@ -48,6 +47,8 @@ import static org.junit.jupiter.api.Assertions.assertTrue; @Slf4j @Disabled +@Tag(TagNames.FILE_IO) +@NativeTag public class FileDocumentIteratorTest extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/FileLabelAwareIteratorTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/FileLabelAwareIteratorTest.java index 96c1f4216..4f5268cba 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/FileLabelAwareIteratorTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/FileLabelAwareIteratorTest.java @@ -25,10 +25,13 @@ import org.deeplearning4j.BaseDL4JTest; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.io.ClassPathResource; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import java.nio.file.Path; @@ -36,6 +39,8 @@ import java.nio.file.Path; import static org.junit.jupiter.api.Assertions.*; @Disabled("Permissions issues on CI") +@Tag(TagNames.FILE_IO) +@NativeTag public class FileLabelAwareIteratorTest extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/FilenamesLabelAwareIteratorTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/FilenamesLabelAwareIteratorTest.java index 7d5c9792f..0c6ca4bf8 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/FilenamesLabelAwareIteratorTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/FilenamesLabelAwareIteratorTest.java @@ -26,9 +26,12 @@ import org.deeplearning4j.BaseDL4JTest; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.resources.Resources; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.nio.file.Path; import java.util.ArrayList; @@ -38,6 +41,8 @@ import static org.junit.jupiter.api.Assertions.assertFalse; import static org.junit.jupiter.api.Assertions.assertTrue; @Disabled("Permissions issues on CI") +@Tag(TagNames.FILE_IO) +@NativeTag public class FilenamesLabelAwareIteratorTest extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/LabelsSourceTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/LabelsSourceTest.java index 673b38485..a8ecaf8a8 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/LabelsSourceTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/documentiterator/LabelsSourceTest.java @@ -22,13 +22,17 @@ package org.deeplearning4j.text.documentiterator; import org.deeplearning4j.BaseDL4JTest; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.util.Arrays; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.JAVA_ONLY) public class LabelsSourceTest extends BaseDL4JTest { @BeforeEach diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizer/BertWordPieceTokenizerTests.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizer/BertWordPieceTokenizerTests.java index e7933d1be..cce78f317 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizer/BertWordPieceTokenizerTests.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizer/BertWordPieceTokenizerTests.java @@ -27,10 +27,13 @@ import org.deeplearning4j.text.tokenization.tokenizer.preprocessor.BertWordPiece import org.deeplearning4j.text.tokenization.tokenizerfactory.BertWordPieceTokenizerFactory; import org.deeplearning4j.text.tokenization.tokenizerfactory.TokenizerFactory; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Timeout; import org.nd4j.common.io.ClassPathResource; import org.nd4j.common.resources.Resources; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.io.ByteArrayInputStream; import java.io.File; @@ -44,6 +47,8 @@ import static org.junit.jupiter.api.Assertions.*; @Slf4j @Disabled +@Tag(TagNames.FILE_IO) +@NativeTag public class BertWordPieceTokenizerTests extends BaseDL4JTest { private File pathToVocab = Resources.asFile("other/vocab.txt"); diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizer/DefaulTokenizerTests.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizer/DefaulTokenizerTests.java index d3ab0bfc8..c4b873748 100755 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizer/DefaulTokenizerTests.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizer/DefaulTokenizerTests.java @@ -22,10 +22,13 @@ package org.deeplearning4j.text.tokenization.tokenizer; import org.apache.commons.io.FileUtils; import org.deeplearning4j.BaseDL4JTest; +import org.junit.jupiter.api.Tag; import org.nd4j.common.io.ClassPathResource; import org.deeplearning4j.text.tokenization.tokenizerfactory.DefaultTokenizerFactory; import org.deeplearning4j.text.tokenization.tokenizerfactory.TokenizerFactory; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -33,7 +36,8 @@ import java.io.ByteArrayInputStream; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@NativeTag public class DefaulTokenizerTests extends BaseDL4JTest { protected static final Logger log = LoggerFactory.getLogger(DefaulTokenizerTests.class); diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizer/NGramTokenizerTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizer/NGramTokenizerTest.java index 6d36889cf..59f08a359 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizer/NGramTokenizerTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizer/NGramTokenizerTest.java @@ -24,7 +24,10 @@ import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.text.tokenization.tokenizerfactory.DefaultTokenizerFactory; import org.deeplearning4j.text.tokenization.tokenizerfactory.NGramTokenizerFactory; import org.deeplearning4j.text.tokenization.tokenizerfactory.TokenizerFactory; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.util.List; @@ -35,6 +38,8 @@ import static org.junit.jupiter.api.Assertions.assertTrue; /** * @author sonali */ +@Tag(TagNames.FILE_IO) +@NativeTag public class NGramTokenizerTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizer/tokenprepreprocessor/EndingPreProcessorTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizer/tokenprepreprocessor/EndingPreProcessorTest.java index 03db99995..8cc0855cc 100755 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizer/tokenprepreprocessor/EndingPreProcessorTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizer/tokenprepreprocessor/EndingPreProcessorTest.java @@ -23,10 +23,14 @@ package org.deeplearning4j.text.tokenization.tokenizer.tokenprepreprocessor; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.text.tokenization.tokenizer.TokenPreProcess; import org.deeplearning4j.text.tokenization.tokenizer.preprocessor.EndingPreProcessor; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@NativeTag public class EndingPreProcessorTest extends BaseDL4JTest { @Test public void testPreProcessor() { diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizerfactory/NGramTokenizerFactoryTest.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizerfactory/NGramTokenizerFactoryTest.java index 32ccee306..591b65d21 100644 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizerfactory/NGramTokenizerFactoryTest.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/text/tokenization/tokenizerfactory/NGramTokenizerFactoryTest.java @@ -24,11 +24,16 @@ import lombok.extern.slf4j.Slf4j; import lombok.val; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.text.tokenization.tokenizer.preprocessor.CommonPreprocessor; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@Tag(TagNames.FILE_IO) +@NativeTag public class NGramTokenizerFactoryTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/wordstore/InMemoryVocabStoreTests.java b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/wordstore/InMemoryVocabStoreTests.java index fab3d2e89..236e4aaa2 100755 --- a/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/wordstore/InMemoryVocabStoreTests.java +++ b/deeplearning4j/deeplearning4j-nlp-parent/deeplearning4j-nlp/src/test/java/org/deeplearning4j/wordstore/InMemoryVocabStoreTests.java @@ -24,12 +24,16 @@ import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.models.word2vec.VocabWord; import org.deeplearning4j.models.word2vec.wordstore.VocabCache; import org.deeplearning4j.models.word2vec.wordstore.inmemory.InMemoryLookupCache; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@NativeTag public class InMemoryVocabStoreTests extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper-parameter-server/src/test/java/org/deeplearning4j/parallelism/parameterserver/ParameterServerParallelWrapperTest.java b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper-parameter-server/src/test/java/org/deeplearning4j/parallelism/parameterserver/ParameterServerParallelWrapperTest.java index f4516b2d3..dad5e56ed 100644 --- a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper-parameter-server/src/test/java/org/deeplearning4j/parallelism/parameterserver/ParameterServerParallelWrapperTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper-parameter-server/src/test/java/org/deeplearning4j/parallelism/parameterserver/ParameterServerParallelWrapperTest.java @@ -34,7 +34,10 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.parallelism.ParallelWrapper; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.linalg.learning.config.Nesterovs; @@ -42,6 +45,8 @@ import org.nd4j.linalg.lossfunctions.LossFunctions; @Slf4j @Disabled("Permissions issues on CI") +@Tag(TagNames.FILE_IO) +@NativeTag public class ParameterServerParallelWrapperTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/InplaceParallelInferenceTest.java b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/InplaceParallelInferenceTest.java index a8db019b4..35940a519 100644 --- a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/InplaceParallelInferenceTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/InplaceParallelInferenceTest.java @@ -27,13 +27,17 @@ import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.parallelism.inference.InferenceMode; import org.deeplearning4j.parallelism.inference.LoadBalanceMode; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@NativeTag public class InplaceParallelInferenceTest extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/ParallelInferenceTest.java b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/ParallelInferenceTest.java index 24cc7778f..5b1a1f739 100644 --- a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/ParallelInferenceTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/ParallelInferenceTest.java @@ -33,6 +33,8 @@ import org.deeplearning4j.nn.conf.NeuralNetConfiguration; import org.deeplearning4j.nn.conf.layers.*; import org.deeplearning4j.nn.graph.ComputationGraph; import org.junit.jupiter.api.*; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.deeplearning4j.datasets.iterator.impl.MnistDataSetIterator; import org.deeplearning4j.eval.Evaluation; @@ -61,6 +63,8 @@ import static org.junit.jupiter.api.Assertions.*; @Slf4j @Disabled("Permissions issues on CI") +@Tag(TagNames.FILE_IO) +@NativeTag public class ParallelInferenceTest extends BaseDL4JTest { private static MultiLayerNetwork model; private static DataSetIterator iterator; diff --git a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/ParallelWrapperTest.java b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/ParallelWrapperTest.java index 7f751df54..d7534df5a 100644 --- a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/ParallelWrapperTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/ParallelWrapperTest.java @@ -35,7 +35,10 @@ import org.deeplearning4j.nn.conf.layers.SubsamplingLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.optimize.listeners.ScoreIterationListener; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -47,7 +50,8 @@ import org.slf4j.LoggerFactory; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@NativeTag public class ParallelWrapperTest extends BaseDL4JTest { private static final Logger log = LoggerFactory.getLogger(ParallelWrapperTest.class); diff --git a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/TestListeners.java b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/TestListeners.java index eb3ccfef8..102fef1db 100644 --- a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/TestListeners.java +++ b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/TestListeners.java @@ -36,7 +36,10 @@ import org.deeplearning4j.optimize.api.BaseTrainingListener; import org.deeplearning4j.optimize.api.TrainingListener; import org.deeplearning4j.ui.model.stats.StatsListener; import org.deeplearning4j.ui.model.storage.InMemoryStatsStorage; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -49,7 +52,8 @@ import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.atomic.AtomicInteger; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@NativeTag public class TestListeners extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/TestParallelEarlyStopping.java b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/TestParallelEarlyStopping.java index 2eaf2e850..c24225d35 100644 --- a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/TestParallelEarlyStopping.java +++ b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/TestParallelEarlyStopping.java @@ -38,7 +38,10 @@ import org.deeplearning4j.nn.conf.layers.OutputLayer; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.optimize.listeners.ScoreIterationListener; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.linalg.factory.Nd4j; @@ -48,7 +51,8 @@ import org.nd4j.linalg.lossfunctions.LossFunctions; import java.util.concurrent.TimeUnit; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@NativeTag public class TestParallelEarlyStopping extends BaseDL4JTest { // parallel training results vary wildly with expected result diff --git a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/TestParallelEarlyStoppingUI.java b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/TestParallelEarlyStoppingUI.java index 07dea5739..0fb4ea2c5 100644 --- a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/TestParallelEarlyStoppingUI.java +++ b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/TestParallelEarlyStoppingUI.java @@ -41,14 +41,18 @@ import org.deeplearning4j.ui.api.UIServer; import org.deeplearning4j.ui.model.stats.StatsListener; import org.deeplearning4j.ui.model.storage.InMemoryStatsStorage; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.linalg.learning.config.Sgd; import org.nd4j.linalg.lossfunctions.LossFunctions; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@NativeTag public class TestParallelEarlyStoppingUI extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/factory/DefaultTrainerContextTest.java b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/factory/DefaultTrainerContextTest.java index 3a85b4b34..826068285 100644 --- a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/factory/DefaultTrainerContextTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/factory/DefaultTrainerContextTest.java @@ -34,13 +34,17 @@ import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.parallelism.ParallelWrapper; import org.deeplearning4j.parallelism.trainer.SymmetricTrainer; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.learning.config.Nesterovs; import org.nd4j.linalg.lossfunctions.LossFunctions; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@NativeTag public class DefaultTrainerContextTest extends BaseDL4JTest { int nChannels = 1; int outputNum = 10; diff --git a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/factory/SymmetricTrainerContextTest.java b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/factory/SymmetricTrainerContextTest.java index ec82896df..159494805 100644 --- a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/factory/SymmetricTrainerContextTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/factory/SymmetricTrainerContextTest.java @@ -34,13 +34,17 @@ import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.parallelism.ParallelWrapper; import org.deeplearning4j.parallelism.trainer.SymmetricTrainer; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.learning.config.Nesterovs; import org.nd4j.linalg.lossfunctions.LossFunctions; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@NativeTag public class SymmetricTrainerContextTest extends BaseDL4JTest { int nChannels = 1; int outputNum = 10; diff --git a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/inference/observers/BatchedInferenceObservableTest.java b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/inference/observers/BatchedInferenceObservableTest.java index 1a49fa3b1..74f9ddcab 100644 --- a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/inference/observers/BatchedInferenceObservableTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/inference/observers/BatchedInferenceObservableTest.java @@ -24,7 +24,10 @@ import lombok.extern.slf4j.Slf4j; import org.deeplearning4j.BaseDL4JTest; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -38,6 +41,8 @@ import static org.junit.jupiter.api.Assertions.assertArrayEquals; import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j +@Tag(TagNames.FILE_IO) +@NativeTag public class BatchedInferenceObservableTest extends BaseDL4JTest { @BeforeEach public void setUp() throws Exception {} diff --git a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/main/ParallelWrapperMainTest.java b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/main/ParallelWrapperMainTest.java index 2378c2c3e..7312a5b5b 100644 --- a/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/main/ParallelWrapperMainTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/deeplearning4j-scaleout-parallelwrapper/src/test/java/org/deeplearning4j/parallelism/main/ParallelWrapperMainTest.java @@ -35,9 +35,12 @@ import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.util.ModelSerializer; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.linalg.learning.config.Nesterovs; @@ -49,6 +52,8 @@ import java.nio.file.Path; @Slf4j @Disabled("Permissions issues on CI") +@Tag(TagNames.FILE_IO) +@NativeTag public class ParallelWrapperMainTest extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/sequencevectors/SparkSequenceVectorsTest.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/sequencevectors/SparkSequenceVectorsTest.java index 9048b8984..b1dc0974e 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/sequencevectors/SparkSequenceVectorsTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/sequencevectors/SparkSequenceVectorsTest.java @@ -33,18 +33,20 @@ import org.deeplearning4j.spark.models.sequencevectors.export.ExportContainer; import org.deeplearning4j.spark.models.sequencevectors.export.SparkModelExporter; import org.deeplearning4j.spark.models.word2vec.SparkWord2VecTest; import org.deeplearning4j.text.tokenization.tokenizerfactory.DefaultTokenizerFactory; -import org.junit.jupiter.api.AfterEach; -import org.junit.jupiter.api.BeforeEach; -import org.junit.jupiter.api.Disabled; -import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.*; import org.nd4j.common.primitives.Counter; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.util.ArrayList; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class SparkSequenceVectorsTest extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/sequencevectors/export/ExportContainerTest.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/sequencevectors/export/ExportContainerTest.java index 3ca30f7d1..eb4b790ed 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/sequencevectors/export/ExportContainerTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/sequencevectors/export/ExportContainerTest.java @@ -23,11 +23,17 @@ package org.deeplearning4j.spark.models.sequencevectors.export; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.models.word2vec.VocabWord; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class ExportContainerTest extends BaseDL4JTest { @BeforeEach public void setUp() throws Exception { diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/word2vec/SparkWord2VecTest.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/word2vec/SparkWord2VecTest.java index a6ce8d2eb..8990e5ad7 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/word2vec/SparkWord2VecTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp-java8/src/test/java/org/deeplearning4j/spark/models/word2vec/SparkWord2VecTest.java @@ -34,10 +34,9 @@ import org.deeplearning4j.spark.models.sequencevectors.export.ExportContainer; import org.deeplearning4j.spark.models.sequencevectors.export.SparkModelExporter; import org.deeplearning4j.spark.models.sequencevectors.learning.elements.SparkSkipGram; import org.deeplearning4j.text.tokenization.tokenizerfactory.DefaultTokenizerFactory; -import org.junit.jupiter.api.AfterEach; -import org.junit.jupiter.api.BeforeEach; -import org.junit.jupiter.api.Disabled; -import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.*; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.parameterserver.distributed.conf.VoidConfiguration; import java.io.Serializable; @@ -45,7 +44,10 @@ import java.util.ArrayList; import java.util.List; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class SparkWord2VecTest extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecTest.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecTest.java index e2bd741fb..3d169f94c 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/models/embeddings/word2vec/Word2VecTest.java @@ -26,6 +26,7 @@ import org.apache.spark.api.java.JavaRDD; import org.apache.spark.api.java.JavaSparkContext; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.io.TempDir; import org.nd4j.common.io.ClassPathResource; import org.deeplearning4j.models.embeddings.inmemory.InMemoryLookupTable; @@ -40,6 +41,8 @@ import org.deeplearning4j.text.tokenization.tokenizerfactory.DefaultTokenizerFac import org.deeplearning4j.text.tokenization.tokenizerfactory.TokenizerFactory; import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import java.io.File; @@ -51,6 +54,10 @@ import java.util.Collection; import static org.junit.jupiter.api.Assertions.*; @Disabled +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class Word2VecTest { diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/TestFunction.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/TestFunction.java index 618bf0ac7..3bfddf12e 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/TestFunction.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/TestFunction.java @@ -21,9 +21,15 @@ package org.deeplearning4j.spark.text; import org.apache.spark.api.java.function.Function; +import org.junit.jupiter.api.Tag; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.util.List; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestFunction implements Function { public TestFunction(List lst) { this.lst = lst; diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/TextPipelineTest.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/TextPipelineTest.java index aa559f90a..9174bd593 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/TextPipelineTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-nlp/src/test/java/org/deeplearning4j/spark/text/TextPipelineTest.java @@ -37,7 +37,10 @@ import org.deeplearning4j.spark.text.functions.TextPipeline; import org.deeplearning4j.text.stopwords.StopWords; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.common.primitives.Counter; import org.nd4j.common.primitives.Pair; @@ -54,6 +57,10 @@ import static org.junit.jupiter.api.Assertions.assertTrue; /** * @author Jeffrey Tang */ +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TextPipelineTest extends BaseSparkTest { private List sentenceList; diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationFunctionTest.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationFunctionTest.java index c5731af74..562755a2b 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationFunctionTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAccumulationFunctionTest.java @@ -22,12 +22,18 @@ package org.deeplearning4j.spark.parameterserver.accumulation; import com.sun.jna.Platform; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class SharedTrainingAccumulationFunctionTest { @BeforeEach public void setUp() throws Exception {} diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAggregateFunctionTest.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAggregateFunctionTest.java index 25ef434bd..222616859 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAggregateFunctionTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/accumulation/SharedTrainingAggregateFunctionTest.java @@ -23,12 +23,18 @@ package org.deeplearning4j.spark.parameterserver.accumulation; import com.sun.jna.Platform; import org.deeplearning4j.spark.parameterserver.training.SharedTrainingResult; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class SharedTrainingAggregateFunctionTest { @BeforeEach public void setUp() throws Exception { diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualDataSetIteratorTest.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualDataSetIteratorTest.java index b837efe5e..fbf0722e9 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualDataSetIteratorTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualDataSetIteratorTest.java @@ -22,7 +22,10 @@ package org.deeplearning4j.spark.parameterserver.iterators; import com.sun.jna.Platform; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.factory.Nd4j; @@ -32,7 +35,10 @@ import java.util.Iterator; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class VirtualDataSetIteratorTest { @BeforeEach public void setUp() throws Exception {} diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualIteratorTest.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualIteratorTest.java index 4e56b575a..9c99fddea 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualIteratorTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/iterators/VirtualIteratorTest.java @@ -22,13 +22,19 @@ package org.deeplearning4j.spark.parameterserver.iterators; import com.sun.jna.Platform; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.util.ArrayList; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class VirtualIteratorTest { @BeforeEach public void setUp() throws Exception { diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/modelimport/elephas/TestElephasImport.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/modelimport/elephas/TestElephasImport.java index 16429f41e..eddf13c8f 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/modelimport/elephas/TestElephasImport.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/modelimport/elephas/TestElephasImport.java @@ -27,8 +27,11 @@ import org.deeplearning4j.spark.impl.multilayer.SparkDl4jMultiLayer; import org.deeplearning4j.spark.impl.paramavg.ParameterAveragingTrainingMaster; import org.deeplearning4j.spark.parameterserver.BaseSparkTest; import org.deeplearning4j.spark.parameterserver.training.SharedTrainingMaster; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; import java.nio.file.Files; @@ -36,7 +39,10 @@ import java.nio.file.StandardCopyOption; import static java.io.File.createTempFile; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestElephasImport extends BaseSparkTest { @Test diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/train/GradientSharingTrainingTest.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/train/GradientSharingTrainingTest.java index 85bdc5b01..15220fd9f 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/train/GradientSharingTrainingTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark-parameterserver/src/test/java/org/deeplearning4j/spark/parameterserver/train/GradientSharingTrainingTest.java @@ -48,9 +48,12 @@ import org.deeplearning4j.spark.parameterserver.BaseSparkTest; import org.deeplearning4j.spark.parameterserver.training.SharedTrainingMaster; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -75,6 +78,10 @@ import static org.junit.jupiter.api.Assertions.*; @Slf4j //@Disabled("AB 2019/05/21 - Failing - Issue #7657") +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class GradientSharingTrainingTest extends BaseSparkTest { diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestKryo.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestKryo.java index 33023d605..28b59d75f 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestKryo.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/TestKryo.java @@ -30,7 +30,10 @@ import org.deeplearning4j.nn.conf.graph.rnn.DuplicateToTimeSeriesVertex; import org.deeplearning4j.nn.conf.graph.rnn.LastTimeStepVertex; import org.deeplearning4j.nn.conf.layers.*; import org.deeplearning4j.nn.conf.preprocessor.CnnToFeedForwardPreProcessor; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.evaluation.IEvaluation; import org.nd4j.evaluation.classification.*; import org.nd4j.evaluation.regression.RegressionEvaluation; @@ -48,7 +51,10 @@ import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.CopyOnWriteArrayList; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestKryo extends BaseSparkKryoTest { private void testSerialization(T in, SerializerInstance si) { diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/common/AddTest.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/common/AddTest.java index f366de5b4..36c84f6f6 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/common/AddTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/common/AddTest.java @@ -23,7 +23,10 @@ package org.deeplearning4j.spark.common; import org.apache.spark.api.java.JavaRDD; import org.deeplearning4j.spark.BaseSparkTest; import org.deeplearning4j.spark.impl.common.Add; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -31,7 +34,10 @@ import java.util.ArrayList; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class AddTest extends BaseSparkTest { @Test diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/data/TestShuffleExamples.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/data/TestShuffleExamples.java index f879cfd29..e01a01d13 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/data/TestShuffleExamples.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/data/TestShuffleExamples.java @@ -20,24 +20,26 @@ package org.deeplearning4j.spark.data; -import org.apache.spark.HashPartitioner; -import org.apache.spark.Partitioner; import org.apache.spark.api.java.JavaRDD; import org.deeplearning4j.spark.BaseSparkTest; import org.deeplearning4j.spark.util.SparkUtils; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.factory.Nd4j; import java.util.ArrayList; -import java.util.Arrays; import java.util.List; -import java.util.Random; import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.junit.jupiter.api.Assertions.assertTrue; +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestShuffleExamples extends BaseSparkTest { @Test diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/data/TestSparkDataUtils.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/data/TestSparkDataUtils.java deleted file mode 100644 index 4e9f12dd9..000000000 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/data/TestSparkDataUtils.java +++ /dev/null @@ -1,33 +0,0 @@ -/* - * ****************************************************************************** - * * - * * - * * 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. - * * - * * See the NOTICE file distributed with this work for additional - * * information regarding copyright ownership. - * * 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.spark.data; - -import org.deeplearning4j.spark.BaseSparkTest; -import org.junit.jupiter.api.Test; - -public class TestSparkDataUtils extends BaseSparkTest { - - @Test - public void testExport(){ - - } - -} diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/MiniBatchTests.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/MiniBatchTests.java index 43c50fdeb..44e15c4fc 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/MiniBatchTests.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/MiniBatchTests.java @@ -26,7 +26,10 @@ import org.datavec.api.conf.Configuration; import org.datavec.api.records.reader.RecordReader; import org.datavec.api.records.reader.impl.misc.SVMLightRecordReader; import org.deeplearning4j.spark.BaseSparkTest; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.common.io.ClassPathResource; import org.slf4j.Logger; @@ -36,7 +39,10 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class MiniBatchTests extends BaseSparkTest { private static final Logger log = LoggerFactory.getLogger(MiniBatchTests.class); diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestDataVecDataSetFunctions.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestDataVecDataSetFunctions.java index 0badb42fe..7230f9d72 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestDataVecDataSetFunctions.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestDataVecDataSetFunctions.java @@ -47,9 +47,12 @@ import org.deeplearning4j.datasets.datavec.SequenceRecordReaderDataSetIterator; import org.deeplearning4j.spark.BaseSparkTest; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.factory.Nd4j; @@ -63,7 +66,10 @@ import java.util.Arrays; import java.util.List; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestDataVecDataSetFunctions extends BaseSparkTest { diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestExport.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestExport.java index b9eef9113..d294ee7fc 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestExport.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestExport.java @@ -27,7 +27,10 @@ import org.apache.spark.api.java.JavaRDD; import org.deeplearning4j.spark.BaseSparkTest; import org.deeplearning4j.spark.data.BatchAndExportDataSetsFunction; import org.deeplearning4j.spark.data.BatchAndExportMultiDataSetsFunction; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.dataset.api.MultiDataSet; import org.nd4j.linalg.factory.Nd4j; @@ -40,7 +43,10 @@ import java.util.Random; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotNull; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestExport extends BaseSparkTest { @Test diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestPreProcessedData.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestPreProcessedData.java index 714c3ffb6..521ba1445 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestPreProcessedData.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/datavec/TestPreProcessedData.java @@ -41,7 +41,10 @@ import org.deeplearning4j.spark.impl.graph.SparkComputationGraph; import org.deeplearning4j.spark.impl.multilayer.SparkDl4jMultiLayer; import org.deeplearning4j.spark.impl.paramavg.ParameterAveragingTrainingMaster; import org.deeplearning4j.spark.iterator.PortableDataStreamDataSetIterator; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -58,7 +61,10 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestPreProcessedData extends BaseSparkTest { @Test diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/TestKryoWarning.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/TestKryoWarning.java index 9bc828abb..33a7d86da 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/TestKryoWarning.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/TestKryoWarning.java @@ -31,8 +31,15 @@ import org.deeplearning4j.spark.impl.graph.SparkComputationGraph; import org.deeplearning4j.spark.impl.multilayer.SparkDl4jMultiLayer; import org.deeplearning4j.spark.impl.paramavg.ParameterAveragingTrainingMaster; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestKryoWarning { private static void doTestMLN(SparkConf sparkConf) { diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/common/repartition/BalancedPartitionerTest.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/common/repartition/BalancedPartitionerTest.java index 1bab0defe..0d8dbc078 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/common/repartition/BalancedPartitionerTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/common/repartition/BalancedPartitionerTest.java @@ -20,11 +20,17 @@ package org.deeplearning4j.spark.impl.common.repartition; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class BalancedPartitionerTest { diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/common/repartition/HashingBalancedPartitionerTest.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/common/repartition/HashingBalancedPartitionerTest.java index 74e8f03be..f4aeff17c 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/common/repartition/HashingBalancedPartitionerTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/common/repartition/HashingBalancedPartitionerTest.java @@ -27,14 +27,20 @@ import org.apache.spark.api.java.function.Function2; import org.apache.spark.api.java.function.PairFunction; import org.deeplearning4j.spark.BaseSparkTest; import org.deeplearning4j.spark.impl.common.repartition.HashingBalancedPartitioner.LinearCongruentialGenerator; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import scala.Tuple2; import java.util.*; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class HashingBalancedPartitionerTest extends BaseSparkTest { // e.g. we have 3 partitions, with red and blue elements, red is indexed by 0, blue by 1: diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/TestCustomLayer.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/TestCustomLayer.java index b3c96333d..0cc5af3a3 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/TestCustomLayer.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/customlayer/TestCustomLayer.java @@ -30,7 +30,10 @@ import org.deeplearning4j.spark.BaseSparkTest; import org.deeplearning4j.spark.impl.customlayer.layer.CustomLayer; import org.deeplearning4j.spark.impl.multilayer.SparkDl4jMultiLayer; import org.deeplearning4j.spark.impl.paramavg.ParameterAveragingTrainingMaster; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.factory.Nd4j; @@ -40,7 +43,11 @@ import org.nd4j.linalg.lossfunctions.LossFunctions; import java.util.ArrayList; import java.util.List; import java.util.Random; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag +@Tag(TagNames.CUSTOM_FUNCTIONALITY) public class TestCustomLayer extends BaseSparkTest { @Test diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/graph/TestSparkComputationGraph.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/graph/TestSparkComputationGraph.java index f003b5171..ea37895ab 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/graph/TestSparkComputationGraph.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/graph/TestSparkComputationGraph.java @@ -48,8 +48,11 @@ import org.deeplearning4j.spark.api.Repartition; import org.deeplearning4j.spark.api.TrainingMaster; import org.deeplearning4j.spark.impl.paramavg.ParameterAveragingTrainingMaster; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Timeout; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.evaluation.IEvaluation; import org.nd4j.evaluation.classification.Evaluation; import org.nd4j.evaluation.classification.ROC; @@ -73,6 +76,10 @@ import java.util.*; import static org.junit.jupiter.api.Assertions.*; @Disabled("AB 2019/05/24 - Rarely getting stuck on CI - see issue #7657") +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestSparkComputationGraph extends BaseSparkTest { public static ComputationGraph getBasicNetIris2Class() { diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/misc/TestFrozenLayers.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/misc/TestFrozenLayers.java index 887696af3..48b8535c5 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/misc/TestFrozenLayers.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/misc/TestFrozenLayers.java @@ -33,7 +33,10 @@ import org.deeplearning4j.spark.api.RDDTrainingApproach; import org.deeplearning4j.spark.impl.graph.SparkComputationGraph; import org.deeplearning4j.spark.impl.multilayer.SparkDl4jMultiLayer; import org.deeplearning4j.spark.impl.paramavg.ParameterAveragingTrainingMaster; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -47,7 +50,10 @@ import java.util.List; import java.util.Map; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestFrozenLayers extends BaseSparkTest { @Test diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/multilayer/TestMiscFunctions.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/multilayer/TestMiscFunctions.java index 550ccc9b2..6989ab25d 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/multilayer/TestMiscFunctions.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/multilayer/TestMiscFunctions.java @@ -36,7 +36,10 @@ import org.deeplearning4j.spark.BaseSparkTest; import org.deeplearning4j.spark.impl.graph.SparkComputationGraph; import org.deeplearning4j.spark.impl.multilayer.scoring.VaeReconstructionErrorWithKeyFunction; import org.deeplearning4j.spark.impl.multilayer.scoring.VaeReconstructionProbWithKeyFunction; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.api.DataSet; @@ -51,7 +54,10 @@ import java.util.*; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestMiscFunctions extends BaseSparkTest { @Test diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/multilayer/TestSparkDl4jMultiLayer.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/multilayer/TestSparkDl4jMultiLayer.java index c64618557..fb71a8ce0 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/multilayer/TestSparkDl4jMultiLayer.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/multilayer/TestSparkDl4jMultiLayer.java @@ -33,7 +33,10 @@ import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.spark.BaseSparkTest; import org.deeplearning4j.spark.api.TrainingMaster; import org.deeplearning4j.spark.impl.paramavg.ParameterAveragingTrainingMaster; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.evaluation.classification.Evaluation; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; @@ -51,6 +54,10 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; @Slf4j +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestSparkDl4jMultiLayer extends BaseSparkTest { @Override diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestCompareParameterAveragingSparkVsSingleMachine.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestCompareParameterAveragingSparkVsSingleMachine.java index cbe7247bd..9bf38b228 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestCompareParameterAveragingSparkVsSingleMachine.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestCompareParameterAveragingSparkVsSingleMachine.java @@ -40,7 +40,10 @@ import org.deeplearning4j.spark.api.TrainingMaster; import org.deeplearning4j.spark.impl.graph.SparkComputationGraph; import org.deeplearning4j.spark.impl.multilayer.SparkDl4jMultiLayer; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -55,7 +58,10 @@ import java.util.Arrays; import java.util.List; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestCompareParameterAveragingSparkVsSingleMachine { @BeforeEach public void setUp() { diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestJsonYaml.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestJsonYaml.java index 64c984ad7..97233b74f 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestJsonYaml.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestJsonYaml.java @@ -22,10 +22,17 @@ package org.deeplearning4j.spark.impl.paramavg; import org.apache.spark.storage.StorageLevel; import org.deeplearning4j.spark.api.TrainingMaster; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag +@Tag(TagNames.JACKSON_SERDE) public class TestJsonYaml { @Test diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestSparkMultiLayerParameterAveraging.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestSparkMultiLayerParameterAveraging.java index 227f2abb8..0295144c4 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestSparkMultiLayerParameterAveraging.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/paramavg/TestSparkMultiLayerParameterAveraging.java @@ -57,10 +57,13 @@ import org.deeplearning4j.spark.stats.EventStats; import org.deeplearning4j.spark.stats.ExampleCountEventStats; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Timeout; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.evaluation.classification.Evaluation; import org.nd4j.evaluation.classification.ROC; import org.nd4j.evaluation.classification.ROCMultiClass; @@ -85,7 +88,10 @@ import java.util.*; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestSparkMultiLayerParameterAveraging extends BaseSparkTest { public static class TestFn implements Function{ diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/stats/TestTrainingStatsCollection.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/stats/TestTrainingStatsCollection.java index a287eb836..5c6c19174 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/stats/TestTrainingStatsCollection.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/impl/stats/TestTrainingStatsCollection.java @@ -40,7 +40,10 @@ import org.deeplearning4j.spark.impl.paramavg.stats.ParameterAveragingTrainingMa import org.deeplearning4j.spark.impl.paramavg.stats.ParameterAveragingTrainingWorkerStats; import org.deeplearning4j.spark.stats.EventStats; import org.deeplearning4j.spark.stats.StatsUtils; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.factory.Nd4j; @@ -50,7 +53,10 @@ import java.lang.reflect.Field; import java.util.*; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestTrainingStatsCollection extends BaseSparkTest { @Test diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/time/TestTimeSource.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/time/TestTimeSource.java index 85a73aab4..7eb17c944 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/time/TestTimeSource.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/time/TestTimeSource.java @@ -20,11 +20,17 @@ package org.deeplearning4j.spark.time; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestTimeSource { @Test diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/ui/TestListeners.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/ui/TestListeners.java index 6f79d7595..ce484fc54 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/ui/TestListeners.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/ui/TestListeners.java @@ -38,7 +38,10 @@ import org.deeplearning4j.spark.impl.multilayer.SparkDl4jMultiLayer; import org.deeplearning4j.spark.impl.paramavg.ParameterAveragingTrainingMaster; import org.deeplearning4j.ui.model.stats.StatsListener; import org.deeplearning4j.ui.model.storage.mapdb.MapDBStatsStorage; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.lossfunctions.LossFunctions; @@ -48,7 +51,11 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag +@Tag(TagNames.UI) public class TestListeners extends BaseSparkTest { @Test diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/MLLIbUtilTest.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/MLLIbUtilTest.java index ef7c0788f..23674df13 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/MLLIbUtilTest.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/MLLIbUtilTest.java @@ -27,7 +27,10 @@ import org.apache.spark.mllib.linalg.Matrix; import org.apache.spark.mllib.regression.LabeledPoint; import org.deeplearning4j.datasets.iterator.impl.IrisDataSetIterator; import org.deeplearning4j.spark.BaseSparkTest; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.factory.Nd4j; @@ -39,7 +42,10 @@ import java.util.List; import java.util.Random; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class MLLIbUtilTest extends BaseSparkTest { private static final Logger log = LoggerFactory.getLogger(MLLIbUtilTest.class); diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/TestRepartitioning.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/TestRepartitioning.java index 75653f9ad..5ea6f486e 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/TestRepartitioning.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/TestRepartitioning.java @@ -29,7 +29,10 @@ import org.deeplearning4j.spark.api.Repartition; import org.deeplearning4j.spark.api.RepartitionStrategy; import org.deeplearning4j.spark.impl.common.CountPartitionsFunction; import org.deeplearning4j.spark.impl.repartitioner.DefaultRepartitioner; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import scala.Tuple2; import java.util.ArrayList; @@ -38,7 +41,10 @@ import java.util.List; import java.util.Random; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestRepartitioning extends BaseSparkTest { @Override diff --git a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/TestValidation.java b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/TestValidation.java index 3ff88365e..5adf42e9f 100644 --- a/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/TestValidation.java +++ b/deeplearning4j/deeplearning4j-scaleout/spark/dl4j-spark/src/test/java/org/deeplearning4j/spark/util/TestValidation.java @@ -26,9 +26,12 @@ import org.deeplearning4j.spark.BaseSparkTest; import org.deeplearning4j.spark.util.data.SparkDataValidation; import org.deeplearning4j.spark.util.data.ValidationResult; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.dataset.MultiDataSet; @@ -41,7 +44,10 @@ import java.util.Arrays; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertFalse; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SPARK) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestValidation extends BaseSparkTest { @Test diff --git a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-components/src/test/java/org/deeplearning4j/ui/TestComponentSerialization.java b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-components/src/test/java/org/deeplearning4j/ui/TestComponentSerialization.java index 6596c526c..5e67cb09d 100644 --- a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-components/src/test/java/org/deeplearning4j/ui/TestComponentSerialization.java +++ b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-components/src/test/java/org/deeplearning4j/ui/TestComponentSerialization.java @@ -34,7 +34,10 @@ 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.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.shade.jackson.databind.ObjectMapper; import java.awt.*; @@ -42,7 +45,10 @@ import java.util.ArrayList; import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.UI) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestComponentSerialization extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-components/src/test/java/org/deeplearning4j/ui/TestRendering.java b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-components/src/test/java/org/deeplearning4j/ui/TestRendering.java index b72c0b4e2..5e369b45d 100644 --- a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-components/src/test/java/org/deeplearning4j/ui/TestRendering.java +++ b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-components/src/test/java/org/deeplearning4j/ui/TestRendering.java @@ -36,7 +36,10 @@ 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.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.shade.jackson.databind.ObjectMapper; import java.awt.*; @@ -45,7 +48,10 @@ import java.util.ArrayList; import java.util.List; import java.util.Random; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.UI) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestRendering extends BaseDL4JTest { @Disabled diff --git a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-components/src/test/java/org/deeplearning4j/ui/TestStandAlone.java b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-components/src/test/java/org/deeplearning4j/ui/TestStandAlone.java index 2073d806f..7b4a23ae9 100644 --- a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-components/src/test/java/org/deeplearning4j/ui/TestStandAlone.java +++ b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-components/src/test/java/org/deeplearning4j/ui/TestStandAlone.java @@ -29,10 +29,16 @@ import org.deeplearning4j.ui.components.table.ComponentTable; import org.deeplearning4j.ui.components.table.style.StyleTable; import org.deeplearning4j.ui.standalone.StaticPageUtil; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.awt.*; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.UI) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestStandAlone extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/TestStorageMetaData.java b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/TestStorageMetaData.java index e31fc1541..2a69cbdc8 100644 --- a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/TestStorageMetaData.java +++ b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/TestStorageMetaData.java @@ -23,12 +23,18 @@ package org.deeplearning4j.ui; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.core.storage.StorageMetaData; import org.deeplearning4j.ui.model.storage.impl.SbeStorageMetaData; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.io.Serializable; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.UI) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestStorageMetaData extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/stats/TestStatsClasses.java b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/stats/TestStatsClasses.java index 0d9f60a24..784246107 100644 --- a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/stats/TestStatsClasses.java +++ b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/stats/TestStatsClasses.java @@ -25,8 +25,11 @@ import org.deeplearning4j.ui.model.stats.api.*; import org.deeplearning4j.ui.model.stats.impl.SbeStatsInitializationReport; import org.deeplearning4j.ui.model.stats.impl.SbeStatsReport; import org.deeplearning4j.ui.model.stats.impl.java.JavaStatsInitializationReport; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.primitives.Pair; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.io.*; import java.util.ArrayList; @@ -35,7 +38,10 @@ import java.util.List; import java.util.Map; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.UI) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestStatsClasses extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/stats/TestStatsListener.java b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/stats/TestStatsListener.java index 56952d870..c1a44f8bd 100644 --- a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/stats/TestStatsListener.java +++ b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/stats/TestStatsListener.java @@ -32,7 +32,10 @@ import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.ui.model.stats.J7StatsListener; import org.deeplearning4j.ui.model.stats.StatsListener; import org.deeplearning4j.ui.model.storage.mapdb.MapDBStatsStorage; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.lossfunctions.LossFunctions; @@ -41,7 +44,10 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotNull; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.UI) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestStatsListener extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/stats/TestTransferStatsCollection.java b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/stats/TestTransferStatsCollection.java index b32c4f143..c647c3e89 100644 --- a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/stats/TestTransferStatsCollection.java +++ b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/stats/TestTransferStatsCollection.java @@ -32,8 +32,11 @@ import org.deeplearning4j.ui.model.stats.StatsListener; import org.deeplearning4j.ui.model.storage.FileStatsStorage; import org.deeplearning4j.ui.model.storage.InMemoryStatsStorage; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.factory.Nd4j; @@ -41,7 +44,10 @@ import org.nd4j.linalg.learning.config.Sgd; import java.io.File; import java.io.IOException; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.UI) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestTransferStatsCollection extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/storage/TestStatsStorage.java b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/storage/TestStatsStorage.java index 18d819a80..008915ec6 100644 --- a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/storage/TestStatsStorage.java +++ b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui-model/src/test/java/org/deeplearning4j/ui/storage/TestStatsStorage.java @@ -38,8 +38,11 @@ import org.deeplearning4j.ui.model.storage.mapdb.MapDBStatsStorage; import org.deeplearning4j.ui.model.storage.sqlite.J7FileStatsStorage; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.io.File; @@ -48,7 +51,10 @@ import java.nio.file.Path; import java.util.*; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.UI) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestStatsStorage extends BaseDL4JTest { diff --git a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui/src/test/java/org/deeplearning4j/ui/weights/HistogramBinTest.java b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui/src/test/java/org/deeplearning4j/ui/weights/HistogramBinTest.java index dc9219629..11d58d775 100644 --- a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui/src/test/java/org/deeplearning4j/ui/weights/HistogramBinTest.java +++ b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui/src/test/java/org/deeplearning4j/ui/weights/HistogramBinTest.java @@ -21,14 +21,20 @@ package org.deeplearning4j.ui.weights; import org.deeplearning4j.ui.model.weights.HistogramBin; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import java.math.BigDecimal; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.UI) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class HistogramBinTest { diff --git a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui/src/test/java/org/deeplearning4j/ui/weights/TestConvolutionalListener.java b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui/src/test/java/org/deeplearning4j/ui/weights/TestConvolutionalListener.java index d3c0e04a9..0daf0c21d 100644 --- a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui/src/test/java/org/deeplearning4j/ui/weights/TestConvolutionalListener.java +++ b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-ui/src/test/java/org/deeplearning4j/ui/weights/TestConvolutionalListener.java @@ -34,12 +34,18 @@ import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.optimize.listeners.ScoreIterationListener; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.linalg.learning.config.Nesterovs; import org.nd4j.linalg.lossfunctions.LossFunctions; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.UI) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestConvolutionalListener { @Test diff --git a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestRemoteReceiver.java b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestRemoteReceiver.java index 8ca018ef8..442895092 100644 --- a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestRemoteReceiver.java +++ b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestRemoteReceiver.java @@ -39,7 +39,10 @@ import org.deeplearning4j.ui.model.stats.impl.SbeStatsInitializationReport; import org.deeplearning4j.ui.model.stats.impl.SbeStatsReport; import org.deeplearning4j.ui.model.storage.impl.SbeStorageMetaData; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.linalg.lossfunctions.LossFunctions; @@ -52,6 +55,10 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; @Disabled +@Tag(TagNames.FILE_IO) +@Tag(TagNames.UI) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestRemoteReceiver extends BaseDL4JTest { @Test diff --git a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestSameDiffUI.java b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestSameDiffUI.java index fccd4bb5d..14ba10f66 100644 --- a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestSameDiffUI.java +++ b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestSameDiffUI.java @@ -23,10 +23,13 @@ package org.deeplearning4j.ui; import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.ui.api.UIServer; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.nd4j.autodiff.samediff.SDVariable; import org.nd4j.autodiff.samediff.SameDiff; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.graph.ui.LogFileWriter; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -39,6 +42,10 @@ import java.nio.file.Path; import java.util.Arrays; @Disabled +@Tag(TagNames.FILE_IO) +@Tag(TagNames.UI) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestSameDiffUI extends BaseDL4JTest { private static Logger log = LoggerFactory.getLogger(TestSameDiffUI.class.getName()); diff --git a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestVertxUI.java b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestVertxUI.java index 1f62def9a..4919322b4 100644 --- a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestVertxUI.java +++ b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestVertxUI.java @@ -46,7 +46,10 @@ import org.deeplearning4j.ui.model.stats.StatsListener; import org.deeplearning4j.ui.model.storage.InMemoryStatsStorage; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.common.function.Function; @@ -64,6 +67,10 @@ import java.util.concurrent.CountDownLatch; import static org.junit.jupiter.api.Assertions.*; @Disabled +@Tag(TagNames.FILE_IO) +@Tag(TagNames.UI) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestVertxUI extends BaseDL4JTest { private static Logger log = LoggerFactory.getLogger(TestVertxUI.class.getName()); diff --git a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestVertxUIManual.java b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestVertxUIManual.java index f442135ad..cf457071c 100644 --- a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestVertxUIManual.java +++ b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestVertxUIManual.java @@ -39,7 +39,10 @@ import org.deeplearning4j.ui.api.UIServer; import org.deeplearning4j.ui.model.stats.StatsListener; import org.deeplearning4j.ui.model.storage.InMemoryStatsStorage; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.common.function.Function; @@ -58,6 +61,10 @@ import java.util.concurrent.CountDownLatch; import static org.junit.jupiter.api.Assertions.*; @Disabled +@Tag(TagNames.FILE_IO) +@Tag(TagNames.UI) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TestVertxUIManual extends BaseDL4JTest { private static Logger log = LoggerFactory.getLogger(TestVertxUIManual.class.getName()); diff --git a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestVertxUIMultiSession.java b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestVertxUIMultiSession.java index db1c7808d..2a6f70c8b 100644 --- a/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestVertxUIMultiSession.java +++ b/deeplearning4j/deeplearning4j-ui-parent/deeplearning4j-vertx/src/test/java/org/deeplearning4j/ui/TestVertxUIMultiSession.java @@ -38,7 +38,10 @@ import org.deeplearning4j.ui.model.stats.StatsListener; import org.deeplearning4j.ui.model.storage.InMemoryStatsStorage; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.common.function.Function; @@ -60,6 +63,10 @@ import static org.junit.jupiter.api.Assertions.*; * @author Tamas Fenyvesi */ @Disabled //https://github.com/eclipse/deeplearning4j/issues/8891 + @Tag(TagNames.FILE_IO) + @Tag(TagNames.UI) + @Tag(TagNames.DIST_SYSTEMS) + @NativeTag public class TestVertxUIMultiSession extends BaseDL4JTest { private static Logger log = LoggerFactory.getLogger(TestVertxUIMultiSession.class.getName()); diff --git a/deeplearning4j/deeplearning4j-zoo/src/test/java/org/deeplearning4j/zoo/MiscTests.java b/deeplearning4j/deeplearning4j-zoo/src/test/java/org/deeplearning4j/zoo/MiscTests.java index e1af69fab..cb7c5264a 100644 --- a/deeplearning4j/deeplearning4j-zoo/src/test/java/org/deeplearning4j/zoo/MiscTests.java +++ b/deeplearning4j/deeplearning4j-zoo/src/test/java/org/deeplearning4j/zoo/MiscTests.java @@ -27,7 +27,10 @@ import org.deeplearning4j.nn.transferlearning.TransferLearning; import org.deeplearning4j.nn.weights.WeightInit; import org.deeplearning4j.zoo.model.VGG16; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.factory.Nd4j; @@ -35,6 +38,9 @@ import org.nd4j.linalg.lossfunctions.LossFunctions; import java.io.File; @Disabled("Times out too often") +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag public class MiscTests extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-zoo/src/test/java/org/deeplearning4j/zoo/TestDownload.java b/deeplearning4j/deeplearning4j-zoo/src/test/java/org/deeplearning4j/zoo/TestDownload.java index 5e768d6f3..b63563cf8 100644 --- a/deeplearning4j/deeplearning4j-zoo/src/test/java/org/deeplearning4j/zoo/TestDownload.java +++ b/deeplearning4j/deeplearning4j-zoo/src/test/java/org/deeplearning4j/zoo/TestDownload.java @@ -33,6 +33,8 @@ import org.deeplearning4j.zoo.util.darknet.DarknetLabels; import org.deeplearning4j.zoo.util.imagenet.ImageNetLabels; import org.junit.jupiter.api.*; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import java.io.File; @@ -46,6 +48,9 @@ import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j @Disabled("Times out too often") +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag public class TestDownload extends BaseDL4JTest { @TempDir static Path sharedTempDir; diff --git a/deeplearning4j/deeplearning4j-zoo/src/test/java/org/deeplearning4j/zoo/TestImageNet.java b/deeplearning4j/deeplearning4j-zoo/src/test/java/org/deeplearning4j/zoo/TestImageNet.java index 434d5e25d..7f4d2686d 100644 --- a/deeplearning4j/deeplearning4j-zoo/src/test/java/org/deeplearning4j/zoo/TestImageNet.java +++ b/deeplearning4j/deeplearning4j-zoo/src/test/java/org/deeplearning4j/zoo/TestImageNet.java @@ -38,7 +38,10 @@ import org.deeplearning4j.zoo.util.darknet.DarknetLabels; import org.deeplearning4j.zoo.util.darknet.VOCLabels; import org.deeplearning4j.zoo.util.imagenet.ImageNetLabels; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.api.preprocessor.DataNormalization; @@ -55,6 +58,9 @@ import static org.junit.jupiter.api.Assertions.assertTrue; @Slf4j @Disabled("Times out too often") +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag public class TestImageNet extends BaseDL4JTest { @Override diff --git a/deeplearning4j/deeplearning4j-zoo/src/test/java/org/deeplearning4j/zoo/TestInstantiation.java b/deeplearning4j/deeplearning4j-zoo/src/test/java/org/deeplearning4j/zoo/TestInstantiation.java index 06e72fcb7..746b7cfc8 100644 --- a/deeplearning4j/deeplearning4j-zoo/src/test/java/org/deeplearning4j/zoo/TestInstantiation.java +++ b/deeplearning4j/deeplearning4j-zoo/src/test/java/org/deeplearning4j/zoo/TestInstantiation.java @@ -36,7 +36,10 @@ import org.deeplearning4j.zoo.model.*; import org.deeplearning4j.zoo.model.helper.DarknetHelper; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -53,6 +56,9 @@ import static org.junit.jupiter.api.Assumptions.assumeTrue; @Slf4j @Disabled("Times out too often") +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag public class TestInstantiation extends BaseDL4JTest { protected static void ignoreIfCuda(){ diff --git a/deeplearning4j/dl4j-integration-tests/src/test/java/org/deeplearning4j/integration/IntegrationTestsDL4J.java b/deeplearning4j/dl4j-integration-tests/src/test/java/org/deeplearning4j/integration/IntegrationTestsDL4J.java index 3180f7d38..acb1f060c 100644 --- a/deeplearning4j/dl4j-integration-tests/src/test/java/org/deeplearning4j/integration/IntegrationTestsDL4J.java +++ b/deeplearning4j/dl4j-integration-tests/src/test/java/org/deeplearning4j/integration/IntegrationTestsDL4J.java @@ -24,13 +24,19 @@ import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.integration.testcases.dl4j.*; import org.junit.jupiter.api.AfterEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.nio.file.Path; //@Disabled("AB - 2019/05/27 - Integration tests need to be updated") +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag public class IntegrationTestsDL4J extends BaseDL4JTest { @TempDir static Path testDir; diff --git a/deeplearning4j/dl4j-integration-tests/src/test/java/org/deeplearning4j/integration/IntegrationTestsSameDiff.java b/deeplearning4j/dl4j-integration-tests/src/test/java/org/deeplearning4j/integration/IntegrationTestsSameDiff.java index 0cc6672a8..6dd41c698 100644 --- a/deeplearning4j/dl4j-integration-tests/src/test/java/org/deeplearning4j/integration/IntegrationTestsSameDiff.java +++ b/deeplearning4j/dl4j-integration-tests/src/test/java/org/deeplearning4j/integration/IntegrationTestsSameDiff.java @@ -23,12 +23,17 @@ import org.deeplearning4j.BaseDL4JTest; import org.deeplearning4j.integration.testcases.samediff.SameDiffCNNCases; import org.deeplearning4j.integration.testcases.samediff.SameDiffMLPTestCases; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.nio.file.Path; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SAMEDIFF) +@NativeTag public class IntegrationTestsSameDiff extends BaseDL4JTest { @TempDir diff --git a/deeplearning4j/pom.xml b/deeplearning4j/pom.xml index 1212df5d6..384f8a081 100644 --- a/deeplearning4j/pom.xml +++ b/deeplearning4j/pom.xml @@ -40,7 +40,7 @@ - scm:git://github.com:deeplearning4j/deeplearning4j.git + scm:git://github.com:eclipse/deeplearning4j.git scm:git:git@github.com:eclipse/deeplearning4j.git git@github.com:eclipse/deeplearning4j.git @@ -126,6 +126,24 @@ ${lombok.version} provided + + org.nd4j + nd4j-common-tests + 1.0.0-SNAPSHOT + test + + + com.google.android + android + 4.1.1.4 + test + + + org.deeplearning4j + deeplearning4j-common-tests + 1.0.0-SNAPSHOT + test + @@ -298,6 +316,11 @@ ${nd4j.version} test + + org.deeplearning4j + deeplearning4j-cuda-11.0 + ${nd4j.version} + diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/TestSessions.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/TestSessions.java index 833f2bef5..d675075e9 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/TestSessions.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/TestSessions.java @@ -20,6 +20,7 @@ package org.nd4j.autodiff; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Timeout; import org.junit.jupiter.params.ParameterizedTest; @@ -32,6 +33,8 @@ import org.nd4j.autodiff.samediff.internal.AbstractSession; import org.nd4j.autodiff.samediff.internal.FrameIter; import org.nd4j.autodiff.samediff.internal.InferenceSession; import org.nd4j.autodiff.samediff.internal.memory.NoOpMemoryMgr; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.imports.graphmapper.tf.TFGraphMapper; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; @@ -39,6 +42,7 @@ import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.linalg.factory.Nd4jBackend; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.samediff.frameworkimport.tensorflow.importer.TensorflowFrameworkImporter; import java.io.File; import java.util.Arrays; @@ -48,6 +52,8 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.*; +@NativeTag +@Tag(TagNames.SAMEDIFF) public class TestSessions extends BaseNd4jTestWithBackends { @Override @@ -222,7 +228,8 @@ public class TestSessions extends BaseNd4jTestWithBackends { for( int numIter : new int[]{1,3}) { File f = new ClassPathResource("tf_graphs/examples/while1/iter_" + numIter + "/frozen_model.pb").getFile(); - SameDiff sd = TFGraphMapper.importGraph(f); + TensorflowFrameworkImporter tensorflowFrameworkImporter = new TensorflowFrameworkImporter(); + SameDiff sd = tensorflowFrameworkImporter.runImport(f.getAbsolutePath(),null); // System.out.println(sd.summary()); sd.summary(); @@ -235,7 +242,7 @@ public class TestSessions extends BaseNd4jTestWithBackends { String n2 = "while/Exit_1"; Map m = is.output(Arrays.asList(n, n2), Collections.emptyMap(), null, - Collections.emptyList(), null, At.defaultAt(Operation.TRAINING)); + Collections.emptyList(), null, At.defaultAt(Operation.TRAINING)); assertEquals(2, m.size()); INDArray exp = Nd4j.scalar((float)numIter); @@ -246,7 +253,7 @@ public class TestSessions extends BaseNd4jTestWithBackends { Map outputs = is.getNodeOutputs(); //Some sanity checks on the internal state: //Check 1: "while/Less" should be executed numIter+1 times... i.e., numIter times through the loop, plus once to exit - for( int i=0; i dt = new DependencyTracker<>(); //Check different order of adding dependencies: i.e., mark X as satisfied, then add x -> y dependency @@ -132,7 +132,7 @@ public class TestDependencyTracker extends BaseNd4jTestWithBackends { assertFalse(dt.hasNewAllSatisfied()); } - @ParameterizedTest + @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") public void testMarkUnsatisfied(Nd4jBackend backend){ @@ -165,8 +165,9 @@ public class TestDependencyTracker extends BaseNd4jTestWithBackends { } - @ParameterizedTest + @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") + @NativeTag public void testIdentityDependencyTracker(){ IdentityDependencyTracker dt = new IdentityDependencyTracker<>(); assertTrue(dt.isEmpty()); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/ActivationGradChecks.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/ActivationGradChecks.java index a8fe416bc..becbab9dc 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/ActivationGradChecks.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/ActivationGradChecks.java @@ -20,12 +20,15 @@ package org.nd4j.autodiff.opvalidation; -import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.autodiff.samediff.SDVariable; import org.nd4j.autodiff.samediff.SameDiff; import org.nd4j.autodiff.validation.GradCheckUtil; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; +import org.nd4j.common.tests.tags.TrainingTag; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -38,6 +41,9 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.assertTrue; +@NativeTag +@Tag(TagNames.SAMEDIFF) +@TrainingTag public class ActivationGradChecks extends BaseOpValidation { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/LayerOpValidation.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/LayerOpValidation.java index d11881051..30fb04f31 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/LayerOpValidation.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/LayerOpValidation.java @@ -26,6 +26,7 @@ import java.util.Collections; import java.util.List; import lombok.extern.slf4j.Slf4j; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.TestInfo; import org.junit.jupiter.params.ParameterizedTest; @@ -34,6 +35,8 @@ import org.nd4j.autodiff.samediff.SDVariable; import org.nd4j.autodiff.samediff.SameDiff; import org.nd4j.autodiff.validation.OpValidation; import org.nd4j.autodiff.validation.TestCase; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.iter.NdIndexIterator; import org.nd4j.linalg.api.ndarray.INDArray; @@ -67,6 +70,8 @@ import org.nd4j.linalg.ops.transforms.Transforms; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag +@Tag(TagNames.SAMEDIFF) public class LayerOpValidation extends BaseOpValidation { @Override diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/LossOpValidation.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/LossOpValidation.java index 4b125cae7..8f74591e5 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/LossOpValidation.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/LossOpValidation.java @@ -30,6 +30,7 @@ import org.nd4j.autodiff.samediff.SDVariable; import org.nd4j.autodiff.samediff.SameDiff; import org.nd4j.autodiff.validation.OpValidation; import org.nd4j.autodiff.validation.TestCase; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.ops.CustomOp; @@ -44,8 +45,9 @@ import java.util.*; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag public class LossOpValidation extends BaseOpValidation { - + @Override public long getTimeoutMilliseconds() { @@ -65,7 +67,7 @@ public class LossOpValidation extends BaseOpValidation { List failed = new ArrayList<>(); int totalRun = 0; - for (String fn : new String[]{ + for (String fn : new String[] { "log_poisson", "log_poisson_full", "absdiff", "cosine", "hinge", "huber", "log", "mse", "sigmoidxent", "sigmoidxent_smooth", "softmaxxent", "softmaxxent_smooth", "mpwse", diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/MiscOpValidation.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/MiscOpValidation.java index a7eb3b6da..1dbd5f39b 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/MiscOpValidation.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/MiscOpValidation.java @@ -23,6 +23,7 @@ package org.nd4j.autodiff.opvalidation; import lombok.extern.slf4j.Slf4j; import lombok.val; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; @@ -80,6 +81,7 @@ import static org.junit.jupiter.api.Assertions.*; import static org.junit.jupiter.api.Assumptions.*; @Slf4j +@Tag("samediff") public class MiscOpValidation extends BaseOpValidation { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/RandomOpValidation.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/RandomOpValidation.java index 8d2032169..9cba3ccf5 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/RandomOpValidation.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/RandomOpValidation.java @@ -21,6 +21,7 @@ package org.nd4j.autodiff.opvalidation; import lombok.extern.slf4j.Slf4j; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; @@ -30,6 +31,8 @@ import org.nd4j.autodiff.samediff.SameDiff; import org.nd4j.autodiff.validation.OpTestCase; import org.nd4j.autodiff.validation.OpValidation; import org.nd4j.autodiff.validation.TestCase; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.iter.NdIndexIterator; import org.nd4j.linalg.api.ndarray.INDArray; @@ -51,6 +54,8 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag +@Tag(TagNames.RNG) public class RandomOpValidation extends BaseOpValidation { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/ReductionBpOpValidation.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/ReductionBpOpValidation.java index 3681c77b8..78bc9bfbf 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/ReductionBpOpValidation.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/ReductionBpOpValidation.java @@ -28,6 +28,7 @@ import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.autodiff.validation.OpTestCase; import org.nd4j.autodiff.validation.OpValidation; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.ops.impl.reduce.bp.CumSumBp; @@ -49,6 +50,7 @@ import org.nd4j.nativeblas.NativeOpsHolder; import static org.junit.jupiter.api.Assertions.assertNull; @Slf4j +@NativeTag public class ReductionBpOpValidation extends BaseOpValidation { private DataType initialType; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/ReductionOpValidation.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/ReductionOpValidation.java index f9cf6cf5a..a479e9c61 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/ReductionOpValidation.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/ReductionOpValidation.java @@ -33,6 +33,7 @@ import org.nd4j.autodiff.samediff.SameDiff; import org.nd4j.autodiff.validation.OpTestCase; import org.nd4j.autodiff.validation.OpValidation; import org.nd4j.autodiff.validation.TestCase; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.ops.CustomOp; @@ -77,7 +78,7 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.*; @Slf4j - +@NativeTag public class ReductionOpValidation extends BaseOpValidation { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/RnnOpValidation.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/RnnOpValidation.java index 97ccef82c..c1a9538c3 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/RnnOpValidation.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/RnnOpValidation.java @@ -21,11 +21,14 @@ package org.nd4j.autodiff.opvalidation; import lombok.extern.slf4j.Slf4j; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.autodiff.samediff.SDVariable; import org.nd4j.autodiff.samediff.SameDiff; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.ops.impl.layers.recurrent.config.LSTMConfiguration; @@ -44,6 +47,8 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j +@NativeTag +@Tag(TagNames.SAMEDIFF) public class RnnOpValidation extends BaseOpValidation { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/ShapeOpValidation.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/ShapeOpValidation.java index aede7d6ba..feedb6e41 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/ShapeOpValidation.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/ShapeOpValidation.java @@ -27,6 +27,7 @@ import lombok.extern.slf4j.Slf4j; import lombok.val; import org.apache.commons.math3.linear.LUDecomposition; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.TestInfo; import org.junit.jupiter.params.ParameterizedTest; @@ -37,6 +38,8 @@ import org.nd4j.autodiff.samediff.SameDiff; import org.nd4j.autodiff.validation.OpTestCase; import org.nd4j.autodiff.validation.OpValidation; import org.nd4j.autodiff.validation.TestCase; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.ops.DynamicCustomOp; @@ -69,6 +72,8 @@ import static org.junit.jupiter.api.Assertions.*; import static org.nd4j.linalg.indexing.NDArrayIndex.*; @Slf4j +@NativeTag +@Tag(TagNames.SAMEDIFF) public class ShapeOpValidation extends BaseOpValidation { /* diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/TransformOpValidation.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/TransformOpValidation.java index a0dec5b66..b5fe68361 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/TransformOpValidation.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/opvalidation/TransformOpValidation.java @@ -22,16 +22,15 @@ package org.nd4j.autodiff.opvalidation; import lombok.extern.slf4j.Slf4j; import lombok.val; -import org.junit.jupiter.api.AfterEach; -import org.junit.jupiter.api.BeforeEach; -import org.junit.jupiter.api.Disabled; -import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.*; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.OpValidationSuite; import org.nd4j.autodiff.functions.DifferentialFunction; import org.nd4j.autodiff.samediff.SDVariable; import org.nd4j.autodiff.samediff.SameDiff; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.enums.DataFormat; import org.nd4j.autodiff.validation.OpTestCase; import org.nd4j.autodiff.validation.OpValidation; @@ -92,6 +91,8 @@ import java.util.*; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag +@Tag(TagNames.SAMEDIFF) public class TransformOpValidation extends BaseOpValidation { private DataType initialType; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/ConvConfigTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/ConvConfigTests.java index 70a0ef950..d144c42ff 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/ConvConfigTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/ConvConfigTests.java @@ -23,9 +23,11 @@ package org.nd4j.autodiff.samediff; import static org.junit.jupiter.api.Assertions.assertTrue; import static org.junit.jupiter.api.Assertions.fail; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ops.impl.layers.convolution.config.Conv1DConfig; import org.nd4j.linalg.api.ops.impl.layers.convolution.config.Conv2DConfig; @@ -37,6 +39,7 @@ import org.nd4j.linalg.api.ops.impl.layers.convolution.config.Pooling2DConfig; import org.nd4j.linalg.api.ops.impl.layers.convolution.config.Pooling3DConfig; import org.nd4j.linalg.factory.Nd4jBackend; +@Tag(TagNames.JAVA_ONLY) public class ConvConfigTests extends BaseNd4jTestWithBackends { @@ -107,9 +110,9 @@ public class ConvConfigTests extends BaseNd4jTestWithBackends { } } - @ParameterizedTest + @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") - public void testConv2D(Nd4jBackend backend){ + public void testConv2D(Nd4jBackend backend) { Conv2DConfig.builder().kH(2).kW(4).build(); try{ @@ -169,7 +172,7 @@ public class ConvConfigTests extends BaseNd4jTestWithBackends { } } - @ParameterizedTest + @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") public void testPooling2D(Nd4jBackend backend){ Pooling2DConfig.builder().kH(2).kW(4).build(); @@ -231,7 +234,7 @@ public class ConvConfigTests extends BaseNd4jTestWithBackends { } } - @ParameterizedTest + @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") public void testDeConv3D(Nd4jBackend backend){ DeConv3DConfig.builder().kH(2).kW(4).kD(3).build(); @@ -321,7 +324,7 @@ public class ConvConfigTests extends BaseNd4jTestWithBackends { } } - @ParameterizedTest + @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") public void testConv3D(Nd4jBackend backend){ Conv3DConfig.builder().kH(2).kW(4).kD(3).build(); @@ -413,7 +416,7 @@ public class ConvConfigTests extends BaseNd4jTestWithBackends { - @ParameterizedTest + @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") public void testPooling3D(Nd4jBackend backend){ Pooling3DConfig.builder().kH(2).kW(4).kD(3).build(); @@ -503,7 +506,7 @@ public class ConvConfigTests extends BaseNd4jTestWithBackends { } } - @ParameterizedTest + @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") public void testConv1D(){ Conv1DConfig.builder().k(2).paddingMode(PaddingMode.SAME).build(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/FailingSameDiffTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/FailingSameDiffTests.java index 273d2e9d3..8c8cca0f5 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/FailingSameDiffTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/FailingSameDiffTests.java @@ -22,10 +22,13 @@ package org.nd4j.autodiff.samediff; import lombok.val; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.OpValidationSuite; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -41,7 +44,8 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertArrayEquals; import static org.junit.jupiter.api.Assertions.assertEquals; -@Disabled("AB 2019/05/21 - JVM Crash on ppc64 - Issue #7657") +@NativeTag +@Tag(TagNames.SAMEDIFF) public class FailingSameDiffTests extends BaseNd4jTestWithBackends { @@ -53,10 +57,9 @@ public class FailingSameDiffTests extends BaseNd4jTestWithBackends { @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") public void testEye(Nd4jBackend backend){ - //OpValidationSuite.ignoreFailing(); INDArray arr = Nd4j.create(new double[]{1, 0, 0, 0, 1, 0}, new int[]{2, 3}); List stack = new ArrayList<>(); - for(int i=0; i< 25; i++){ + for(int i = 0; i < 25; i++){ stack.add(arr); } INDArray expOut = Nd4j.pile(stack).reshape(5, 5, 2, 3); @@ -69,7 +72,7 @@ public class FailingSameDiffTests extends BaseNd4jTestWithBackends { @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") - public void testEyeShape(Nd4jBackend backend){ + public void testEyeShape(Nd4jBackend backend) { val dco = DynamicCustomOp.builder("eye") .addIntegerArguments(3,3) //.addIntegerArguments(-99,3,3) //Also fails @@ -83,7 +86,6 @@ public class FailingSameDiffTests extends BaseNd4jTestWithBackends { @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") public void testExecutionDifferentShapesTransform(Nd4jBackend backend){ - OpValidationSuite.ignoreFailing(); SameDiff sd = SameDiff.create(); SDVariable in = sd.var("in", Nd4j.linspace(1,12,12, DataType.DOUBLE).reshape(3,4)); @@ -105,7 +107,6 @@ public class FailingSameDiffTests extends BaseNd4jTestWithBackends { @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") public void testDropout(Nd4jBackend backend) { - OpValidationSuite.ignoreFailing(); SameDiff sd = SameDiff.create(); double p = 0.5; INDArray ia = Nd4j.create(new long[]{2, 2}); @@ -119,7 +120,6 @@ public class FailingSameDiffTests extends BaseNd4jTestWithBackends { @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") public void testExecutionDifferentShapesDynamicCustom(Nd4jBackend backend){ - OpValidationSuite.ignoreFailing(); SameDiff sd = SameDiff.create(); SDVariable in = sd.var("in", Nd4j.linspace(1,12,12, DataType.DOUBLE).reshape(3,4)); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/FlatBufferSerdeTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/FlatBufferSerdeTest.java index 42f93b98e..def1e8c39 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/FlatBufferSerdeTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/FlatBufferSerdeTest.java @@ -23,12 +23,15 @@ package org.nd4j.autodiff.samediff; import lombok.extern.slf4j.Slf4j; import org.apache.commons.io.IOUtils; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.autodiff.functions.DifferentialFunction; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.graph.FlatConfiguration; import org.nd4j.graph.FlatGraph; import org.nd4j.graph.FlatNode; @@ -70,6 +73,9 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@Tag(TagNames.FILE_IO) +@Tag(TagNames.SAMEDIFF) +@NativeTag public class FlatBufferSerdeTest extends BaseNd4jTestWithBackends { @TempDir Path testDir; @@ -333,7 +339,7 @@ public class FlatBufferSerdeTest extends BaseNd4jTestWithBackends { //Check training post deserialization - for( int i=0; i<3; i++ ){ + for( int i = 0; i < 3; i++) { sd.fit(ds); sd2.fit(ds); } @@ -355,7 +361,7 @@ public class FlatBufferSerdeTest extends BaseNd4jTestWithBackends { @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") - public void pooling3DSerialization(Nd4jBackend backend){ + public void pooling3DSerialization(Nd4jBackend backend) { SameDiff sd = SameDiff.create(); SDVariable x = sd.placeHolder("x", DataType.FLOAT, 1, 28, 28); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/GraphTransformUtilTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/GraphTransformUtilTests.java index 5aba28584..3c895239c 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/GraphTransformUtilTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/GraphTransformUtilTests.java @@ -21,6 +21,7 @@ package org.nd4j.autodiff.samediff; import lombok.extern.slf4j.Slf4j; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; @@ -29,6 +30,7 @@ import org.nd4j.autodiff.samediff.transform.OpPredicate; import org.nd4j.autodiff.samediff.transform.SubGraph; import org.nd4j.autodiff.samediff.transform.SubGraphPredicate; import org.nd4j.autodiff.samediff.transform.SubGraphProcessor; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -44,6 +46,7 @@ import static org.junit.jupiter.api.Assertions.assertFalse; import static org.junit.jupiter.api.Assertions.assertTrue; @Slf4j +@Tag(TagNames.SAMEDIFF) public class GraphTransformUtilTests extends BaseNd4jTestWithBackends { @@ -54,7 +57,7 @@ public class GraphTransformUtilTests extends BaseNd4jTestWithBackends { @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") - public void testBasic(Nd4jBackend backend){ + public void testBasic(Nd4jBackend backend) { SameDiff sd = SameDiff.create(); SDVariable ph1 = sd.placeHolder("ph1", DataType.FLOAT, -1, 32); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/MemoryMgrTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/MemoryMgrTest.java index 0f09e4632..030df9791 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/MemoryMgrTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/MemoryMgrTest.java @@ -20,10 +20,12 @@ package org.nd4j.autodiff.samediff; -import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.autodiff.samediff.internal.memory.ArrayCacheMemoryMgr; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -34,6 +36,9 @@ import java.lang.reflect.Field; import static org.junit.jupiter.api.Assertions.*; +@NativeTag +@Tag(TagNames.SAMEDIFF) +@Tag(TagNames.WORKSPACES) public class MemoryMgrTest extends BaseNd4jTestWithBackends { @@ -73,7 +78,7 @@ public class MemoryMgrTest extends BaseNd4jTestWithBackends { //At this point: array store is full. //If we try to release more, the oldest (first released) values should be closed - for( int i=0; i<10; i++ ) { + for( int i=0; i < 10; i++) { INDArray toRelease = Nd4j.create(DataType.FLOAT, 25); mmgr.release(toRelease); //oldest N only should be closed by this point... diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/NameScopeTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/NameScopeTests.java index c2724b585..739b50689 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/NameScopeTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/NameScopeTests.java @@ -20,11 +20,13 @@ package org.nd4j.autodiff.samediff; -import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.autodiff.samediff.internal.SameDiffOp; import org.nd4j.autodiff.samediff.internal.Variable; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.factory.Nd4jBackend; @@ -37,6 +39,9 @@ import java.util.Set; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; + +@Tag(TagNames.SAMEDIFF) +@NativeTag public class NameScopeTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/SameDiffMultiThreadTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/SameDiffMultiThreadTests.java index 7d44be585..4e2516897 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/SameDiffMultiThreadTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/autodiff/samediff/SameDiffMultiThreadTests.java @@ -21,11 +21,13 @@ package org.nd4j.autodiff.samediff; import lombok.extern.slf4j.Slf4j; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.common.primitives.AtomicBoolean; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -40,6 +42,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertFalse; @Slf4j +@Tag(TagNames.SAMEDIFF) +@Tag(TagNames.MULTI_THREADED) public class SameDiffMultiThreadTests extends BaseND4JTest { @@ -105,7 +109,7 @@ public class SameDiffMultiThreadTests extends BaseND4JTest { String inName, String outName, AtomicBoolean[] failuresByThread, AtomicInteger[] counters, Semaphore s, CountDownLatch latch){ - for( int i=0; i= max[i]){ + for( int j = 0; j < exp.length; j++ ){ + if(max[i] != null && dIn[j] >= max[i]) { exp[j] = max[i]; } else if(dIn[j] < threshold[i]){ exp[j] = negativeSlope[i] * (dIn[j] - threshold[i]); @@ -108,7 +112,7 @@ public class TestActivation extends BaseNd4jTestWithBackends { //Test backprop INDArray eps = Nd4j.arange(in.length()).castTo(DataType.DOUBLE); double[] dEps = eps.data().asDouble(); - for( int i=0; i p = r.backprop(in.dup(), eps.dup()); INDArray grad = p.getFirst(); @@ -132,6 +136,7 @@ public class TestActivation extends BaseNd4jTestWithBackends { @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") + @Tag(TagNames.JACKSON_SERDE) public void testJson(Nd4jBackend backend) throws Exception { IActivation[] activations = new IActivation[] {new ActivationCube(), new ActivationELU(0.25), diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestBackend.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestBackend.java index 273499c8c..672215af5 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestBackend.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestBackend.java @@ -19,20 +19,23 @@ */ package org.nd4j.linalg.api; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.assertFalse; - +@NativeTag public class TestBackend extends BaseNd4jTestWithBackends { - @ParameterizedTest + @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") - public void testBuildInfo(Nd4jBackend backend){ + public void testBuildInfo(Nd4jBackend backend) { System.out.println("Backend build info: " + backend.buildInfo()); } } diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestEnvironment.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestEnvironment.java index 4dd36aedb..fc28dcc41 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestEnvironment.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestEnvironment.java @@ -19,16 +19,19 @@ */ package org.nd4j.linalg.api; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.factory.Environment; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.assertFalse; - +@NativeTag public class TestEnvironment extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestNDArrayCreation.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestNDArrayCreation.java index 2d7a56eae..49e93cb69 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestNDArrayCreation.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestNDArrayCreation.java @@ -25,9 +25,12 @@ import lombok.val; import org.bytedeco.javacpp.FloatPointer; import org.bytedeco.javacpp.Pointer; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataBuffer; import org.nd4j.linalg.api.buffer.DataType; @@ -42,6 +45,7 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag public class TestNDArrayCreation extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestNDArrayCreationUtil.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestNDArrayCreationUtil.java index 3919ea8e5..7f4076b95 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestNDArrayCreationUtil.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestNDArrayCreationUtil.java @@ -20,18 +20,22 @@ package org.nd4j.linalg.api; -import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.primitives.Pair; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; +import org.nd4j.common.util.ArrayUtil; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.checkutil.NDArrayCreationUtil; -import org.nd4j.common.primitives.Pair; -import org.nd4j.common.util.ArrayUtil; import static org.junit.jupiter.api.Assertions.assertArrayEquals; +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class TestNDArrayCreationUtil extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestNamespaces.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestNamespaces.java index 39eb7dfd0..09160295c 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestNamespaces.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/TestNamespaces.java @@ -20,14 +20,17 @@ package org.nd4j.linalg.api; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.linalg.factory.Nd4jBackend; - +@NativeTag public class TestNamespaces extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/LapackTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/LapackTest.java index d130b286f..6f60b397a 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/LapackTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/LapackTest.java @@ -20,10 +20,9 @@ package org.nd4j.linalg.api.blas; -import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; - +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataBuffer; import org.nd4j.linalg.api.ndarray.INDArray; @@ -32,7 +31,7 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.assertEquals; - +@NativeTag public class LapackTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/Level1Test.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/Level1Test.java index 5ececc0d8..a7fde0fbf 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/Level1Test.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/Level1Test.java @@ -25,6 +25,7 @@ import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -36,7 +37,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals; /** * @author Adam Gibson */ - +@NativeTag public class Level1Test extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/Level2Test.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/Level2Test.java index 252109aac..d3d036d1b 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/Level2Test.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/Level2Test.java @@ -20,10 +20,9 @@ package org.nd4j.linalg.api.blas; -import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; - +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -31,7 +30,7 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.assertEquals; - +@NativeTag public class Level2Test extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/Level3Test.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/Level3Test.java index c9113a1f6..981d9e582 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/Level3Test.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/Level3Test.java @@ -20,10 +20,9 @@ package org.nd4j.linalg.api.blas; -import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; - +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -31,7 +30,7 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.assertEquals; - +@NativeTag public class Level3Test extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/params/ParamsTestsF.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/params/ParamsTestsF.java index f2b072c8f..5eb7cced7 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/params/ParamsTestsF.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/blas/params/ParamsTestsF.java @@ -20,10 +20,9 @@ package org.nd4j.linalg.api.blas.params; -import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; - +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -34,7 +33,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals; /** * @author Adam Gibson */ - +@NativeTag public class ParamsTestsF extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/DataBufferTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/DataBufferTests.java index e10bab8af..1540d26aa 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/DataBufferTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/DataBufferTests.java @@ -28,6 +28,7 @@ import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.concurrency.AffinityManager; import org.nd4j.linalg.api.memory.MemoryWorkspace; @@ -46,7 +47,7 @@ import java.nio.ByteOrder; import static org.junit.jupiter.api.Assertions.*; @Slf4j - +@NativeTag public class DataBufferTests extends BaseNd4jTestWithBackends { @@ -406,7 +407,7 @@ public class DataBufferTests extends BaseNd4jTestWithBackends { } - @ParameterizedTest + @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") public void testEnsureLocation(){ //https://github.com/eclipse/deeplearning4j/issues/8783 diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/DataTypeValidationTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/DataTypeValidationTests.java index 5735852b5..5923f83f0 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/DataTypeValidationTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/DataTypeValidationTests.java @@ -26,6 +26,7 @@ import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.exception.ND4JIllegalStateException; @@ -34,7 +35,7 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.assertThrows; - +@NativeTag public class DataTypeValidationTests extends BaseNd4jTestWithBackends { DataType initialType = Nd4j.dataType(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/DoubleDataBufferTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/DoubleDataBufferTest.java index e2ee38913..08bc4d4a4 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/DoubleDataBufferTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/DoubleDataBufferTest.java @@ -29,6 +29,7 @@ import org.junit.jupiter.api.io.TempDir; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.util.DataTypeUtil; import org.nd4j.linalg.api.memory.MemoryWorkspace; @@ -57,6 +58,7 @@ import static org.junit.jupiter.api.Assertions.*; */ @Disabled("AB 2019/05/23 - Failing on linux-x86_64-cuda-9.2 - see issue #7657") +@NativeTag public class DoubleDataBufferTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/FloatDataBufferTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/FloatDataBufferTest.java index 8af34a323..961969b22 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/FloatDataBufferTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/FloatDataBufferTest.java @@ -29,6 +29,7 @@ import org.junit.jupiter.api.io.TempDir; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.util.DataTypeUtil; import org.nd4j.linalg.api.memory.MemoryWorkspace; @@ -56,6 +57,7 @@ import static org.junit.jupiter.api.Assertions.*; * @author Adam Gibson */ @Disabled("AB 2019/05/21 - Failing on linux-x86_64-cuda-9.2 - see issue #7657") +@NativeTag public class FloatDataBufferTest extends BaseNd4jTestWithBackends { DataType initialType = Nd4j.dataType(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/IntDataBufferTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/IntDataBufferTests.java index 8e1b3646e..ac93e64df 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/IntDataBufferTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/buffer/IntDataBufferTests.java @@ -25,6 +25,7 @@ import lombok.val; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.memory.MemoryWorkspace; import org.nd4j.linalg.api.memory.conf.WorkspaceConfiguration; @@ -39,6 +40,7 @@ import java.util.Arrays; import static org.junit.jupiter.api.Assertions.*; +@NativeTag public class IntDataBufferTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/IndexingTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/IndexingTests.java index 4dcbf8fb8..3957e9c41 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/IndexingTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/IndexingTests.java @@ -20,10 +20,12 @@ package org.nd4j.linalg.api.indexing; -import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -38,6 +40,8 @@ import static org.junit.jupiter.api.Assertions.assertTrue; /** * @author Adam Gibson */ +@Tag(TagNames.NDARRAY_INDEXING) +@NativeTag public class IndexingTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/IndexingTestsC.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/IndexingTestsC.java index fbcbd656a..08ee5b9cd 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/IndexingTestsC.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/IndexingTestsC.java @@ -20,9 +20,12 @@ package org.nd4j.linalg.api.indexing; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.common.base.Preconditions; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.common.util.ArrayUtil; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; @@ -42,7 +45,8 @@ import static org.nd4j.linalg.indexing.NDArrayIndex.*; /** * @author Adam Gibson */ - +@Tag(TagNames.NDARRAY_INDEXING) +@NativeTag public class IndexingTestsC extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/resolve/NDArrayIndexResolveTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/resolve/NDArrayIndexResolveTests.java index fa69cbe58..adb1c6021 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/resolve/NDArrayIndexResolveTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/resolve/NDArrayIndexResolveTests.java @@ -20,10 +20,13 @@ package org.nd4j.linalg.api.indexing.resolve; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -37,7 +40,8 @@ import static org.junit.jupiter.api.Assertions.*; /** * @author Adam Gibson */ - +@Tag(TagNames.NDARRAY_INDEXING) +@NativeTag public class NDArrayIndexResolveTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/shape/IndexShapeTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/shape/IndexShapeTests.java index 38ce6a6f0..8d3cad4eb 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/shape/IndexShapeTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/shape/IndexShapeTests.java @@ -20,10 +20,11 @@ package org.nd4j.linalg.api.indexing.shape; -import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; - +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.factory.Nd4jBackend; import org.nd4j.linalg.indexing.INDArrayIndex; @@ -35,7 +36,8 @@ import static org.junit.jupiter.api.Assertions.assertArrayEquals; /** * @author Adam Gibson */ - +@Tag(TagNames.NDARRAY_INDEXING) +@NativeTag public class IndexShapeTests extends BaseNd4jTestWithBackends { private int[] shape = {1, 1, 2, 1, 3, 4, 5, 1}; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/shape/IndexShapeTests2d.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/shape/IndexShapeTests2d.java index 4176c98df..24447ca78 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/shape/IndexShapeTests2d.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/indexing/shape/IndexShapeTests2d.java @@ -20,10 +20,11 @@ package org.nd4j.linalg.api.indexing.shape; -import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; - +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.factory.Nd4jBackend; import org.nd4j.linalg.indexing.Indices; @@ -34,7 +35,8 @@ import static org.junit.jupiter.api.Assertions.assertArrayEquals; /** * @author Adam Gibson */ - +@Tag(TagNames.NDARRAY_INDEXING) +@NativeTag public class IndexShapeTests2d extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/iterator/NDIndexIteratorTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/iterator/NDIndexIteratorTest.java index 41fc72a31..4429ae2cf 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/iterator/NDIndexIteratorTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/iterator/NDIndexIteratorTest.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.api.iterator; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.iter.NdIndexIterator; import org.nd4j.linalg.factory.Nd4jBackend; @@ -34,7 +37,8 @@ import static org.junit.jupiter.api.Assertions.assertArrayEquals; /** * @author Adam Gibson */ - +@Tag(TagNames.JAVA_ONLY) +@NativeTag public class NDIndexIteratorTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestNdArrReadWriteTxt.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestNdArrReadWriteTxt.java index 9e5491098..bfd07fa95 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestNdArrReadWriteTxt.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestNdArrReadWriteTxt.java @@ -25,12 +25,15 @@ import lombok.val; import org.apache.commons.io.FileUtils; import org.apache.commons.lang3.ArrayUtils; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.checkutil.NDArrayCreationUtil; import org.nd4j.linalg.factory.Nd4j; @@ -46,6 +49,8 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j +@NativeTag +@Tag(TagNames.NDARRAY_SERDE) public class TestNdArrReadWriteTxt extends BaseNd4jTestWithBackends { @TempDir Path testDir; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestNdArrReadWriteTxtC.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestNdArrReadWriteTxtC.java index 861412773..d25290f40 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestNdArrReadWriteTxtC.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestNdArrReadWriteTxtC.java @@ -22,12 +22,15 @@ package org.nd4j.linalg.api.ndarray; import lombok.extern.slf4j.Slf4j; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.factory.Nd4jBackend; @@ -36,7 +39,8 @@ import java.nio.file.Path; import static org.nd4j.linalg.api.ndarray.TestNdArrReadWriteTxt.compareArrays; @Slf4j - +@NativeTag +@Tag(TagNames.NDARRAY_SERDE) public class TestNdArrReadWriteTxtC extends BaseNd4jTestWithBackends { @TempDir Path testDir; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestSerialization.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestSerialization.java index fd055618e..e5eef1633 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestSerialization.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestSerialization.java @@ -20,10 +20,13 @@ package org.nd4j.linalg.api.ndarray; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.linalg.factory.Nd4jBackend; @@ -33,7 +36,8 @@ import java.io.*; import static org.junit.jupiter.api.Assertions.assertEquals; - +@NativeTag +@Tag(TagNames.NDARRAY_SERDE) public class TestSerialization extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestSerializationDoubleToFloat.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestSerializationDoubleToFloat.java index fabe36d64..49e9911f7 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestSerializationDoubleToFloat.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestSerializationDoubleToFloat.java @@ -23,10 +23,13 @@ package org.nd4j.linalg.api.ndarray; import lombok.extern.slf4j.Slf4j; import lombok.val; import org.junit.jupiter.api.AfterEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.buffer.util.DataTypeUtil; @@ -40,7 +43,8 @@ import java.io.*; import static org.junit.jupiter.api.Assertions.assertTrue; @Slf4j - +@NativeTag +@Tag(TagNames.NDARRAY_SERDE) public class TestSerializationDoubleToFloat extends BaseNd4jTestWithBackends { DataType initialType = Nd4j.dataType(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestSerializationFloatToDouble.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestSerializationFloatToDouble.java index 3ddb27acd..40875dda6 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestSerializationFloatToDouble.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/ndarray/TestSerializationFloatToDouble.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.api.ndarray; import org.junit.jupiter.api.AfterEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.buffer.util.DataTypeUtil; @@ -38,7 +41,8 @@ import java.io.*; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@NativeTag +@Tag(TagNames.NDARRAY_SERDE) public class TestSerializationFloatToDouble extends BaseNd4jTestWithBackends { DataType initialType = Nd4j.dataType(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/rng/RngTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/rng/RngTests.java index 3d983117e..0373783e3 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/rng/RngTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/rng/RngTests.java @@ -20,10 +20,13 @@ package org.nd4j.linalg.api.rng; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -34,7 +37,8 @@ import static org.junit.jupiter.api.Assertions.*; /** * @author Adam Gibson */ - +@NativeTag +@Tag(TagNames.RNG) public class RngTests extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/string/TestFormatting.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/string/TestFormatting.java index 25a0390d7..42c0c45e3 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/string/TestFormatting.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/string/TestFormatting.java @@ -22,10 +22,13 @@ package org.nd4j.linalg.api.string; import lombok.extern.slf4j.Slf4j; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -39,7 +42,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; * @author Adam Gibson */ @Slf4j - +@NativeTag +@Tag(TagNames.NDARRAY_SERDE) public class TestFormatting extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/tad/TestTensorAlongDimension.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/tad/TestTensorAlongDimension.java index 32056619c..d4f9f9e48 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/tad/TestTensorAlongDimension.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/api/tad/TestTensorAlongDimension.java @@ -22,10 +22,13 @@ package org.nd4j.linalg.api.tad; import lombok.extern.slf4j.Slf4j; import org.apache.commons.lang3.time.StopWatch; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -41,7 +44,8 @@ import static org.junit.jupiter.api.Assertions.assertArrayEquals; import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class TestTensorAlongDimension extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/blas/BlasTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/blas/BlasTests.java index 25ebdbf8b..7da7818dc 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/blas/BlasTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/blas/BlasTests.java @@ -28,6 +28,7 @@ import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -40,7 +41,7 @@ import java.util.Collections; import static org.junit.jupiter.api.Assertions.*; @Slf4j - +@NativeTag public class BlasTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/broadcast/BasicBroadcastTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/broadcast/BasicBroadcastTests.java index ccbd72bc7..319c03154 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/broadcast/BasicBroadcastTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/broadcast/BasicBroadcastTests.java @@ -23,10 +23,13 @@ package org.nd4j.linalg.broadcast; import lombok.extern.slf4j.Slf4j; import lombok.val; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -42,7 +45,8 @@ import static org.junit.jupiter.api.Assertions.assertThrows; import static org.junit.jupiter.api.Assertions.assertTrue; @Slf4j - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class BasicBroadcastTests extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/compression/CompressionMagicTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/compression/CompressionMagicTests.java index 75164f89b..309b7a28b 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/compression/CompressionMagicTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/compression/CompressionMagicTests.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.compression; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -33,7 +36,8 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.COMPRESSION) public class CompressionMagicTests extends BaseNd4jTestWithBackends { @BeforeEach diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/compression/CompressionPerformanceTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/compression/CompressionPerformanceTests.java index da305c617..43375af4d 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/compression/CompressionPerformanceTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/compression/CompressionPerformanceTests.java @@ -23,10 +23,13 @@ package org.nd4j.linalg.compression; import lombok.extern.slf4j.Slf4j; import lombok.val; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataBuffer; import org.nd4j.linalg.api.ndarray.INDArray; @@ -38,7 +41,8 @@ import java.io.ByteArrayOutputStream; @Slf4j @Disabled - +@NativeTag +@Tag(TagNames.COMPRESSION) public class CompressionPerformanceTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/compression/CompressionSerDeTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/compression/CompressionSerDeTests.java index 42381483d..2cb3a406e 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/compression/CompressionSerDeTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/compression/CompressionSerDeTests.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.compression; import org.apache.commons.io.output.ByteArrayOutputStream; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -35,7 +38,8 @@ import java.io.ByteArrayInputStream; import static org.junit.jupiter.api.Assertions.assertEquals; - +@NativeTag +@Tag(TagNames.COMPRESSION) public class CompressionSerDeTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/compression/CompressionTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/compression/CompressionTests.java index 9809a7552..5ead23234 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/compression/CompressionTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/compression/CompressionTests.java @@ -23,10 +23,13 @@ package org.nd4j.linalg.compression; import lombok.extern.slf4j.Slf4j; import lombok.val; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.memory.MemoryWorkspace; @@ -47,7 +50,8 @@ import java.util.Arrays; import static org.junit.jupiter.api.Assertions.*; @Slf4j - +@NativeTag +@Tag(TagNames.COMPRESSION) public class CompressionTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/convolution/ConvolutionTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/convolution/ConvolutionTests.java index c3c8284e6..df3a774d7 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/convolution/ConvolutionTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/convolution/ConvolutionTests.java @@ -26,6 +26,7 @@ import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataBuffer; import org.nd4j.linalg.api.buffer.DataType; @@ -49,7 +50,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.nd4j.linalg.indexing.NDArrayIndex.all; import static org.nd4j.linalg.indexing.NDArrayIndex.point; - +@NativeTag public class ConvolutionTests extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/convolution/ConvolutionTestsC.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/convolution/ConvolutionTestsC.java index fe09f0555..05144cc99 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/convolution/ConvolutionTestsC.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/convolution/ConvolutionTestsC.java @@ -26,6 +26,7 @@ import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataBuffer; import org.nd4j.linalg.api.buffer.DataType; @@ -47,7 +48,7 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j - +@NativeTag public class ConvolutionTestsC extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/convolution/DeconvTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/convolution/DeconvTests.java index 4809aa379..b38a74bc4 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/convolution/DeconvTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/convolution/DeconvTests.java @@ -24,12 +24,15 @@ import static org.junit.jupiter.api.Assertions.assertFalse; import static org.junit.jupiter.api.Assertions.assertTrue; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -45,7 +48,8 @@ import java.util.Collections; import java.util.HashSet; import java.util.List; import java.util.Set; - +@NativeTag +@Tag(TagNames.FILE_IO) public class DeconvTests extends BaseNd4jTestWithBackends { @TempDir Path testDir; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/crash/CrashTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/crash/CrashTest.java index ec95134a3..cc6cf9742 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/crash/CrashTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/crash/CrashTest.java @@ -23,10 +23,13 @@ package org.nd4j.linalg.crash; import lombok.extern.slf4j.Slf4j; import org.apache.commons.lang3.RandomUtils; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.ops.CustomOp; @@ -43,6 +46,8 @@ import org.nd4j.linalg.indexing.conditions.Conditions; @Slf4j @Disabled +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class CrashTest extends BaseNd4jTestWithBackends { private static final int ITERATIONS = 10; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/crash/SpecialTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/crash/SpecialTests.java index 92d274d24..5c98e8fcb 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/crash/SpecialTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/crash/SpecialTests.java @@ -24,10 +24,13 @@ import lombok.extern.slf4j.Slf4j; import lombok.val; import lombok.var; import org.apache.commons.lang3.RandomUtils; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.memory.conf.WorkspaceConfiguration; @@ -56,7 +59,8 @@ import static org.junit.jupiter.api.Assertions.*; import static org.nd4j.linalg.indexing.NDArrayIndex.*; @Slf4j - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class SpecialTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/custom/CustomOpsTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/custom/CustomOpsTests.java index 4ed12dc0e..1af93afc3 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/custom/CustomOpsTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/custom/CustomOpsTests.java @@ -26,6 +26,7 @@ import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.blas.params.MMulTranspose; import org.nd4j.linalg.api.buffer.DataType; @@ -95,6 +96,7 @@ import static java.lang.Float.NaN; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag public class CustomOpsTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/custom/ExpandableOpsTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/custom/ExpandableOpsTests.java index 771a2fc3d..63b707382 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/custom/ExpandableOpsTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/custom/ExpandableOpsTests.java @@ -25,6 +25,7 @@ import lombok.val; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ops.compat.CompatStringSplit; import org.nd4j.linalg.api.ops.util.PrintVariable; @@ -35,6 +36,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotNull; @Slf4j +@NativeTag public class ExpandableOpsTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/BalanceMinibatchesTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/BalanceMinibatchesTest.java index 55ae9457b..b3ef0a544 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/BalanceMinibatchesTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/BalanceMinibatchesTest.java @@ -21,11 +21,14 @@ package org.nd4j.linalg.dataset; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.linalg.factory.Nd4jBackend; @@ -38,7 +41,8 @@ import java.util.List; import java.util.Map; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag public class BalanceMinibatchesTest extends BaseNd4jTestWithBackends { @TempDir Path testDir; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/CachingDataSetIteratorTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/CachingDataSetIteratorTest.java index a23b009eb..5bd32c0d7 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/CachingDataSetIteratorTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/CachingDataSetIteratorTest.java @@ -22,10 +22,13 @@ package org.nd4j.linalg.dataset; import org.apache.commons.io.FileUtils; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.dataset.api.DataSetPreProcessor; import org.nd4j.linalg.dataset.api.iterator.CachingDataSetIterator; @@ -43,7 +46,8 @@ import java.nio.file.Path; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag public class CachingDataSetIteratorTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/DataSetTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/DataSetTest.java index f16dccd08..c4cce78c8 100755 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/DataSetTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/DataSetTest.java @@ -23,12 +23,15 @@ package org.nd4j.linalg.dataset; import lombok.extern.slf4j.Slf4j; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -49,7 +52,9 @@ import static org.junit.jupiter.api.Assertions.*; import static org.nd4j.linalg.indexing.NDArrayIndex.*; @Slf4j - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag +@Tag(TagNames.FILE_IO) public class DataSetTest extends BaseNd4jTestWithBackends { @TempDir Path testDir; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/ImagePreProcessortTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/ImagePreProcessortTest.java index ab0bbec1d..aac8a5186 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/ImagePreProcessortTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/ImagePreProcessortTest.java @@ -20,10 +20,13 @@ package org.nd4j.linalg.dataset; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -38,7 +41,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag public class ImagePreProcessortTest extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/IrisDataFetcher.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/IrisDataFetcher.java index d9fa4fae1..5b396a211 100755 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/IrisDataFetcher.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/IrisDataFetcher.java @@ -20,11 +20,16 @@ package org.nd4j.linalg.dataset; +import org.junit.jupiter.api.Tag; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.dataset.api.iterator.fetcher.BaseDataFetcher; import java.io.IOException; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag +@Tag(TagNames.FILE_IO) public class IrisDataFetcher extends BaseDataFetcher { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/KFoldIteratorTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/KFoldIteratorTest.java index beef4223d..37d342cdc 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/KFoldIteratorTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/KFoldIteratorTest.java @@ -20,10 +20,13 @@ package org.nd4j.linalg.dataset; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -35,7 +38,9 @@ import java.util.HashSet; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag +@Tag(TagNames.FILE_IO) public class KFoldIteratorTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MinMaxStatsTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MinMaxStatsTest.java index 3628de7d9..f6e10412c 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MinMaxStatsTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MinMaxStatsTest.java @@ -20,10 +20,13 @@ package org.nd4j.linalg.dataset; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.api.preprocessor.stats.MinMaxStats; @@ -35,7 +38,9 @@ import static org.junit.jupiter.api.Assertions.assertEquals; /** * @author Ede Meijer */ - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag +@Tag(TagNames.FILE_IO) public class MinMaxStatsTest extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MiniBatchFileDataSetIteratorTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MiniBatchFileDataSetIteratorTest.java index 5a4873203..f2749587e 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MiniBatchFileDataSetIteratorTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MiniBatchFileDataSetIteratorTest.java @@ -21,9 +21,12 @@ package org.nd4j.linalg.dataset; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.io.TempDir; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.linalg.factory.Nd4jBackend; @@ -32,7 +35,9 @@ import java.nio.file.Path; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag +@Tag(TagNames.FILE_IO) public class MiniBatchFileDataSetIteratorTest extends BaseNd4jTestWithBackends { @TempDir Path testDir; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MultiDataSetTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MultiDataSetTest.java index 39a39520b..ddae16229 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MultiDataSetTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MultiDataSetTest.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.dataset; import lombok.extern.slf4j.Slf4j; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -45,7 +48,9 @@ import static org.nd4j.linalg.indexing.NDArrayIndex.all; import static org.nd4j.linalg.indexing.NDArrayIndex.interval; @Slf4j - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag +@Tag(TagNames.FILE_IO) public class MultiDataSetTest extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MultiNormalizerHybridTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MultiNormalizerHybridTest.java index 3d6d0b1ea..d5d0ac15b 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MultiNormalizerHybridTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MultiNormalizerHybridTest.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.dataset; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.api.preprocessor.MultiNormalizerHybrid; @@ -33,7 +36,9 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag +@Tag(TagNames.FILE_IO) public class MultiNormalizerHybridTest extends BaseNd4jTestWithBackends { private MultiNormalizerHybrid SUT; private MultiDataSet data; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MultiNormalizerMinMaxScalerTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MultiNormalizerMinMaxScalerTest.java index acd7e5e75..2e67d4576 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MultiNormalizerMinMaxScalerTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MultiNormalizerMinMaxScalerTest.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.dataset; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator; @@ -36,7 +39,9 @@ import org.nd4j.linalg.ops.transforms.Transforms; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag +@Tag(TagNames.FILE_IO) public class MultiNormalizerMinMaxScalerTest extends BaseNd4jTestWithBackends { private static final double TOLERANCE_PERC = 0.01; // 0.01% of correct value private static final int INPUT1_SCALE = 1, INPUT2_SCALE = 2, OUTPUT1_SCALE = 3, OUTPUT2_SCALE = 4; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MultiNormalizerStandardizeTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MultiNormalizerStandardizeTest.java index a833269b0..9273c06e0 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MultiNormalizerStandardizeTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/MultiNormalizerStandardizeTest.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.dataset; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.api.iterator.MultiDataSetIterator; @@ -36,7 +39,9 @@ import org.nd4j.linalg.ops.transforms.Transforms; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag +@Tag(TagNames.FILE_IO) public class MultiNormalizerStandardizeTest extends BaseNd4jTestWithBackends { private static final double TOLERANCE_PERC = 0.01; // 0.01% of correct value private static final int INPUT1_SCALE = 1, INPUT2_SCALE = 2, OUTPUT1_SCALE = 3, OUTPUT2_SCALE = 4; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerMinMaxScalerTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerMinMaxScalerTest.java index 7ce85c482..34ca76a8b 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerMinMaxScalerTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerMinMaxScalerTest.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.dataset; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; @@ -38,7 +41,9 @@ import org.nd4j.linalg.ops.transforms.Transforms; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag +@Tag(TagNames.FILE_IO) public class NormalizerMinMaxScalerTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerSerializerTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerSerializerTest.java index 091e5ccd7..90f87a438 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerSerializerTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerSerializerTest.java @@ -22,10 +22,13 @@ package org.nd4j.linalg.dataset; import lombok.Getter; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.dataset.api.preprocessor.AbstractDataSetNormalizer; import org.nd4j.linalg.dataset.api.preprocessor.ImagePreProcessingScaler; @@ -54,7 +57,9 @@ import static org.junit.jupiter.api.Assertions.assertThrows; /** * @author Ede Meijer */ - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag +@Tag(TagNames.FILE_IO) public class NormalizerSerializerTest extends BaseNd4jTestWithBackends { private File tmpFile; private NormalizerSerializer SUT; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerStandardizeLabelsTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerStandardizeLabelsTest.java index 5fee9eb30..5f7dadd5b 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerStandardizeLabelsTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerStandardizeLabelsTest.java @@ -20,10 +20,13 @@ package org.nd4j.linalg.dataset; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; @@ -36,7 +39,9 @@ import org.nd4j.linalg.ops.transforms.Transforms; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag +@Tag(TagNames.FILE_IO) public class NormalizerStandardizeLabelsTest extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerStandardizeTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerStandardizeTest.java index 5dfe18d8d..cbc4faf3e 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerStandardizeTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerStandardizeTest.java @@ -20,10 +20,13 @@ package org.nd4j.linalg.dataset; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -36,7 +39,9 @@ import org.nd4j.linalg.ops.transforms.Transforms; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag +@Tag(TagNames.FILE_IO) public class NormalizerStandardizeTest extends BaseNd4jTestWithBackends { @Override diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerTests.java index 15feda1df..8a4f2f738 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/NormalizerTests.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.dataset; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.adapter.MultiDataSetIteratorAdapter; @@ -50,7 +53,9 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag +@Tag(TagNames.FILE_IO) public class NormalizerTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/PreProcessor3D4DTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/PreProcessor3D4DTest.java index ed85afbd1..8ad7238df 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/PreProcessor3D4DTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/PreProcessor3D4DTest.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.dataset; import lombok.extern.slf4j.Slf4j; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -44,7 +47,9 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.*; @Slf4j - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag +@Tag(TagNames.FILE_IO) public class PreProcessor3D4DTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/PreProcessorTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/PreProcessorTests.java index d20374a95..d636350c5 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/PreProcessorTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/PreProcessorTests.java @@ -20,9 +20,12 @@ package org.nd4j.linalg.dataset; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -33,7 +36,9 @@ import org.nd4j.linalg.factory.Nd4jBackend; import org.nd4j.linalg.indexing.NDArrayIndex; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag +@Tag(TagNames.FILE_IO) public class PreProcessorTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/StandardScalerTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/StandardScalerTest.java index 9cd11a615..e351e8d8d 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/StandardScalerTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/StandardScalerTest.java @@ -21,21 +21,26 @@ package org.nd4j.linalg.dataset; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.api.iterator.DataSetIterator; import org.nd4j.linalg.dataset.api.iterator.StandardScaler; import org.nd4j.linalg.factory.Nd4jBackend; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag +@Tag(TagNames.FILE_IO) public class StandardScalerTest extends BaseNd4jTestWithBackends { @Disabled - @ParameterizedTest + @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") public void testScale(Nd4jBackend backend) { StandardScaler scaler = new StandardScaler(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/CompositeDataSetPreProcessorTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/CompositeDataSetPreProcessorTest.java index 5d5765ac8..51ab57955 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/CompositeDataSetPreProcessorTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/CompositeDataSetPreProcessorTest.java @@ -20,9 +20,12 @@ package org.nd4j.linalg.dataset.api.preprocessor; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.dataset.DataSet; import org.nd4j.linalg.dataset.api.DataSetPreProcessor; @@ -31,6 +34,8 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.*; +@Tag(TagNames.NDARRAY_ETL) +@NativeTag public class CompositeDataSetPreProcessorTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/CropAndResizeDataSetPreProcessorTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/CropAndResizeDataSetPreProcessorTest.java index 28377da43..01613a3a1 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/CropAndResizeDataSetPreProcessorTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/CropAndResizeDataSetPreProcessorTest.java @@ -20,9 +20,12 @@ package org.nd4j.linalg.dataset.api.preprocessor; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -32,7 +35,8 @@ import org.nd4j.linalg.factory.Nd4j; import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag public class CropAndResizeDataSetPreProcessorTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/MinMaxStrategyTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/MinMaxStrategyTest.java index 17cdc05f4..1bf083b2b 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/MinMaxStrategyTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/MinMaxStrategyTest.java @@ -20,10 +20,13 @@ package org.nd4j.linalg.dataset.api.preprocessor; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.api.preprocessor.stats.MinMaxStats; @@ -34,7 +37,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; /** * @author Ede Meijer */ - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag public class MinMaxStrategyTest extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/PermuteDataSetPreProcessorTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/PermuteDataSetPreProcessorTest.java index a3155734c..064ab0675 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/PermuteDataSetPreProcessorTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/PermuteDataSetPreProcessorTest.java @@ -20,8 +20,11 @@ package org.nd4j.linalg.dataset.api.preprocessor; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.junit.jupiter.api.Test; import org.nd4j.linalg.api.ndarray.INDArray; @@ -30,7 +33,8 @@ import org.nd4j.linalg.factory.Nd4j; import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag public class PermuteDataSetPreProcessorTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/RGBtoGrayscaleDataSetPreProcessorTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/RGBtoGrayscaleDataSetPreProcessorTest.java index b56220c7e..973fcd77e 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/RGBtoGrayscaleDataSetPreProcessorTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/RGBtoGrayscaleDataSetPreProcessorTest.java @@ -20,8 +20,11 @@ package org.nd4j.linalg.dataset.api.preprocessor; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -29,7 +32,8 @@ import org.nd4j.linalg.factory.Nd4j; import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag public class RGBtoGrayscaleDataSetPreProcessorTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/UnderSamplingPreProcessorTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/UnderSamplingPreProcessorTest.java index ab63f40c3..b2490d54e 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/UnderSamplingPreProcessorTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dataset/api/preprocessor/UnderSamplingPreProcessorTest.java @@ -22,10 +22,13 @@ package org.nd4j.linalg.dataset.api.preprocessor; import lombok.extern.slf4j.Slf4j; import net.jcip.annotations.NotThreadSafe; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.ops.random.impl.BernoulliDistribution; @@ -51,6 +54,8 @@ import static org.junit.jupiter.api.Assertions.assertTrue; @Slf4j @NotThreadSafe +@Tag(TagNames.NDARRAY_ETL) +@NativeTag public class UnderSamplingPreProcessorTest extends BaseNd4jTestWithBackends { int shortSeq = 10000; int longSeq = 20020; //not a perfect multiple of windowSize diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dimensionalityreduction/TestPCA.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dimensionalityreduction/TestPCA.java index 091724474..fec0760d7 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dimensionalityreduction/TestPCA.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dimensionalityreduction/TestPCA.java @@ -20,10 +20,13 @@ package org.nd4j.linalg.dimensionalityreduction; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -33,7 +36,8 @@ import org.nd4j.linalg.string.NDArrayStrings; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag public class TestPCA extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dimensionalityreduction/TestRandomProjection.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dimensionalityreduction/TestRandomProjection.java index eeccdda1d..3936e2238 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dimensionalityreduction/TestRandomProjection.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/dimensionalityreduction/TestRandomProjection.java @@ -22,10 +22,13 @@ package org.nd4j.linalg.dimensionalityreduction; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.exception.ND4JIllegalStateException; @@ -41,7 +44,8 @@ import static org.nd4j.linalg.dimensionalityreduction.RandomProjection.johnsonLi import static org.nd4j.linalg.dimensionalityreduction.RandomProjection.targetShape; @Disabled - +@Tag(TagNames.NDARRAY_ETL) +@NativeTag public class TestRandomProjection extends BaseNd4jTestWithBackends { INDArray z1 = Nd4j.createUninitialized(new int[]{(int)1e6, 1000}); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/factory/Nd4jTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/factory/Nd4jTest.java index cad8f7eda..5059d84b7 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/factory/Nd4jTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/factory/Nd4jTest.java @@ -24,10 +24,13 @@ import lombok.val; import org.bytedeco.javacpp.FloatPointer; import org.bytedeco.javacpp.Pointer; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataBuffer; import org.nd4j.linalg.api.buffer.DataType; @@ -50,7 +53,9 @@ import static org.junit.jupiter.api.Assertions.assertEquals; /** */ - +@Tag(TagNames.RNG) +@NativeTag +@Tag(TagNames.FILE_IO) public class Nd4jTest extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/factory/ops/NDBaseTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/factory/ops/NDBaseTest.java index b03ba2b12..107911fd4 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/factory/ops/NDBaseTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/factory/ops/NDBaseTest.java @@ -20,9 +20,12 @@ package org.nd4j.linalg.factory.ops; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -32,6 +35,8 @@ import org.nd4j.linalg.indexing.conditions.Conditions; import static org.junit.jupiter.api.Assertions.*; +@Tag(TagNames.SAMEDIFF) +@NativeTag public class NDBaseTest extends BaseNd4jTestWithBackends { @Override diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/factory/ops/NDLossTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/factory/ops/NDLossTest.java index a0b021ff2..30f02d5f9 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/factory/ops/NDLossTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/factory/ops/NDLossTest.java @@ -20,12 +20,15 @@ package org.nd4j.linalg.factory.ops; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.autodiff.loss.LossReduce; import org.nd4j.autodiff.samediff.SDVariable; import org.nd4j.autodiff.samediff.SameDiff; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -35,7 +38,8 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.assertArrayEquals; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.SAMEDIFF) +@NativeTag public class NDLossTest extends BaseNd4jTestWithBackends { @Override diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/generated/SDLinalgTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/generated/SDLinalgTest.java index 3ac390087..ceb163f31 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/generated/SDLinalgTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/generated/SDLinalgTest.java @@ -20,11 +20,14 @@ package org.nd4j.linalg.generated; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.autodiff.samediff.SDVariable; import org.nd4j.autodiff.samediff.SameDiff; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -33,7 +36,8 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.assertArrayEquals; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.SAMEDIFF) +@NativeTag public class SDLinalgTest extends BaseNd4jTestWithBackends { @Override diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/indexing/BooleanIndexingTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/indexing/BooleanIndexingTest.java index 89cff5fdc..84ecd6606 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/indexing/BooleanIndexingTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/indexing/BooleanIndexingTest.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.indexing; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -43,8 +46,8 @@ import java.util.Arrays; import java.util.Collections; import static org.junit.jupiter.api.Assertions.*; - - +@Tag(TagNames.NDARRAY_INDEXING) +@NativeTag public class BooleanIndexingTest extends BaseNd4jTestWithBackends { /* 1D array checks diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/indexing/TransformsTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/indexing/TransformsTest.java index b37fd1875..5b1e68206 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/indexing/TransformsTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/indexing/TransformsTest.java @@ -22,10 +22,13 @@ package org.nd4j.linalg.indexing; import lombok.extern.slf4j.Slf4j; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -37,7 +40,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; @Slf4j - +@NativeTag public class TransformsTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/inverse/TestInvertMatrices.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/inverse/TestInvertMatrices.java index 4589a42a5..e6cb6c331 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/inverse/TestInvertMatrices.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/inverse/TestInvertMatrices.java @@ -24,10 +24,13 @@ import org.apache.commons.math3.linear.Array2DRowRealMatrix; import org.apache.commons.math3.linear.LUDecomposition; import org.apache.commons.math3.linear.MatrixUtils; import org.apache.commons.math3.linear.RealMatrix; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -41,7 +44,7 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag public class TestInvertMatrices extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lapack/LapackTestsC.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lapack/LapackTestsC.java index 8ab8dd1dc..0e93a9bf1 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lapack/LapackTestsC.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lapack/LapackTestsC.java @@ -23,10 +23,13 @@ package org.nd4j.linalg.lapack; import lombok.extern.slf4j.Slf4j; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -36,7 +39,7 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j - +@NativeTag public class LapackTestsC extends BaseNd4jTestWithBackends { DataType initialType = Nd4j.dataType(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lapack/LapackTestsF.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lapack/LapackTestsF.java index 635dc3a6a..8f21a9bb8 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lapack/LapackTestsF.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lapack/LapackTestsF.java @@ -23,10 +23,13 @@ package org.nd4j.linalg.lapack; import lombok.extern.slf4j.Slf4j; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -36,7 +39,7 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j - +@NativeTag public class LapackTestsF extends BaseNd4jTestWithBackends { DataType initialType = Nd4j.dataType(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/learning/UpdaterTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/learning/UpdaterTest.java index b94552bed..41f089771 100755 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/learning/UpdaterTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/learning/UpdaterTest.java @@ -20,10 +20,13 @@ package org.nd4j.linalg.learning; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.rng.distribution.Distribution; @@ -38,7 +41,9 @@ import org.nd4j.linalg.learning.config.Nesterovs; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.TRAINING) +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class UpdaterTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/learning/UpdaterValidation.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/learning/UpdaterValidation.java index 0285c8036..332745a26 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/learning/UpdaterValidation.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/learning/UpdaterValidation.java @@ -20,9 +20,12 @@ package org.nd4j.linalg.learning; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -43,7 +46,9 @@ import java.util.HashMap; import java.util.Map; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.TRAINING) +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class UpdaterValidation extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lossfunctions/LossFunctionJson.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lossfunctions/LossFunctionJson.java index 01a83c5e2..312264a40 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lossfunctions/LossFunctionJson.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lossfunctions/LossFunctionJson.java @@ -20,9 +20,12 @@ package org.nd4j.linalg.lossfunctions; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -48,7 +51,10 @@ import org.nd4j.shade.jackson.databind.ObjectMapper; import org.nd4j.shade.jackson.databind.SerializationFeature; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.TRAINING) +@NativeTag +@Tag(TagNames.LOSS_FUNCTIONS) +@Tag(TagNames.JACKSON_SERDE) public class LossFunctionJson extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lossfunctions/LossFunctionTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lossfunctions/LossFunctionTest.java index 7437c805f..046866cc2 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lossfunctions/LossFunctionTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lossfunctions/LossFunctionTest.java @@ -20,9 +20,12 @@ package org.nd4j.linalg.lossfunctions; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.activations.IActivation; import org.nd4j.linalg.activations.impl.ActivationSigmoid; @@ -46,7 +49,10 @@ import org.nd4j.linalg.lossfunctions.impl.LossNegativeLogLikelihood; import org.nd4j.linalg.lossfunctions.impl.LossSparseMCXENT; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.LOSS_FUNCTIONS) +@Tag(TagNames.TRAINING) +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class LossFunctionTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lossfunctions/TestLossFunctionsSizeChecks.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lossfunctions/TestLossFunctionsSizeChecks.java index 19fadaeda..bdc3a059f 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lossfunctions/TestLossFunctionsSizeChecks.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/lossfunctions/TestLossFunctionsSizeChecks.java @@ -20,9 +20,12 @@ package org.nd4j.linalg.lossfunctions; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.activations.Activation; import org.nd4j.linalg.api.ndarray.INDArray; @@ -32,7 +35,9 @@ import org.nd4j.linalg.lossfunctions.LossFunctions.LossFunction; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.LOSS_FUNCTIONS) +@NativeTag +@Tag(TagNames.DL4J_OLD_API) public class TestLossFunctionsSizeChecks extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/memory/AccountingTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/memory/AccountingTests.java index df58891e1..9e8d1e217 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/memory/AccountingTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/memory/AccountingTests.java @@ -23,10 +23,13 @@ package org.nd4j.linalg.memory; import lombok.extern.slf4j.Slf4j; import lombok.val; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.memory.AllocationsTracker; @@ -42,6 +45,8 @@ import static org.junit.jupiter.api.Assertions.*; @Slf4j @Disabled +@NativeTag +@Tag(TagNames.WORKSPACES) public class AccountingTests extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/memory/CloseableTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/memory/CloseableTests.java index 239e43839..24727e643 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/memory/CloseableTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/memory/CloseableTests.java @@ -22,10 +22,13 @@ package org.nd4j.linalg.memory; import lombok.extern.slf4j.Slf4j; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.memory.conf.WorkspaceConfiguration; import org.nd4j.linalg.factory.Nd4j; @@ -35,7 +38,8 @@ import org.nd4j.linalg.indexing.NDArrayIndex; import static org.junit.jupiter.api.Assertions.*; @Slf4j - +@NativeTag +@Tag(TagNames.WORKSPACES) public class CloseableTests extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/memory/DeviceLocalNDArrayTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/memory/DeviceLocalNDArrayTests.java index bf7f15f7c..9ccf3326d 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/memory/DeviceLocalNDArrayTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/memory/DeviceLocalNDArrayTests.java @@ -22,10 +22,13 @@ package org.nd4j.linalg.memory; import lombok.extern.slf4j.Slf4j; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -40,7 +43,8 @@ import static org.junit.jupiter.api.Assertions.assertArrayEquals; import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j - +@Tag(TagNames.WORKSPACES) +@NativeTag public class DeviceLocalNDArrayTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/mixed/MixedDataTypesTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/mixed/MixedDataTypesTests.java index 5b5c46915..0df369361 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/mixed/MixedDataTypesTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/mixed/MixedDataTypesTests.java @@ -27,6 +27,7 @@ import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.graph.FlatArray; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; @@ -53,6 +54,7 @@ import org.nd4j.nativeblas.NativeOpsHolder; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag public class MixedDataTypesTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/mixed/StringArrayTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/mixed/StringArrayTests.java index ad630ec09..b5d2dcf82 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/mixed/StringArrayTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/mixed/StringArrayTests.java @@ -26,6 +26,7 @@ import lombok.val; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.graph.FlatArray; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; @@ -35,6 +36,7 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag public class StringArrayTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/multithreading/MultithreadedTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/multithreading/MultithreadedTests.java index cbc7fd48e..955e2a103 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/multithreading/MultithreadedTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/multithreading/MultithreadedTests.java @@ -21,9 +21,12 @@ package org.nd4j.linalg.multithreading; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -34,6 +37,9 @@ import java.util.HashSet; import static org.junit.jupiter.api.Assertions.assertEquals; +@NativeTag +@Tag(TagNames.WORKSPACES) +@Tag(TagNames.MULTI_THREADED) public class MultithreadedTests extends BaseNd4jTestWithBackends { @Override diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/nativ/NativeBlasTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/nativ/NativeBlasTests.java index c09403f83..1c671c225 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/nativ/NativeBlasTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/nativ/NativeBlasTests.java @@ -27,6 +27,7 @@ import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ops.DynamicCustomOp; @@ -36,6 +37,7 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j +@NativeTag public class NativeBlasTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/nativ/OpsMappingTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/nativ/OpsMappingTests.java index 0a05c06e4..f1d9cf4b4 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/nativ/OpsMappingTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/nativ/OpsMappingTests.java @@ -28,6 +28,7 @@ import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.autodiff.functions.DifferentialFunction; import org.nd4j.autodiff.samediff.serde.FlatBuffersMapper; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.imports.NoOpNameFoundException; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ops.BaseBroadcastOp; @@ -55,6 +56,7 @@ import java.util.List; import java.util.Set; @Slf4j +@NativeTag public class OpsMappingTests extends BaseNd4jTestWithBackends { @@ -113,7 +115,7 @@ public class OpsMappingTests extends BaseNd4jTestWithBackends { protected boolean opMapped(List haystack, Operation needle) { for (val c: haystack) { if (needle.getFirst().longValue() == -1L) { - if (c.getSecond().toLowerCase().equals(needle.getSecond().toLowerCase())) + if (c.getSecond().equalsIgnoreCase(needle.getSecond())) return true; } else { if (c.getFirst().longValue() == needle.getFirst().longValue()) diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/DerivativeTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/DerivativeTests.java index 210791686..306f7dfdb 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/DerivativeTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/DerivativeTests.java @@ -27,6 +27,7 @@ import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -46,7 +47,7 @@ import org.nd4j.linalg.ops.transforms.Transforms; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag public class DerivativeTests extends BaseNd4jTestWithBackends { public static final double REL_ERROR_TOLERANCE = 1e-3; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/OpConstructorTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/OpConstructorTests.java index 5c2312424..ece9ed136 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/OpConstructorTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/OpConstructorTests.java @@ -43,6 +43,7 @@ import java.util.*; import static org.junit.jupiter.api.Assertions.assertEquals; @Disabled //AB 2019/08/23 Ignored for now + public class OpConstructorTests extends BaseNd4jTestWithBackends { //Ignore individual classes diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/OpExecutionerTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/OpExecutionerTests.java index d4fb22de8..3939a08a5 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/OpExecutionerTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/OpExecutionerTests.java @@ -26,6 +26,7 @@ import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -68,7 +69,7 @@ import java.util.concurrent.Executors; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag public class OpExecutionerTests extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/OpExecutionerTestsC.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/OpExecutionerTestsC.java index 151db8db2..3bd70f71f 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/OpExecutionerTestsC.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/OpExecutionerTestsC.java @@ -28,6 +28,7 @@ import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataBuffer; import org.nd4j.linalg.api.buffer.DataType; @@ -79,7 +80,7 @@ import static org.nd4j.linalg.indexing.NDArrayIndex.all; import static org.nd4j.linalg.indexing.NDArrayIndex.point; @Slf4j - +@NativeTag public class OpExecutionerTestsC extends BaseNd4jTestWithBackends { DataType initialType = Nd4j.dataType(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/RationalTanhTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/RationalTanhTest.java index 94111a468..68bdec656 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/RationalTanhTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/RationalTanhTest.java @@ -20,10 +20,9 @@ package org.nd4j.linalg.ops; -import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; - +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.ops.impl.transforms.gradient.RationalTanhDerivative; @@ -32,7 +31,7 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.assertTrue; - +@NativeTag public class RationalTanhTest extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/broadcast/row/RowVectorOpsC.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/broadcast/row/RowVectorOpsC.java index 9493e3a19..b49cf5779 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/broadcast/row/RowVectorOpsC.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/broadcast/row/RowVectorOpsC.java @@ -20,8 +20,11 @@ package org.nd4j.linalg.ops.broadcast.row; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -33,7 +36,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; /** * @author Adam Gibson */ - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class RowVectorOpsC extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/copy/CopyTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/copy/CopyTest.java index 18ee217ed..fc1076aa9 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/copy/CopyTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/ops/copy/CopyTest.java @@ -20,10 +20,9 @@ package org.nd4j.linalg.ops.copy; -import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; - +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -31,7 +30,7 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.assertEquals; - +@NativeTag public class CopyTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/options/ArrayOptionsTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/options/ArrayOptionsTests.java index bf3e380fd..c7f19151d 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/options/ArrayOptionsTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/options/ArrayOptionsTests.java @@ -22,10 +22,12 @@ package org.nd4j.linalg.options; import lombok.extern.slf4j.Slf4j; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.shape.options.ArrayOptionsHelper; @@ -36,7 +38,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertNotEquals; @Slf4j - +@Tag(TagNames.JAVA_ONLY) public class ArrayOptionsTests extends BaseNd4jTestWithBackends { private static long[] shapeInfo; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/profiling/InfNanTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/profiling/InfNanTests.java index e436cb76d..e745725a0 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/profiling/InfNanTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/profiling/InfNanTests.java @@ -26,6 +26,7 @@ import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.ops.executioner.OpExecutioner; @@ -36,7 +37,7 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.assertThrows; - +@NativeTag public class InfNanTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/profiling/OperationProfilerTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/profiling/OperationProfilerTests.java index 4aff0470d..485e75eea 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/profiling/OperationProfilerTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/profiling/OperationProfilerTests.java @@ -29,6 +29,7 @@ import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataBuffer; import org.nd4j.linalg.api.buffer.DataType; @@ -50,6 +51,7 @@ import org.nd4j.linalg.profiler.ProfilerConfig; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@NativeTag public class OperationProfilerTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/profiling/PerformanceTrackerTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/profiling/PerformanceTrackerTests.java index 831046c1d..1d77d8958 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/profiling/PerformanceTrackerTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/profiling/PerformanceTrackerTests.java @@ -29,6 +29,7 @@ import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ops.executioner.OpExecutioner; import org.nd4j.linalg.api.ops.performance.PerformanceTracker; @@ -41,7 +42,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; @Slf4j - +@NativeTag public class PerformanceTrackerTests extends BaseNd4jTestWithBackends { @BeforeEach diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/profiling/StackAggregatorTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/profiling/StackAggregatorTests.java index 0f6630153..1a480d127 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/profiling/StackAggregatorTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/profiling/StackAggregatorTests.java @@ -27,6 +27,7 @@ import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.ops.executioner.OpExecutioner; @@ -41,6 +42,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; @Slf4j +@NativeTag public class StackAggregatorTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/rng/HalfTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/rng/HalfTests.java index 18d423d1a..036a5b7da 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/rng/HalfTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/rng/HalfTests.java @@ -24,10 +24,13 @@ import lombok.extern.slf4j.Slf4j; import lombok.val; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.factory.Nd4j; @@ -38,7 +41,8 @@ import static org.junit.jupiter.api.Assertions.assertTrue; @Slf4j - +@Tag(TagNames.RNG) +@NativeTag public class HalfTests extends BaseNd4jTestWithBackends { private DataType initialType = Nd4j.dataType(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/rng/RandomPerformanceTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/rng/RandomPerformanceTests.java index f9eb48d20..2d51843bd 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/rng/RandomPerformanceTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/rng/RandomPerformanceTests.java @@ -23,11 +23,16 @@ package org.nd4j.linalg.rng; import lombok.extern.slf4j.Slf4j; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; @Slf4j @Disabled +@Tag(TagNames.RNG) +@NativeTag public class RandomPerformanceTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/rng/RandomTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/rng/RandomTests.java index efc56e3c9..7cd631a11 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/rng/RandomTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/rng/RandomTests.java @@ -24,13 +24,12 @@ import lombok.extern.slf4j.Slf4j; import lombok.val; import org.apache.commons.math3.random.JDKRandomGenerator; import org.apache.commons.math3.util.FastMath; -import org.junit.jupiter.api.AfterEach; -import org.junit.jupiter.api.BeforeEach; -import org.junit.jupiter.api.Disabled; -import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.*; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.buffer.util.DataTypeUtil; @@ -71,7 +70,8 @@ import java.util.concurrent.atomic.AtomicInteger; import static org.junit.jupiter.api.Assertions.*; @Slf4j - +@Tag(TagNames.RNG) +@NativeTag public class RandomTests extends BaseNd4jTestWithBackends { private DataType initialType; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/rng/RngValidationTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/rng/RngValidationTests.java index c7f05bfc3..8fe62a784 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/rng/RngValidationTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/rng/RngValidationTests.java @@ -27,10 +27,13 @@ import lombok.Builder; import lombok.Data; import lombok.extern.slf4j.Slf4j; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.common.base.Preconditions; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.common.util.ArrayUtil; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; @@ -65,6 +68,8 @@ import java.util.List; import java.util.Map; @Slf4j +@NativeTag +@Tag(TagNames.RNG) public class RngValidationTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/schedule/TestSchedules.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/schedule/TestSchedules.java index 29eb4e066..c15fba204 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/schedule/TestSchedules.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/schedule/TestSchedules.java @@ -20,9 +20,11 @@ package org.nd4j.linalg.schedule; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.factory.Nd4jBackend; import org.nd4j.shade.jackson.databind.DeserializationFeature; @@ -31,7 +33,8 @@ import org.nd4j.shade.jackson.databind.ObjectMapper; import org.nd4j.shade.jackson.databind.SerializationFeature; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.JACKSON_SERDE) +@Tag(TagNames.JAVA_ONLY) public class TestSchedules extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/serde/BasicSerDeTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/serde/BasicSerDeTests.java index 3bc764e13..04b21f7a8 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/serde/BasicSerDeTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/serde/BasicSerDeTests.java @@ -23,10 +23,13 @@ package org.nd4j.linalg.serde; import lombok.extern.slf4j.Slf4j; import lombok.val; import org.junit.jupiter.api.AfterEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -40,6 +43,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j +@Tag(TagNames.JACKSON_SERDE) +@NativeTag public class BasicSerDeTests extends BaseNd4jTestWithBackends { DataType initialType = Nd4j.dataType(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/serde/JsonSerdeTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/serde/JsonSerdeTests.java index a53673d68..4ea8275eb 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/serde/JsonSerdeTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/serde/JsonSerdeTests.java @@ -24,9 +24,12 @@ import lombok.Data; import lombok.EqualsAndHashCode; import lombok.NoArgsConstructor; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -43,6 +46,8 @@ import org.nd4j.shade.jackson.databind.annotation.JsonSerialize; import static org.junit.jupiter.api.Assertions.assertEquals; +@NativeTag +@Tag(TagNames.JACKSON_SERDE) public class JsonSerdeTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/serde/LargeSerDeTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/serde/LargeSerDeTests.java index 7cedba774..dde0a37e3 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/serde/LargeSerDeTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/serde/LargeSerDeTests.java @@ -23,10 +23,13 @@ package org.nd4j.linalg.serde; import lombok.extern.slf4j.Slf4j; import lombok.val; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -40,6 +43,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j @Disabled("AB 2019/05/23 - JVM crash on linux-x86_64-cpu-avx512 - issue #7657") +@Tag(TagNames.JACKSON_SERDE) +@NativeTag public class LargeSerDeTests extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/serde/NumpyFormatTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/serde/NumpyFormatTests.java index c60dff2f2..e9a0d0710 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/serde/NumpyFormatTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/serde/NumpyFormatTests.java @@ -25,11 +25,13 @@ import lombok.val; import org.apache.commons.io.FileUtils; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -44,6 +46,8 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@Tag(TagNames.FILE_IO) +@Tag(TagNames.NDARRAY_SERDE) public class NumpyFormatTests extends BaseNd4jTestWithBackends { @TempDir Path testDir; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/EmptyTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/EmptyTests.java index a554f0954..8398084ca 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/EmptyTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/EmptyTests.java @@ -22,10 +22,13 @@ package org.nd4j.linalg.shape; import lombok.extern.slf4j.Slf4j; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -38,7 +41,8 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.*; @Slf4j - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class EmptyTests extends BaseNd4jTestWithBackends { DataType initialType = Nd4j.dataType(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/LongShapeTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/LongShapeTests.java index f8a94abcc..1f472d98e 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/LongShapeTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/LongShapeTests.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.shape; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.factory.Nd4j; @@ -33,7 +36,8 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.assertArrayEquals; import static org.junit.jupiter.api.Assertions.assertEquals; - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class LongShapeTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/NDArrayMathTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/NDArrayMathTests.java index cd310db03..5c268face 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/NDArrayMathTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/NDArrayMathTests.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.shape; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -38,7 +41,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; /** * @author Adam Gibson */ - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class NDArrayMathTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ShapeBufferTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ShapeBufferTests.java index 72a1c3319..b5a6c8ba1 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ShapeBufferTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ShapeBufferTests.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.shape; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.shape.Shape; @@ -34,7 +37,8 @@ import org.nd4j.common.util.ArrayUtil; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class ShapeBufferTests extends BaseNd4jTestWithBackends { @Override diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ShapeTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ShapeTests.java index a8fa4ca53..bce388760 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ShapeTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ShapeTests.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.shape; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -43,7 +46,8 @@ import static org.nd4j.linalg.indexing.NDArrayIndex.all; /** * @author Adam Gibson */ - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class ShapeTests extends BaseNd4jTestWithBackends { @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ShapeTestsC.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ShapeTestsC.java index 5c8495f82..a6786424c 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ShapeTestsC.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ShapeTestsC.java @@ -22,10 +22,13 @@ package org.nd4j.linalg.shape; import lombok.val; import org.junit.jupiter.api.AfterEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.buffer.util.DataTypeUtil; @@ -39,7 +42,8 @@ import static org.junit.jupiter.api.Assertions.*; /** * @author Adam Gibson */ - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class ShapeTestsC extends BaseNd4jTestWithBackends { DataType initialType = Nd4j.dataType(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/StaticShapeTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/StaticShapeTests.java index 9f02c0dee..17c4a72c1 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/StaticShapeTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/StaticShapeTests.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.shape; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataBuffer; import org.nd4j.linalg.api.buffer.DataType; @@ -45,7 +48,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; /** * @author Adam Gibson */ - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class StaticShapeTests extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/TADTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/TADTests.java index 1168ddc87..5289c82ae 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/TADTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/TADTests.java @@ -22,10 +22,13 @@ package org.nd4j.linalg.shape; import lombok.NonNull; import lombok.extern.slf4j.Slf4j; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataBuffer; import org.nd4j.linalg.api.buffer.DataType; @@ -43,7 +46,8 @@ import static org.nd4j.linalg.indexing.NDArrayIndex.all; import static org.nd4j.linalg.indexing.NDArrayIndex.point; @Slf4j - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class TADTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/concat/ConcatTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/concat/ConcatTests.java index d3fc86076..618652cea 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/concat/ConcatTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/concat/ConcatTests.java @@ -22,10 +22,13 @@ package org.nd4j.linalg.shape.concat; import lombok.extern.slf4j.Slf4j; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -46,7 +49,8 @@ import static org.junit.jupiter.api.Assertions.assertTrue; * @author Adam Gibson */ @Slf4j - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class ConcatTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/concat/ConcatTestsC.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/concat/ConcatTestsC.java index fd0ddb762..5268f6acd 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/concat/ConcatTestsC.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/concat/ConcatTestsC.java @@ -23,10 +23,13 @@ package org.nd4j.linalg.shape.concat; import lombok.extern.slf4j.Slf4j; import lombok.val; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -49,7 +52,8 @@ import static org.junit.jupiter.api.Assertions.*; * @author Adam Gibson */ @Slf4j - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class ConcatTestsC extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/concat/padding/PaddingTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/concat/padding/PaddingTests.java index e106708cf..8c5135fed 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/concat/padding/PaddingTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/concat/padding/PaddingTests.java @@ -20,10 +20,11 @@ package org.nd4j.linalg.shape.concat.padding; -import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; - +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -36,7 +37,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; /** * @author Adam Gibson */ - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class PaddingTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/concat/padding/PaddingTestsC.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/concat/padding/PaddingTestsC.java index ccc04d37c..e5c024782 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/concat/padding/PaddingTestsC.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/concat/padding/PaddingTestsC.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.shape.concat.padding; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -38,7 +41,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; /** * @author Adam Gibson */ - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class PaddingTestsC extends BaseNd4jTestWithBackends { @Override diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/indexing/IndexingTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/indexing/IndexingTests.java index d72531df1..c8b511907 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/indexing/IndexingTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/indexing/IndexingTests.java @@ -24,10 +24,13 @@ import lombok.extern.slf4j.Slf4j; import lombok.val; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -43,7 +46,8 @@ import static org.junit.jupiter.api.Assertions.*; * @author Adam Gibson */ @Slf4j - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class IndexingTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/indexing/IndexingTestsC.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/indexing/IndexingTestsC.java index aa997a3c9..ee5d2a069 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/indexing/IndexingTestsC.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/indexing/IndexingTestsC.java @@ -23,10 +23,13 @@ package org.nd4j.linalg.shape.indexing; import lombok.extern.slf4j.Slf4j; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -43,7 +46,8 @@ import static org.junit.jupiter.api.Assertions.*; * @author Adam Gibson */ @Slf4j - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class IndexingTestsC extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ones/LeadingAndTrailingOnes.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ones/LeadingAndTrailingOnes.java index 01c294f72..2bee5101d 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ones/LeadingAndTrailingOnes.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ones/LeadingAndTrailingOnes.java @@ -20,10 +20,13 @@ package org.nd4j.linalg.shape.ones; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -38,7 +41,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; /** * @author Adam Gibson */ - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class LeadingAndTrailingOnes extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ones/LeadingAndTrailingOnesC.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ones/LeadingAndTrailingOnesC.java index 5dc4351db..537c59453 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ones/LeadingAndTrailingOnesC.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/ones/LeadingAndTrailingOnesC.java @@ -20,10 +20,13 @@ package org.nd4j.linalg.shape.ones; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -35,7 +38,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; /** * @author Adam Gibson */ - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class LeadingAndTrailingOnesC extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/reshape/ReshapeTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/reshape/ReshapeTests.java index b2a7df195..12796254c 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/reshape/ReshapeTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/shape/reshape/ReshapeTests.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.shape.reshape; import lombok.extern.slf4j.Slf4j; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -39,7 +42,8 @@ import static org.junit.jupiter.api.Assumptions.*; * @author Adam Gibson */ @Slf4j - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class ReshapeTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/slicing/SlicingTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/slicing/SlicingTests.java index 5eba51cd3..635759d62 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/slicing/SlicingTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/slicing/SlicingTests.java @@ -21,10 +21,13 @@ package org.nd4j.linalg.slicing; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -35,7 +38,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; /** * @author Adam Gibson */ - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class SlicingTests extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/slicing/SlicingTestsC.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/slicing/SlicingTestsC.java index f70821595..df8a0b51a 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/slicing/SlicingTestsC.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/slicing/SlicingTestsC.java @@ -20,10 +20,13 @@ package org.nd4j.linalg.slicing; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -38,7 +41,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; /** * @author Adam Gibson */ - +@NativeTag +@Tag(TagNames.NDARRAY_INDEXING) public class SlicingTestsC extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/specials/CudaTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/specials/CudaTests.java index 09540f291..11cdbc74d 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/specials/CudaTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/specials/CudaTests.java @@ -28,6 +28,7 @@ import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ops.executioner.GridExecutioner; @@ -37,7 +38,7 @@ import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j - +@NativeTag public class CudaTests extends BaseNd4jTestWithBackends { DataType initialType = Nd4j.dataType(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/specials/LongTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/specials/LongTests.java index 4793043bb..6876f2cf0 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/specials/LongTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/specials/LongTests.java @@ -26,6 +26,7 @@ import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataBuffer; import org.nd4j.linalg.api.buffer.DataType; @@ -44,7 +45,7 @@ import static org.junit.jupiter.api.Assertions.assertNotEquals; @Slf4j @Disabled - +@NativeTag public class LongTests extends BaseNd4jTestWithBackends { DataType initialType = Nd4j.dataType(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/DataSetUtilsTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/DataSetUtilsTest.java index 9ffd78d90..be614e421 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/DataSetUtilsTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/DataSetUtilsTest.java @@ -23,11 +23,14 @@ package org.nd4j.linalg.util; import lombok.extern.slf4j.Slf4j; import org.junit.jupiter.api.AfterEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.dataset.DataSet; @@ -40,6 +43,8 @@ import java.nio.file.Path; import static org.junit.jupiter.api.Assertions.assertTrue; @Slf4j +@NativeTag +@Tag(TagNames.FILE_IO) public class DataSetUtilsTest extends BaseNd4jTestWithBackends { @TempDir Path tmpFld; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/NDArrayUtilTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/NDArrayUtilTest.java index 0504620d6..befe84cfe 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/NDArrayUtilTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/NDArrayUtilTest.java @@ -24,6 +24,7 @@ import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.common.util.ArrayUtil; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; @@ -35,7 +36,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals; /** * @author Hamdi Douss */ - +@NativeTag public class NDArrayUtilTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/PreconditionsTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/PreconditionsTest.java index 7ec6d6370..c9b87b8fe 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/PreconditionsTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/PreconditionsTest.java @@ -20,10 +20,12 @@ package org.nd4j.linalg.util; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.common.base.Preconditions; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -34,7 +36,7 @@ import java.util.Arrays; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.fail; - +@NativeTag public class PreconditionsTest extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/ShapeTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/ShapeTest.java index e2894518f..0d0e1f317 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/ShapeTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/ShapeTest.java @@ -20,10 +20,13 @@ package org.nd4j.linalg.util; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.api.shape.Shape; @@ -35,7 +38,8 @@ import static org.junit.jupiter.api.Assertions.*; /** * @author Adam Gibson */ - +@Tag(TagNames.NDARRAY_INDEXING) +@NativeTag public class ShapeTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/ShapeTestC.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/ShapeTestC.java index 5c71fb1f7..99510c079 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/ShapeTestC.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/ShapeTestC.java @@ -22,10 +22,13 @@ package org.nd4j.linalg.util; import lombok.extern.slf4j.Slf4j; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -41,7 +44,8 @@ import static org.junit.jupiter.api.Assertions.*; * @author Adam Gibson */ @Slf4j - +@Tag(TagNames.NDARRAY_INDEXING) +@NativeTag public class ShapeTestC extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/TestArrayUtils.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/TestArrayUtils.java index d37178421..fc4347d13 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/TestArrayUtils.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/TestArrayUtils.java @@ -20,9 +20,9 @@ package org.nd4j.linalg.util; -import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.common.util.ArrayUtil; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.factory.Nd4jBackend; @@ -30,7 +30,7 @@ import org.nd4j.linalg.factory.Nd4jBackend; import java.util.Random; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag public class TestArrayUtils extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/TestCollections.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/TestCollections.java index f7e880c26..4f396dcf8 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/TestCollections.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/TestCollections.java @@ -23,6 +23,7 @@ package org.nd4j.linalg.util; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.common.collection.CompactHeapStringList; import org.nd4j.linalg.factory.Nd4jBackend; @@ -31,7 +32,7 @@ import java.util.*; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; - +@NativeTag public class TestCollections extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/ValidationUtilTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/ValidationUtilTests.java index 92483350a..ff18001be 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/ValidationUtilTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/util/ValidationUtilTests.java @@ -23,6 +23,7 @@ package org.nd4j.linalg.util; import org.apache.commons.io.FileUtils; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.io.TempDir; @@ -30,6 +31,8 @@ import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.autodiff.samediff.SDVariable; import org.nd4j.autodiff.samediff.SameDiff; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; @@ -48,7 +51,8 @@ import java.util.zip.ZipEntry; import java.util.zip.ZipOutputStream; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.FILE_IO) public class ValidationUtilTests extends BaseNd4jTestWithBackends { @TempDir Path testDir; diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/BasicWorkspaceTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/BasicWorkspaceTests.java index 0a667310f..5b04dbbeb 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/BasicWorkspaceTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/BasicWorkspaceTests.java @@ -22,13 +22,12 @@ package org.nd4j.linalg.workspace; import lombok.extern.slf4j.Slf4j; import lombok.val; -import org.junit.jupiter.api.AfterEach; -import org.junit.jupiter.api.BeforeEach; -import org.junit.jupiter.api.Disabled; -import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.*; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.concurrency.AffinityManager; @@ -53,7 +52,8 @@ import static org.junit.jupiter.api.Assertions.*; import static org.nd4j.linalg.api.buffer.DataType.DOUBLE; @Slf4j - +@Tag(TagNames.WORKSPACES) +@NativeTag public class BasicWorkspaceTests extends BaseNd4jTestWithBackends { DataType initialType = Nd4j.dataType(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/CudaWorkspaceTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/CudaWorkspaceTests.java index 3811a0ce4..98ef833eb 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/CudaWorkspaceTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/CudaWorkspaceTests.java @@ -22,10 +22,13 @@ package org.nd4j.linalg.workspace; import lombok.extern.slf4j.Slf4j; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.memory.conf.WorkspaceConfiguration; @@ -37,7 +40,8 @@ import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j - +@Tag(TagNames.WORKSPACES) +@NativeTag public class CudaWorkspaceTests extends BaseNd4jTestWithBackends { private DataType initialType = Nd4j.dataType(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/CyclicWorkspaceTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/CyclicWorkspaceTests.java index f3df3399e..dc2a16b0f 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/CyclicWorkspaceTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/CyclicWorkspaceTests.java @@ -23,10 +23,13 @@ package org.nd4j.linalg.workspace; import lombok.extern.slf4j.Slf4j; import lombok.val; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.memory.conf.WorkspaceConfiguration; import org.nd4j.linalg.api.memory.enums.AllocationPolicy; @@ -37,7 +40,8 @@ import org.nd4j.linalg.factory.Nd4j; import org.nd4j.linalg.factory.Nd4jBackend; @Slf4j - +@Tag(TagNames.WORKSPACES) +@NativeTag public class CyclicWorkspaceTests extends BaseNd4jTestWithBackends { @ParameterizedTest diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/DebugModeTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/DebugModeTests.java index 00ee07c24..48aaffaad 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/DebugModeTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/DebugModeTests.java @@ -24,10 +24,13 @@ import lombok.extern.slf4j.Slf4j; import lombok.val; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.memory.conf.WorkspaceConfiguration; @@ -43,7 +46,8 @@ import org.nd4j.linalg.api.memory.abstracts.Nd4jWorkspace; import static org.junit.jupiter.api.Assertions.*; @Slf4j - +@Tag(TagNames.WORKSPACES) +@NativeTag public class DebugModeTests extends BaseNd4jTestWithBackends { DataType initialType = Nd4j.dataType(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/EndlessWorkspaceTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/EndlessWorkspaceTests.java index 2cbea5cc9..101214007 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/EndlessWorkspaceTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/EndlessWorkspaceTests.java @@ -23,13 +23,12 @@ package org.nd4j.linalg.workspace; import lombok.extern.slf4j.Slf4j; import org.apache.commons.lang3.RandomUtils; import org.bytedeco.javacpp.Pointer; -import org.junit.jupiter.api.AfterEach; -import org.junit.jupiter.api.BeforeEach; -import org.junit.jupiter.api.Disabled; -import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.*; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.memory.MemoryWorkspace; @@ -50,7 +49,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; @Disabled @Slf4j - +@Tag(TagNames.WORKSPACES) +@NativeTag public class EndlessWorkspaceTests extends BaseNd4jTestWithBackends { DataType initialType = Nd4j.dataType(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/SpecialWorkspaceTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/SpecialWorkspaceTests.java index cb846d95b..cb8bc8b28 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/SpecialWorkspaceTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/SpecialWorkspaceTests.java @@ -24,10 +24,13 @@ import lombok.extern.slf4j.Slf4j; import lombok.val; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.memory.MemoryWorkspace; @@ -50,7 +53,8 @@ import java.util.Arrays; import static org.junit.jupiter.api.Assertions.*; @Slf4j - +@Tag(TagNames.WORKSPACES) +@NativeTag public class SpecialWorkspaceTests extends BaseNd4jTestWithBackends { private DataType initialType = Nd4j.dataType(); diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/WorkspaceProviderTests.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/WorkspaceProviderTests.java index e68caef4b..18923696a 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/WorkspaceProviderTests.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/linalg/workspace/WorkspaceProviderTests.java @@ -24,10 +24,13 @@ import lombok.extern.slf4j.Slf4j; import lombok.val; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.memory.MemoryWorkspace; @@ -52,7 +55,8 @@ import java.util.concurrent.CopyOnWriteArrayList; import static org.junit.jupiter.api.Assertions.*; @Slf4j - +@Tag(TagNames.WORKSPACES) +@NativeTag public class WorkspaceProviderTests extends BaseNd4jTestWithBackends { private static final WorkspaceConfiguration basicConfiguration = WorkspaceConfiguration.builder().initialSize(81920) .overallocationLimit(0.1).policySpill(SpillPolicy.EXTERNAL).policyLearning(LearningPolicy.NONE) diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/list/NDArrayListTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/list/NDArrayListTest.java index 2d4d93a7f..636513fb1 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/list/NDArrayListTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/list/NDArrayListTest.java @@ -20,9 +20,9 @@ package org.nd4j.list; -import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.factory.Nd4jBackend; @@ -31,6 +31,7 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertEquals; +@NativeTag public class NDArrayListTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/serde/base64/Nd4jBase64Test.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/serde/base64/Nd4jBase64Test.java index 1b13efed9..06f59b1c5 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/serde/base64/Nd4jBase64Test.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/serde/base64/Nd4jBase64Test.java @@ -20,16 +20,20 @@ package org.nd4j.serde.base64; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.linalg.factory.Nd4jBackend; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.NDARRAY_SERDE) +@NativeTag public class Nd4jBase64Test extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/serde/binary/BinarySerdeTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/serde/binary/BinarySerdeTest.java index bc463cadc..4139603f7 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/serde/binary/BinarySerdeTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/serde/binary/BinarySerdeTest.java @@ -21,10 +21,13 @@ package org.nd4j.serde.binary; import org.apache.commons.lang3.time.StopWatch; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.OpValidationSuite; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.BaseNd4jTestWithBackends; import org.nd4j.linalg.api.buffer.DataBuffer; import org.nd4j.linalg.api.ndarray.INDArray; @@ -39,7 +42,8 @@ import java.nio.ByteBuffer; import java.util.UUID; import static org.junit.jupiter.api.Assertions.*; - +@NativeTag +@Tag(TagNames.NDARRAY_SERDE) public class BinarySerdeTest extends BaseNd4jTestWithBackends { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/smoketests/SmokeTest.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/smoketests/SmokeTest.java index c29d942f3..7b5030d33 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/smoketests/SmokeTest.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/smoketests/SmokeTest.java @@ -27,12 +27,14 @@ import lombok.extern.slf4j.Slf4j; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.linalg.profiler.ProfilerConfig; @Slf4j +@NativeTag public class SmokeTest { diff --git a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/systeminfo/TestSystemInfo.java b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/systeminfo/TestSystemInfo.java index 976f17517..ccf242ef8 100644 --- a/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/systeminfo/TestSystemInfo.java +++ b/nd4j/nd4j-backends/nd4j-tests/src/test/java/org/nd4j/systeminfo/TestSystemInfo.java @@ -20,11 +20,12 @@ package org.nd4j.systeminfo; -import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.MethodSource; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +@NativeTag public class TestSystemInfo extends BaseND4JTest { @ParameterizedTest @MethodSource("org.nd4j.linalg.BaseNd4jTestWithBackends#configs") diff --git a/nd4j/nd4j-common-tests/src/main/java/org/nd4j/common/tests/tags/NativeTag.java b/nd4j/nd4j-common-tests/src/main/java/org/nd4j/common/tests/tags/NativeTag.java new file mode 100644 index 000000000..9a2c12304 --- /dev/null +++ b/nd4j/nd4j-common-tests/src/main/java/org/nd4j/common/tests/tags/NativeTag.java @@ -0,0 +1,38 @@ +/* + * + * * ****************************************************************************** + * * * + * * * + * * * 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. + * * * + * * * See the NOTICE file distributed with this work for additional + * * * information regarding copyright ownership. + * * * 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.nd4j.common.tests.tags; + +import org.junit.jupiter.api.Tag; + +import java.lang.annotation.ElementType; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; + +@Target({ElementType.TYPE, ElementType.METHOD}) +@Retention(RetentionPolicy.RUNTIME) +@Tag("jvm-crash") +@Tag("hardware-accelerated") +public @interface NativeTag { +} diff --git a/nd4j/nd4j-common-tests/src/main/java/org/nd4j/common/tests/tags/TagNames.java b/nd4j/nd4j-common-tests/src/main/java/org/nd4j/common/tests/tags/TagNames.java new file mode 100644 index 000000000..a103523aa --- /dev/null +++ b/nd4j/nd4j-common-tests/src/main/java/org/nd4j/common/tests/tags/TagNames.java @@ -0,0 +1,51 @@ +/* + * + * * ****************************************************************************** + * * * + * * * + * * * 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. + * * * + * * * See the NOTICE file distributed with this work for additional + * * * information regarding copyright ownership. + * * * 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.nd4j.common.tests.tags; + +public class TagNames { + + public final static String SAMEDIFF = "samediff"; //tests related to samediff + public final static String RNG = "rng"; //tests related to RNG + public final static String JAVA_ONLY = "java-only"; //tests with only pure java involved + public final static String FILE_IO = "file-io"; // tests with file i/o + public final static String DL4J_OLD_API = "dl4j-old-api"; //tests involving old dl4j api + public final static String WORKSPACES = "workspaces"; //tests involving workspaces + public final static String MULTI_THREADED = "multi-threaded"; //tests involving multi threading + public final static String TRAINING = "training"; //tests related to training models + public final static String LOSS_FUNCTIONS = "loss-functions"; //tests related to loss functions + public final static String UI = "ui"; //ui related tests + public final static String EVAL_METRICS = "model-eval-metrics"; //model evaluation metrics related + public final static String CUSTOM_FUNCTIONALITY = "custom-functionality"; //tests related to custom ops, loss functions, layers + public final static String JACKSON_SERDE = "jackson-serde"; //tests related to jackson serialization + public final static String NDARRAY_INDEXING = "ndarray-indexing"; //tests related to ndarray slicing + public final static String NDARRAY_SERDE = "ndarray-serde"; //tests related to ndarray serialization + public final static String COMPRESSION = "compression"; //tests related to compression + public final static String NDARRAY_ETL = "ndarray-etl"; //tests related to data preparation such as transforms and normalization + public final static String MANUAL = "manual"; //tests related to running manually + public final static String SPARK = "spark"; //tests related to apache spark + public final static String DIST_SYSTEMS = "distributed-systems"; + public final static String SOLR = "solr"; + public final static String KERAS = "keras"; + public final static String PYTHON = "python"; +} diff --git a/nd4j/nd4j-common-tests/src/main/java/org/nd4j/common/tests/tags/TrainingTag.java b/nd4j/nd4j-common-tests/src/main/java/org/nd4j/common/tests/tags/TrainingTag.java new file mode 100644 index 000000000..9a9cc5095 --- /dev/null +++ b/nd4j/nd4j-common-tests/src/main/java/org/nd4j/common/tests/tags/TrainingTag.java @@ -0,0 +1,38 @@ +/* + * + * * ****************************************************************************** + * * * + * * * + * * * 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. + * * * + * * * See the NOTICE file distributed with this work for additional + * * * information regarding copyright ownership. + * * * 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.nd4j.common.tests.tags; + +import org.junit.jupiter.api.Tag; + +import java.lang.annotation.ElementType; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; + +@Target({ElementType.TYPE, ElementType.METHOD}) +@Retention(RetentionPolicy.RUNTIME) +@NativeTag +@Tag("training") +public @interface TrainingTag { +} diff --git a/nd4j/nd4j-onnxruntime/pom.xml b/nd4j/nd4j-onnxruntime/pom.xml index 0a5f03e33..be408ab64 100644 --- a/nd4j/nd4j-onnxruntime/pom.xml +++ b/nd4j/nd4j-onnxruntime/pom.xml @@ -73,7 +73,12 @@ org.junit.jupiter junit-jupiter-engine - + + org.nd4j + nd4j-common-tests + ${project.version} + test + org.nd4j nd4j-native diff --git a/nd4j/nd4j-onnxruntime/src/test/java/org/nd4j/onnxruntime/runner/OnnxRuntimeRunnerTests.java b/nd4j/nd4j-onnxruntime/src/test/java/org/nd4j/onnxruntime/runner/OnnxRuntimeRunnerTests.java index 9625a5f7f..5ba3a0e8e 100644 --- a/nd4j/nd4j-onnxruntime/src/test/java/org/nd4j/onnxruntime/runner/OnnxRuntimeRunnerTests.java +++ b/nd4j/nd4j-onnxruntime/src/test/java/org/nd4j/onnxruntime/runner/OnnxRuntimeRunnerTests.java @@ -20,8 +20,11 @@ package org.nd4j.onnxruntime.runner; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.io.ClassPathResource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -31,7 +34,9 @@ import java.util.Map; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DL4J_OLD_API) +@NativeTag public class OnnxRuntimeRunnerTests { diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-client/src/test/java/org/nd4j/parameterserver/background/RemoteParameterServerClientTests.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-client/src/test/java/org/nd4j/parameterserver/background/RemoteParameterServerClientTests.java index 456e39aa5..795309263 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-client/src/test/java/org/nd4j/parameterserver/background/RemoteParameterServerClientTests.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-client/src/test/java/org/nd4j/parameterserver/background/RemoteParameterServerClientTests.java @@ -29,6 +29,8 @@ import org.agrona.concurrent.BusySpinIdleStrategy; import org.junit.jupiter.api.*; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.aeron.ipc.AeronUtil; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.parameterserver.client.ParameterServerClient; @@ -39,6 +41,9 @@ import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j @Disabled +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class RemoteParameterServerClientTests extends BaseND4JTest { private int parameterLength = 1000; private Aeron.Context ctx; diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-client/src/test/java/org/nd4j/parameterserver/client/ParameterServerClientPartialTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-client/src/test/java/org/nd4j/parameterserver/client/ParameterServerClientPartialTest.java index ccc393960..b58d9a08b 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-client/src/test/java/org/nd4j/parameterserver/client/ParameterServerClientPartialTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-client/src/test/java/org/nd4j/parameterserver/client/ParameterServerClientPartialTest.java @@ -25,13 +25,12 @@ import io.aeron.driver.MediaDriver; import io.aeron.driver.ThreadingMode; import lombok.extern.slf4j.Slf4j; import org.agrona.concurrent.BusySpinIdleStrategy; -import org.junit.jupiter.api.BeforeAll; -import org.junit.jupiter.api.Disabled; -import org.junit.jupiter.api.Test; -import org.junit.jupiter.api.Timeout; +import org.junit.jupiter.api.*; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.aeron.ipc.AeronUtil; import org.nd4j.aeron.ipc.NDArrayMessage; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.parameterserver.ParameterServerListener; @@ -41,6 +40,9 @@ import static org.junit.jupiter.api.Assertions.*; @Slf4j @Disabled +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class ParameterServerClientPartialTest extends BaseND4JTest { private static MediaDriver mediaDriver; private static Aeron.Context ctx; diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-client/src/test/java/org/nd4j/parameterserver/client/ParameterServerClientTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-client/src/test/java/org/nd4j/parameterserver/client/ParameterServerClientTest.java index eea4cff83..ecb798cc9 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-client/src/test/java/org/nd4j/parameterserver/client/ParameterServerClientTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-client/src/test/java/org/nd4j/parameterserver/client/ParameterServerClientTest.java @@ -22,12 +22,11 @@ package org.nd4j.parameterserver.client; import io.aeron.Aeron; import io.aeron.driver.MediaDriver; -import org.junit.jupiter.api.BeforeAll; -import org.junit.jupiter.api.Disabled; -import org.junit.jupiter.api.Test; -import org.junit.jupiter.api.Timeout; +import org.junit.jupiter.api.*; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.aeron.ipc.AeronUtil; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.parameterserver.ParameterServerListener; @@ -38,6 +37,9 @@ import org.slf4j.LoggerFactory; import static org.junit.jupiter.api.Assertions.*; @Disabled +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class ParameterServerClientTest extends BaseND4JTest { private static MediaDriver mediaDriver; private static Logger log = LoggerFactory.getLogger(ParameterServerClientTest.class); diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/VoidParameterServerStressTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/VoidParameterServerStressTest.java index 4129c041d..dac164997 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/VoidParameterServerStressTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/VoidParameterServerStressTest.java @@ -24,6 +24,8 @@ import lombok.extern.slf4j.Slf4j; import org.apache.commons.lang3.RandomUtils; import org.junit.jupiter.api.*; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.parameterserver.distributed.conf.VoidConfiguration; import org.nd4j.parameterserver.distributed.enums.NodeRole; @@ -51,6 +53,9 @@ import static org.junit.jupiter.api.Assertions.*; @Slf4j @Disabled @Deprecated +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class VoidParameterServerStressTest extends BaseND4JTest { private static final int NUM_WORDS = 100000; diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/VoidParameterServerTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/VoidParameterServerTest.java index 964445b82..3f13b51a2 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/VoidParameterServerTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/VoidParameterServerTest.java @@ -23,6 +23,8 @@ package org.nd4j.parameterserver.distributed; import lombok.extern.slf4j.Slf4j; import org.junit.jupiter.api.*; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.parameterserver.distributed.conf.VoidConfiguration; @@ -53,6 +55,9 @@ import static org.junit.jupiter.api.Assertions.*; @Slf4j @Disabled @Deprecated +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class VoidParameterServerTest extends BaseND4JTest { private static List localIPs; private static List badIPs; diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/conf/VoidConfigurationTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/conf/VoidConfigurationTest.java index fc5479974..b8cab1742 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/conf/VoidConfigurationTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/conf/VoidConfigurationTest.java @@ -22,14 +22,20 @@ package org.nd4j.parameterserver.distributed.conf; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.exception.ND4JIllegalStateException; import static org.junit.jupiter.api.Assertions.*; @Disabled +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class VoidConfigurationTest extends BaseND4JTest { diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/logic/ClipboardTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/logic/ClipboardTest.java index 4f703ca32..c24a6e22c 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/logic/ClipboardTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/logic/ClipboardTest.java @@ -23,6 +23,8 @@ package org.nd4j.parameterserver.distributed.logic; import lombok.extern.slf4j.Slf4j; import org.junit.jupiter.api.*; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.parameterserver.distributed.logic.completion.Clipboard; import org.nd4j.parameterserver.distributed.messages.aggregations.InitializationAggregation; @@ -36,6 +38,9 @@ import static org.junit.jupiter.api.Assertions.*; @Slf4j @Disabled @Deprecated +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class ClipboardTest extends BaseND4JTest { @BeforeEach public void setUp() throws Exception { diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/logic/FrameCompletionHandlerTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/logic/FrameCompletionHandlerTest.java index c3e1c6d26..22698318b 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/logic/FrameCompletionHandlerTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/logic/FrameCompletionHandlerTest.java @@ -23,15 +23,21 @@ package org.nd4j.parameterserver.distributed.logic; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.parameterserver.distributed.logic.completion.FrameCompletionHandler; import static org.junit.jupiter.api.Assertions.*; @Disabled @Deprecated +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class FrameCompletionHandlerTest extends BaseND4JTest { @BeforeEach public void setUp() throws Exception { diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/logic/routing/InterleavedRouterTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/logic/routing/InterleavedRouterTest.java index cfa7d9afa..66e8ab085 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/logic/routing/InterleavedRouterTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/logic/routing/InterleavedRouterTest.java @@ -23,9 +23,12 @@ package org.nd4j.parameterserver.distributed.logic.routing; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.util.HashUtil; import org.nd4j.parameterserver.distributed.conf.VoidConfiguration; import org.nd4j.parameterserver.distributed.messages.VoidMessage; @@ -40,6 +43,9 @@ import static org.junit.jupiter.api.Assertions.*; @Disabled @Deprecated +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class InterleavedRouterTest extends BaseND4JTest { VoidConfiguration configuration; Transport transport; diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/messages/FrameTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/messages/FrameTest.java index 97d4b4de5..14a26b3c8 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/messages/FrameTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/messages/FrameTest.java @@ -21,11 +21,10 @@ package org.nd4j.parameterserver.distributed.messages; import org.agrona.concurrent.UnsafeBuffer; -import org.junit.jupiter.api.BeforeEach; -import org.junit.jupiter.api.Disabled; -import org.junit.jupiter.api.Test; -import org.junit.jupiter.api.Timeout; +import org.junit.jupiter.api.*; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.parameterserver.distributed.conf.VoidConfiguration; import org.nd4j.parameterserver.distributed.enums.NodeRole; import org.nd4j.parameterserver.distributed.logic.completion.Clipboard; @@ -40,6 +39,9 @@ import static org.junit.jupiter.api.Assertions.*; @Disabled @Deprecated +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class FrameTest extends BaseND4JTest { @BeforeEach public void setUp() throws Exception { diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/messages/VoidMessageTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/messages/VoidMessageTest.java index a710e87bf..8a5138452 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/messages/VoidMessageTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/messages/VoidMessageTest.java @@ -22,12 +22,17 @@ package org.nd4j.parameterserver.distributed.messages; import org.junit.jupiter.api.*; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.parameterserver.distributed.messages.requests.SkipGramRequestMessage; import static org.junit.jupiter.api.Assertions.*; @Disabled @Deprecated +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class VoidMessageTest extends BaseND4JTest { @BeforeEach public void setUp() throws Exception { diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/messages/aggregations/VoidAggregationTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/messages/aggregations/VoidAggregationTest.java index 2e99bddf6..139d1a39d 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/messages/aggregations/VoidAggregationTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/messages/aggregations/VoidAggregationTest.java @@ -23,6 +23,8 @@ package org.nd4j.parameterserver.distributed.messages.aggregations; import lombok.extern.slf4j.Slf4j; import org.junit.jupiter.api.*; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -34,6 +36,9 @@ import static org.junit.jupiter.api.Assertions.*; @Slf4j @Disabled @Deprecated +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class VoidAggregationTest extends BaseND4JTest { private static final short NODES = 100; private static final int ELEMENTS_PER_NODE = 3; diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/transport/RoutedTransportTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/transport/RoutedTransportTest.java index 068945181..e36c32312 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/transport/RoutedTransportTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/transport/RoutedTransportTest.java @@ -22,6 +22,8 @@ package org.nd4j.parameterserver.distributed.transport; import org.junit.jupiter.api.*; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.parameterserver.distributed.conf.VoidConfiguration; import org.nd4j.parameterserver.distributed.enums.NodeRole; import org.nd4j.parameterserver.distributed.logic.ClientRouter; @@ -38,6 +40,9 @@ import static org.junit.jupiter.api.Assertions.*; @Disabled @Deprecated +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class RoutedTransportTest extends BaseND4JTest { @BeforeEach public void setUp() throws Exception { diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/util/NetworkOrganizerTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/util/NetworkOrganizerTest.java index f20b3634e..9f27b49c0 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/util/NetworkOrganizerTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/util/NetworkOrganizerTest.java @@ -24,6 +24,8 @@ import lombok.extern.slf4j.Slf4j; import org.apache.commons.lang3.RandomUtils; import org.junit.jupiter.api.*; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.util.*; @@ -31,6 +33,9 @@ import static org.junit.jupiter.api.Assertions.*; @Slf4j @Disabled +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class NetworkOrganizerTest extends BaseND4JTest { @BeforeEach public void setUp() throws Exception { diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/DelayedModelParameterServerTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/DelayedModelParameterServerTest.java index 78ce59bde..4790ea252 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/DelayedModelParameterServerTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/DelayedModelParameterServerTest.java @@ -26,6 +26,8 @@ import lombok.val; import org.apache.commons.lang3.RandomUtils; import org.junit.jupiter.api.*; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.common.primitives.AtomicBoolean; @@ -52,6 +54,9 @@ import static org.junit.jupiter.api.Assertions.assertTrue; @Slf4j @Disabled +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class DelayedModelParameterServerTest extends BaseND4JTest { private static final String rootId = "ROOT_NODE"; diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/ModelParameterServerTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/ModelParameterServerTest.java index 129784436..d334c2a06 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/ModelParameterServerTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/ModelParameterServerTest.java @@ -24,9 +24,12 @@ import io.reactivex.functions.Consumer; import lombok.extern.slf4j.Slf4j; import lombok.val; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Timeout; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.common.primitives.AtomicBoolean; @@ -50,6 +53,9 @@ import static org.junit.jupiter.api.Assertions.*; @Slf4j @Disabled +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class ModelParameterServerTest extends BaseND4JTest { private static final String rootId = "ROOT_NODE"; diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/chunks/impl/FileChunksTrackerTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/chunks/impl/FileChunksTrackerTest.java index 32a2cca99..17a42fc84 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/chunks/impl/FileChunksTrackerTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/chunks/impl/FileChunksTrackerTest.java @@ -23,8 +23,11 @@ package org.nd4j.parameterserver.distributed.v2.chunks.impl; import lombok.extern.slf4j.Slf4j; import lombok.val; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.parameterserver.distributed.v2.chunks.VoidChunk; import org.nd4j.parameterserver.distributed.v2.messages.impl.GradientsUpdateMessage; @@ -36,6 +39,9 @@ import static org.junit.jupiter.api.Assertions.*; @Slf4j @Disabled +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class FileChunksTrackerTest extends BaseND4JTest { @Test public void testTracker_1() throws Exception { @@ -43,7 +49,7 @@ public class FileChunksTrackerTest extends BaseND4JTest { val splitter = MessageSplitter.getInstance(); val message = new GradientsUpdateMessage("123", array); - val messages = new ArrayList(splitter.split(message, 16384)); + val messages = new ArrayList<>(splitter.split(message, 16384)); val tracker = new FileChunksTracker(messages.get(0)); diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/chunks/impl/InmemoryChunksTrackerTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/chunks/impl/InmemoryChunksTrackerTest.java index ad2de54ba..db98c1bf3 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/chunks/impl/InmemoryChunksTrackerTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/chunks/impl/InmemoryChunksTrackerTest.java @@ -22,8 +22,11 @@ package org.nd4j.parameterserver.distributed.v2.chunks.impl; import lombok.val; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.parameterserver.distributed.v2.chunks.VoidChunk; import org.nd4j.parameterserver.distributed.v2.messages.impl.GradientsUpdateMessage; @@ -32,7 +35,9 @@ import org.nd4j.parameterserver.distributed.v2.util.MessageSplitter; import java.util.ArrayList; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class InmemoryChunksTrackerTest extends BaseND4JTest { @Test @Disabled diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/messages/VoidMessageTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/messages/VoidMessageTest.java index fc7b5d496..65ad12b0d 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/messages/VoidMessageTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/messages/VoidMessageTest.java @@ -22,14 +22,20 @@ package org.nd4j.parameterserver.distributed.v2.messages; import lombok.extern.slf4j.Slf4j; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.common.util.SerializationUtils; import org.nd4j.parameterserver.distributed.v2.messages.pairs.handshake.HandshakeRequest; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class VoidMessageTest extends BaseND4JTest { @Test public void testHandshakeSerialization_1() throws Exception { diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/messages/history/HashHistoryHolderTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/messages/history/HashHistoryHolderTest.java index b9b93e299..9c8b98ddc 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/messages/history/HashHistoryHolderTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/messages/history/HashHistoryHolderTest.java @@ -22,12 +22,18 @@ package org.nd4j.parameterserver.distributed.v2.messages.history; import lombok.extern.slf4j.Slf4j; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class HashHistoryHolderTest extends BaseND4JTest { @Test diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/transport/impl/AeronUdpTransportTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/transport/impl/AeronUdpTransportTest.java index 1aa250d87..24ee33a84 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/transport/impl/AeronUdpTransportTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/transport/impl/AeronUdpTransportTest.java @@ -23,13 +23,19 @@ package org.nd4j.parameterserver.distributed.v2.transport.impl; import lombok.extern.slf4j.Slf4j; import lombok.val; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.parameterserver.distributed.conf.VoidConfiguration; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class AeronUdpTransportTest extends BaseND4JTest { private static final String IP = "127.0.0.1"; private static final int ROOT_PORT = 40781; diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/transport/impl/DummyTransportTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/transport/impl/DummyTransportTest.java index 4fed8645c..31550981d 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/transport/impl/DummyTransportTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/transport/impl/DummyTransportTest.java @@ -22,8 +22,11 @@ package org.nd4j.parameterserver.distributed.v2.transport.impl; import lombok.extern.slf4j.Slf4j; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.parameterserver.distributed.v2.enums.PropagationMode; import org.nd4j.parameterserver.distributed.v2.messages.impl.GradientsUpdateMessage; @@ -37,6 +40,9 @@ import java.util.concurrent.atomic.AtomicInteger; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class DummyTransportTest extends BaseND4JTest { @Test diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/util/MeshOrganizerTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/util/MeshOrganizerTest.java index 33703356d..e7feac050 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/util/MeshOrganizerTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/util/MeshOrganizerTest.java @@ -22,9 +22,12 @@ package org.nd4j.parameterserver.distributed.v2.util; import lombok.extern.slf4j.Slf4j; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Timeout; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.common.util.SerializationUtils; import org.nd4j.parameterserver.distributed.v2.enums.MeshBuildMode; @@ -35,6 +38,9 @@ import java.util.ArrayList; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class MeshOrganizerTest extends BaseND4JTest { @Test() diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/util/MessageSplitterTest.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/util/MessageSplitterTest.java index 17e9dd7aa..c5567be4f 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/util/MessageSplitterTest.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server-node/src/test/java/org/nd4j/parameterserver/distributed/v2/util/MessageSplitterTest.java @@ -22,8 +22,11 @@ package org.nd4j.parameterserver.distributed.v2.util; import lombok.extern.slf4j.Slf4j; import lombok.val; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.common.primitives.Atomic; import org.nd4j.common.primitives.Optional; @@ -34,6 +37,9 @@ import java.util.ArrayList; import static org.junit.jupiter.api.Assertions.*; @Slf4j +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class MessageSplitterTest extends BaseND4JTest { @Test diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server/src/test/java/org/nd4j/parameterserver/updater/ParameterServerUpdaterTests.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server/src/test/java/org/nd4j/parameterserver/updater/ParameterServerUpdaterTests.java index a896618d8..e68b23a2f 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server/src/test/java/org/nd4j/parameterserver/updater/ParameterServerUpdaterTests.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server/src/test/java/org/nd4j/parameterserver/updater/ParameterServerUpdaterTests.java @@ -20,17 +20,22 @@ package org.nd4j.parameterserver.updater; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Timeout; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.aeron.ipc.NDArrayMessage; import org.nd4j.aeron.ndarrayholder.InMemoryNDArrayHolder; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.parameterserver.updater.storage.NoUpdateStorage; import static org.junit.jupiter.api.Assertions.*; import static org.junit.jupiter.api.Assumptions.*; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class ParameterServerUpdaterTests extends BaseND4JTest { @Test() diff --git a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server/src/test/java/org/nd4j/parameterserver/updater/storage/UpdaterStorageTests.java b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server/src/test/java/org/nd4j/parameterserver/updater/storage/UpdaterStorageTests.java index 7a55484a0..29b6b58b2 100644 --- a/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server/src/test/java/org/nd4j/parameterserver/updater/storage/UpdaterStorageTests.java +++ b/nd4j/nd4j-parameter-server-parent/nd4j-parameter-server/src/test/java/org/nd4j/parameterserver/updater/storage/UpdaterStorageTests.java @@ -20,16 +20,21 @@ package org.nd4j.parameterserver.updater.storage; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Timeout; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.aeron.ipc.NDArrayMessage; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertThrows; - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class UpdaterStorageTests extends BaseND4JTest { diff --git a/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/AeronNDArraySerdeTest.java b/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/AeronNDArraySerdeTest.java index 0fc74a500..ed1532a7d 100644 --- a/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/AeronNDArraySerdeTest.java +++ b/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/AeronNDArraySerdeTest.java @@ -23,8 +23,11 @@ package org.nd4j.aeron.ipc; import org.agrona.concurrent.UnsafeBuffer; import org.apache.commons.lang3.time.StopWatch; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -37,7 +40,9 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; @NotThreadSafe @Disabled("Tests are too flaky") - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class AeronNDArraySerdeTest extends BaseND4JTest { @Test diff --git a/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/LargeNdArrayIpcTest.java b/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/LargeNdArrayIpcTest.java index 3862da096..9fb249947 100644 --- a/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/LargeNdArrayIpcTest.java +++ b/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/LargeNdArrayIpcTest.java @@ -24,11 +24,10 @@ import io.aeron.Aeron; import io.aeron.driver.MediaDriver; import lombok.extern.slf4j.Slf4j; import org.agrona.CloseHelper; -import org.junit.jupiter.api.AfterEach; -import org.junit.jupiter.api.BeforeEach; -import org.junit.jupiter.api.Disabled; -import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.*; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -40,6 +39,9 @@ import static org.junit.jupiter.api.Assertions.assertFalse; @Slf4j @NotThreadSafe @Disabled("Tests are too flaky") +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class LargeNdArrayIpcTest extends BaseND4JTest { private MediaDriver mediaDriver; private Aeron.Context ctx; diff --git a/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/NDArrayMessageTest.java b/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/NDArrayMessageTest.java index 1bab3cc6b..c452fd231 100644 --- a/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/NDArrayMessageTest.java +++ b/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/NDArrayMessageTest.java @@ -22,8 +22,11 @@ package org.nd4j.aeron.ipc; import org.agrona.DirectBuffer; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -33,7 +36,9 @@ import static org.junit.jupiter.api.Assertions.assertEquals; @NotThreadSafe @Disabled("Tests are too flaky") - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class NDArrayMessageTest extends BaseND4JTest { @Test diff --git a/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/NdArrayIpcTest.java b/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/NdArrayIpcTest.java index 20620b32c..42ed02c0f 100644 --- a/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/NdArrayIpcTest.java +++ b/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/NdArrayIpcTest.java @@ -23,11 +23,10 @@ package org.nd4j.aeron.ipc; import io.aeron.Aeron; import io.aeron.driver.MediaDriver; import org.agrona.CloseHelper; -import org.junit.jupiter.api.AfterEach; -import org.junit.jupiter.api.BeforeEach; -import org.junit.jupiter.api.Disabled; -import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.*; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.slf4j.Logger; @@ -42,7 +41,9 @@ import static org.junit.jupiter.api.Assertions.assertFalse; @NotThreadSafe @Disabled("Tests are too flaky") - +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class NdArrayIpcTest extends BaseND4JTest { private MediaDriver mediaDriver; private static Logger log = LoggerFactory.getLogger(NdArrayIpcTest.class); diff --git a/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/chunk/ChunkAccumulatorTests.java b/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/chunk/ChunkAccumulatorTests.java index fe273a729..fe1e5d47e 100644 --- a/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/chunk/ChunkAccumulatorTests.java +++ b/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/chunk/ChunkAccumulatorTests.java @@ -21,9 +21,12 @@ package org.nd4j.aeron.ipc.chunk; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.aeron.ipc.NDArrayMessage; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import javax.annotation.concurrent.NotThreadSafe; @@ -32,6 +35,9 @@ import static org.junit.jupiter.api.Assertions.assertEquals; @NotThreadSafe @Disabled("Tests are too flaky") +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class ChunkAccumulatorTests extends BaseND4JTest { @Test diff --git a/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/chunk/NDArrayMessageChunkTests.java b/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/chunk/NDArrayMessageChunkTests.java index daef2beb1..f756b8265 100644 --- a/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/chunk/NDArrayMessageChunkTests.java +++ b/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/chunk/NDArrayMessageChunkTests.java @@ -22,10 +22,13 @@ package org.nd4j.aeron.ipc.chunk; import org.agrona.DirectBuffer; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.aeron.ipc.NDArrayMessage; import org.nd4j.aeron.util.BufferUtil; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import javax.annotation.concurrent.NotThreadSafe; @@ -36,6 +39,9 @@ import static org.junit.jupiter.api.Assertions.assertEquals; @NotThreadSafe @Disabled("Tests are too flaky") +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class NDArrayMessageChunkTests extends BaseND4JTest { @Test diff --git a/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/response/AeronNDArrayResponseTest.java b/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/response/AeronNDArrayResponseTest.java index c98fcc01f..140c35e95 100644 --- a/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/response/AeronNDArrayResponseTest.java +++ b/nd4j/nd4j-serde/nd4j-aeron/src/test/java/org/nd4j/aeron/ipc/response/AeronNDArrayResponseTest.java @@ -28,9 +28,12 @@ import org.agrona.CloseHelper; import org.agrona.concurrent.BusySpinIdleStrategy; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; import org.nd4j.aeron.ipc.*; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -43,6 +46,9 @@ import static org.junit.jupiter.api.Assertions.assertEquals; @Slf4j @NotThreadSafe @Disabled("Tests are too flaky") +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class AeronNDArrayResponseTest extends BaseND4JTest { private MediaDriver mediaDriver; diff --git a/nd4j/nd4j-serde/nd4j-arrow/src/test/java/org/nd4j/arrow/ArrowSerdeTest.java b/nd4j/nd4j-serde/nd4j-arrow/src/test/java/org/nd4j/arrow/ArrowSerdeTest.java index e8d4362aa..45aaa157c 100644 --- a/nd4j/nd4j-serde/nd4j-arrow/src/test/java/org/nd4j/arrow/ArrowSerdeTest.java +++ b/nd4j/nd4j-serde/nd4j-arrow/src/test/java/org/nd4j/arrow/ArrowSerdeTest.java @@ -21,13 +21,17 @@ package org.nd4j.arrow; import org.apache.arrow.flatbuf.Tensor; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.nd4j.common.tests.BaseND4JTest; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@NativeTag public class ArrowSerdeTest extends BaseND4JTest { @Test diff --git a/nd4j/nd4j-tvm/pom.xml b/nd4j/nd4j-tvm/pom.xml index 882149119..b05541832 100644 --- a/nd4j/nd4j-tvm/pom.xml +++ b/nd4j/nd4j-tvm/pom.xml @@ -38,6 +38,12 @@ + + org.nd4j + nd4j-common-tests + ${project.version} + test + org.nd4j nd4j-api diff --git a/nd4j/nd4j-tvm/src/test/java/org/nd4j/tvm/runner/TvmRunnerTests.java b/nd4j/nd4j-tvm/src/test/java/org/nd4j/tvm/runner/TvmRunnerTests.java index fba116f5d..2aa0a99f6 100644 --- a/nd4j/nd4j-tvm/src/test/java/org/nd4j/tvm/runner/TvmRunnerTests.java +++ b/nd4j/nd4j-tvm/src/test/java/org/nd4j/tvm/runner/TvmRunnerTests.java @@ -23,7 +23,10 @@ import org.bytedeco.cpython.*; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -39,6 +42,9 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import org.junit.jupiter.api.io.TempDir; @Disabled +@Tag(TagNames.FILE_IO) +@Tag(TagNames.DIST_SYSTEMS) +@NativeTag public class TvmRunnerTests { static void PrepareTestLibs(String libPath) throws Exception { diff --git a/pom.xml b/pom.xml index 7690b8b9f..f9d8831ff 100644 --- a/pom.xml +++ b/pom.xml @@ -150,7 +150,7 @@ 0.8.0 2.2 1.15 - 3.17 + 5.0.0 0.5.0 2.3.23 2.8.1 diff --git a/python4j/python4j-core/pom.xml b/python4j/python4j-core/pom.xml index 0fc3e096f..0685b2fca 100644 --- a/python4j/python4j-core/pom.xml +++ b/python4j/python4j-core/pom.xml @@ -34,6 +34,12 @@ python4j-core + + org.nd4j + nd4j-common-tests + ${project.version} + test + org.json json diff --git a/python4j/python4j-core/src/test/java/PythonBasicExecutionTest.java b/python4j/python4j-core/src/test/java/PythonBasicExecutionTest.java index 544af14ae..cd58dfff0 100644 --- a/python4j/python4j-core/src/test/java/PythonBasicExecutionTest.java +++ b/python4j/python4j-core/src/test/java/PythonBasicExecutionTest.java @@ -20,7 +20,10 @@ +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.python4j.*; import javax.annotation.concurrent.NotThreadSafe; @@ -30,6 +33,9 @@ import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertThrows; @NotThreadSafe +@Tag(TagNames.FILE_IO) +@NativeTag +@Tag(TagNames.PYTHON) public class PythonBasicExecutionTest { @Test() diff --git a/python4j/python4j-core/src/test/java/PythonCollectionsTest.java b/python4j/python4j-core/src/test/java/PythonCollectionsTest.java index 41c19d1f1..1a85fad4f 100644 --- a/python4j/python4j-core/src/test/java/PythonCollectionsTest.java +++ b/python4j/python4j-core/src/test/java/PythonCollectionsTest.java @@ -19,6 +19,9 @@ */ +import org.junit.jupiter.api.Tag; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.python4j.*; import org.junit.jupiter.api.Test; @@ -29,6 +32,9 @@ import static org.junit.jupiter.api.Assertions.assertEquals; @javax.annotation.concurrent.NotThreadSafe +@Tag(TagNames.FILE_IO) +@NativeTag +@Tag(TagNames.PYTHON) public class PythonCollectionsTest { diff --git a/python4j/python4j-core/src/test/java/PythonContextManagerTest.java b/python4j/python4j-core/src/test/java/PythonContextManagerTest.java index 32ec7e5c7..1498ecc76 100644 --- a/python4j/python4j-core/src/test/java/PythonContextManagerTest.java +++ b/python4j/python4j-core/src/test/java/PythonContextManagerTest.java @@ -20,6 +20,9 @@ */ +import org.junit.jupiter.api.Tag; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.python4j.Python; import org.nd4j.python4j.PythonContextManager; import org.nd4j.python4j.PythonExecutioner; @@ -32,6 +35,10 @@ import javax.annotation.concurrent.NotThreadSafe; import static org.junit.jupiter.api.Assertions.assertEquals; @NotThreadSafe +@Tag(TagNames.FILE_IO) +@NativeTag +@Tag(TagNames.FILE_IO) +@Tag(TagNames.PYTHON) public class PythonContextManagerTest { @Test diff --git a/python4j/python4j-core/src/test/java/PythonGCTest.java b/python4j/python4j-core/src/test/java/PythonGCTest.java index 7e61eafc5..048929664 100644 --- a/python4j/python4j-core/src/test/java/PythonGCTest.java +++ b/python4j/python4j-core/src/test/java/PythonGCTest.java @@ -18,6 +18,9 @@ * ***************************************************************************** */ +import org.junit.jupiter.api.Tag; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.python4j.Python; import org.nd4j.python4j.PythonGC; import org.nd4j.python4j.PythonGIL; @@ -31,6 +34,8 @@ import static org.junit.jupiter.api.Assertions.assertTrue; @NotThreadSafe +@Tag(TagNames.FILE_IO) +@NativeTag public class PythonGCTest { @Test diff --git a/python4j/python4j-core/src/test/java/PythonMultiThreadTest.java b/python4j/python4j-core/src/test/java/PythonMultiThreadTest.java index 53375dce9..a4c067740 100644 --- a/python4j/python4j-core/src/test/java/PythonMultiThreadTest.java +++ b/python4j/python4j-core/src/test/java/PythonMultiThreadTest.java @@ -18,7 +18,10 @@ * ***************************************************************************** */ +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.python4j.*; import javax.annotation.concurrent.NotThreadSafe; @@ -36,6 +39,10 @@ import static org.junit.jupiter.api.Assertions.assertTrue; @NotThreadSafe +@Tag(TagNames.FILE_IO) +@NativeTag +@Tag(TagNames.PYTHON) +@Tag(TagNames.MULTI_THREADED) public class PythonMultiThreadTest { @Test diff --git a/python4j/python4j-core/src/test/java/PythonPrimitiveTypesTest.java b/python4j/python4j-core/src/test/java/PythonPrimitiveTypesTest.java index 3081cd0dd..7de05de88 100644 --- a/python4j/python4j-core/src/test/java/PythonPrimitiveTypesTest.java +++ b/python4j/python4j-core/src/test/java/PythonPrimitiveTypesTest.java @@ -19,6 +19,9 @@ */ +import org.junit.jupiter.api.Tag; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.python4j.*; import org.junit.jupiter.api.Test; @@ -28,7 +31,9 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertArrayEquals; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@NativeTag +@Tag(TagNames.PYTHON) public class PythonPrimitiveTypesTest { @Test diff --git a/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyBasicTest.java b/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyBasicTest.java index 4d8e74ce5..c2aa54365 100644 --- a/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyBasicTest.java +++ b/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyBasicTest.java @@ -23,9 +23,12 @@ package org.nd4j.python4j; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -41,6 +44,9 @@ import java.util.stream.Stream; import static org.junit.jupiter.api.Assertions.assertEquals; @NotThreadSafe +@Tag(TagNames.FILE_IO) +@NativeTag +@Tag(TagNames.PYTHON) public class PythonNumpyBasicTest { public static Stream params() { diff --git a/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyCollectionsTest.java b/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyCollectionsTest.java index a9e170f50..3c816cbe3 100644 --- a/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyCollectionsTest.java +++ b/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyCollectionsTest.java @@ -42,9 +42,12 @@ package org.nd4j.python4j;/* */ +import org.junit.jupiter.api.Tag; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.python4j.PythonException; import org.nd4j.python4j.PythonGIL; import org.nd4j.python4j.PythonObject; @@ -63,6 +66,9 @@ import static org.junit.jupiter.api.Assertions.assertEquals; @NotThreadSafe +@Tag(TagNames.FILE_IO) +@NativeTag +@Tag(TagNames.PYTHON) public class PythonNumpyCollectionsTest { diff --git a/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyGCTest.java b/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyGCTest.java index f241e8685..8a20ab9ba 100644 --- a/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyGCTest.java +++ b/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyGCTest.java @@ -41,7 +41,10 @@ package org.nd4j.python4j;/* * ***************************************************************************** */ +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import javax.annotation.concurrent.NotThreadSafe; @@ -50,6 +53,9 @@ import static org.junit.jupiter.api.Assertions.assertTrue; @NotThreadSafe +@Tag(TagNames.FILE_IO) +@NativeTag +@Tag(TagNames.PYTHON) public class PythonNumpyGCTest { @Test diff --git a/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyImportTest.java b/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyImportTest.java index d52dfbb10..0f4b6b2e9 100644 --- a/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyImportTest.java +++ b/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyImportTest.java @@ -41,13 +41,18 @@ package org.nd4j.python4j;/* * ***************************************************************************** */ +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.buffer.DataType; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@NativeTag +@Tag(TagNames.PYTHON) public class PythonNumpyImportTest { @Test diff --git a/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyMultiThreadTest.java b/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyMultiThreadTest.java index 9e4aac13d..d256c789f 100644 --- a/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyMultiThreadTest.java +++ b/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyMultiThreadTest.java @@ -41,9 +41,12 @@ package org.nd4j.python4j;/* * ***************************************************************************** */ +import org.junit.jupiter.api.Tag; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.MethodSource; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.python4j.*; import org.junit.jupiter.api.Test; @@ -63,6 +66,9 @@ import static org.junit.jupiter.api.Assertions.assertEquals; @NotThreadSafe +@Tag(TagNames.FILE_IO) +@NativeTag +@Tag(TagNames.PYTHON) public class PythonNumpyMultiThreadTest { public static Stream params() { diff --git a/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyServiceLoaderTest.java b/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyServiceLoaderTest.java index 4b74acb3a..c2498c405 100644 --- a/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyServiceLoaderTest.java +++ b/python4j/python4j-numpy/src/test/java/org/nd4j/python4j/PythonNumpyServiceLoaderTest.java @@ -43,7 +43,10 @@ package org.nd4j.python4j;/* +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.python4j.NumpyArray; @@ -54,6 +57,9 @@ import javax.annotation.concurrent.NotThreadSafe; import static org.junit.jupiter.api.Assertions.assertEquals; @NotThreadSafe +@Tag(TagNames.FILE_IO) +@NativeTag +@Tag(TagNames.PYTHON) public class PythonNumpyServiceLoaderTest { @Test diff --git a/rl4j/rl4j-core/pom.xml b/rl4j/rl4j-core/pom.xml index 3e1254798..7e18bfdb5 100644 --- a/rl4j/rl4j-core/pom.xml +++ b/rl4j/rl4j-core/pom.xml @@ -52,6 +52,12 @@ + + org.nd4j + nd4j-common-tests + ${project.version} + test + org.deeplearning4j rl4j-api diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/AgentLearnerTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/AgentLearnerTest.java index 83901c41c..aa1c8313c 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/AgentLearnerTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/AgentLearnerTest.java @@ -29,6 +29,7 @@ import org.deeplearning4j.rl4j.observation.Observation; import org.deeplearning4j.rl4j.observation.transform.TransformProcess; import org.deeplearning4j.rl4j.policy.IPolicy; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.ArgumentCaptor; @@ -36,6 +37,8 @@ import org.mockito.Mock; import org.mockito.invocation.InvocationOnMock; import org.mockito.junit.MockitoJUnitRunner; import org.mockito.stubbing.Answer; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import java.util.HashMap; @@ -48,6 +51,8 @@ import static org.junit.jupiter.api.Assertions.*; @RunWith(MockitoJUnitRunner.class) @Disabled("Mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class AgentLearnerTest { @Mock diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/AgentTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/AgentTest.java index a65af5211..b257b5ef8 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/AgentTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/AgentTest.java @@ -27,6 +27,7 @@ import org.deeplearning4j.rl4j.observation.transform.TransformProcess; import org.deeplearning4j.rl4j.policy.IPolicy; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import static org.junit.jupiter.api.Assertions.*; @@ -37,6 +38,8 @@ import org.mockito.*; import org.mockito.exceptions.base.MockitoException; import org.mockito.junit.*; import org.mockito.junit.jupiter.MockitoExtension; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import java.util.HashMap; @@ -48,6 +51,8 @@ import static org.mockito.Mockito.*; //@RunWith(JUnitPlatform.class) @ExtendWith(MockitoExtension.class) @Disabled("Mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class AgentTest { @Mock Environment environmentMock; @Mock TransformProcess transformProcessMock; diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentActorCriticHelperTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentActorCriticHelperTest.java index bac000d73..bf91ab43b 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentActorCriticHelperTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentActorCriticHelperTest.java @@ -20,13 +20,17 @@ package org.deeplearning4j.rl4j.agent.learning.algorithm.actorcritic; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.assertArrayEquals; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@NativeTag public class NonRecurrentActorCriticHelperTest { private final NonRecurrentActorCriticHelper sut = new NonRecurrentActorCriticHelper(3); diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentAdvantageActorCriticTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentAdvantageActorCriticTest.java index 182400ede..a9762995a 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentAdvantageActorCriticTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/NonRecurrentAdvantageActorCriticTest.java @@ -29,11 +29,14 @@ import org.deeplearning4j.rl4j.network.NeuralNetOutput; import org.deeplearning4j.rl4j.observation.Observation; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.ArgumentCaptor; import org.mockito.Mock; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -45,6 +48,8 @@ import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) @Disabled("mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class NonRecurrentAdvantageActorCriticTest { private static final int ACTION_SPACE_SIZE = 2; private static final double GAMMA = 0.99; diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentActorCriticHelperTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentActorCriticHelperTest.java index 855cc7ddf..adc495720 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentActorCriticHelperTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentActorCriticHelperTest.java @@ -20,13 +20,17 @@ package org.deeplearning4j.rl4j.agent.learning.algorithm.actorcritic; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.assertArrayEquals; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@NativeTag public class RecurrentActorCriticHelperTest { private final RecurrentActorCriticHelper sut = new RecurrentActorCriticHelper(3); diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentAdvantageActorCriticTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentAdvantageActorCriticTest.java index 1bca65745..c55efd99d 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentAdvantageActorCriticTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/actorcritic/RecurrentAdvantageActorCriticTest.java @@ -29,11 +29,14 @@ import org.deeplearning4j.rl4j.network.NeuralNetOutput; import org.deeplearning4j.rl4j.observation.Observation; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.ArgumentCaptor; import org.mockito.Mock; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import org.nd4j.linalg.indexing.NDArrayIndex; @@ -46,6 +49,8 @@ import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) @Disabled("Mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class RecurrentAdvantageActorCriticTest { private static final int ACTION_SPACE_SIZE = 2; private static final double GAMMA = 0.99; diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/DoubleDQNTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/DoubleDQNTest.java index 46656e79c..e87952393 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/DoubleDQNTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/DoubleDQNTest.java @@ -30,10 +30,13 @@ import org.deeplearning4j.rl4j.network.NeuralNetOutput; import org.deeplearning4j.rl4j.observation.Observation; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.Mock; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -46,6 +49,8 @@ import static org.mockito.Mockito.when; @RunWith(MockitoJUnitRunner.class) @Disabled("mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class DoubleDQNTest { @Mock diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/StandardDQNTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/StandardDQNTest.java index ea428efb0..4843d3d09 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/StandardDQNTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/dqn/StandardDQNTest.java @@ -30,10 +30,13 @@ import org.deeplearning4j.rl4j.network.NeuralNetOutput; import org.deeplearning4j.rl4j.observation.Observation; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.Mock; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -46,6 +49,8 @@ import static org.mockito.Mockito.when; @RunWith(MockitoJUnitRunner.class) @Disabled("mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class StandardDQNTest { @Mock diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningHelperTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningHelperTest.java index 97ec2c44f..6e7604f9b 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningHelperTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningHelperTest.java @@ -25,8 +25,11 @@ import org.deeplearning4j.rl4j.network.CommonOutputNames; import org.deeplearning4j.rl4j.network.IOutputNeuralNet; import org.deeplearning4j.rl4j.network.NeuralNetOutput; import org.deeplearning4j.rl4j.observation.Observation; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.mockito.ArgumentCaptor; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -35,7 +38,8 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.*; import static org.mockito.Mockito.*; - +@Tag(TagNames.FILE_IO) +@NativeTag public class NonRecurrentNStepQLearningHelperTest { private final NonRecurrentNStepQLearningHelper sut = new NonRecurrentNStepQLearningHelper(3); diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningTest.java index c4ff7aea8..61a315145 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/NonRecurrentNStepQLearningTest.java @@ -26,11 +26,14 @@ import org.deeplearning4j.rl4j.experience.StateActionReward; import org.deeplearning4j.rl4j.network.*; import org.deeplearning4j.rl4j.observation.Observation; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.ArgumentCaptor; import org.mockito.Mock; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -42,6 +45,8 @@ import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) @Disabled("mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class NonRecurrentNStepQLearningTest { private static final int ACTION_SPACE_SIZE = 2; diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningHelperTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningHelperTest.java index e364d272f..e57e45c1a 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningHelperTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningHelperTest.java @@ -26,8 +26,11 @@ import org.deeplearning4j.rl4j.network.CommonOutputNames; import org.deeplearning4j.rl4j.network.IOutputNeuralNet; import org.deeplearning4j.rl4j.network.NeuralNetOutput; import org.deeplearning4j.rl4j.observation.Observation; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.mockito.ArgumentCaptor; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -37,7 +40,8 @@ import java.util.List; import static org.junit.jupiter.api.Assertions.assertArrayEquals; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.mockito.Mockito.*; - +@Tag(TagNames.FILE_IO) +@NativeTag public class RecurrentNStepQLearningHelperTest { private final RecurrentNStepQLearningHelper sut = new RecurrentNStepQLearningHelper(3); diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningTest.java index cd7e82c36..81371e409 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/algorithm/nstepqlearning/RecurrentNStepQLearningTest.java @@ -27,11 +27,14 @@ import org.deeplearning4j.rl4j.experience.StateActionReward; import org.deeplearning4j.rl4j.network.*; import org.deeplearning4j.rl4j.observation.Observation; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.ArgumentCaptor; import org.mockito.Mock; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -43,6 +46,8 @@ import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) @Disabled("mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class RecurrentNStepQLearningTest { private static final int ACTION_SPACE_SIZE = 2; diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/behavior/LearningBehaviorTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/behavior/LearningBehaviorTest.java index 16201f4c5..684e84209 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/behavior/LearningBehaviorTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/behavior/LearningBehaviorTest.java @@ -20,16 +20,18 @@ package org.deeplearning4j.rl4j.agent.learning.behavior; -import org.deeplearning4j.rl4j.agent.learning.behavior.LearningBehavior; import org.deeplearning4j.rl4j.agent.learning.update.IUpdateRule; import org.deeplearning4j.rl4j.experience.ExperienceHandler; import org.deeplearning4j.rl4j.observation.Observation; import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.ArgumentCaptor; import org.mockito.Mock; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -41,6 +43,8 @@ import static org.junit.jupiter.api.Assertions.assertFalse; import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) +@Tag(TagNames.FILE_IO) +@NativeTag public class LearningBehaviorTest { @Mock diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesBuilderTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesBuilderTest.java index e67999ec7..c6668de74 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesBuilderTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesBuilderTest.java @@ -25,9 +25,12 @@ import org.deeplearning4j.rl4j.experience.StateActionRewardState; import org.deeplearning4j.rl4j.observation.IObservationSource; import org.deeplearning4j.rl4j.observation.Observation; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -39,6 +42,8 @@ import static org.junit.jupiter.api.Assertions.assertEquals; @RunWith(MockitoJUnitRunner.class) @Disabled("mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class FeaturesBuilderTest { @Test diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesLabelsTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesLabelsTest.java index 2466f5f8d..a125762a1 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesLabelsTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesLabelsTest.java @@ -21,9 +21,12 @@ package org.deeplearning4j.rl4j.agent.learning.update; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -33,6 +36,8 @@ import static org.mockito.Mockito.when; @RunWith(MockitoJUnitRunner.class) @Disabled("mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class FeaturesLabelsTest { @Test diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesTest.java index 43f4d3c31..35dd1e77a 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/FeaturesTest.java @@ -20,13 +20,17 @@ package org.deeplearning4j.rl4j.agent.learning.update; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertSame; - +@Tag(TagNames.FILE_IO) +@NativeTag public class FeaturesTest { @Test diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/GradientsTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/GradientsTest.java index 6f53ef0d3..11bd1e199 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/GradientsTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/GradientsTest.java @@ -22,9 +22,12 @@ package org.deeplearning4j.rl4j.agent.learning.update; import org.deeplearning4j.nn.gradient.Gradient; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertSame; @@ -32,6 +35,8 @@ import static org.mockito.Mockito.mock; @RunWith(MockitoJUnitRunner.class) @Disabled("mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class GradientsTest { @Test diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/UpdateRuleTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/UpdateRuleTest.java index cc2f4926d..a64c78bdf 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/UpdateRuleTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/UpdateRuleTest.java @@ -24,10 +24,13 @@ import org.deeplearning4j.rl4j.agent.learning.algorithm.IUpdateAlgorithm; import org.deeplearning4j.rl4j.agent.learning.update.updater.INeuralNetUpdater; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.Mock; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.util.ArrayList; import java.util.List; @@ -37,6 +40,8 @@ import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) @Disabled("mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class UpdateRuleTest { @Mock diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncGradientsNeuralNetUpdaterTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncGradientsNeuralNetUpdaterTest.java index 8f02fa800..e6cfd3498 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncGradientsNeuralNetUpdaterTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncGradientsNeuralNetUpdaterTest.java @@ -23,14 +23,19 @@ package org.deeplearning4j.rl4j.agent.learning.update.updater.async; import org.deeplearning4j.rl4j.agent.learning.update.Gradients; import org.deeplearning4j.rl4j.agent.learning.update.updater.NeuralNetUpdaterConfiguration; import org.deeplearning4j.rl4j.network.ITrainableNeuralNet; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.Mock; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) +@Tag(TagNames.FILE_IO) +@NativeTag public class AsyncGradientsNeuralNetUpdaterTest { @Mock diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncLabelsNeuralNetUpdaterTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncLabelsNeuralNetUpdaterTest.java index d953202d7..40693fbea 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncLabelsNeuralNetUpdaterTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncLabelsNeuralNetUpdaterTest.java @@ -24,14 +24,19 @@ import org.deeplearning4j.rl4j.agent.learning.update.FeaturesLabels; import org.deeplearning4j.rl4j.agent.learning.update.Gradients; import org.deeplearning4j.rl4j.agent.learning.update.updater.NeuralNetUpdaterConfiguration; import org.deeplearning4j.rl4j.network.ITrainableNeuralNet; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.Mock; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) +@Tag(TagNames.FILE_IO) +@NativeTag public class AsyncLabelsNeuralNetUpdaterTest { @Mock diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncSharedNetworksUpdateHandlerTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncSharedNetworksUpdateHandlerTest.java index 56694cfd9..ad8a48eaa 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncSharedNetworksUpdateHandlerTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/async/AsyncSharedNetworksUpdateHandlerTest.java @@ -23,10 +23,13 @@ package org.deeplearning4j.rl4j.agent.learning.update.updater.async; import org.deeplearning4j.rl4j.agent.learning.update.Gradients; import org.deeplearning4j.rl4j.agent.learning.update.updater.NeuralNetUpdaterConfiguration; import org.deeplearning4j.rl4j.network.ITrainableNeuralNet; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.Mock; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.assertTrue; import static org.junit.jupiter.api.Assertions.fail; @@ -34,6 +37,8 @@ import static org.mockito.ArgumentMatchers.any; import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) +@Tag(TagNames.FILE_IO) +@NativeTag public class AsyncSharedNetworksUpdateHandlerTest { @Mock diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncGradientsNeuralNetUpdaterTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncGradientsNeuralNetUpdaterTest.java index f11e6e45d..82193517e 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncGradientsNeuralNetUpdaterTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncGradientsNeuralNetUpdaterTest.java @@ -23,14 +23,19 @@ package org.deeplearning4j.rl4j.agent.learning.update.updater.sync; import org.deeplearning4j.rl4j.agent.learning.update.Gradients; import org.deeplearning4j.rl4j.agent.learning.update.updater.NeuralNetUpdaterConfiguration; import org.deeplearning4j.rl4j.network.ITrainableNeuralNet; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.Mock; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) +@Tag(TagNames.FILE_IO) +@NativeTag public class SyncGradientsNeuralNetUpdaterTest { @Mock diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncLabelsNeuralNetUpdaterTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncLabelsNeuralNetUpdaterTest.java index dd11d8a75..f4e0b3c24 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncLabelsNeuralNetUpdaterTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/agent/learning/update/updater/sync/SyncLabelsNeuralNetUpdaterTest.java @@ -23,16 +23,21 @@ package org.deeplearning4j.rl4j.agent.learning.update.updater.sync; import org.deeplearning4j.rl4j.agent.learning.update.FeaturesLabels; import org.deeplearning4j.rl4j.agent.learning.update.updater.NeuralNetUpdaterConfiguration; import org.deeplearning4j.rl4j.network.ITrainableNeuralNet; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.Mock; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.assertTrue; import static org.junit.jupiter.api.Assertions.fail; import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) +@Tag(TagNames.FILE_IO) +@NativeTag public class SyncLabelsNeuralNetUpdaterTest { @Mock diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/experience/ReplayMemoryExperienceHandlerTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/experience/ReplayMemoryExperienceHandlerTest.java index ca739f7b6..e2c430f25 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/experience/ReplayMemoryExperienceHandlerTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/experience/ReplayMemoryExperienceHandlerTest.java @@ -23,11 +23,14 @@ package org.deeplearning4j.rl4j.experience; import org.deeplearning4j.rl4j.learning.sync.IExpReplay; import org.deeplearning4j.rl4j.observation.Observation; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.ArgumentCaptor; import org.mockito.Mock; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import java.util.List; @@ -37,6 +40,8 @@ import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) @Disabled("Mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class ReplayMemoryExperienceHandlerTest { @Mock diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/experience/StateActionExperienceHandlerTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/experience/StateActionExperienceHandlerTest.java index c2c79a363..526f8e36e 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/experience/StateActionExperienceHandlerTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/experience/StateActionExperienceHandlerTest.java @@ -21,13 +21,17 @@ package org.deeplearning4j.rl4j.experience; import org.deeplearning4j.rl4j.observation.Observation; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.factory.Nd4j; import java.util.List; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@NativeTag public class StateActionExperienceHandlerTest { private StateActionExperienceHandler.Configuration buildConfiguration(int batchSize) { diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/helper/INDArrayHelperTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/helper/INDArrayHelperTest.java index b82c9a219..4ba17ef63 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/helper/INDArrayHelperTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/helper/INDArrayHelperTest.java @@ -20,12 +20,16 @@ package org.deeplearning4j.rl4j.helper; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@NativeTag public class INDArrayHelperTest { @Test public void when_inputHasIncorrectShape_expect_outputWithCorrectShape() { diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ActorCriticNetworkTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ActorCriticNetworkTest.java index 2d0fe5336..9890b2098 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ActorCriticNetworkTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ActorCriticNetworkTest.java @@ -27,9 +27,12 @@ import org.deeplearning4j.rl4j.agent.learning.update.Features; import org.deeplearning4j.rl4j.agent.learning.update.FeaturesLabels; import org.deeplearning4j.rl4j.agent.learning.update.Gradients; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -40,6 +43,8 @@ import static org.mockito.Mockito.times; @RunWith(MockitoJUnitRunner.class) @Disabled("Mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class ActorCriticNetworkTest { private FeaturesLabels createFeaturesLabelsMock() { diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ChannelToNetworkInputMapperTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ChannelToNetworkInputMapperTest.java index a5a503c8c..baf9678c1 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ChannelToNetworkInputMapperTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ChannelToNetworkInputMapperTest.java @@ -23,9 +23,12 @@ package org.deeplearning4j.rl4j.network; import org.deeplearning4j.rl4j.agent.learning.update.Features; import org.deeplearning4j.rl4j.observation.Observation; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -33,6 +36,8 @@ import static org.junit.jupiter.api.Assertions.*; @RunWith(MockitoJUnitRunner.class) @Disabled("Mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class ChannelToNetworkInputMapperTest { @Test diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/CompoundNetworkHandlerTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/CompoundNetworkHandlerTest.java index ab9e219e5..147e37019 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/CompoundNetworkHandlerTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/CompoundNetworkHandlerTest.java @@ -25,10 +25,13 @@ import org.deeplearning4j.rl4j.agent.learning.update.FeaturesLabels; import org.deeplearning4j.rl4j.agent.learning.update.Gradients; import org.deeplearning4j.rl4j.observation.Observation; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.Mock; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -37,6 +40,8 @@ import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) @Disabled("Mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class CompoundNetworkHandlerTest { @Mock diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ComputationGraphHandlerTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ComputationGraphHandlerTest.java index 084beadab..a9c905fc0 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ComputationGraphHandlerTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/ComputationGraphHandlerTest.java @@ -31,10 +31,13 @@ import org.deeplearning4j.rl4j.agent.learning.update.FeaturesLabels; import org.deeplearning4j.rl4j.agent.learning.update.Gradients; import org.deeplearning4j.rl4j.observation.Observation; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.ArgumentCaptor; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -47,6 +50,8 @@ import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) @Disabled("Mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class ComputationGraphHandlerTest { private static final String[] LABEL_NAMES = new String[]{"TEST_LABEL"}; diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/MultiLayerNetworkHandlerTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/MultiLayerNetworkHandlerTest.java index adf76fef6..a4fbc4ec0 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/MultiLayerNetworkHandlerTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/MultiLayerNetworkHandlerTest.java @@ -31,10 +31,13 @@ import org.deeplearning4j.rl4j.agent.learning.update.FeaturesLabels; import org.deeplearning4j.rl4j.agent.learning.update.Gradients; import org.deeplearning4j.rl4j.observation.Observation; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.ArgumentCaptor; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -47,6 +50,8 @@ import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) @Disabled("Mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class MultiLayerNetworkHandlerTest { private static final String LABEL_NAME = "TEST_LABEL"; diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/NetworkHelperTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/NetworkHelperTest.java index 1d3f37986..3796a1607 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/NetworkHelperTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/NetworkHelperTest.java @@ -25,9 +25,12 @@ import org.deeplearning4j.nn.graph.ComputationGraph; import org.deeplearning4j.nn.multilayer.MultiLayerNetwork; import org.deeplearning4j.rl4j.observation.Observation; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -40,6 +43,8 @@ import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) @Disabled("Mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class NetworkHelperTest { @Test diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/QNetworkTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/QNetworkTest.java index f3cd52a8d..921941137 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/QNetworkTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/network/QNetworkTest.java @@ -27,9 +27,12 @@ import org.deeplearning4j.rl4j.agent.learning.update.Features; import org.deeplearning4j.rl4j.agent.learning.update.FeaturesLabels; import org.deeplearning4j.rl4j.agent.learning.update.Gradients; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; @@ -39,6 +42,8 @@ import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) @Disabled("Mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class QNetworkTest { private FeaturesLabels createFeaturesLabelsMock() { diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/TransformProcessTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/TransformProcessTest.java index b0bbcbce8..e42d1faa1 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/TransformProcessTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/TransformProcessTest.java @@ -21,7 +21,10 @@ package org.deeplearning4j.rl4j.observation.transform; import org.deeplearning4j.rl4j.observation.Observation; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.dataset.api.DataSet; import org.nd4j.linalg.dataset.api.DataSetPreProcessor; import org.nd4j.linalg.factory.Nd4j; @@ -31,7 +34,8 @@ import java.util.HashMap; import java.util.Map; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@NativeTag public class TransformProcessTest { @Test() public void when_noChannelNameIsSuppliedToBuild_expect_exception() { diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/ArrayToINDArrayTransformTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/ArrayToINDArrayTransformTest.java index b6a0d091f..2c5279a87 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/ArrayToINDArrayTransformTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/ArrayToINDArrayTransformTest.java @@ -20,12 +20,16 @@ package org.deeplearning4j.rl4j.observation.transform.operation; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import static org.junit.jupiter.api.Assertions.assertArrayEquals; import static org.junit.jupiter.api.Assertions.assertEquals; - +@Tag(TagNames.FILE_IO) +@NativeTag public class ArrayToINDArrayTransformTest { @Test diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/HistoryMergeTransformTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/HistoryMergeTransformTest.java index 172f58c2d..718ab1cd4 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/HistoryMergeTransformTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/HistoryMergeTransformTest.java @@ -22,12 +22,16 @@ package org.deeplearning4j.rl4j.observation.transform.operation; import org.deeplearning4j.rl4j.observation.transform.operation.historymerge.HistoryMergeAssembler; import org.deeplearning4j.rl4j.observation.transform.operation.historymerge.HistoryMergeElementStore; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@NativeTag public class HistoryMergeTransformTest { @Test diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/SimpleNormalizationTransformTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/SimpleNormalizationTransformTest.java index 9c2f4eebc..2f21b59e4 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/SimpleNormalizationTransformTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/SimpleNormalizationTransformTest.java @@ -20,13 +20,17 @@ package org.deeplearning4j.rl4j.observation.transform.operation; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertThrows; - +@Tag(TagNames.FILE_IO) +@NativeTag public class SimpleNormalizationTransformTest { @Test() public void when_maxIsLessThanMin_expect_exception() { diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryStackAssemblerTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryStackAssemblerTest.java index 6adfdbb19..eee37e3af 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryStackAssemblerTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/observation/transform/operation/historymerge/HistoryStackAssemblerTest.java @@ -20,12 +20,16 @@ package org.deeplearning4j.rl4j.observation.transform.operation.historymerge; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.factory.Nd4j; import static org.junit.jupiter.api.Assertions.*; - +@Tag(TagNames.FILE_IO) +@NativeTag public class HistoryStackAssemblerTest { @Test diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/trainer/AsyncTrainerTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/trainer/AsyncTrainerTest.java index ea15a7871..5aa14b97b 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/trainer/AsyncTrainerTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/trainer/AsyncTrainerTest.java @@ -24,10 +24,13 @@ import org.apache.commons.lang3.builder.Builder; import org.deeplearning4j.rl4j.agent.IAgentLearner; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.Mock; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.util.concurrent.atomic.AtomicInteger; import java.util.function.Predicate; @@ -37,6 +40,8 @@ import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) @Disabled("Mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class AsyncTrainerTest { @Mock diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/trainer/SyncTrainerTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/trainer/SyncTrainerTest.java index c34bd4a2a..ccfe2d322 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/trainer/SyncTrainerTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/trainer/SyncTrainerTest.java @@ -24,10 +24,13 @@ import org.apache.commons.lang3.builder.Builder; import org.deeplearning4j.rl4j.agent.IAgentLearner; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; import org.junit.runner.RunWith; import org.mockito.Mock; import org.mockito.junit.MockitoJUnitRunner; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import java.util.function.Predicate; @@ -36,6 +39,8 @@ import static org.mockito.Mockito.*; @RunWith(MockitoJUnitRunner.class) @Disabled("Mockito") +@Tag(TagNames.FILE_IO) +@NativeTag public class SyncTrainerTest { @Mock diff --git a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/util/DataManagerTrainingListenerTest.java b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/util/DataManagerTrainingListenerTest.java index 8fc55bffe..b79bd78ad 100644 --- a/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/util/DataManagerTrainingListenerTest.java +++ b/rl4j/rl4j-core/src/test/java/org/deeplearning4j/rl4j/util/DataManagerTrainingListenerTest.java @@ -34,11 +34,15 @@ import org.deeplearning4j.rl4j.support.MockDataManager; import org.deeplearning4j.rl4j.support.MockHistoryProcessor; import org.deeplearning4j.rl4j.support.MockMDP; import org.deeplearning4j.rl4j.support.MockObservationSpace; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertSame; - +@Tag(TagNames.FILE_IO) +@NativeTag public class DataManagerTrainingListenerTest { @Test diff --git a/rl4j/rl4j-gym/pom.xml b/rl4j/rl4j-gym/pom.xml index 180237718..1177f3bdc 100644 --- a/rl4j/rl4j-gym/pom.xml +++ b/rl4j/rl4j-gym/pom.xml @@ -37,6 +37,12 @@ rl4j-gym + + org.nd4j + nd4j-common-tests + ${project.version} + test + org.deeplearning4j rl4j-api @@ -47,6 +53,12 @@ gym-platform ${gym.version}-${javacpp-presets.version} + + org.nd4j + nd4j-common-tests + 1.0.0-SNAPSHOT + test + diff --git a/rl4j/rl4j-gym/src/test/java/org/deeplearning4j/rl4j/mdp/gym/GymEnvTest.java b/rl4j/rl4j-gym/src/test/java/org/deeplearning4j/rl4j/mdp/gym/GymEnvTest.java index 7de2b3cc4..95977e0c7 100644 --- a/rl4j/rl4j-gym/src/test/java/org/deeplearning4j/rl4j/mdp/gym/GymEnvTest.java +++ b/rl4j/rl4j-gym/src/test/java/org/deeplearning4j/rl4j/mdp/gym/GymEnvTest.java @@ -25,7 +25,10 @@ import org.deeplearning4j.rl4j.space.ArrayObservationSpace; import org.deeplearning4j.rl4j.space.Box; import org.deeplearning4j.rl4j.space.DiscreteSpace; import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Tag; import org.junit.jupiter.api.Test; +import org.nd4j.common.tests.tags.NativeTag; +import org.nd4j.common.tests.tags.TagNames; import static org.junit.jupiter.api.Assertions.assertArrayEquals; import static org.junit.jupiter.api.Assertions.assertEquals; @@ -35,14 +38,16 @@ import static org.junit.jupiter.api.Assertions.assertNotEquals; * * @author saudet */ +@Tag(TagNames.FILE_IO) +@NativeTag public class GymEnvTest { @Test @Disabled("Permissions issues on CI") public void testCartpole() { GymEnv mdp = new GymEnv("CartPole-v0", false, false); - assertArrayEquals(new int[] {4}, ((ArrayObservationSpace)mdp.getObservationSpace()).getShape()); - assertEquals(2, ((DiscreteSpace)mdp.getActionSpace()).getSize()); + assertArrayEquals(new int[] {4}, mdp.getObservationSpace().getShape()); + assertEquals(2, mdp.getActionSpace().getSize()); assertEquals(false, mdp.isDone()); Box o = (Box)mdp.reset(); StepReply r = mdp.step(0);