├── .github ├── build.sh ├── setup.sh └── workflows │ └── build.yml ├── src ├── main │ ├── resources │ │ ├── ClassDiagramInterestPointRegistration.dia │ │ └── LICENSE │ └── java │ │ ├── net │ │ └── preibisch │ │ │ ├── mvrecon │ │ │ ├── process │ │ │ │ ├── fusion │ │ │ │ │ ├── transformed │ │ │ │ │ │ ├── nonrigid │ │ │ │ │ │ │ ├── grid │ │ │ │ │ │ │ │ └── ModelGridTools.java │ │ │ │ │ │ │ ├── NonrigidIP.java │ │ │ │ │ │ │ ├── IPL.java │ │ │ │ │ │ │ ├── SimpleReferenceIP.java │ │ │ │ │ │ │ └── NonRigidParameters.java │ │ │ │ │ │ ├── AbstractTransformedImgRandomAccessible.java │ │ │ │ │ │ └── weightcombination │ │ │ │ │ │ │ ├── CombineWeightsMulRandomAccess.java │ │ │ │ │ │ │ └── CombineWeightsSumRandomAccess.java │ │ │ │ │ ├── intensity │ │ │ │ │ │ ├── IntensityMatchingFilter.java │ │ │ │ │ │ ├── mpicbg │ │ │ │ │ │ │ ├── Point1D.java │ │ │ │ │ │ │ ├── PointMatch1D.java │ │ │ │ │ │ │ └── SimpleErrorStatistic.java │ │ │ │ │ │ ├── UnbleachFunction.java │ │ │ │ │ │ └── ViewPairCoefficientMatches.java │ │ │ │ │ ├── ImagePortion.java │ │ │ │ │ └── intensityadjust │ │ │ │ │ │ └── IntensityAdjuster.java │ │ │ │ ├── deconvolution │ │ │ │ │ ├── init │ │ │ │ │ │ ├── PsiInitFactory.java │ │ │ │ │ │ ├── PsiInitAvgApproxFactory.java │ │ │ │ │ │ ├── PsiInitAvgPreciseFactory.java │ │ │ │ │ │ ├── PsiInitBlurredFusedFactory.java │ │ │ │ │ │ ├── PsiInitFromFileFactory.java │ │ │ │ │ │ ├── PsiInit.java │ │ │ │ │ │ └── PsiInitFromRAIFactory.java │ │ │ │ │ └── iteration │ │ │ │ │ │ └── ComputeBlockThreadFactory.java │ │ │ │ ├── interestpointregistration │ │ │ │ │ ├── pairwise │ │ │ │ │ │ ├── constellation │ │ │ │ │ │ │ ├── grouping │ │ │ │ │ │ │ │ ├── Grouping.java │ │ │ │ │ │ │ │ └── Bool.java │ │ │ │ │ │ │ ├── range │ │ │ │ │ │ │ │ ├── RangeComparator.java │ │ │ │ │ │ │ │ ├── AllInRange.java │ │ │ │ │ │ │ │ ├── TimepointRange.java │ │ │ │ │ │ │ │ └── ReferenceTimepointRange.java │ │ │ │ │ │ │ ├── overlap │ │ │ │ │ │ │ │ ├── OverlapDetection.java │ │ │ │ │ │ │ │ └── AllAgainstAllOverlap.java │ │ │ │ │ │ │ ├── AllToAll.java │ │ │ │ │ │ │ └── IndividualTimepoints.java │ │ │ │ │ │ ├── methods │ │ │ │ │ │ │ ├── centerofmass │ │ │ │ │ │ │ │ └── CenterOfMassParameters.java │ │ │ │ │ │ │ └── fastrgldm │ │ │ │ │ │ │ │ └── FRGLDMParameters.java │ │ │ │ │ │ └── LinkedInterestPoint.java │ │ │ │ │ └── global │ │ │ │ │ │ ├── pointmatchcreating │ │ │ │ │ │ ├── weak │ │ │ │ │ │ │ ├── WeakLinkFactory.java │ │ │ │ │ │ │ ├── WeakLinkPointMatchCreator.java │ │ │ │ │ │ │ └── MetaDataWeakLinkFactory.java │ │ │ │ │ │ └── Link.java │ │ │ │ │ │ ├── linkremoval │ │ │ │ │ │ └── LinkRemovalStrategy.java │ │ │ │ │ │ └── convergence │ │ │ │ │ │ ├── IterativeConvergenceStrategy.java │ │ │ │ │ │ └── ConvergenceStrategy.java │ │ │ │ ├── export │ │ │ │ │ └── Calibrateable.java │ │ │ │ ├── boundingbox │ │ │ │ │ └── BoundingBoxEstimation.java │ │ │ │ ├── pointcloud │ │ │ │ │ ├── pointdescriptor │ │ │ │ │ │ ├── similarity │ │ │ │ │ │ │ ├── SimilarityMeasure.java │ │ │ │ │ │ │ ├── LinearDistance.java │ │ │ │ │ │ │ ├── SquareDistance.java │ │ │ │ │ │ │ └── ManhattanDistance.java │ │ │ │ │ │ ├── exception │ │ │ │ │ │ │ └── NoSuitablePointsException.java │ │ │ │ │ │ ├── LinkedPoint.java │ │ │ │ │ │ ├── model │ │ │ │ │ │ │ └── TranslationInvariantModel.java │ │ │ │ │ │ └── test │ │ │ │ │ │ │ └── PointNode.java │ │ │ │ │ └── icp │ │ │ │ │ │ └── PointMatchIdentification.java │ │ │ │ ├── interestpointremoval │ │ │ │ │ ├── RelativeThinOutParameters.java │ │ │ │ │ ├── CreateFromCorrespondencesParameters.java │ │ │ │ │ └── ThinOutParameters.java │ │ │ │ └── cuda │ │ │ │ │ ├── BlockGenerator.java │ │ │ │ │ ├── CUDAFourierConvolution.java │ │ │ │ │ └── CUDAStandardFunctions.java │ │ │ └── fiji │ │ │ │ ├── spimdata │ │ │ │ ├── imgloaders │ │ │ │ │ ├── util │ │ │ │ │ │ ├── BioformatsReaderSetupHook.java │ │ │ │ │ │ └── BioformatsReaderUtils.java │ │ │ │ │ ├── filemap2 │ │ │ │ │ │ ├── FileMapGettable.java │ │ │ │ │ │ └── FileMapEntry.java │ │ │ │ │ ├── flatfield │ │ │ │ │ │ ├── FlatfieldCorrectionWrappedImgLoader.java │ │ │ │ │ │ └── XmlIoFlatfieldCorrectedWrappedImgLoaderMR.java │ │ │ │ │ ├── AbstractImgFactoryImgLoader.java │ │ │ │ │ ├── Calibration.java │ │ │ │ │ ├── CalibratedImg.java │ │ │ │ │ ├── StackImgLoaderIJ.java │ │ │ │ │ ├── StackImgLoaderLOCI.java │ │ │ │ │ ├── XmlIoStackImgLoaderIJ.java │ │ │ │ │ ├── XmlIoStackImgLoaderLOCI.java │ │ │ │ │ ├── MicroManagerImgLoader.java │ │ │ │ │ └── LightSheetZ1ImgLoader.java │ │ │ │ ├── explorer │ │ │ │ │ ├── popup │ │ │ │ │ │ ├── BasicBDVPopup.java │ │ │ │ │ │ ├── Separator.java │ │ │ │ │ │ ├── ExplorerWindowSetable.java │ │ │ │ │ │ └── LabelPopUp.java │ │ │ │ │ ├── StitchingResultsSettable.java │ │ │ │ │ ├── GroupedRowWindow.java │ │ │ │ │ ├── SelectedViewDescriptionListener.java │ │ │ │ │ ├── bdv │ │ │ │ │ │ └── ToggleDialogActionBrightness.java │ │ │ │ │ ├── FilteredAndGroupedExplorer.java │ │ │ │ │ ├── ExplorerWindow.java │ │ │ │ │ └── SimpleInfoBox.java │ │ │ │ ├── interestpoints │ │ │ │ │ ├── NonWastefulRealPoint.java │ │ │ │ │ ├── InterestPointValue.java │ │ │ │ │ ├── XmlKeysInterestPoints.java │ │ │ │ │ └── ViewInterestPointLists.java │ │ │ │ ├── stitchingresults │ │ │ │ │ ├── PairwiseLinkInterface.java │ │ │ │ │ ├── PairwiseLinkImpl.java │ │ │ │ │ ├── VectorUtil.java │ │ │ │ │ └── XmlKeysStitchingResults.java │ │ │ │ ├── boundingbox │ │ │ │ │ ├── XmlKeysBoundingBox.java │ │ │ │ │ └── BoundingBoxes.java │ │ │ │ ├── intensityadjust │ │ │ │ │ ├── XmlKeysIntensityAdjustments.java │ │ │ │ │ └── IntensityAdjustments.java │ │ │ │ └── pointspreadfunctions │ │ │ │ │ ├── XmlKeysPointSpreadFunctions.java │ │ │ │ │ └── PointSpreadFunctions.java │ │ │ │ ├── plugin │ │ │ │ ├── apply │ │ │ │ │ └── ApplyParameters.java │ │ │ │ ├── util │ │ │ │ │ └── GenericDialogAppender.java │ │ │ │ ├── interestpointregistration │ │ │ │ │ ├── global │ │ │ │ │ │ ├── GlobalGUI.java │ │ │ │ │ │ ├── AllToAllGUI.java │ │ │ │ │ │ └── IndividualTimepointGUI.java │ │ │ │ │ └── parameters │ │ │ │ │ │ ├── GroupParameters.java │ │ │ │ │ │ └── FixMapBackParameters.java │ │ │ │ ├── interestpointdetection │ │ │ │ │ └── interactive │ │ │ │ │ │ ├── FrameListener.java │ │ │ │ │ │ ├── InteractiveDoGParams.java │ │ │ │ │ │ ├── FinishedButtonListener.java │ │ │ │ │ │ └── ImagePlusListener.java │ │ │ │ └── resave │ │ │ │ │ └── ProgressWriterIJ.java │ │ │ │ └── datasetmanager │ │ │ │ ├── patterndetector │ │ │ │ └── FilenamePatternDetector.java │ │ │ │ └── metadatarefinement │ │ │ │ └── TileOrAngleRefiner.java │ │ │ └── legacy │ │ │ ├── registration │ │ │ ├── bead │ │ │ │ ├── SegmentationBenchmark.java │ │ │ │ ├── laplace │ │ │ │ │ └── RejectStatistics.java │ │ │ │ └── error │ │ │ │ │ └── GlobalErrorStatistics.java │ │ │ ├── detection │ │ │ │ ├── Detection.java │ │ │ │ └── descriptor │ │ │ │ │ └── CorrespondenceExtraction.java │ │ │ └── threshold │ │ │ │ └── ComponentProperties.java │ │ │ ├── segmentation │ │ │ └── SimplePeak.java │ │ │ └── mpicbg │ │ │ └── PointMatchGeneric.java │ │ └── util │ │ └── RealViews.java └── test │ └── java │ └── net │ └── preibisch │ └── mvrecon │ └── fiji │ └── spimdata │ └── interestpoints │ └── ExampleDirectLoading.java └── .gitignore /.github/build.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | curl -fsLO https://raw.githubusercontent.com/scijava/scijava-scripts/main/ci-build.sh 3 | sh ci-build.sh 4 | -------------------------------------------------------------------------------- /.github/setup.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | curl -fsLO https://raw.githubusercontent.com/scijava/scijava-scripts/main/ci-setup-github-actions.sh 3 | sh ci-setup-github-actions.sh 4 | -------------------------------------------------------------------------------- /src/main/resources/ClassDiagramInterestPointRegistration.dia: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JaneliaSciComp/multiview-reconstruction/HEAD/src/main/resources/ClassDiagramInterestPointRegistration.dia -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_STORE 2 | /jars/ 3 | /plugins/ 4 | 5 | # Eclipse # 6 | /.classpath 7 | /.project 8 | /.settings/ 9 | /bin/ 10 | 11 | # Maven # 12 | /target/ 13 | 14 | # VS-CODE # 15 | .vscode/ 16 | 17 | # IntelliJ # 18 | .idea/ 19 | SPIM_Registration.iml 20 | -------------------------------------------------------------------------------- /src/main/resources/LICENSE: -------------------------------------------------------------------------------- 1 | License: GPLv3 2 | 3 | Copyright (C) 2013 Dr. Stephan Preibisch (stephan.preibisch (at) gmx.de) 4 | 5 | This program is free software: you can redistribute it and/or modify 6 | it under the terms of the GNU General Public License as published by 7 | the Free Software Foundation, either version 3 of the License, or 8 | (at your option) any later version. 9 | 10 | This program is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | GNU General Public License for more details. 14 | 15 | You should have received a copy of the GNU General Public License 16 | along with this program. If not, see . -------------------------------------------------------------------------------- /.github/workflows/build.yml: -------------------------------------------------------------------------------- 1 | name: build 2 | 3 | on: 4 | push: 5 | branches: 6 | - master 7 | tags: 8 | - "*-[0-9]+.*" 9 | pull_request: 10 | branches: 11 | - master 12 | 13 | jobs: 14 | build: 15 | runs-on: ubuntu-latest 16 | 17 | steps: 18 | - uses: actions/checkout@v2 19 | - name: Set up Java 20 | uses: actions/setup-java@v3 21 | with: 22 | java-version: '8' 23 | java-package: 'jdk+fx' 24 | distribution: 'zulu' 25 | cache: 'maven' 26 | - name: Set up CI environment 27 | run: .github/setup.sh 28 | - name: Execute the build 29 | run: .github/build.sh 30 | env: 31 | GPG_KEY_NAME: ${{ secrets.GPG_KEY_NAME }} 32 | GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }} 33 | MAVEN_USER: ${{ secrets.MAVEN_USER }} 34 | MAVEN_PASS: ${{ secrets.MAVEN_PASS }} 35 | CENTRAL_USER: ${{ secrets.CENTRAL_USER }} 36 | CENTRAL_PASS: ${{ secrets.CENTRAL_PASS }} 37 | SIGNING_ASC: ${{ secrets.SIGNING_ASC }} 38 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/fusion/transformed/nonrigid/grid/ModelGridTools.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.fusion.transformed.nonrigid.grid; 24 | 25 | public class ModelGridTools 26 | { 27 | 28 | } 29 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/deconvolution/init/PsiInitFactory.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.deconvolution.init; 24 | 25 | public interface PsiInitFactory 26 | { 27 | public abstract PsiInit createPsiInitialization(); 28 | } 29 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/legacy/registration/bead/SegmentationBenchmark.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.legacy.registration.bead; 24 | 25 | public class SegmentationBenchmark 26 | { 27 | public long openFiles = 0; 28 | public long computation = 0; 29 | } 30 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/fusion/transformed/nonrigid/NonrigidIP.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.fusion.transformed.nonrigid; 24 | 25 | public interface NonrigidIP 26 | { 27 | public double[] getTargetW(); 28 | public double[] getL(); 29 | public double[] getW(); 30 | } 31 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/imgloaders/util/BioformatsReaderSetupHook.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.imgloaders.util; 24 | 25 | import loci.formats.IFormatReader; 26 | 27 | public interface BioformatsReaderSetupHook { 28 | public void runSetup(IFormatReader reader); 29 | } 30 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/pairwise/constellation/grouping/Grouping.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation.grouping; 24 | 25 | public interface Grouping< V, X > 26 | { 27 | public X group( final Group< V > group ); 28 | } 29 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/export/Calibrateable.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.export; 24 | 25 | public interface Calibrateable 26 | { 27 | public void setCalibration( final double[] pixelSize, final String unit ); 28 | public String getUnit(); 29 | public double[] getPixelSize(); 30 | } 31 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/pairwise/constellation/range/RangeComparator.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation.range; 24 | 25 | public interface RangeComparator< V > 26 | { 27 | public boolean inRange( V view1, V view2 ); 28 | } 29 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/boundingbox/BoundingBoxEstimation.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.boundingbox; 24 | 25 | import net.preibisch.mvrecon.fiji.spimdata.boundingbox.BoundingBox; 26 | 27 | public interface BoundingBoxEstimation 28 | { 29 | public BoundingBox estimate( final String title ); 30 | } 31 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/deconvolution/iteration/ComputeBlockThreadFactory.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.deconvolution.iteration; 24 | 25 | public interface ComputeBlockThreadFactory< C extends ComputeBlockThread > 26 | { 27 | public C create( final int id ); 28 | public int numParallelBlocks(); 29 | } 30 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/pairwise/constellation/grouping/Bool.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation.grouping; 24 | 25 | public class Bool 26 | { 27 | public boolean state; 28 | 29 | public Bool( final boolean state ) { this.state = state; } 30 | } 31 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/imgloaders/filemap2/FileMapGettable.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.imgloaders.filemap2; 24 | 25 | import java.util.Map; 26 | 27 | import mpicbg.spim.data.sequence.ViewId; 28 | 29 | public interface FileMapGettable 30 | { 31 | Map< ? extends ViewId, FileMapEntry > getFileMap(); 32 | } 33 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/deconvolution/init/PsiInitAvgApproxFactory.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.deconvolution.init; 24 | 25 | public class PsiInitAvgApproxFactory implements PsiInitFactory 26 | { 27 | @Override 28 | public PsiInitAvgApprox createPsiInitialization() 29 | { 30 | return new PsiInitAvgApprox(); 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/explorer/popup/BasicBDVPopup.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.explorer.popup; 24 | 25 | import bdv.BigDataViewer; 26 | 27 | public interface BasicBDVPopup 28 | { 29 | public void updateBDV(); 30 | public BigDataViewer getBDV(); 31 | public boolean bdvRunning(); 32 | public void closeBDV(); 33 | } 34 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/deconvolution/init/PsiInitAvgPreciseFactory.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.deconvolution.init; 24 | 25 | public class PsiInitAvgPreciseFactory implements PsiInitFactory 26 | { 27 | @Override 28 | public PsiInitAvgPrecise createPsiInitialization() 29 | { 30 | return new PsiInitAvgPrecise(); 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/plugin/apply/ApplyParameters.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.plugin.apply; 24 | 25 | public class ApplyParameters 26 | { 27 | public int applyTo, model, defineAs; 28 | public double minResolution; 29 | public boolean sameModelTimePoints, sameModelChannels, sameModelIlluminations, sameModelAngles, sameModelTiles; 30 | } 31 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/deconvolution/init/PsiInitBlurredFusedFactory.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.deconvolution.init; 24 | 25 | public class PsiInitBlurredFusedFactory implements PsiInitFactory 26 | { 27 | @Override 28 | public PsiInitBlurredFused createPsiInitialization() 29 | { 30 | return new PsiInitBlurredFused(); 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/pairwise/constellation/range/AllInRange.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation.range; 24 | 25 | public class AllInRange< V > implements RangeComparator< V > 26 | { 27 | @Override 28 | public boolean inRange( final V view1, final V view2 ) { return true; } 29 | } 30 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/interestpoints/NonWastefulRealPoint.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.interestpoints; 24 | 25 | import net.imglib2.RealPoint; 26 | 27 | public class NonWastefulRealPoint extends RealPoint 28 | { 29 | public NonWastefulRealPoint( final double[] position, final boolean copy ) 30 | { 31 | super( position, copy ); 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/pointcloud/pointdescriptor/similarity/SimilarityMeasure.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.pointcloud.pointdescriptor.similarity; 24 | 25 | import java.util.ArrayList; 26 | 27 | import mpicbg.models.PointMatch; 28 | 29 | public interface SimilarityMeasure 30 | { 31 | public double getSimilarity( final ArrayList matches ); 32 | } 33 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointremoval/RelativeThinOutParameters.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointremoval; 24 | 25 | public class RelativeThinOutParameters extends ThinOutParameters 26 | { 27 | public String relativeLabel; 28 | 29 | /** 30 | * @return relative to why label interest point should be removed 31 | */ 32 | public String getRelativeLabel() { return relativeLabel; } 33 | } 34 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointremoval/CreateFromCorrespondencesParameters.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointremoval; 24 | 25 | public class CreateFromCorrespondencesParameters 26 | { 27 | public String correspondingLabel; 28 | public String newLabel; 29 | 30 | public String getCorrespondingLabel() { return correspondingLabel; } 31 | public String getNewLabel() { return newLabel; } 32 | } 33 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/pairwise/constellation/overlap/OverlapDetection.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation.overlap; 24 | 25 | import net.imglib2.RealInterval; 26 | 27 | public interface OverlapDetection< V > 28 | { 29 | public boolean overlaps( final V view1, final V view2 ); 30 | public RealInterval getOverlapInterval( final V view1, final V view2 ); 31 | } 32 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/legacy/registration/bead/laplace/RejectStatistics.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.legacy.registration.bead.laplace; 24 | 25 | public class RejectStatistics 26 | { 27 | public int noStableMaxima = 0; 28 | public int tooHighEigenValueRatio = 0; 29 | public int noInverseOfHessianMatrix = 0; 30 | public int peakTooLow = 0; 31 | public int imaginaryEigenValues = 0; 32 | public int notHighestValueInIdentityRadius = 0; 33 | } 34 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/explorer/StitchingResultsSettable.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.explorer; 24 | 25 | import net.preibisch.mvrecon.fiji.spimdata.stitchingresults.StitchingResults; 26 | 27 | /** 28 | * Interface to be implemented by classes that need access to the global stitching results 29 | * @author david 30 | * 31 | */ 32 | public interface StitchingResultsSettable 33 | { 34 | public void setStitchingResults(StitchingResults res); 35 | } 36 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/legacy/segmentation/SimplePeak.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.legacy.segmentation; 24 | 25 | public class SimplePeak 26 | { 27 | public SimplePeak( final int[] location, final float intensity, final boolean isMin, final boolean isMax ) 28 | { 29 | this.location = location.clone(); 30 | this.isMin = isMin; 31 | this.isMax = isMax; 32 | this.intensity = intensity; 33 | } 34 | 35 | public int[] location; 36 | public boolean isMax, isMin; 37 | public float intensity; 38 | } 39 | 40 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/stitchingresults/PairwiseLinkInterface.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.stitchingresults; 24 | 25 | import java.util.Set; 26 | 27 | import mpicbg.spim.data.sequence.ViewId; 28 | import net.imglib2.util.Pair; 29 | import net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation.grouping.Group; 30 | 31 | public interface PairwiseLinkInterface 32 | { 33 | public Set< Pair< Group< ViewId >, Group< ViewId > > > getPairwiseLinks(); 34 | } 35 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/cuda/BlockGenerator.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.cuda; 24 | 25 | import java.util.List; 26 | 27 | public interface BlockGenerator< T extends Block > 28 | { 29 | /** 30 | * Divides an image into blocks 31 | * 32 | * @param imgSize - the size of the image 33 | * @param kernelSize - the size of the kernel (has to be odd!) 34 | * @return array of blocks 35 | */ 36 | public List< T > divideIntoBlocks( final long[] imgSize, final long[] kernelSize ); 37 | } 38 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/boundingbox/XmlKeysBoundingBox.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.boundingbox; 24 | 25 | public class XmlKeysBoundingBox 26 | { 27 | public static final String BOUNDINGBOXES_TAG = "BoundingBoxes"; 28 | public static final String BOUNDINGBOX_TAG = "BoundingBoxDefinition"; 29 | 30 | public static final String BOUNDINGBOX_TAG_NAME = "name"; 31 | public static final String BOUNDINGBOX_TAG_MIN = "min"; 32 | public static final String BOUNDINGBOX_TAG_MAX = "max"; 33 | } 34 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/intensityadjust/XmlKeysIntensityAdjustments.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.intensityadjust; 24 | 25 | public class XmlKeysIntensityAdjustments 26 | { 27 | public static final String INTENSITYADJ_TAG = "IntensityAdjustments"; 28 | 29 | public static final String INTENSITYADJ_TIMEPOINT_ATTRIBUTE_NAME = "timepoint"; 30 | public static final String INTENSITYADJ_SETUP_ATTRIBUTE_NAME = "setup"; 31 | 32 | public static final String INTENSITYADJ_VALUE_TAG = "model"; 33 | } 34 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/global/pointmatchcreating/weak/WeakLinkFactory.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.global.pointmatchcreating.weak; 24 | 25 | import java.util.HashMap; 26 | 27 | import mpicbg.models.Model; 28 | import mpicbg.models.Tile; 29 | import mpicbg.spim.data.sequence.ViewId; 30 | 31 | public interface WeakLinkFactory 32 | { 33 | public < M extends Model< M > > WeakLinkPointMatchCreator< M > create( final HashMap< ViewId, Tile< M > > models ); 34 | } 35 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/explorer/popup/Separator.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.explorer.popup; 24 | 25 | import javax.swing.JSeparator; 26 | 27 | import net.preibisch.mvrecon.fiji.spimdata.explorer.ExplorerWindow; 28 | 29 | public class Separator extends JSeparator implements ExplorerWindowSetable 30 | { 31 | private static final long serialVersionUID = 5234649267634013390L; 32 | 33 | @Override 34 | public JSeparator setExplorerWindow( final ExplorerWindow< ? > panel ) 35 | { 36 | return this; 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/plugin/util/GenericDialogAppender.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.plugin.util; 24 | 25 | import ij.gui.GenericDialog; 26 | 27 | public interface GenericDialogAppender 28 | { 29 | /* 30 | * adds the questions this registration wants to ask 31 | * 32 | * @param gd 33 | */ 34 | public void addQuery( final GenericDialog gd ); 35 | 36 | /* 37 | * queries the questions asked before 38 | * 39 | * @param gd 40 | * @return 41 | */ 42 | public boolean parseDialog( final GenericDialog gd ); 43 | 44 | } 45 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/datasetmanager/patterndetector/FilenamePatternDetector.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.datasetmanager.patterndetector; 24 | 25 | import java.util.List; 26 | import java.util.regex.Pattern; 27 | 28 | public interface FilenamePatternDetector 29 | { 30 | public void detectPatterns(List files); 31 | public String getInvariant(int n); 32 | public List getValuesForVariable(int n); 33 | public Pattern getPatternAsRegex(); 34 | public String getStringRepresentation(); 35 | public int getNumVariables(); 36 | } 37 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/interestpoints/InterestPointValue.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.interestpoints; 24 | 25 | public class InterestPointValue extends InterestPoint 26 | { 27 | private static final long serialVersionUID = -4538307380458133556L; 28 | 29 | final private double intensity; 30 | 31 | public InterestPointValue( final int id, final double[] l, final double intensity ) 32 | { 33 | super( id, l ); 34 | this.intensity = intensity; 35 | } 36 | 37 | public double getIntensity() { return intensity; } 38 | } 39 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/pointspreadfunctions/XmlKeysPointSpreadFunctions.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.pointspreadfunctions; 24 | 25 | public class XmlKeysPointSpreadFunctions 26 | { 27 | public static final String PSFS_TAG = "PointSpreadFunctions"; 28 | public static final String PSF_TAG = "BoundingBoxDefinition"; 29 | 30 | public static final String PSF_FILE_TAG = "File"; 31 | public static final String PSF_TIMEPOINT_ATTRIBUTE_NAME = "timepoint"; 32 | public static final String PSF_SETUP_ATTRIBUTE_NAME = "setup"; 33 | } 34 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/plugin/interestpointregistration/global/GlobalGUI.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.plugin.interestpointregistration.global; 24 | 25 | import java.util.List; 26 | 27 | import mpicbg.spim.data.sequence.ViewId; 28 | 29 | public interface GlobalGUI 30 | { 31 | /* 32 | * If the registration consists of multiple, completely indepedents sets of views, split them up here for later 33 | * 34 | * @param viewIds 35 | * @return 36 | */ 37 | public List< List< ViewId > > getIndividualSets( final List< ViewId > viewIds ); 38 | } 39 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/plugin/interestpointregistration/global/AllToAllGUI.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.plugin.interestpointregistration.global; 24 | 25 | import java.util.ArrayList; 26 | import java.util.List; 27 | 28 | import mpicbg.spim.data.sequence.ViewId; 29 | 30 | public class AllToAllGUI implements GlobalGUI 31 | { 32 | public List< List< ViewId > > getIndividualSets( final List< ViewId > viewIds ) 33 | { 34 | final ArrayList< List< ViewId > > sets = new ArrayList<>(); 35 | sets.add( viewIds ); 36 | 37 | return sets; 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/explorer/GroupedRowWindow.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.explorer; 24 | 25 | import java.util.Collection; 26 | import java.util.List; 27 | 28 | import mpicbg.spim.data.generic.sequence.BasicViewDescription; 29 | import mpicbg.spim.data.generic.sequence.BasicViewSetup; 30 | import mpicbg.spim.data.sequence.ViewId; 31 | 32 | public interface GroupedRowWindow 33 | { 34 | public Collection< List< BasicViewDescription< ? > > > selectedRowsGroups(); 35 | public List> selectedRowsViewIdGroups(); 36 | } 37 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/fusion/intensity/IntensityMatchingFilter.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.fusion.intensity; 24 | 25 | import mpicbg.models.PointMatch; 26 | import net.preibisch.mvrecon.process.fusion.intensity.mpicbg.FastAffineModel1D; 27 | import net.preibisch.mvrecon.process.fusion.intensity.mpicbg.FlattenedMatches; 28 | 29 | import java.util.Collection; 30 | 31 | interface IntensityMatchingFilter { 32 | 33 | FastAffineModel1D model(); 34 | 35 | void filter(FlattenedMatches candidates, Collection reducedMatches); 36 | } 37 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointremoval/ThinOutParameters.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointremoval; 24 | 25 | public class ThinOutParameters 26 | { 27 | public String label, newLabel; 28 | public double lowerThreshold, upperThreshold; 29 | public boolean keep; 30 | 31 | public String getLabel() { return label; } 32 | public String getNewLabel() { return newLabel; } 33 | public boolean keepRange() { return keep; } 34 | public double getMin() { return lowerThreshold; } 35 | public double getMax() { return upperThreshold; } 36 | } 37 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/plugin/interestpointdetection/interactive/FrameListener.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.plugin.interestpointdetection.interactive; 24 | 25 | import java.awt.event.WindowAdapter; 26 | import java.awt.event.WindowEvent; 27 | 28 | public class FrameListener extends WindowAdapter { 29 | final InteractiveDoG parent; 30 | 31 | public FrameListener( 32 | final InteractiveDoG parent ) 33 | { 34 | super(); 35 | this.parent = parent; 36 | } 37 | 38 | @Override 39 | public void windowClosing(WindowEvent e) { 40 | parent.dispose(); 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/cuda/CUDAFourierConvolution.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.cuda; 24 | 25 | 26 | public interface CUDAFourierConvolution extends CUDAStandardFunctions 27 | { 28 | /* 29 | __declspec(dllexport) imageType* convolution3DfftCUDA(imageType* im,int* imDim,imageType* kernel,int* kernelDim,int devCUDA); 30 | */ 31 | public float[] convolution3DfftCUDA( float[] im, int[] imDim, float[] kernel, int[] kernelDim, int devCUDA ); 32 | public void convolution3DfftCUDAInPlace( float[] im, int[] imDim, float[] kernel, int[] kernelDim, int devCUDA ); 33 | } 34 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/plugin/interestpointregistration/parameters/GroupParameters.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.plugin.interestpointregistration.parameters; 24 | 25 | public class GroupParameters 26 | { 27 | public static String[] ipGroupChoice = new String[]{ 28 | "Do not group interest points, compute views independently", 29 | "Group interest points (simply combine all in one virtual view)" }; 30 | 31 | public enum InterestpointGroupingType { DO_NOT_GROUP, ADD_ALL }; 32 | 33 | public InterestpointGroupingType grouping; 34 | public double mergeDistance; 35 | } 36 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/datasetmanager/metadatarefinement/TileOrAngleRefiner.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.datasetmanager.metadatarefinement; 24 | 25 | import java.util.List; 26 | 27 | import net.preibisch.mvrecon.fiji.datasetmanager.FileListDatasetDefinitionUtil; 28 | import net.preibisch.mvrecon.fiji.datasetmanager.FileListDatasetDefinitionUtil.TileOrAngleInfo; 29 | 30 | import loci.formats.IFormatReader; 31 | 32 | public interface TileOrAngleRefiner 33 | { 34 | public void refineTileOrAngleInfo( IFormatReader r, List infos); 35 | } 36 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/plugin/interestpointdetection/interactive/InteractiveDoGParams.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.plugin.interestpointdetection.interactive; 24 | 25 | import net.preibisch.mvrecon.fiji.plugin.interestpointdetection.DifferenceOfGaussianGUI; 26 | 27 | public class InteractiveDoGParams { 28 | 29 | public double sigma = DifferenceOfGaussianGUI.defaultSigma, threshold = DifferenceOfGaussianGUI.defaultThreshold; 30 | 31 | public boolean findMaxima = DifferenceOfGaussianGUI.defaultFindMax; 32 | public boolean findMinima = DifferenceOfGaussianGUI.defaultFindMin; 33 | } 34 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/explorer/popup/ExplorerWindowSetable.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.explorer.popup; 24 | 25 | import javax.swing.JComponent; 26 | 27 | import net.preibisch.mvrecon.fiji.spimdata.explorer.ExplorerWindow; 28 | 29 | import mpicbg.spim.data.generic.AbstractSpimData; 30 | import mpicbg.spim.data.generic.sequence.AbstractSequenceDescription; 31 | 32 | public interface ExplorerWindowSetable 33 | { 34 | public JComponent setExplorerWindow( final ExplorerWindow< ? > panel ); 35 | } 36 | // AbstractSpimData< ? extends AbstractSequenceDescription< ?, ?, ? > > 37 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/pointcloud/pointdescriptor/exception/NoSuitablePointsException.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.pointcloud.pointdescriptor.exception; 24 | 25 | public class NoSuitablePointsException extends Exception 26 | { 27 | /** 28 | * 29 | */ 30 | private static final long serialVersionUID = 1L; 31 | 32 | public NoSuitablePointsException( final String message ) { super( message ); } 33 | 34 | public NoSuitablePointsException( final Object obj, final String message ) { super( obj.getClass().getCanonicalName() + ": " + message ); } 35 | 36 | public NoSuitablePointsException() { super(); } 37 | 38 | } 39 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/fusion/transformed/nonrigid/IPL.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.fusion.transformed.nonrigid; 24 | 25 | import java.util.Map; 26 | 27 | import net.preibisch.mvrecon.fiji.spimdata.interestpoints.InterestPoint; 28 | 29 | public class IPL 30 | { 31 | final String label; 32 | final Map< Integer, InterestPoint > map; 33 | 34 | public IPL( final String label, final Map< Integer, InterestPoint > map ) 35 | { 36 | this.label = label; 37 | this.map = map; 38 | } 39 | 40 | public String getLabel() { return label; } 41 | public Map< Integer, InterestPoint > getInterestPointMap() { return map; } 42 | } 43 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/legacy/registration/detection/Detection.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.legacy.registration.detection; 24 | 25 | public class Detection extends AbstractDetection 26 | { 27 | /** 28 | * 29 | */ 30 | private static final long serialVersionUID = 1L; 31 | 32 | public Detection( final int id, final double[] location ) 33 | { 34 | super(id, location); 35 | } 36 | 37 | public Detection( final int id, final double[] location, final double weight ) 38 | { 39 | super(id, location, weight); 40 | } 41 | 42 | @Override 43 | public Detection[] createArray( final int arg0 ) { return new Detection[ arg0 ]; } 44 | 45 | } 46 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/fusion/ImagePortion.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.fusion; 24 | 25 | public class ImagePortion 26 | { 27 | public ImagePortion( final long startPosition, long loopSize ) 28 | { 29 | this.startPosition = startPosition; 30 | this.loopSize = loopSize; 31 | } 32 | 33 | public long getStartPosition() { return startPosition; } 34 | public long getLoopSize() { return loopSize; } 35 | 36 | protected long startPosition; 37 | protected long loopSize; 38 | 39 | @Override 40 | public String toString() { return "Portion [" + getStartPosition() + " ... " + ( getStartPosition() + getLoopSize() - 1 ) + " ]"; } 41 | } 42 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/global/linkremoval/LinkRemovalStrategy.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.global.linkremoval; 24 | 25 | import java.util.HashMap; 26 | 27 | import mpicbg.models.Tile; 28 | import mpicbg.models.TileConfiguration; 29 | import mpicbg.spim.data.sequence.ViewId; 30 | import net.imglib2.util.Pair; 31 | import net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation.grouping.Group; 32 | 33 | public interface LinkRemovalStrategy 34 | { 35 | public Pair< Group< ViewId >, Group< ViewId > > removeLink( TileConfiguration tc, HashMap< ViewId, ? extends Tile< ? > > map ); 36 | } 37 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/interestpoints/XmlKeysInterestPoints.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.interestpoints; 24 | 25 | public class XmlKeysInterestPoints 26 | { 27 | public static final String VIEWINTERESTPOINTS_TAG = "ViewInterestPoints"; 28 | public static final String VIEWINTERESTPOINTSFILE_TAG = "ViewInterestPointsFile"; 29 | public static final String VIEWINTERESTPOINTS_TIMEPOINT_ATTRIBUTE_NAME = "timepoint"; 30 | public static final String VIEWINTERESTPOINTS_SETUP_ATTRIBUTE_NAME = "setup"; 31 | public static final String VIEWINTERESTPOINTS_LABEL_ATTRIBUTE_NAME = "label"; 32 | public static final String VIEWINTERESTPOINTS_PARAMETERS_ATTRIBUTE_NAME = "params"; 33 | } 34 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/legacy/registration/detection/descriptor/CorrespondenceExtraction.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.legacy.registration.detection.descriptor; 24 | 25 | import java.util.ArrayList; 26 | 27 | import net.preibisch.legacy.mpicbg.PointMatchGeneric; 28 | import net.preibisch.legacy.registration.detection.AbstractDetection; 29 | 30 | public interface CorrespondenceExtraction > 31 | { 32 | public ArrayList> extractCorrespondenceCandidates( 33 | final ArrayList< T > pointListA, 34 | final ArrayList< T > pointListB, 35 | final double differenceThreshold, 36 | final double ratioOfDistance, 37 | final boolean useAssociatedBeads ); 38 | } 39 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/pairwise/constellation/range/TimepointRange.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation.range; 24 | 25 | import mpicbg.spim.data.sequence.ViewId; 26 | 27 | public class TimepointRange< V extends ViewId > implements RangeComparator< V > 28 | { 29 | final int maxDistance; 30 | 31 | public TimepointRange( final int maxDistance ) { this.maxDistance = maxDistance; } 32 | 33 | @Override 34 | public boolean inRange( final V view1, final V view2 ) 35 | { 36 | if ( Math.abs( view2.getTimePointId() - view1.getTimePointId() ) <= maxDistance ) 37 | return true; 38 | else 39 | return false; 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/imgloaders/flatfield/FlatfieldCorrectionWrappedImgLoader.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.imgloaders.flatfield; 24 | 25 | import java.io.File; 26 | 27 | import mpicbg.spim.data.sequence.ImgLoader; 28 | import mpicbg.spim.data.sequence.ViewId; 29 | 30 | public interface FlatfieldCorrectionWrappedImgLoader extends ImgLoader 31 | { 32 | public IL getWrappedImgLoder(); 33 | public void setActive(boolean active); 34 | public boolean isActive(); 35 | public void setCached(boolean cached); 36 | public boolean isCached(); 37 | public void setBrightImage(ViewId vId, File imgFile); 38 | public void setDarkImage(ViewId vId, File imgFile); 39 | } 40 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/plugin/interestpointdetection/interactive/FinishedButtonListener.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.plugin.interestpointdetection.interactive; 24 | 25 | import java.awt.event.ActionEvent; 26 | import java.awt.event.ActionListener; 27 | 28 | public class FinishedButtonListener implements ActionListener { 29 | final InteractiveDoG parent; 30 | final boolean cancel; 31 | 32 | public FinishedButtonListener( 33 | final InteractiveDoG parent, 34 | final boolean cancel) { 35 | this.parent = parent; 36 | this.cancel = cancel; 37 | } 38 | 39 | @Override 40 | public void actionPerformed(final ActionEvent arg0) { 41 | parent.wasCanceled = cancel; 42 | parent.dispose(); 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/legacy/registration/threshold/ComponentProperties.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.legacy.registration.threshold; 24 | 25 | import net.preibisch.mvrecon.vecmath.Point3d; 26 | 27 | public class ComponentProperties 28 | { 29 | // the label this component has 30 | int label; 31 | 32 | // size in pixels 33 | public int size; 34 | 35 | // dimension in pixels 36 | public int minX = Integer.MAX_VALUE; 37 | public int maxX = Integer.MIN_VALUE; 38 | public int minY = Integer.MAX_VALUE; 39 | public int maxY = Integer.MIN_VALUE; 40 | public int minZ = Integer.MAX_VALUE; 41 | public int maxZ = Integer.MIN_VALUE; 42 | public int sizeX, sizeY, sizeZ; 43 | 44 | // center of mass 45 | public Point3d center; 46 | } 47 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/explorer/SelectedViewDescriptionListener.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.explorer; 24 | 25 | import java.util.List; 26 | 27 | import mpicbg.spim.data.generic.AbstractSpimData; 28 | import mpicbg.spim.data.generic.sequence.BasicViewDescription; 29 | 30 | public interface SelectedViewDescriptionListener< AS extends AbstractSpimData< ? > > 31 | { 32 | //public void firstSelectedViewDescriptions( List< BasicViewDescription< ? extends BasicViewSetup > > viewDescriptions ); 33 | public void selectedViewDescriptions( List< List< BasicViewDescription< ? > > > viewDescriptions ); 34 | public void updateContent( final AS data ); 35 | public void save(); 36 | public void quit(); 37 | } 38 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/imgloaders/flatfield/XmlIoFlatfieldCorrectedWrappedImgLoaderMR.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.imgloaders.flatfield; 24 | 25 | import mpicbg.spim.data.generic.sequence.ImgLoaderIo; 26 | 27 | /** 28 | * Dummy class so we can use XmlIoFlatfieldCorrectedWrappedImgLoader for both 29 | * multiresolution and non-multiresolution ImgLoaders with flatfield correction 30 | * 31 | * @author david 32 | * 33 | */ 34 | 35 | @ImgLoaderIo(format = "spimreconstruction.wrapped.flatfield.multiresolution", type = MultiResolutionFlatfieldCorrectionWrappedImgLoader.class) 36 | public class XmlIoFlatfieldCorrectedWrappedImgLoaderMR extends XmlIoFlatfieldCorrectedWrappedImgLoader 37 | { 38 | } 39 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/pairwise/methods/centerofmass/CenterOfMassParameters.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.pairwise.methods.centerofmass; 24 | 25 | /** 26 | * Center of Mass (Avg/Median) implementation 27 | * 28 | * @author Stephan Preibisch (stephan.preibisch@gmx.de) 29 | * 30 | */ 31 | public class CenterOfMassParameters 32 | { 33 | final static String[] centerChoice = new String[]{ "Average", "Median" }; 34 | public static int defaultCenterChoice = 0; 35 | protected int centerType = 0; 36 | 37 | public CenterOfMassParameters( final int centerType ) { this.centerType = centerType; } 38 | 39 | public int getCenterType() { return centerType; } 40 | } 41 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/imgloaders/AbstractImgFactoryImgLoader.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.imgloaders; 24 | 25 | import net.imglib2.img.ImgFactory; 26 | import net.imglib2.img.cell.CellImgFactory; 27 | import net.imglib2.type.NativeType; 28 | import net.imglib2.type.numeric.real.FloatType; 29 | 30 | public abstract class AbstractImgFactoryImgLoader extends AbstractImgLoader 31 | { 32 | protected ImgFactory< ? extends NativeType< ? > > imgFactory1 = new CellImgFactory<>( new FloatType() ); 33 | 34 | public ImgFactory< ? extends NativeType< ? > > getImgFactory() { return imgFactory1; } 35 | public void setImgFactory( final ImgFactory< ? extends NativeType< ? > > imgFactory ) { this.imgFactory1 = imgFactory; } 36 | } 37 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/pairwise/LinkedInterestPoint.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.pairwise; 24 | 25 | import net.imglib2.util.Util; 26 | import net.preibisch.mvrecon.fiji.spimdata.interestpoints.InterestPoint; 27 | 28 | public class LinkedInterestPoint< P > extends InterestPoint 29 | { 30 | private static final long serialVersionUID = 1L; 31 | 32 | final P link; 33 | 34 | public LinkedInterestPoint( final int id, final double[] l, final P link ) 35 | { 36 | super( id, l.clone() ); 37 | this.link = link; 38 | } 39 | 40 | public P getLinkedObject() { return link; } 41 | 42 | public String toString() { return "LinkedInterestPoint " + Util.printCoordinates( l ); } 43 | } 44 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/pointcloud/pointdescriptor/similarity/LinearDistance.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.pointcloud.pointdescriptor.similarity; 24 | 25 | import java.util.ArrayList; 26 | 27 | import mpicbg.models.Point; 28 | import mpicbg.models.PointMatch; 29 | 30 | public class LinearDistance implements SimilarityMeasure 31 | { 32 | @Override 33 | public double getSimilarity( final ArrayList matches ) 34 | { 35 | final int numDimensions = matches.get( 0 ).getP1().getL().length; 36 | 37 | double difference = 0; 38 | 39 | for ( final PointMatch match : matches ) 40 | difference += Point.distance( match.getP1(), match.getP2() ); 41 | 42 | return difference / (double)numDimensions; 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/pointcloud/pointdescriptor/similarity/SquareDistance.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.pointcloud.pointdescriptor.similarity; 24 | 25 | import java.util.ArrayList; 26 | 27 | import mpicbg.models.Point; 28 | import mpicbg.models.PointMatch; 29 | 30 | public class SquareDistance implements SimilarityMeasure 31 | { 32 | @Override 33 | public double getSimilarity( final ArrayList matches ) 34 | { 35 | final int numDimensions = matches.get( 0 ).getP1().getL().length; 36 | 37 | double difference = 0; 38 | 39 | for ( final PointMatch match : matches ) 40 | difference += Point.squareDistance( match.getP1(), match.getP2() ); 41 | 42 | return difference / (double)numDimensions; 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/boundingbox/BoundingBoxes.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.boundingbox; 24 | 25 | import java.util.ArrayList; 26 | import java.util.Collection; 27 | import java.util.List; 28 | 29 | public class BoundingBoxes 30 | { 31 | private List< BoundingBox > boundingBoxes; 32 | 33 | public BoundingBoxes() 34 | { 35 | this.boundingBoxes = new ArrayList< BoundingBox >(); 36 | } 37 | 38 | public BoundingBoxes( final Collection< BoundingBox > boundingBoxes ) 39 | { 40 | this(); 41 | this.boundingBoxes.addAll( boundingBoxes ); 42 | } 43 | 44 | public List< BoundingBox > getBoundingBoxes() { return boundingBoxes; } 45 | public void addBoundingBox( final BoundingBox box ) { this.boundingBoxes.add( box ); } 46 | } 47 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/imgloaders/Calibration.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.imgloaders; 24 | 25 | public class Calibration 26 | { 27 | final int w, h, d; 28 | final double calX, calY, calZ; 29 | 30 | public Calibration( final int w, final int h, final int d, final double calX, final double calY, final double calZ ) 31 | { 32 | this.w = w; 33 | this.h = h; 34 | this.d = d; 35 | this.calX = calX; 36 | this.calY = calY; 37 | this.calZ = calZ; 38 | } 39 | 40 | public double getCalX() { return calX; } 41 | public double getCalY() { return calY; } 42 | public double getCalZ() { return calZ; } 43 | public int getWidth() { return w; } 44 | public int getHeight() { return h; } 45 | public int getDepth() { return d; } 46 | } 47 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/global/convergence/IterativeConvergenceStrategy.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.global.convergence; 24 | 25 | import mpicbg.models.TileConfiguration; 26 | 27 | public abstract class IterativeConvergenceStrategy extends ConvergenceStrategy 28 | { 29 | public IterativeConvergenceStrategy( 30 | final double maxAllowedError, 31 | final int maxIterations, 32 | final int maxPlateauwidth ) 33 | { 34 | super( maxAllowedError, maxIterations, maxPlateauwidth ); 35 | } 36 | 37 | public IterativeConvergenceStrategy( final double maxAllowedError ) 38 | { 39 | super( maxAllowedError ); 40 | } 41 | 42 | public abstract boolean isConverged( final TileConfiguration tc ); 43 | } 44 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/pointcloud/icp/PointMatchIdentification.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.pointcloud.icp; 24 | 25 | 26 | import java.util.List; 27 | 28 | import net.imglib2.RealLocalizable; 29 | import net.preibisch.legacy.mpicbg.PointMatchGeneric; 30 | import net.preibisch.mvrecon.process.interestpointregistration.pairwise.LinkedInterestPoint; 31 | import net.preibisch.mvrecon.process.pointcloud.pointdescriptor.exception.NoSuitablePointsException; 32 | 33 | public interface PointMatchIdentification < P extends RealLocalizable > 34 | { 35 | public List< PointMatchGeneric< LinkedInterestPoint< P > > > assignPointMatches( final List< LinkedInterestPoint< P > > target, final List< LinkedInterestPoint< P > > reference ) throws NoSuitablePointsException; 36 | } 37 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/fusion/transformed/nonrigid/SimpleReferenceIP.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.fusion.transformed.nonrigid; 24 | 25 | public class SimpleReferenceIP implements NonrigidIP 26 | { 27 | final double[] l, w; 28 | double[] targetW; 29 | 30 | public SimpleReferenceIP( final double[] l, final double[] w, final double[] targetW ) 31 | { 32 | this.l = l; 33 | this.w = w; 34 | this.targetW = targetW; 35 | } 36 | 37 | public SimpleReferenceIP( final double[] l, final double[] w ) 38 | { 39 | this( l, w, w ); 40 | } 41 | 42 | public void setTargetW( final double[] targetW ) { this.targetW = targetW; } 43 | public double[] getTargetW() { return targetW; } 44 | public double[] getL() { return l; } 45 | public double[] getW() { return w; } 46 | } 47 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/pointcloud/pointdescriptor/LinkedPoint.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.pointcloud.pointdescriptor; 24 | 25 | import mpicbg.models.Point; 26 | import net.imglib2.util.Util; 27 | 28 | public class LinkedPoint< P > extends Point 29 | { 30 | private static final long serialVersionUID = 1L; 31 | 32 | final P link; 33 | 34 | public LinkedPoint( final double[] l, final P link ) 35 | { 36 | super( l.clone() ); 37 | this.link = link; 38 | } 39 | 40 | public LinkedPoint( final double[] l, final double[] w, final P link ) 41 | { 42 | super( l.clone(), w.clone() ); 43 | this.link = link; 44 | } 45 | 46 | public P getLinkedObject() { return link; } 47 | 48 | public String toString() { return "LinkedPoint " + Util.printCoordinates( l ); } 49 | } 50 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/stitchingresults/PairwiseLinkImpl.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.stitchingresults; 24 | 25 | import java.util.Set; 26 | 27 | import mpicbg.spim.data.sequence.ViewId; 28 | import net.imglib2.util.Pair; 29 | import net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation.grouping.Group; 30 | 31 | public class PairwiseLinkImpl implements PairwiseLinkInterface 32 | { 33 | final Set< Pair< Group< ViewId >, Group< ViewId > > > results; 34 | 35 | public PairwiseLinkImpl( final Set< Pair< Group< ViewId >, Group< ViewId > > > results ) 36 | { 37 | this.results = results; 38 | } 39 | 40 | @Override 41 | public Set< Pair< Group< ViewId >, Group< ViewId > > > getPairwiseLinks() 42 | { 43 | return results; 44 | } 45 | 46 | } 47 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/explorer/popup/LabelPopUp.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.explorer.popup; 24 | 25 | import java.awt.Color; 26 | import java.awt.Font; 27 | 28 | import javax.swing.JLabel; 29 | 30 | import net.preibisch.mvrecon.fiji.spimdata.explorer.ExplorerWindow; 31 | 32 | public class LabelPopUp extends JLabel implements ExplorerWindowSetable 33 | { 34 | private static final long serialVersionUID = 5234649267634013390L; 35 | 36 | public LabelPopUp( final String text ) 37 | { 38 | super( text ); 39 | this.setFont( new Font( Font.SANS_SERIF, Font.ITALIC, 11 ) ); 40 | this.setForeground( new Color( 128, 128, 128 )); 41 | } 42 | 43 | @Override 44 | public JLabel setExplorerWindow( final ExplorerWindow< ? > panel ) 45 | { 46 | return this; 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/pointspreadfunctions/PointSpreadFunctions.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.pointspreadfunctions; 24 | 25 | import java.util.HashMap; 26 | 27 | import mpicbg.spim.data.sequence.ViewId; 28 | 29 | public class PointSpreadFunctions 30 | { 31 | private HashMap< ViewId, PointSpreadFunction > psfs; 32 | 33 | public PointSpreadFunctions() 34 | { 35 | this.psfs = new HashMap<>(); 36 | } 37 | 38 | public PointSpreadFunctions( final HashMap< ViewId, PointSpreadFunction > psfs ) 39 | { 40 | this(); 41 | this.psfs.putAll( psfs ); 42 | } 43 | 44 | public HashMap< ViewId, PointSpreadFunction > getPointSpreadFunctions() { return psfs; } 45 | public void addPSF( final ViewId viewId, final PointSpreadFunction img ) { this.psfs.put( viewId, img ); } 46 | } 47 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/stitchingresults/VectorUtil.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.stitchingresults; 24 | 25 | public class VectorUtil 26 | { 27 | public static double getVectorLength(double[] vec){ 28 | double res = 0; 29 | for (int i = 0; i. 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.fusion.transformed.nonrigid; 24 | 25 | import java.util.ArrayList; 26 | 27 | public class NonRigidParameters 28 | { 29 | protected double alpha = 1.0; 30 | protected long controlPointDistance = 10; 31 | protected boolean showDistanceMap = false; 32 | protected boolean nonRigidAcrossTime = false; 33 | protected ArrayList< String > labelList = new ArrayList<>(); 34 | 35 | public double getAlpha() { return alpha; } 36 | public long getControlPointDistance() { return controlPointDistance; } 37 | public boolean showDistanceMap() { return showDistanceMap; } 38 | public boolean nonRigidAcrossTime() { return nonRigidAcrossTime; } 39 | public ArrayList< String > getLabels() { return labelList; } 40 | } 41 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/plugin/resave/ProgressWriterIJ.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.plugin.resave; 24 | 25 | import bdv.export.ProgressWriter; 26 | import ij.IJ; 27 | import ij.io.LogStream; 28 | 29 | import java.io.PrintStream; 30 | 31 | public class ProgressWriterIJ implements ProgressWriter 32 | { 33 | protected final PrintStream out; 34 | 35 | protected final PrintStream err; 36 | 37 | public ProgressWriterIJ() 38 | { 39 | out = new LogStream(); 40 | err = new LogStream(); 41 | } 42 | 43 | @Override 44 | public PrintStream out() 45 | { 46 | return out; 47 | } 48 | 49 | @Override 50 | public PrintStream err() 51 | { 52 | return err; 53 | } 54 | 55 | @Override 56 | public void setProgress( final double completionRatio ) 57 | { 58 | IJ.showProgress( completionRatio ); 59 | } 60 | } 61 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/deconvolution/init/PsiInitFromFileFactory.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.deconvolution.init; 24 | 25 | import java.io.File; 26 | 27 | public class PsiInitFromFileFactory implements PsiInitFactory 28 | { 29 | final File psiStartFile; 30 | final boolean precise; 31 | 32 | /** 33 | * @param psiStartFile - what is used as init for the deconvolved image (loaded from disc) 34 | * @param precise - if avg and max[] of input are computed approximately or precise 35 | */ 36 | public PsiInitFromFileFactory( final File psiStartFile, final boolean precise ) 37 | { 38 | this.psiStartFile = psiStartFile; 39 | this.precise = precise; 40 | } 41 | 42 | @Override 43 | public PsiInitFromFile createPsiInitialization() 44 | { 45 | return new PsiInitFromFile( psiStartFile, precise ); 46 | } 47 | } 48 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/imgloaders/CalibratedImg.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.imgloaders; 24 | 25 | import net.imglib2.img.Img; 26 | 27 | public class CalibratedImg< T > 28 | { 29 | final Img< T > image; 30 | final double calX, calY, calZ; 31 | 32 | public CalibratedImg( final Img< T > image ) 33 | { 34 | this.image = image; 35 | this.calX = this.calY = this.calZ = -1; 36 | } 37 | 38 | public CalibratedImg( final Img< T > image, final double calX, final double calY, final double calZ ) 39 | { 40 | this.image = image; 41 | this.calX = calX; 42 | this.calY = calY; 43 | this.calZ = calZ; 44 | } 45 | 46 | public Img< T > getImg(){ return image; } 47 | public double getCalX() { return calX; } 48 | public double getCalY() { return calY; } 49 | public double getCalZ() { return calZ; } 50 | } 51 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/imgloaders/StackImgLoaderIJ.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.imgloaders; 24 | 25 | import java.io.File; 26 | 27 | import mpicbg.spim.data.generic.sequence.AbstractSequenceDescription; 28 | import net.imglib2.img.ImgFactory; 29 | import net.imglib2.type.NativeType; 30 | 31 | public class StackImgLoaderIJ extends StackImgLoader< LegacyStackImgLoaderIJ > 32 | { 33 | public StackImgLoaderIJ( 34 | final File path, final String fileNamePattern, 35 | final int layoutTP, final int layoutChannels, final int layoutIllum, final int layoutAngles, final int layoutTiles, 36 | final AbstractSequenceDescription< ?, ?, ? > sequenceDescription ) 37 | { 38 | super( new LegacyStackImgLoaderIJ( path, fileNamePattern, layoutTP, layoutChannels, layoutIllum, layoutAngles, layoutTiles, sequenceDescription ) ); 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/fusion/intensity/mpicbg/Point1D.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.fusion.intensity.mpicbg; 24 | 25 | import mpicbg.models.CoordinateTransform; 26 | import mpicbg.models.Point; 27 | 28 | /** 29 | * A 1D point. This is used in the intensity matching algorithm and adds an optimized method for applying a 30 | * transformation a 1D point. The method doesn't overwrite {@link Point#apply(CoordinateTransform)} since this method 31 | * is marked as final in the superclass. 32 | */ 33 | public class Point1D extends Point { 34 | public Point1D(final double l, final double w) { 35 | super(new double[] { l }, new double[] { w }); 36 | } 37 | 38 | public Point1D(final double l) { 39 | this(l, l); 40 | } 41 | 42 | public void applyFast(final CoordinateTransform t) { 43 | w[0] = l[0]; 44 | t.applyInPlace(w); 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/imgloaders/StackImgLoaderLOCI.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.imgloaders; 24 | 25 | import java.io.File; 26 | 27 | import mpicbg.spim.data.generic.sequence.AbstractSequenceDescription; 28 | import net.imglib2.img.ImgFactory; 29 | import net.imglib2.type.NativeType; 30 | 31 | public class StackImgLoaderLOCI extends StackImgLoader< LegacyStackImgLoaderLOCI > 32 | { 33 | public StackImgLoaderLOCI( 34 | final File path, final String fileNamePattern, 35 | final int layoutTP, final int layoutChannels, final int layoutIllum, final int layoutAngles, final int layoutTiles, 36 | final AbstractSequenceDescription< ?, ?, ? > sequenceDescription ) 37 | { 38 | super( new LegacyStackImgLoaderLOCI( path, fileNamePattern, layoutTP, layoutChannels, layoutIllum, layoutAngles, layoutTiles, sequenceDescription ) ); 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/pointcloud/pointdescriptor/similarity/ManhattanDistance.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.pointcloud.pointdescriptor.similarity; 24 | 25 | import java.util.ArrayList; 26 | 27 | import mpicbg.models.PointMatch; 28 | 29 | public class ManhattanDistance implements SimilarityMeasure 30 | { 31 | @Override 32 | public double getSimilarity( final ArrayList matches ) 33 | { 34 | final int numDimensions = matches.get( 0 ).getP1().getL().length; 35 | 36 | double difference = 0; 37 | 38 | for ( final PointMatch match : matches ) 39 | { 40 | final double[] t1 = match.getP2().getW(); 41 | final double[] t2 = match.getP1().getW(); 42 | 43 | for ( int d = 0; d < numDimensions; ++d ) 44 | difference += Math.abs( t1[ d ] - t2[ d ] ); 45 | } 46 | 47 | return difference / (double)numDimensions; 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/stitchingresults/XmlKeysStitchingResults.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.stitchingresults; 24 | 25 | public class XmlKeysStitchingResults 26 | { 27 | public static final String STITCHINGRESULTS_TAG = "StitchingResults"; 28 | public static final String STITCHINGRESULT_PW_TAG = "PairwiseResult"; 29 | 30 | public static final String STITCHING_VS_A_TAG = "view_setup_a"; 31 | public static final String STITCHING_VS_B_TAG = "view_setup_b"; 32 | public static final String STITCHING_TP_A_TAG = "tp_a"; 33 | public static final String STITCHING_TP_B_TAG = "tp_b"; 34 | public static final String STICHING_SHIFT_TAG = "shift"; 35 | public static final String STICHING_CORRELATION_TAG = "correlation"; 36 | public static final String STITCHING_HASH_TAG = "hash"; 37 | public static final String STICHING_BBOX_TAG = "overlap_boundingbox"; 38 | 39 | } 40 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/fusion/intensity/UnbleachFunction.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.fusion.intensity; 24 | 25 | /** 26 | * Compute the corrected intensity when {@code intensity} was observed in a 27 | * pixel that has been bleached by previously being imaged. 28 | */ 29 | @FunctionalInterface 30 | public interface UnbleachFunction { 31 | 32 | /** 33 | * Compute the corrected intensity when {@code intensity} was observed 34 | * in a pixel that has been {@code nBleachIterations} times imaged 35 | * already. (When this is the first time the pixel is imaged, {@code 36 | * nBleachIterations==0}. 37 | * 38 | * @param intensity 39 | * observed intensity 40 | * @param nBleachIterations 41 | * number of times the pixel was bleached 42 | * 43 | * @return corrected intensity 44 | */ 45 | double unbleach(double intensity, int nBleachIterations); 46 | } 47 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/explorer/bdv/ToggleDialogActionBrightness.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.explorer.bdv; 24 | 25 | import java.awt.event.ActionEvent; 26 | 27 | import bdv.tools.ToggleDialogAction; 28 | 29 | public class ToggleDialogActionBrightness extends ToggleDialogAction 30 | { 31 | final ScrollableBrightnessDialog dialog; 32 | 33 | public ToggleDialogActionBrightness( final String name, final ScrollableBrightnessDialog dialog ) 34 | { 35 | super( name, dialog ); 36 | 37 | this.dialog = dialog; 38 | } 39 | 40 | @Override 41 | public void actionPerformed( final ActionEvent arg0 ) 42 | { 43 | updatePanels(); 44 | super.actionPerformed( arg0 ); 45 | } 46 | 47 | public void updatePanels() 48 | { 49 | if ( this.dialog.isVisible() ) 50 | this.dialog.updatePanels(); 51 | } 52 | 53 | private static final long serialVersionUID = 1L; 54 | } 55 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/deconvolution/init/PsiInit.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.deconvolution.init; 24 | 25 | import java.util.List; 26 | import java.util.concurrent.ExecutorService; 27 | 28 | import net.imglib2.img.Img; 29 | import net.imglib2.type.numeric.real.FloatType; 30 | import net.preibisch.mvrecon.process.deconvolution.DeconView; 31 | 32 | public interface PsiInit 33 | { 34 | public enum PsiInitType { FUSED_BLURRED, AVG, APPROX_AVG, FROM_FILE, FROM_RAI }; 35 | 36 | public boolean runInitialization( final Img< FloatType > psi, final List< DeconView > views, final ExecutorService service ); 37 | 38 | /** 39 | * @return the average in the overlapping area 40 | */ 41 | public double getAvg(); 42 | 43 | /** 44 | * @return the maximal intensities (maybe approximated) of the views, in the same order as the list of DeconView 45 | */ 46 | public float[] getMax(); 47 | } 48 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/plugin/interestpointdetection/interactive/ImagePlusListener.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.plugin.interestpointdetection.interactive; 24 | 25 | import fiji.tool.SliceListener; 26 | import ij.ImagePlus; 27 | import net.preibisch.mvrecon.fiji.plugin.interestpointdetection.interactive.InteractiveDoG.ValueChange; 28 | 29 | public class ImagePlusListener implements SliceListener 30 | { 31 | final InteractiveDoG parent; 32 | 33 | public ImagePlusListener( final InteractiveDoG parent ) 34 | { 35 | this.parent = parent; 36 | } 37 | 38 | @Override 39 | public void sliceChanged(ImagePlus arg0) { 40 | if (parent.isStarted) { 41 | // System.out.println("Slice changed!"); 42 | while (parent.isComputing) { 43 | try { 44 | Thread.sleep( 10 ); 45 | } catch (InterruptedException e) {} 46 | } 47 | parent.updatePreview(ValueChange.SLICE); 48 | } 49 | } 50 | } 51 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/intensityadjust/IntensityAdjustments.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.intensityadjust; 24 | 25 | import java.util.HashMap; 26 | 27 | import mpicbg.models.AffineModel1D; 28 | import mpicbg.spim.data.sequence.ViewId; 29 | 30 | public class IntensityAdjustments 31 | { 32 | private HashMap< ViewId, AffineModel1D > intensityAdjustment; 33 | 34 | public IntensityAdjustments() 35 | { 36 | this.intensityAdjustment = new HashMap<>(); 37 | } 38 | 39 | public IntensityAdjustments( final HashMap< ViewId, AffineModel1D > models ) 40 | { 41 | this(); 42 | this.intensityAdjustment.putAll( models ); 43 | } 44 | 45 | public HashMap< ViewId, AffineModel1D > getIntensityAdjustments() { return intensityAdjustment; } 46 | public void addIntensityAdjustments( final ViewId viewId, final AffineModel1D model ) { this.intensityAdjustment.put( viewId, model ); } 47 | } 48 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/deconvolution/init/PsiInitFromRAIFactory.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.deconvolution.init; 24 | 25 | import net.imglib2.RandomAccessibleInterval; 26 | import net.imglib2.type.numeric.real.FloatType; 27 | 28 | public class PsiInitFromRAIFactory implements PsiInitFactory 29 | { 30 | final RandomAccessibleInterval< FloatType > psiRAI; 31 | final boolean precise; 32 | 33 | /** 34 | * @param psiRAI - what is used as init for the deconvolved image 35 | * @param precise - if avg and max[] of input are computed approximately or precise 36 | */ 37 | public PsiInitFromRAIFactory( final RandomAccessibleInterval< FloatType > psiRAI, final boolean precise ) 38 | { 39 | this.psiRAI = psiRAI; 40 | this.precise = precise; 41 | } 42 | 43 | @Override 44 | public PsiInitFromRAI createPsiInitialization() 45 | { 46 | return new PsiInitFromRAI( psiRAI, precise ); 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/global/convergence/ConvergenceStrategy.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.global.convergence; 24 | 25 | public class ConvergenceStrategy 26 | { 27 | double maxAllowedError; 28 | int maxIterations; 29 | int maxPlateauwidth; 30 | 31 | public ConvergenceStrategy( final double maxAllowedError ) 32 | { 33 | this( maxAllowedError, 10000, 200 ); 34 | } 35 | 36 | public ConvergenceStrategy( 37 | final double maxAllowedError, 38 | final int maxIterations, 39 | final int maxPlateauwidth ) 40 | { 41 | this.maxAllowedError = maxAllowedError; 42 | this.maxIterations = maxIterations; 43 | this.maxPlateauwidth = maxPlateauwidth; 44 | } 45 | 46 | public double getMaxError() { return maxAllowedError; } 47 | public int getMaxIterations() { return maxIterations; } 48 | public int getMaxPlateauWidth() { return maxPlateauwidth; } 49 | } 50 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/explorer/FilteredAndGroupedExplorer.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.explorer; 24 | 25 | import java.util.ArrayList; 26 | 27 | import javax.swing.JFrame; 28 | 29 | import net.preibisch.mvrecon.fiji.spimdata.SpimData2; 30 | 31 | public abstract class FilteredAndGroupedExplorer 32 | { 33 | 34 | protected JFrame frame; 35 | protected FilteredAndGroupedExplorerPanel< AS > panel; 36 | 37 | 38 | public AS getSpimData() 39 | { return panel.getSpimData(); } 40 | 41 | public FilteredAndGroupedExplorerPanel< AS > getPanel() 42 | { return panel; } 43 | 44 | public JFrame getFrame() 45 | { return frame; } 46 | 47 | public void addListener(final SelectedViewDescriptionListener< AS > listener) 48 | { panel.addListener( listener ); } 49 | 50 | public ArrayList< SelectedViewDescriptionListener< AS > > getListeners() 51 | { return panel.getListeners(); } 52 | 53 | } 54 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/pairwise/constellation/overlap/AllAgainstAllOverlap.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation.overlap; 24 | 25 | import net.imglib2.FinalRealInterval; 26 | import net.imglib2.RealInterval; 27 | 28 | public class AllAgainstAllOverlap< V > implements OverlapDetection< V > 29 | { 30 | final int n; 31 | 32 | public AllAgainstAllOverlap( final int numDimensions ){ this.n = numDimensions; } 33 | 34 | @Override 35 | public boolean overlaps( final V view1, final V view2 ) { return true; } 36 | 37 | @Override 38 | public RealInterval getOverlapInterval( final V view1, final V view2 ) 39 | { 40 | final double[] min = new double[ n ]; 41 | final double[] max = new double[ n ]; 42 | 43 | for ( int d = 0; d < n; ++d ) 44 | { 45 | min[ d ] = 0; 46 | max[ d ] = 1; 47 | } 48 | 49 | return new FinalRealInterval( min, max ); 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /src/test/java/net/preibisch/mvrecon/fiji/spimdata/interestpoints/ExampleDirectLoading.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.interestpoints; 24 | 25 | import java.net.URI; 26 | import java.util.Arrays; 27 | import java.util.Map; 28 | 29 | import mpicbg.spim.data.SpimDataException; 30 | 31 | public class ExampleDirectLoading 32 | { 33 | public static void main( String[] args ) throws SpimDataException 34 | { 35 | int viewSetupId = 1; 36 | 37 | // 38 | // works without the XML, just loads the N5 directly 39 | // 40 | InterestPointsN5 ip = new InterestPointsN5( 41 | URI.create("/nrs/saalfeld/john/for/keller/danio_1_488/dataset-orig-tifs/3/"), 42 | "tpId_0_viewSetupId_" + viewSetupId + "/beads8v2" ); 43 | 44 | Map< Integer, InterestPoint> points = ip.getInterestPointsCopy(); 45 | 46 | for ( final InterestPoint p : points.values() ) 47 | { 48 | System.out.println( p.getId() + " " + Arrays.toString( p.getL() )); 49 | } 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /src/main/java/util/RealViews.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package util; 24 | 25 | import net.imglib2.RealRandomAccessible; 26 | 27 | public class RealViews 28 | { 29 | /** 30 | * Add a dimension to a {@link RealRandomAccessible}. The resulting 31 | * {@link RealRandomAccessible} has samples from the original dimensions 32 | * continuously stacked along the added dimensions. 33 | * 34 | * The additional dimension is the last dimension. For example, an XYZ view 35 | * is created for an XY source. When accessing an XYZ sample in the view, 36 | * the final coordinate is discarded and the source XY sample is accessed. 37 | * 38 | * @param source 39 | * the source 40 | * @param 41 | * the pixel type 42 | * @return stacked view with an additional last dimension 43 | */ 44 | public static < T > RealRandomAccessible< T > addDimension( final RealRandomAccessible< T > source ) 45 | { 46 | return new StackingRealRandomAccessible< >( source, 1 ); 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/imgloaders/XmlIoStackImgLoaderIJ.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.imgloaders; 24 | 25 | import java.io.File; 26 | 27 | import mpicbg.spim.data.generic.sequence.AbstractSequenceDescription; 28 | import mpicbg.spim.data.generic.sequence.ImgLoaderIo; 29 | import net.imglib2.img.ImgFactory; 30 | import net.imglib2.type.NativeType; 31 | 32 | @ImgLoaderIo( format = "spimreconstruction.stack.ij", type = StackImgLoaderIJ.class ) 33 | public class XmlIoStackImgLoaderIJ extends XmlIoStackImgLoader< StackImgLoaderIJ > 34 | { 35 | @Override 36 | protected StackImgLoaderIJ createImgLoader( File path, String fileNamePattern, 37 | int layoutTP, int layoutChannels, int layoutIllum, int layoutAngles, int layoutTiles, 38 | AbstractSequenceDescription< ?, ?, ? > sequenceDescription ) 39 | { 40 | return new StackImgLoaderIJ( path, fileNamePattern, layoutTP, layoutChannels, layoutIllum, layoutAngles, layoutTiles, sequenceDescription ); 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/imgloaders/XmlIoStackImgLoaderLOCI.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.imgloaders; 24 | 25 | import java.io.File; 26 | 27 | import mpicbg.spim.data.generic.sequence.AbstractSequenceDescription; 28 | import mpicbg.spim.data.generic.sequence.ImgLoaderIo; 29 | import net.imglib2.img.ImgFactory; 30 | import net.imglib2.type.NativeType; 31 | 32 | @ImgLoaderIo( format = "spimreconstruction.stack.loci", type = StackImgLoaderLOCI.class ) 33 | public class XmlIoStackImgLoaderLOCI extends XmlIoStackImgLoader< StackImgLoaderLOCI > 34 | { 35 | @Override 36 | protected StackImgLoaderLOCI createImgLoader( File path, String fileNamePattern, 37 | int layoutTP, int layoutChannels, int layoutIllum, int layoutAngles, int layoutTiles, 38 | AbstractSequenceDescription< ?, ?, ? > sequenceDescription ) 39 | { 40 | return new StackImgLoaderLOCI( path, fileNamePattern, layoutTP, layoutChannels, layoutIllum, layoutAngles, layoutTiles, sequenceDescription ); 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/explorer/ExplorerWindow.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.explorer; 24 | 25 | import java.net.URI; 26 | import java.util.List; 27 | 28 | import mpicbg.spim.data.generic.sequence.BasicViewDescription; 29 | import mpicbg.spim.data.sequence.ViewId; 30 | import net.preibisch.mvrecon.fiji.spimdata.SpimData2; 31 | import net.preibisch.mvrecon.fiji.spimdata.explorer.popup.BasicBDVPopup; 32 | 33 | public interface ExplorerWindow< AS extends SpimData2 > 34 | { 35 | public List< BasicViewDescription< ? > > selectedRows(); 36 | public List< ViewId > selectedRowsViewId(); 37 | public AS getSpimData(); 38 | public void updateContent(); 39 | public URI xml(); 40 | public void saveXML(); 41 | 42 | public boolean tilesGrouped(); 43 | public boolean illumsGrouped(); 44 | public boolean channelsGrouped(); 45 | 46 | // BDV-specific 47 | public BasicBDVPopup bdvPopup(); 48 | public boolean colorMode(); 49 | public BasicViewDescription< ? > firstSelectedVD(); 50 | } 51 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/imgloaders/util/BioformatsReaderUtils.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.imgloaders.util; 24 | 25 | import java.util.HashMap; 26 | 27 | import loci.formats.IFormatReader; 28 | import loci.formats.ImageReader; 29 | import loci.formats.in.ZeissCZIReader; 30 | 31 | public class BioformatsReaderUtils { 32 | 33 | static HashMap, BioformatsReaderSetupHook> setupHooks = new HashMap<>(); 34 | static { 35 | setupHooks.put(ZeissCZIReader.class, CZIReaderSetupHook.getInstance()); 36 | } 37 | 38 | public static ImageReader createImageReaderWithSetupHooks() 39 | { 40 | final ImageReader reader = new ImageReader(); 41 | 42 | // go through all specific format readers and run setup if necessary 43 | for(final IFormatReader formatReader : reader.getReaders()) 44 | if (setupHooks.containsKey(formatReader.getClass())) 45 | setupHooks.get(formatReader.getClass()).runSetup(formatReader); 46 | 47 | return reader; 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/fusion/intensity/ViewPairCoefficientMatches.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.fusion.intensity; 24 | 25 | import java.io.Serializable; 26 | import java.util.List; 27 | import mpicbg.spim.data.sequence.ViewId; 28 | 29 | public class ViewPairCoefficientMatches implements Serializable { 30 | 31 | private final ViewId view1; 32 | private final ViewId view2; 33 | private final List coefficientMatches; 34 | 35 | public ViewPairCoefficientMatches( 36 | final ViewId view1, 37 | final ViewId view2, 38 | final List coefficientMatches 39 | ) { 40 | this.view1 = view1; 41 | this.view2 = view2; 42 | this.coefficientMatches = coefficientMatches; 43 | } 44 | 45 | public ViewId view1() { 46 | return view1; 47 | } 48 | 49 | public ViewId view2() { 50 | return view2; 51 | } 52 | 53 | public List coefficientMatches() { 54 | return coefficientMatches; 55 | } 56 | } 57 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/imgloaders/MicroManagerImgLoader.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.imgloaders; 24 | 25 | import java.io.File; 26 | 27 | import mpicbg.spim.data.generic.sequence.AbstractSequenceDescription; 28 | import mpicbg.spim.data.generic.sequence.BasicViewDescription; 29 | import mpicbg.spim.data.generic.sequence.BasicViewSetup; 30 | import mpicbg.spim.data.legacy.LegacyImgLoaderWrapper; 31 | import net.imglib2.type.numeric.integer.UnsignedShortType; 32 | 33 | public class MicroManagerImgLoader extends LegacyImgLoaderWrapper< UnsignedShortType, LegacyMicroManagerImgLoader > 34 | { 35 | public MicroManagerImgLoader( 36 | final File mmFile, 37 | final AbstractSequenceDescription< ?, ?, ? > sequenceDescription ) 38 | { 39 | super( new LegacyMicroManagerImgLoader( mmFile, sequenceDescription ) ); 40 | } 41 | 42 | public File getFile() { return legacyImgLoader.getFile(); } 43 | 44 | @Override 45 | public String toString() { 46 | return legacyImgLoader.toString(); 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/fusion/intensityadjust/IntensityAdjuster.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.fusion.intensityadjust; 24 | 25 | import mpicbg.models.AffineModel1D; 26 | import net.imglib2.converter.Converter; 27 | import net.imglib2.type.numeric.real.FloatType; 28 | 29 | public class IntensityAdjuster implements Converter< FloatType, FloatType > 30 | { 31 | final double m00, m01; 32 | 33 | public IntensityAdjuster( final AffineModel1D intensityTransform ) 34 | { 35 | final double[] m = new double[ 2 ]; 36 | 37 | intensityTransform.getMatrix( m ); 38 | this.m00 = m[ 0 ]; 39 | this.m01 = m[ 1 ]; 40 | } 41 | 42 | @Override 43 | public void convert( final FloatType input, final FloatType output ) 44 | { 45 | // cannot use this because the double[] array l cannot be shared 46 | //this.intensityTransform.applyInPlace( this.l ); 47 | 48 | output.set( (float)apply( input.get() ) ); 49 | } 50 | 51 | final public double apply( final double l ) 52 | { 53 | return l * m00 + m01; 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/legacy/mpicbg/PointMatchGeneric.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.legacy.mpicbg; 24 | 25 | import mpicbg.models.Point; 26 | import mpicbg.models.PointMatch; 27 | 28 | public class PointMatchGeneric

