Comments (2)
Hello @jni,
First I'd like to thank you for your kind and detailed reply.
So far I just wanted to give you a feedback on the fact that I managed to use affinder with my 3D images in the 3D view mode (MIP). I first added landmark "points" in the dorsal plane, then a few others in transverse and median plane.
This gave a first rough alignment. I will check on the details of your answer to see how I could contribute to this plugin.
Best regards,
Marine
from affinder.
Hello @marbre2!
Thanks for opening this issue!
So, in theory, it should actually already work in 3D: all of the alignment and callback code makes no assumptions about the dimensionality of the underlying images. The three issues are that:
- adding correspondence points in 3D is tricky / doesn't work at all; we could potentially do it with a similar method to the 3D filament annotator: https://twitter.com/anna_medyukhina/status/1578114418805800976 ie, click once to create a "ray", rotate the view, click again to select a point within the ray. I'd be super excited to help with that.
- napari doesn't handle non-orthogonal transformations in 3D when displaying 2D slices. That is, if you e.g. rotate a volume 45ΒΊ along the xz plane, when you look at xy napari will show orthogonal planes to z. Therefore, if you are using the 2D view (which is the only view where you can currently add points), the images won't be aligned correctly, which is kinda sorta the whole point with affinder. π
- The other whole point with affinder π is to set the view to center on the predicted location of your next click, once you have an initial alignment. I think that probably doesn't work in 3D view; in 2D view, which as we said above is flawed, it could be made to work, but we should also use
dims.set_point
in addition to setting the viewbox.
So, in summary, those are the challenges, but the alignment stuff should basically work; contributions would be super super welcome and I would be happy to help, give you a tour of the code if anything's unclear (π¬) (omg just saw that the main function doesn't even have a docstring yet π π), etc!
PS: You might also be interested in @thanushipeiris's in-progress PR to allow mixed-dimension registration, #58.
from affinder.
Related Issues (20)
- Task: Allow aligning non-image layers
- wheel building broken?
- Task: add tests for non-image alignment
- GitHub actions and Trove classifiers should be updated to drop Py3.7 and add Py 3.10
- refresh available layers in dropdown HOT 1
- Transformation matrix with skimage.transform.warp HOT 5
- why not make the description the readme? HOT 10
- Should add sample data
- Change docs theme to Pydata Sphinx theme
- Improve documentation, explaining how affinder works
- Add documentation URL to repo description HOT 1
- Widget idea: table showing current point coordinates and residuals for each point HOT 6
- Adding layers with small scale values results in absurdly large points
- Starting affinder without layers causes Napari to crash
- apply_affine does not correctly transform images for scales<1 HOT 2
- Limit "Select File" button for output to .txt files
- Need ability to undo point adding and effect of callbacks
- Closing the widget should close affinder
- Add test to ensure moving points layer have the correct affine transform
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from affinder.