Skip to content

Commit

Permalink
bump to pom-scijava-37.0.0
Browse files Browse the repository at this point in the history
# Conflicts:
#	src/main/java/org/janelia/saalfeldlab/View.java
#	src/main/java/org/janelia/saalfeldlab/cosem/ViewCosem.java
  • Loading branch information
axtimwalde committed May 2, 2024
1 parent 062e22a commit c74a73a
Show file tree
Hide file tree
Showing 8 changed files with 274 additions and 613 deletions.
47 changes: 30 additions & 17 deletions pom.xml
Original file line number Diff line number Diff line change
@@ -1,19 +1,22 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>org.scijava</groupId>
<artifactId>pom-scijava</artifactId>
<version>33.2.0</version>
<version>37.0.0</version>
</parent>

<groupId>org.janelia.saalfeldlab</groupId>
<artifactId>n5-utils</artifactId>
<version>0.0.7-SNAPSHOT</version>

<name>N5 Utils</name>
<description>simple standalone BigDataViewer for multiple N5 (or HDF5) datasets.</description>
<description>simple standalone BigDataViewer for multiple N5 (or HDF5)
datasets.</description>
<url>https://github.com/saalfeldlab/n5-utils</url>
<inceptionYear>2017</inceptionYear>
<organization>
Expand Down Expand Up @@ -48,27 +51,37 @@
<contributor>
<name>Jan Funke</name>
<url>https://imagej.net/User:Funke</url>
<properties><id>funkey</id></properties>
<properties>
<id>funkey</id>
</properties>
</contributor>
<contributor>
<name>Kyle Harrington</name>
<url>https://imagej.net/User:Kharrington</url>
<properties><id>kephale</id></properties>
<properties>
<id>kephale</id>
</properties>
</contributor>
<contributor>
<name>Gregory Jefferis</name>
<url>https://imagej.net/User:Jefferis</url>
<properties><id>jefferis</id></properties>
<properties>
<id>jefferis</id>
</properties>
</contributor>
<contributor>
<name>Tobias Pietzsch</name>
<url>https://imagej.net/User:Pietzsch</url>
<properties><id>tpietzsch</id></properties>
<properties>
<id>tpietzsch</id>
</properties>
</contributor>
<contributor>
<name>Igor Pisarev</name>
<url>https://imagej.net/User:Pisarevi</url>
<properties><id>igorpisarev</id></properties>
<properties>
<id>igorpisarev</id>
</properties>
</contributor>
<contributor>
<name>Greg Fleishman</name>
Expand Down Expand Up @@ -107,13 +120,6 @@
<!-- NB: Deploy releases to the SciJava Maven repository. -->
<releaseProfiles>sign,deploy-to-scijava</releaseProfiles>

<!-- TODO remove when pom-scijava-base is updated -->
<scijava.jvm.version>8</scijava.jvm.version>
<scijava.jvm.build.version>[1.8.0-101,)</scijava.jvm.build.version>

<maven-enforcer-plugin.version>3.0.0-M3</maven-enforcer-plugin.version>
<jacoco-maven-plugin.version>0.8.6</jacoco-maven-plugin.version>

<n5-jpeg.version>0.0.1-beta1</n5-jpeg.version>
</properties>

Expand Down Expand Up @@ -147,6 +153,11 @@
<groupId>org.janelia.saalfeldlab</groupId>
<artifactId>n5-hdf5</artifactId>
</dependency>
<dependency>
<groupId>net.imglib2</groupId>
<artifactId>imglib2-algorithm-gpl</artifactId>
</dependency>

<dependency>
<groupId>org.janelia.saalfeldlab</groupId>
<artifactId>n5-aws-s3</artifactId>
Expand Down Expand Up @@ -200,11 +211,13 @@
<artifactId>n5-jpeg</artifactId>
<version>${n5-jpeg.version}</version>
</dependency>

<dependency>
<groupId>org.janelia.saalfeldlab</groupId>
<artifactId>n5-universe</artifactId>
</dependency>
<dependency>
<groupId>cisd</groupId>
<artifactId>jhdf5</artifactId>
<version>${cisd.jhdf5.version}</version>
</dependency>
</dependencies>

Expand Down
25 changes: 15 additions & 10 deletions src/main/java/org/janelia/saalfeldlab/Copy.java
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,6 @@
*/
package org.janelia.saalfeldlab;

import java.io.IOException;
import java.util.HashSet;
import java.util.List;
import java.util.Map;
Expand All @@ -129,12 +128,12 @@
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;