extends PointMatch 29 | { 30 | private static final long serialVersionUID = 1L; 31 | 32 | public PointMatchGeneric( P p1, P p2, double[] weights, double strength ) 33 | { 34 | super( p1, p2, weights, strength ); 35 | } 36 | 37 | public PointMatchGeneric( P p1, P p2, double[] weights ) 38 | { 39 | super( p1, p2, weights ); 40 | } 41 | 42 | public PointMatchGeneric( P p1, P p2, double weight ) 43 | { 44 | super( p1, p2, weight ); 45 | } 46 | 47 | public PointMatchGeneric( P p1, P p2, double weight, double strength ) 48 | { 49 | super( p1, p2, weight, strength ); 50 | } 51 | 52 | public PointMatchGeneric( P p1, P p2 ) 53 | { 54 | super( p1, p2 ); 55 | } 56 | 57 | final public P getPoint1() { return (P)getP1(); } 58 | 59 | final public P getPoint2() { return (P)getP2(); } 60 | 61 | } 62 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/fusion/intensity/mpicbg/PointMatch1D.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.fusion.intensity.mpicbg; 24 | 25 | import mpicbg.models.CoordinateTransform; 26 | import mpicbg.models.PointMatch; 27 | 28 | /** 29 | * A match of two 1D points. This is used in the intensity matching algorithm and adds an optimized method for computing 30 | * the distance of two 1D points. 31 | */ 32 | public class PointMatch1D extends PointMatch { 33 | public PointMatch1D(final Point1D p1, final Point1D p2) { 34 | super(p1, p2); 35 | } 36 | 37 | public PointMatch1D(final Point1D p1, final Point1D p2, final double weight) { 38 | super(p1, p2, weight); 39 | } 40 | 41 | @Override 42 | public void apply(final CoordinateTransform t) { 43 | final Point1D p1 = (Point1D) this.p1; 44 | p1.applyFast(t); 45 | } 46 | 47 | @Override 48 | public double getDistance(){ 49 | final Point1D p1 = (Point1D) this.p1; 50 | final Point1D p2 = (Point1D) this.p2; 51 | return Math.abs(p1.getW()[0] - p2.getW()[0]); 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/pairwise/constellation/AllToAll.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation; 24 | 25 | import java.util.Collection; 26 | import java.util.List; 27 | import java.util.Set; 28 | 29 | import net.imglib2.util.Pair; 30 | import net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation.grouping.Group; 31 | import net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation.range.AllInRange; 32 | 33 | public class AllToAll< V extends Comparable< V > > extends AllToAllRange< V, AllInRange< V > > 34 | { 35 | public AllToAll( 36 | final List< V > views, 37 | final Set< Group< V > > groups ) 38 | { 39 | super( views, groups, new AllInRange<>() ); 40 | } 41 | 42 | public static < V > List< Pair< V, V > > allPairs( 43 | final List< ? extends V > views, 44 | final Collection< ? extends Group< V > > groups ) 45 | { 46 | return AllToAllRange.allPairs( views, groups, new AllInRange<>() ); 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/fusion/transformed/AbstractTransformedImgRandomAccessible.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.fusion.transformed; 24 | 25 | import net.imglib2.Interval; 26 | import net.imglib2.RandomAccessibleInterval; 27 | import net.imglib2.type.numeric.RealType; 28 | import net.imglib2.type.numeric.real.FloatType; 29 | 30 | public abstract class AbstractTransformedImgRandomAccessible< T extends RealType< T > > extends AbstractTransformedIntervalRandomAccessible 31 | { 32 | final protected RandomAccessibleInterval< T > img; 33 | 34 | final protected boolean hasMinValue; 35 | final protected float minValue; 36 | 37 | public AbstractTransformedImgRandomAccessible( 38 | final RandomAccessibleInterval< T > img, // from ImgLoader 39 | final boolean hasMinValue, 40 | final float minValue, 41 | final FloatType outsideValue, 42 | final Interval boundingBox ) 43 | { 44 | super( img, outsideValue, boundingBox ); 45 | 46 | this.img = img; 47 | this.hasMinValue = hasMinValue; 48 | this.minValue = minValue; 49 | } 50 | } 51 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/explorer/SimpleInfoBox.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.explorer; 24 | 25 | import java.awt.BorderLayout; 26 | import java.awt.Dimension; 27 | 28 | import javax.swing.JFrame; 29 | import javax.swing.JPanel; 30 | import javax.swing.JScrollPane; 31 | import javax.swing.JTextArea; 32 | 33 | public class SimpleInfoBox 34 | { 35 | final JFrame frame; 36 | 37 | public SimpleInfoBox( final String title, final String text ) 38 | { 39 | frame = new JFrame( title ); 40 | 41 | final JTextArea textarea = new JTextArea( text ); 42 | 43 | final JPanel panel = new JPanel(); 44 | panel.add( textarea, BorderLayout.CENTER ); 45 | final JScrollPane pane = new JScrollPane( panel ); 46 | frame.add( pane, BorderLayout.CENTER ); 47 | 48 | frame.pack(); 49 | 50 | final Dimension d = pane.getSize(); 51 | d.setSize( d.width + 20, d.height + 10 ); 52 | pane.setSize( d ); 53 | pane.setPreferredSize( d ); 54 | frame.setPreferredSize( d ); 55 | 56 | frame.pack(); 57 | frame.setVisible( true ); 58 | } 59 | } 60 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/cuda/CUDAStandardFunctions.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.cuda; 24 | 25 | import com.sun.jna.Library; 26 | 27 | public interface CUDAStandardFunctions extends Library 28 | { 29 | /* 30 | __declspec(dllexport) int getCUDAcomputeCapabilityMinorVersion(int devCUDA); 31 | __declspec(dllexport) int getCUDAcomputeCapabilityMajorVersion(int devCUDA); 32 | __declspec(dllexport) int getNumDevicesCUDA(); 33 | __declspec(dllexport) char* getNameDeviceCUDA(int devCUDA); 34 | __declspec(dllexport) long long int getMemDeviceCUDA(int devCUDA); 35 | long long int getFreeMemDeviceCUDA(int devCUDA) 36 | */ 37 | public int getCUDAcomputeCapabilityMinorVersion(int devCUDA); 38 | public int getCUDAcomputeCapabilityMajorVersion(int devCUDA); 39 | /** 40 | * @return -1 if driver crashed, otherwise the number of CUDA devices, <= 0 41 | */ 42 | public int getNumDevicesCUDA(); 43 | public void getNameDeviceCUDA(int devCUDA, byte[] name); 44 | public long getMemDeviceCUDA(int devCUDA); 45 | public long getFreeMemDeviceCUDA(int devCUDA); 46 | } 47 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/fusion/transformed/weightcombination/CombineWeightsMulRandomAccess.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.fusion.transformed.weightcombination; 24 | 25 | import java.util.List; 26 | 27 | import net.imglib2.RandomAccessible; 28 | import net.imglib2.type.numeric.real.FloatType; 29 | 30 | public class CombineWeightsMulRandomAccess extends CombineWeightsRandomAccess 31 | { 32 | public CombineWeightsMulRandomAccess( 33 | final int n, 34 | final List< ? extends RandomAccessible< FloatType > > weights ) 35 | { 36 | super( n, weights ); 37 | } 38 | 39 | @Override 40 | public FloatType get() 41 | { 42 | double mulW = 1; 43 | 44 | for ( int j = 0; j < numImages; ++j ) 45 | mulW *= w[ j ].get().getRealDouble(); 46 | 47 | value.set( (float)mulW ); 48 | 49 | return value; 50 | } 51 | 52 | @Override 53 | public CombineWeightsMulRandomAccess copyRandomAccess() 54 | { 55 | final CombineWeightsMulRandomAccess r = new CombineWeightsMulRandomAccess( n, weights ); 56 | r.setPosition( this ); 57 | return r; 58 | } 59 | 60 | } 61 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/fusion/transformed/weightcombination/CombineWeightsSumRandomAccess.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.fusion.transformed.weightcombination; 24 | 25 | import java.util.List; 26 | 27 | import net.imglib2.RandomAccessible; 28 | import net.imglib2.type.numeric.real.FloatType; 29 | 30 | public class CombineWeightsSumRandomAccess extends CombineWeightsRandomAccess 31 | { 32 | public CombineWeightsSumRandomAccess( 33 | final int n, 34 | final List< ? extends RandomAccessible< FloatType > > weights ) 35 | { 36 | super( n, weights ); 37 | } 38 | 39 | @Override 40 | public FloatType get() 41 | { 42 | double sumW = 0; 43 | 44 | for ( int j = 0; j < numImages; ++j ) 45 | sumW += w[ j ].get().getRealDouble(); 46 | 47 | value.set( (float)sumW ); 48 | 49 | return value; 50 | } 51 | 52 | @Override 53 | public CombineWeightsSumRandomAccess copyRandomAccess() 54 | { 55 | final CombineWeightsSumRandomAccess r = new CombineWeightsSumRandomAccess( n, weights ); 56 | r.setPosition( this ); 57 | return r; 58 | } 59 | 60 | } 61 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/fusion/intensity/mpicbg/SimpleErrorStatistic.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.fusion.intensity.mpicbg; 24 | 25 | import java.util.Arrays; 26 | 27 | class SimpleErrorStatistic 28 | { 29 | private final double[] values; 30 | 31 | private int size = 0; 32 | 33 | private double mean = 0; 34 | 35 | public SimpleErrorStatistic( final int capacity ) 36 | { 37 | values = new double[ capacity ]; 38 | } 39 | 40 | public double getMedian() 41 | { 42 | Arrays.sort( values, 0, size ); 43 | final int m = size / 2; 44 | if ( size % 2 == 0 ) 45 | return ( values[ m - 1 ] + values[ m ] ) / 2.0; 46 | else 47 | return values[ m ]; 48 | } 49 | 50 | final public void add( final double new_value ) 51 | { 52 | int i = size++; 53 | values[ i ] = new_value; 54 | 55 | final double delta = new_value - mean; 56 | mean += delta / size; 57 | } 58 | 59 | public int n() 60 | { 61 | return size; 62 | } 63 | 64 | public double mean() 65 | { 66 | return mean; 67 | } 68 | 69 | public void clear() 70 | { 71 | size = 0; 72 | mean = 0; 73 | } 74 | } 75 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/pointcloud/pointdescriptor/model/TranslationInvariantModel.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.pointcloud.pointdescriptor.model; 24 | 25 | import mpicbg.models.AbstractModel; 26 | import mpicbg.models.Model; 27 | import net.preibisch.mvrecon.process.pointcloud.pointdescriptor.AbstractPointDescriptor; 28 | 29 | /** 30 | * This class is a subtle hint that {@link Model}s which are used to fit {@link AbstractPointDescriptor}s should be translation invariant. 31 | * 32 | * @author Stephan Preibisch (preibisch@mpi-cbg.de) 33 | * 34 | * @param something that extends {@link Model} 35 | */ 36 | public abstract class TranslationInvariantModel< M extends TranslationInvariantModel< M > > extends AbstractModel< M > 37 | { 38 | /** 39 | * The {@link TranslationInvariantModel} can tell which dimensions it supports. 40 | * 41 | * @param numDimensions - The dimensionality (e.g. 3 means 3-dimensional) 42 | * @return - If the {@link TranslationInvariantModel} supports that dimensionality 43 | */ 44 | public abstract boolean canDoNumDimension( int numDimensions ); 45 | } 46 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/global/pointmatchcreating/weak/WeakLinkPointMatchCreator.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.global.pointmatchcreating.weak; 24 | 25 | import java.util.HashMap; 26 | import java.util.HashSet; 27 | 28 | import net.preibisch.mvrecon.process.interestpointregistration.global.pointmatchcreating.PointMatchCreator; 29 | 30 | import mpicbg.models.Model; 31 | import mpicbg.models.Tile; 32 | import mpicbg.spim.data.sequence.ViewId; 33 | 34 | public abstract class WeakLinkPointMatchCreator< M extends Model< M > > implements PointMatchCreator 35 | { 36 | final HashMap< ViewId, Tile< M > > models1; 37 | final HashSet< ViewId > allViews; 38 | 39 | /** 40 | * @param models1 - the models from the first round of global optimization 41 | */ 42 | public WeakLinkPointMatchCreator( final HashMap< ViewId, Tile< M > > models1 ) 43 | { 44 | this.models1 = models1; 45 | this.allViews = new HashSet<>(); 46 | 47 | this.allViews.addAll( models1.keySet() ); 48 | } 49 | 50 | @Override 51 | public HashSet< ViewId > getAllViews() { return allViews; } 52 | } 53 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/pairwise/methods/fastrgldm/FRGLDMParameters.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.pairwise.methods.fastrgldm; 24 | 25 | import mpicbg.models.Model; 26 | 27 | public class FRGLDMParameters 28 | { 29 | public static double ratioOfDistance = 10; 30 | 31 | public static int redundancy = 1; 32 | 33 | protected final double rod; 34 | protected final int nn, re; 35 | 36 | private Model< ? > model = null; 37 | public Model< ? > getModel() { return model.copy(); } 38 | 39 | public FRGLDMParameters( final Model< ? > model ) 40 | { 41 | this.rod = ratioOfDistance; 42 | this.nn = 3; 43 | this.re = redundancy; 44 | this.model = model; 45 | } 46 | 47 | public FRGLDMParameters( final Model< ? > model, final double ratioOfDistance, final int redundancy ) 48 | { 49 | this.model = model; 50 | this.rod = ratioOfDistance; 51 | this.nn = 3; 52 | this.re = redundancy; 53 | } 54 | 55 | public double getRatioOfDistance() { return rod; } 56 | public int getNumNeighbors() { return nn; } 57 | public int getRedundancy() { return re; } 58 | } 59 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/legacy/registration/bead/error/GlobalErrorStatistics.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.legacy.registration.bead.error; 24 | 25 | public interface GlobalErrorStatistics 26 | { 27 | public double getMinAlignmentError(); 28 | public double getAverageAlignmentError(); 29 | public double getMaxAlignmentError(); 30 | 31 | public void setMinAlignmentError( double min ); 32 | public void setAverageAlignmentError( double avg ); 33 | public void setMaxAlignmentError( double max ); 34 | 35 | public int getNumDetections(); 36 | public int getNumCandidates(); 37 | public int getNumCorrespondences(); 38 | 39 | public void setNumDetections( int numDetection ); 40 | public void setNumCandidates( int numCandidates ); 41 | public void setNumCorrespondences( int numCorrespondences ); 42 | 43 | public void setAbsoluteLocalAlignmentError( double error ); 44 | public void setAlignmentErrorCount( int count ); 45 | public double getAbsoluteLocalAlignmentError(); 46 | public int getAlignmentErrorCount(); 47 | 48 | public double getAverageLocalAlignmentError(); 49 | 50 | public void reset(); 51 | } 52 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/plugin/interestpointregistration/global/IndividualTimepointGUI.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.plugin.interestpointregistration.global; 24 | 25 | import java.util.ArrayList; 26 | import java.util.List; 27 | 28 | import net.preibisch.mvrecon.fiji.spimdata.SpimData2; 29 | 30 | import mpicbg.spim.data.sequence.TimePoint; 31 | import mpicbg.spim.data.sequence.ViewId; 32 | 33 | public class IndividualTimepointGUI implements GlobalGUI 34 | { 35 | final SpimData2 data; 36 | 37 | public IndividualTimepointGUI( final SpimData2 data ) 38 | { 39 | this.data = data; 40 | } 41 | 42 | public List< List< ViewId > > getIndividualSets( final List< ViewId > viewIds ) 43 | { 44 | final ArrayList< List< ViewId > > sets = new ArrayList<>(); 45 | 46 | for ( final TimePoint timepoint : SpimData2.getAllTimePointsSorted( data, viewIds ) ) 47 | { 48 | final ArrayList< ViewId > set = new ArrayList<>(); 49 | 50 | for ( final ViewId viewId : viewIds ) 51 | if ( viewId.getTimePointId() == timepoint.getId() ) 52 | set.add( viewId ); 53 | 54 | sets.add( set ); 55 | } 56 | 57 | return sets; 58 | } 59 | } 60 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/interestpoints/ViewInterestPointLists.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.interestpoints; 24 | 25 | import java.util.HashMap; 26 | 27 | import mpicbg.spim.data.sequence.ViewId; 28 | 29 | /** 30 | * Maps from a String label to a list of interest points for a specific viewid 31 | * 32 | * @author Stephan Preibisch (stephan.preibisch@gmx.de) 33 | * 34 | */ 35 | public class ViewInterestPointLists extends ViewId 36 | { 37 | protected final HashMap< String, InterestPoints > lookup; 38 | 39 | public ViewInterestPointLists( final int timepointId, final int setupId ) 40 | { 41 | super( timepointId, setupId ); 42 | 43 | this.lookup = new HashMap< String, InterestPoints >(); 44 | } 45 | 46 | public boolean contains( final String label ) { return lookup.containsKey( label ); } 47 | public HashMap< String, InterestPoints > getHashMap() { return lookup; } 48 | public InterestPoints getInterestPointList( final String label ) { return lookup.get( label ); } 49 | public void addInterestPointList( final String label, final InterestPoints pointList ) { lookup.put( label, pointList ); } 50 | } 51 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/pairwise/constellation/IndividualTimepoints.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation; 24 | 25 | import java.util.Collection; 26 | import java.util.List; 27 | import java.util.Set; 28 | 29 | import mpicbg.spim.data.sequence.ViewId; 30 | import net.imglib2.util.Pair; 31 | import net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation.grouping.Group; 32 | import net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation.range.TimepointRange; 33 | 34 | public class IndividualTimepoints extends AllToAllRange< ViewId, TimepointRange< ViewId > > 35 | { 36 | public IndividualTimepoints( 37 | final List< ViewId > views, 38 | final Set< Group< ViewId > > groups ) 39 | { 40 | super( views, groups, new TimepointRange< ViewId >( 0 ) ); 41 | } 42 | 43 | public static < V extends ViewId > List< Pair< V, V > > allPairs( 44 | final List< ? extends V > views, 45 | final Collection< ? extends Group< V > > groups ) 46 | { 47 | return AllToAllRange.allPairs( views, groups, new TimepointRange< V >( 0 ) ); 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/imgloaders/LightSheetZ1ImgLoader.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.imgloaders; 24 | 25 | import java.io.File; 26 | 27 | import mpicbg.spim.data.generic.sequence.AbstractSequenceDescription; 28 | import mpicbg.spim.data.legacy.LegacyImgLoaderWrapper; 29 | import net.imglib2.img.ImgFactory; 30 | import net.imglib2.type.NativeType; 31 | import net.imglib2.type.numeric.integer.UnsignedShortType; 32 | 33 | public class LightSheetZ1ImgLoader extends LegacyImgLoaderWrapper< UnsignedShortType, LegacyLightSheetZ1ImgLoader > 34 | { 35 | public LightSheetZ1ImgLoader( 36 | final File cziFile, 37 | final ImgFactory< ? extends NativeType< ? > > imgFactory, 38 | final AbstractSequenceDescription sequenceDescription ) 39 | { 40 | super( new LegacyLightSheetZ1ImgLoader( cziFile, imgFactory, sequenceDescription ) ); 41 | } 42 | 43 | public File getCZIFile() { return legacyImgLoader.getCZIFile(); } 44 | public ImgFactory< ? extends NativeType< ? > > getImgFactory() { return legacyImgLoader.getImgFactory(); } 45 | 46 | @Override 47 | public String toString() { 48 | return legacyImgLoader.toString(); 49 | } 50 | } 51 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/plugin/interestpointregistration/parameters/FixMapBackParameters.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.plugin.interestpointregistration.parameters; 24 | 25 | import java.util.Map; 26 | import java.util.Set; 27 | 28 | import mpicbg.models.Model; 29 | import mpicbg.spim.data.sequence.ViewId; 30 | import net.imglib2.Dimensions; 31 | import net.imglib2.util.Pair; 32 | import net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation.Subset; 33 | 34 | public class FixMapBackParameters 35 | { 36 | public static String[] fixViewsChoice = new String[]{ 37 | "Fix first view", 38 | "Select fixed view", 39 | "Do not fix views" }; 40 | 41 | public static String[] mapBackChoice = new String[]{ 42 | "Do not map back (use this if views are fixed)", 43 | "Map back to first view using translation model", 44 | "Map back to first view using rigid model", 45 | "Map back to user defined view using translation model", 46 | "Map back to user defined view using rigid model" }; 47 | 48 | public Set< ViewId > fixedViews; 49 | public Model< ? > model; 50 | public Map< Subset< ViewId >, Pair< ViewId, Dimensions > > mapBackViews; 51 | } 52 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/global/pointmatchcreating/Link.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.global.pointmatchcreating; 24 | 25 | import net.imglib2.RealInterval; 26 | import net.imglib2.realtransform.AffineGet; 27 | 28 | public class Link 29 | { 30 | private final T first; 31 | private final T second; 32 | private final AffineGet transform; 33 | private final double linkQuality; 34 | private final RealInterval boundingBox; 35 | 36 | public Link(final T fst, final T snd, final RealInterval boundingBox, final AffineGet transform, final double linkQuality) 37 | { 38 | this.first = fst; 39 | this.second = snd; 40 | this.transform = transform; 41 | this.linkQuality = linkQuality; 42 | this.boundingBox = boundingBox; 43 | } 44 | 45 | public RealInterval getBoundingBox() { return boundingBox; } 46 | public T getFirst() { return first; } 47 | public T getSecond() { return second; } 48 | public AffineGet getTransform() { return transform; } 49 | public double getLinkQuality() { return linkQuality; } 50 | 51 | @Override 52 | public String toString() 53 | { return "("+ first.toString() + ", " + second.toString() + ")"; } 54 | } 55 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/pairwise/constellation/range/ReferenceTimepointRange.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation.range; 24 | 25 | import mpicbg.spim.data.sequence.TimePoint; 26 | import mpicbg.spim.data.sequence.ViewId; 27 | 28 | public class ReferenceTimepointRange< V extends ViewId > implements RangeComparator< V > 29 | { 30 | final int referenceTimepoint; 31 | 32 | public ReferenceTimepointRange( final int referenceTimepoint ) 33 | { 34 | this.referenceTimepoint = referenceTimepoint; 35 | } 36 | public ReferenceTimepointRange( final TimePoint referenceTimepoint ) 37 | { 38 | this( referenceTimepoint.getId() ); 39 | } 40 | 41 | @Override 42 | public boolean inRange( final V view1, final V view2 ) 43 | { 44 | // if one of the views is a reference timepoint or if they are from the same timepoint (fixed views are discarded later) 45 | if ( view1.getTimePointId() == referenceTimepoint || view2.getTimePointId() == referenceTimepoint || view1.getTimePointId() == view2.getTimePointId() ) 46 | return true; 47 | else 48 | return false; 49 | } 50 | 51 | public int getReferenceTimepointId() { return referenceTimepoint; } 52 | } 53 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/fiji/spimdata/imgloaders/filemap2/FileMapEntry.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.fiji.spimdata.imgloaders.filemap2; 24 | 25 | import java.io.File; 26 | import java.util.Objects; 27 | 28 | public class FileMapEntry 29 | { 30 | private final File file; 31 | 32 | private final int series; 33 | 34 | private final int channel; 35 | 36 | // TODO: rename to FileSeriesChannel ? 37 | public FileMapEntry( final File file, final int series, final int channel ) 38 | { 39 | this.file = file; 40 | this.series = series; 41 | this.channel = channel; 42 | } 43 | 44 | public File file() 45 | { 46 | return file; 47 | } 48 | 49 | public int series() 50 | { 51 | return series; 52 | } 53 | 54 | public int channel() 55 | { 56 | return channel; 57 | } 58 | 59 | @Override 60 | public boolean equals( final Object o ) 61 | { 62 | if ( this == o ) 63 | return true; 64 | if ( !( o instanceof FileMapEntry ) ) 65 | return false; 66 | final FileMapEntry that = ( FileMapEntry ) o; 67 | return series == that.series && channel == that.channel && Objects.equals( file, that.file ); 68 | } 69 | 70 | @Override 71 | public int hashCode() 72 | { 73 | return Objects.hash( file, series, channel ); 74 | } 75 | } 76 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/pointcloud/pointdescriptor/test/PointNode.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.pointcloud.pointdescriptor.test; 24 | 25 | import fiji.util.node.Leaf; 26 | import mpicbg.models.Point; 27 | 28 | public class PointNode extends Point implements Leaf 29 | { 30 | /** 31 | * 32 | */ 33 | private static final long serialVersionUID = 1L; 34 | 35 | final int numDimensions; 36 | 37 | public PointNode( final Point p ) 38 | { 39 | super( p.getL().clone(), p.getW().clone() ); 40 | this.numDimensions = l.length; 41 | } 42 | 43 | public PointNode( final double[] l ) 44 | { 45 | super( l ); 46 | this.numDimensions = l.length; 47 | } 48 | 49 | public PointNode( final double[] l, final double[] w ) 50 | { 51 | super( l, w ); 52 | this.numDimensions = l.length; 53 | } 54 | 55 | @Override 56 | public PointNode[] createArray( final int n ) { return new PointNode[ n ]; } 57 | 58 | @Override 59 | public float distanceTo( final PointNode other ) { return (float)Point.distance( this, other ); } 60 | 61 | @Override 62 | public float get( final int k ) { return (float)w[ k ]; } 63 | 64 | @Override 65 | public int getNumDimensions() { return numDimensions; } 66 | 67 | @Override 68 | public boolean isLeaf() { return true; } 69 | } 70 | -------------------------------------------------------------------------------- /src/main/java/net/preibisch/mvrecon/process/interestpointregistration/global/pointmatchcreating/weak/MetaDataWeakLinkFactory.java: -------------------------------------------------------------------------------- 1 | /*- 2 | * #%L 3 | * Software for the reconstruction of multi-view microscopic acquisitions 4 | * like Selective Plane Illumination Microscopy (SPIM) Data. 5 | * %% 6 | * Copyright (C) 2012 - 2025 Multiview Reconstruction developers. 7 | * %% 8 | * This program is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as 10 | * published by the Free Software Foundation, either version 2 of the 11 | * License, or (at your option) any later version. 12 | * 13 | * This program is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public 19 | * License along with this program. If not, see 20 | * . 21 | * #L% 22 | */ 23 | package net.preibisch.mvrecon.process.interestpointregistration.global.pointmatchcreating.weak; 24 | 25 | import java.util.HashMap; 26 | import java.util.Map; 27 | 28 | import net.preibisch.mvrecon.process.interestpointregistration.pairwise.constellation.overlap.OverlapDetection; 29 | 30 | import mpicbg.models.Model; 31 | import mpicbg.models.Tile; 32 | import mpicbg.spim.data.registration.ViewRegistration; 33 | import mpicbg.spim.data.sequence.ViewId; 34 | 35 | public class MetaDataWeakLinkFactory implements WeakLinkFactory 36 | { 37 | final OverlapDetection< ViewId > overlapDetection; 38 | final Map< ViewId, ViewRegistration > viewRegistrations; 39 | 40 | public MetaDataWeakLinkFactory( 41 | final Map< ViewId, ViewRegistration > viewRegistrations, 42 | final OverlapDetection< ViewId > overlapDetection ) 43 | { 44 | this.viewRegistrations = viewRegistrations; 45 | this.overlapDetection = overlapDetection; 46 | } 47 | 48 | @Override 49 | public < M extends Model< M > > WeakLinkPointMatchCreator< M > create( 50 | final HashMap< ViewId, Tile< M > > models ) 51 | { 52 | return new MetaDataWeakLinkCreator<>( models, overlapDetection, viewRegistrations ); 53 | } 54 | 55 | } 56 | --------------------------------------------------------------------------------