freemercury / Aberration_correction_metasensor

42 stars 7 forks source link

About Dynamic Correction #1

Open CodeRed97 opened 1 year ago

CodeRed97 commented 1 year ago

Thanks for your work! I had some questions about the dynamic corrction code. I didn't understand what does the scanning_pos (which is determined as 17) stand for, is it a super parameter or it changes along with time? The selected (u,v) calculated by 0.99^(abs(t-nshift^2) is confusing to me as well. As for the optical flow method, it seems the algorithm's input is two frames from different (u,v) instead of two frames in a video. I thought the Meta_image contains only img info shot at single moment, but how the motion artefact is corrected using only one Meta_image? Maybe I lack some background knowledge about optics, a little more comment may be helpful to the learners. Thanks again for your code.

freemercury commented 1 year ago

Thx for your questions.

  1. The scanning_pos "17" is not a super parameter but a fixed number for the demo data, which is relative to the scanning position of the piezo at the moment. It is not tunable.
  2. The input of dynamic correction is two frames from the same (u,v). We utilized the consistency of movement and the redundancy of sampling to remove the motion artefacts. In other words, it is more like a video-super-resolution task. The scanning can ensure the difference between every two frames even for a static scene.
  3. 0.99^(abs(t-nshift^2)) is a specific way to claim the weights aiming to help us find the reference frame. It can be replaced by any other forms suchlike 0.88^(abs(t-nshift^2)) and so on.
CodeRed97 commented 1 year ago

Thanks for your reply. Still kind of confused though. I'll review the code and try to figure it out. Really appreciate your help.