import org.janelia.saalfeldlab.N5Factory.N5Options;
import org.janelia.saalfeldlab.n5.Bzip2Compression;
import org.janelia.saalfeldlab.n5.Compression;
import org.janelia.saalfeldlab.n5.DatasetAttributes;
import org.janelia.saalfeldlab.n5.GzipCompression;
import org.janelia.saalfeldlab.n5.Lz4Compression;
import org.janelia.saalfeldlab.n5.N5Exception;
import org.janelia.saalfeldlab.n5.N5Reader;
import org.janelia.saalfeldlab.n5.N5Writer;
import org.janelia.saalfeldlab.n5.RawCompression;
Expand All @@ -143,6 +142,7 @@
import org.janelia.saalfeldlab.n5.hdf5.N5HDF5Writer;
import org.janelia.saalfeldlab.n5.imglib2.N5Utils;
import org.janelia.saalfeldlab.n5.jpeg.JPEGCompression;
import org.janelia.saalfeldlab.n5.universe.N5Factory;

import net.imglib2.RandomAccessibleInterval;
import net.imglib2.type.NativeType;
Expand Down Expand Up @@ -236,7 +236,7 @@ protected void reorderIfNecessary(final long[] array) {
reorder(array);
}

protected <T extends NativeType<T>> void copyDataset(final String datasetName) throws IOException, InterruptedException, ExecutionException {
protected <T extends NativeType<T>> void copyDataset(final String datasetName) throws InterruptedException, ExecutionException {

System.out.println(datasetName);

Expand Down Expand Up @@ -272,8 +272,7 @@ protected <T extends NativeType<T>> void copyDataset(final String datasetName) t
copyAttributes(datasetName);
}

protected void copyAttributes(final String groupName)
throws IOException {
protected void copyAttributes(final String groupName) {

System.out.println(" attributes:");

Expand All @@ -291,14 +290,14 @@ protected void copyAttributes(final String groupName)

try {
n5Writer.setAttribute(groupName, key, n5Reader.getAttribute(groupName, key, clazz));
} catch (final IOException e) {
} catch (final N5Exception e) {
e.printStackTrace(System.err);
}
}
});
}

protected <T extends NativeType<T>> void copyGroup(final String groupName) throws IOException, InterruptedException, ExecutionException {
protected <T extends NativeType<T>> void copyGroup(final String groupName) throws InterruptedException, ExecutionException {

System.out.println(groupName);

Expand All @@ -315,7 +314,7 @@ protected <T extends NativeType<T>> void copyGroup(final String groupName) throw
}

@Override
public Void call() throws IOException, InterruptedException, ExecutionException {
public Void call() throws InterruptedException, ExecutionException {

blockSize = blockSizeString == null ? null : parseCSIntArray(blockSizeString);

Expand Down Expand Up @@ -349,8 +348,14 @@ public Void call() throws IOException, InterruptedException, ExecutionException
}
}

n5Reader = N5Factory.createN5Reader(new N5Options(inputContainerPath, blockSize, compression));
n5Writer = N5Factory.createN5Writer(new N5Options(outputContainerPath, blockSize, compression));
final N5Factory n5Factory = new N5Factory()
.hdf5DefaultBlockSize(blockSize)
.zarrDimensionSeparator(".")
.zarrMapN5Attributes(false)
.zarrMergeAttributes(false);

n5Reader = n5Factory.openReader(inputContainerPath);
n5Writer = n5Factory.openWriter(outputContainerPath);

if (groupNames == null)
copyGroup("");
Expand Down
12 changes: 6 additions & 6 deletions src/main/java/org/janelia/saalfeldlab/Equals.java
Original file line number Diff line number Diff line change
Expand Up @@ -119,15 +119,15 @@
*/
package org.janelia.saalfeldlab;

import java.io.IOException;
import java.util.Arrays;
import java.util.concurrent.Callable;
import java.util.concurrent.ExecutionException;

import org.janelia.saalfeldlab.N5Factory.N5Options;
import org.janelia.saalfeldlab.n5.DatasetAttributes;
import org.janelia.saalfeldlab.n5.N5Exception;
import org.janelia.saalfeldlab.n5.N5Reader;
import org.janelia.saalfeldlab.n5.imglib2.N5Utils;
import org.janelia.saalfeldlab.n5.universe.N5Factory;

import net.imglib2.Cursor;
import net.imglib2.RandomAccessibleInterval;
Expand Down Expand Up @@ -179,18 +179,18 @@ protected <T extends Type<T>> Boolean datasetEquals() {

return equals;
}
catch (final IOException e) {
catch (final N5Exception e) {

return false;
}
}


@Override
public Boolean call() throws IOException, InterruptedException, ExecutionException {
public Boolean call() throws InterruptedException, ExecutionException {

n5Reader1 = N5Factory.createN5Reader(new N5Options(inputContainerPath1, null, null));
n5Reader2 = N5Factory.createN5Reader(new N5Options(inputContainerPath2, null, null));
n5Reader1 = new N5Factory().openReader(inputContainerPath1);
n5Reader2 = new N5Factory().openReader(inputContainerPath2);

return datasetEquals();
}
Expand Down
Loading

0 comments on commit c74a73a

Please sign in to comment.