Skip to content

Commit

Permalink
JRCVNC2018M <-> MANC transform: make sure to use MANC in microns
Browse files Browse the repository at this point in the history
  • Loading branch information
schlegelp committed Aug 8, 2023
1 parent 01c78ea commit 8fe2dbf
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions flybrains/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,13 @@ def search_register_path(path, verbose=False):
if source == 'JRCFIB2018F':
source = 'JRCFIB2018Fum'

# "MANC" likewise requires microns
if target == 'MANC':
target = 'MANCum'

if source == 'MANC':
source = 'MANCum'

# Initialize the transform
transform = tr(hit)

Expand Down Expand Up @@ -464,6 +471,13 @@ def register_transforms():
target='MANCnm',
transform_type='bridging')

# Add MANC to MANCum transform
tr = transforms.AffineTransform(np.diag([1000, 1000, 1000, 1]))
transforms.registry.register_transform(transform=tr,
source='MANCum',
target='MANC',
transform_type='bridging')

# Some general notes for the Elastix transform between FANC and JRCVNC2018F:
# 1. Elastix transforms are not invertible - hence there are two separate
# transforms for forward and reverse directions
Expand Down

0 comments on commit 8fe2dbf

Please sign in to comment.