public class KernelExchange extends KernelIndependent<VoxelizedMarksWithEnergy,UpdatableMarksList>
Constructor and Description |
---|
KernelExchange() |
Modifier and Type | Method and Description |
---|---|
double |
calculateAcceptanceProbability(int existingSize,
int proposalSize,
double poissonIntensity,
Dimensions dimensions,
double densityRatio) |
int[] |
changedMarkIDArray()
The mark ids that were changed in the last energy calculation for the kernel
|
String |
describeLast() |
MarkProposer |
getMarkProposer() |
boolean |
isCompatibleWith(Mark testMark) |
Optional<VoxelizedMarksWithEnergy> |
makeProposal(Optional<VoxelizedMarksWithEnergy> existing,
KernelCalculationContext context)
Calculates the Energy for a proposal
|
void |
setMarkProposer(MarkProposer markProposer) |
void |
updateAfterAcceptance(UpdatableMarksList updatableState,
VoxelizedMarksWithEnergy existing,
VoxelizedMarksWithEnergy accpted)
If the kernel is accepted, makes the necessary changes to a ListUpdatableMarkSetCollection
|
informLatestState, initBeforeCalc
initializerForMarksBeans
getInitialization, getLogger, getPropertyInitializer, initialize, initializeRecursive, initRecursiveWithInitializer, isInitialized, onInitialization
checkMisconfigured, describeBean, describeChildren, duplicateBean, fields, findFieldsOfClass, getBeanName, getLocalPath, localise, toString
public double calculateAcceptanceProbability(int existingSize, int proposalSize, double poissonIntensity, Dimensions dimensions, double densityRatio)
calculateAcceptanceProbability
in class Kernel<VoxelizedMarksWithEnergy,UpdatableMarksList>
public String describeLast()
describeLast
in class Kernel<VoxelizedMarksWithEnergy,UpdatableMarksList>
public void updateAfterAcceptance(UpdatableMarksList updatableState, VoxelizedMarksWithEnergy existing, VoxelizedMarksWithEnergy accpted) throws UpdateMarkSetException
Kernel
updateAfterAcceptance
in class Kernel<VoxelizedMarksWithEnergy,UpdatableMarksList>
updatableState
- where to make the changesexisting
- existing energyaccpted
- accepted energyUpdateMarkSetException
public int[] changedMarkIDArray()
Kernel
Guaranteed only to be called, if energy calculation did not return null
changedMarkIDArray
in class Kernel<VoxelizedMarksWithEnergy,UpdatableMarksList>
public Optional<VoxelizedMarksWithEnergy> makeProposal(Optional<VoxelizedMarksWithEnergy> existing, KernelCalculationContext context) throws KernelCalculateEnergyException
Kernel
makeProposal
in class Kernel<VoxelizedMarksWithEnergy,UpdatableMarksList>
existing
- the existing EnergyKernelCalculateEnergyException
public boolean isCompatibleWith(Mark testMark)
public MarkProposer getMarkProposer()
public void setMarkProposer(MarkProposer markProposer)
Copyright © 2010–2023 Owen Feehan, ETH Zurich, University of Zurich, Hoffmann-La Roche. All rights reserved.