本文整理汇总了Java中mpicbg.spim.data.sequence.TimePoints类的典型用法代码示例。如果您正苦于以下问题:Java TimePoints类的具体用法?Java TimePoints怎么用?Java TimePoints使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
TimePoints类属于mpicbg.spim.data.sequence包,在下文中一共展示了TimePoints类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: create
import mpicbg.spim.data.sequence.TimePoints; //导入依赖的package包/类
public static FusionResult create(
final SpimRegistrationSequence spimseq,
final String filepath,
final String filepattern,
final int numSlices,
final double sliceValueMin,
final double sliceValueMax,
final Map< Integer, AffineTransform3D > perTimePointFusionTransforms )
{
// add one fused ViewSetup per channel in the SpimRegistrationSequence
final List< Integer > channels = new ArrayList<>();
for ( final BasicViewSetup setup : spimseq.getSequenceDescription().getViewSetupsOrdered() )
{
final int channel = setup.getAttribute( Channel.class ).getId();
if ( ! channels.contains( channel ) )
channels.add( channel );
}
final TimePoints timepoints = spimseq.getSequenceDescription().getTimePoints();
return new FusionResult( filepath, filepattern, channels, timepoints, numSlices, sliceValueMin, sliceValueMax, perTimePointFusionTransforms );
}
示例2: FusionResult
import mpicbg.spim.data.sequence.TimePoints; //导入依赖的package包/类
public FusionResult(
final String filepath,
final String filepattern,
final TimePoints timepoints,
final int numSlices,
final double sliceValueMin,
final double sliceValueMax,
final Map< Integer, AffineTransform3D > perTimePointFusionTransforms )
{
final HashMap< Integer, Integer > setupIdToChannelId = new HashMap<>();
setupIdToChannelId.put( 0, 0 );
final ImgLoader fusionLoader = new FusionImageLoader<>( filepath +"/" + filepattern, setupIdToChannelId, numSlices, new FusionImageLoader.Gray32ImagePlusLoader(), sliceValueMin, sliceValueMax );
final int setupId = 0;
final String name = "fused";
final int timepointId = timepoints.getTimePointsOrdered().get( 0 ).getId();
final Dimensions size = fusionLoader.getSetupImgLoader( setupId ).getImageSize( timepointId );
final VoxelDimensions voxelSize = fusionLoader.getSetupImgLoader( setupId ).getVoxelSize( timepointId );
final BasicViewSetup setup = new BasicViewSetup( setupId, name, size, voxelSize );
desc = new SequenceDescriptionMinimal( timepoints, Entity.idMap( Arrays.asList( setup ) ), fusionLoader, null );
final ArrayList< ViewRegistration > registrations = new ArrayList<>();
for ( final TimePoint timepoint : timepoints.getTimePointsOrdered() )
registrations.add( new ViewRegistration( timepoint.getId(), 0, perTimePointFusionTransforms.get( timepoint.getId() ) ) );
regs = new ViewRegistrations( registrations );
}
示例3: createTimePoints
import mpicbg.spim.data.sequence.TimePoints; //导入依赖的package包/类
/**
* Creates the {@link TimePoints} for the {@link SpimData} object
*/
protected TimePoints createTimePoints(final SlideBook6MetaData meta) {
final ArrayList<TimePoint> timepoints = new ArrayList<TimePoint>();
int firstCapture = defaultCapture;
int numCaptures = 1;
if (defaultCapture == -1) {
firstCapture = 0;
numCaptures = meta.numCaptures();
}
int t = 0;
for (; t < meta.numTimepoints(firstCapture); ++t)
timepoints.add(new TimePoint(t));
return new TimePoints(timepoints);
}
示例4: GraphFrame
import mpicbg.spim.data.sequence.TimePoints; //导入依赖的package包/类
public GraphFrame(
final TimePoints timepoints,
final JFreeChart chart,
final int referenceTimePoint,
final boolean enableReferenceTimePoint,
final List< SelectTimepointEntry > extraMenuItems,
final ArrayList< RegistrationStatistics > data )
{
super();
mainPanel = new JPanel();
mainPanel.setLayout( new BorderLayout() );
updateWithNewChart( timepoints, chart, true, extraMenuItems, data, referenceTimePoint, enableReferenceTimePoint );
JPanel buttonsPanel = new JPanel();
mainPanel.add( buttonsPanel, BorderLayout.SOUTH );
setContentPane( mainPanel );
validate();
GUI.center( this );
}
示例5: MouseListenerTimelapse
import mpicbg.spim.data.sequence.TimePoints; //导入依赖的package包/类
MouseListenerTimelapse( final TimePoints timepoints, final ChartPanel panel, final int referenceTimePoint, final boolean enableReferenceTimePoint )
{
this.timepoints = timepoints;
this.panel = panel;
this.referenceTimePoint = referenceTimePoint;
this.enableReferenceTimePoint = enableReferenceTimePoint;
if ( enableReferenceTimePoint || referenceTimePoint != -1 ) // at least show it if it is not -1
{
if ( timepoints != null )
setReferenceTimepoint( timepoints, referenceTimePoint );
valueMarker = makeMarker( referenceTimePoint );
if ( referenceTimePoint >= 0 )
{
((XYPlot)panel.getChart().getPlot()).addDomainMarker( valueMarker );
markerShown = true;
}
}
}
示例6: setReferenceTimepoint
import mpicbg.spim.data.sequence.TimePoints; //导入依赖的package包/类
public static boolean setReferenceTimepoint( final TimePoints timepoints, final int referenceTimePoint )
{
final TimePoint ref = timepoints.getTimePoints().get( referenceTimePoint );
if ( ref != null )
{
final List< TimePoint > tps = timepoints.getTimePointsOrdered();
for ( int tp = 0; tp < tps.size(); ++tp )
{
if ( tps.get( tp ).getId() == referenceTimePoint )
{
Interest_Point_Registration.defaultReferenceTimepointIndex = tp;
return true;
}
}
}
return false;
}
示例7: SpimRegistrationSequence
import mpicbg.spim.data.sequence.TimePoints; //导入依赖的package包/类
public SpimRegistrationSequence( final SPIMConfiguration conf )
{
this.conf = conf;
final ArrayList< ViewSetup > setups = createViewSetups( conf );
// final HashMap< Integer, ViewSetup > setups = Entity.idMap( createViewSetups( conf ) );
final TimePoints timepoints = createTimePoints( conf );
final BasicImgLoader imgLoader = createImageLoader( conf, setups );
viewRegistrations = createViewRegistrations( conf, setups );
sequenceDescription = new SequenceDescriptionMinimal( timepoints, Entity.idMap( createViewSetups( conf ) ), imgLoader, null );
}
示例8: createTimePoints
import mpicbg.spim.data.sequence.TimePoints; //导入依赖的package包/类
protected static TimePoints createTimePoints( final SPIMConfiguration conf )
{
final ArrayList< TimePoint > timepoints = new ArrayList<>();
for ( final int tp : conf.timepoints )
timepoints.add( new TimePoint( tp ) );
return new TimePoints( timepoints );
}
示例9: readTimePoints
import mpicbg.spim.data.sequence.TimePoints; //导入依赖的package包/类
public TimePoints readTimePoints()
{
final Element root = document.getRootElement();
final int nTimePoints = Integer.parseInt( root.getChild( "TimelapsCondition" ).getChildText( "Iteration" ) );
final List< TimePoint > timepoints = new ArrayList<>( nTimePoints );
for ( int i = 0; i < nTimePoints; i++ )
{
timepoints.add( new TimePoint( Integer.valueOf( i ) ) );
}
return new TimePoints( timepoints );
}
示例10: assembleTimepoints
import mpicbg.spim.data.sequence.TimePoints; //导入依赖的package包/类
protected static String[] assembleTimepoints( final TimePoints timepoints )
{
final String[] tps = new String[ timepoints.size() ];
for ( int t = 0; t < tps.length; ++t )
tps[ t ] = timepoints.getTimePointsOrdered().get( t ).getName();
return tps;
}
示例11: createTimePoints
import mpicbg.spim.data.sequence.TimePoints; //导入依赖的package包/类
/**
* Creates the {@link TimePoints} for the {@link SpimData} object
*/
protected TimePoints createTimePoints( final LightSheetZ1MetaData meta )
{
final ArrayList< TimePoint > timepoints = new ArrayList< TimePoint >();
for ( int t = 0; t < meta.numTimepoints(); ++t )
timepoints.add( new TimePoint( t ) );
return new TimePoints( timepoints );
}
示例12: createTimePoints
import mpicbg.spim.data.sequence.TimePoints; //导入依赖的package包/类
/**
* Creates the {@link TimePoints} for the {@link SpimData} object
*/
protected TimePoints createTimePoints( final DHMMetaData meta )
{
final ArrayList< TimePoint > timepoints = new ArrayList< TimePoint >();
for ( int t = 0; t < meta.getTimepoints().size(); ++t )
timepoints.add( new TimePoint( Integer.parseInt( meta.getTimepoints().get( t ) ) ) );
return new TimePoints( timepoints );
}
示例13: createTimePoints
import mpicbg.spim.data.sequence.TimePoints; //导入依赖的package包/类
/**
* Creates the {@link TimePoints} for the {@link SpimData} object
*/
protected TimePoints createTimePoints( MultipageTiffReader meta )
{
final ArrayList< TimePoint > timepoints = new ArrayList< TimePoint >();
for ( int t = 0; t < meta.numTimepoints(); ++t )
timepoints.add( new TimePoint( t ) );
return new TimePoints( timepoints );
}
示例14: createDataset
import mpicbg.spim.data.sequence.TimePoints; //导入依赖的package包/类
@Override
public SpimData2 createDataset()
{
// collect all the information
if ( !queryInformation() )
return null;
// assemble timepints, viewsetups, missingviews and the imgloader
final TimePoints timepoints = this.createTimePoints();
final ArrayList< ViewSetup > setups = this.createViewSetups();
final MissingViews missingViews = this.createMissingViews();
// instantiate the sequencedescription
final SequenceDescription sequenceDescription = new SequenceDescription( timepoints, setups, null, missingViews );
final ImgLoader imgLoader = createAndInitImgLoader( ".", new File( directory ), imgFactory, sequenceDescription );
sequenceDescription.setImgLoader( imgLoader );
// get the minimal resolution of all calibrations
final double minResolution = Apply_Transformation.assembleAllMetaData(
sequenceDescription,
sequenceDescription.getViewDescriptions().values() );
IOFunctions.println( "Minimal resolution in all dimensions over all views is: " + minResolution );
IOFunctions.println( "(The smallest resolution in any dimension; the distance between two pixels in the output image will be that wide)" );
// create the initial view registrations (they are all the identity transform)
final ViewRegistrations viewRegistrations = createViewRegistrations( sequenceDescription.getViewDescriptions(), minResolution );
// create the initial view interest point object
final ViewInterestPoints viewInterestPoints = new ViewInterestPoints();
viewInterestPoints.createViewInterestPoints( sequenceDescription.getViewDescriptions() );
// finally create the SpimData itself based on the sequence description and the view registration
final SpimData2 spimData = new SpimData2( new File( directory ), sequenceDescription, viewRegistrations, viewInterestPoints, new BoundingBoxes() );
return spimData;
}
示例15: createTimePoints
import mpicbg.spim.data.sequence.TimePoints; //导入依赖的package包/类
/**
* Creates the {@link TimePoints} for the {@link SpimData} object
*/
protected TimePoints createTimePoints()
{
try
{
return new TimePointsPattern( timepoints );
}
catch ( final ParseException e )
{
throw new RuntimeException( e );
}
}