Code Monkey home page Code Monkey logo

Comments (2)

marbre2 avatar marbre2 commented on August 26, 2024 1

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.

jni avatar jni commented on August 26, 2024

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)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.