From c987e98e86842f8162e5c7da20c7e99c56239122 Mon Sep 17 00:00:00 2001 From: Michael Innerberger Date: Fri, 18 Aug 2023 10:49:57 -0400 Subject: [PATCH] Clean up some syntax errors and warnings --- .../client/newsolver/AffineDistributedSolver.java | 11 +++++------ .../DistributedIntensityCorrectionSolver.java | 3 ++- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/render-ws-java-client/src/main/java/org/janelia/render/client/newsolver/AffineDistributedSolver.java b/render-ws-java-client/src/main/java/org/janelia/render/client/newsolver/AffineDistributedSolver.java index 1a9ba3eba..de1861e41 100644 --- a/render-ws-java-client/src/main/java/org/janelia/render/client/newsolver/AffineDistributedSolver.java +++ b/render-ws-java-client/src/main/java/org/janelia/render/client/newsolver/AffineDistributedSolver.java @@ -127,20 +127,19 @@ public static void main( final String[] args ) throws IOException { allItems.addAll( future.get() ); } - catch (InterruptedException | ExecutionException e) + catch (final InterruptedException | ExecutionException e) { LOG.error( "Failed to compute alignments: " + e ); e.printStackTrace(); - return; } } ); taskExecutor.shutdown(); } - catch (InterruptedException e1) + catch (final InterruptedException e) { - LOG.error( "Failed to compute alignments: " + e1 ); - e1.printStackTrace(); + LOG.error( "Failed to compute alignments: " + e ); + e.printStackTrace(); return; } @@ -164,7 +163,7 @@ public static void main( final String[] args ) throws IOException allItems, solver, (r,z) -> z.set( r ), - () -> new AffineModel2D() ); + AffineModel2D::new); assembler.createAssembly(); diff --git a/render-ws-java-client/src/main/java/org/janelia/render/client/newsolver/DistributedIntensityCorrectionSolver.java b/render-ws-java-client/src/main/java/org/janelia/render/client/newsolver/DistributedIntensityCorrectionSolver.java index 8b407af4c..4c254ef4a 100644 --- a/render-ws-java-client/src/main/java/org/janelia/render/client/newsolver/DistributedIntensityCorrectionSolver.java +++ b/render-ws-java-client/src/main/java/org/janelia/render/client/newsolver/DistributedIntensityCorrectionSolver.java @@ -134,7 +134,8 @@ public static void main(final String[] args) throws IOException { cmdLineSetup.distributedSolve.maxIterationsGlobal, cmdLineSetup.threadsGlobal); - final Assembler, TranslationModel1D, ArrayList, ZBlockFactory> assembler = new Assembler<>(allItems, solver); + final Assembler, TranslationModel1D, ArrayList, ZBlockFactory> assembler = + new Assembler<>(allItems, solver, (r, z) -> z.addAll(r), ArrayList::new); assembler.createAssembly(); }