Code Monkey home page Code Monkey logo

Comments (11)

marius10p avatar marius10p commented on August 30, 2024

Seems like this has to do with BiDiPhaseOffsets. Any ideas @carsen-stringer ?

from suite2p.

carsen-stringer avatar carsen-stringer commented on August 30, 2024

ah yes sorry this was only working for frames with even pixels! try now

from suite2p.

swift505 avatar swift505 commented on August 30, 2024

Hi @carsen-stringer
I now no longer get the error messages, but the registered TIFFs show a strange 'scrolling' artefact where the image appears to translate vertically by approximately 1 row per frame. This only occurs for odd numbers of pixels.
768x768 works fine -0.2 0 0 0.1
1024x1024 works fine -0.2 0 0 0
767x767 scrolling effect -0.2 0 0 0.1
1023x1023 scrolling effect -0.2 0 0 0

from suite2p.

carsen-stringer avatar carsen-stringer commented on August 30, 2024

Are they giving different bidiphase offsets depending on the number of pixels? Or is the bidiphase offset the same for both?

from suite2p.

swift505 avatar swift505 commented on August 30, 2024

Hi @carsen-stringer,
In all cases bidir offset = 0.

  • Isaac

from suite2p.

carsen-stringer avatar carsen-stringer commented on August 30, 2024

that's strange, now it should avoid any pixel shifts if bidiphase=0. let me know if it works.

from suite2p.

swift505 avatar swift505 commented on August 30, 2024

Hi @carsen-stringer ,

I'm afraid the 'scrolling' problem still seems to persist. Also, if this helps diagnose the problem, as well as translating vertically 1 row per frame, the registered movie also appears to have jumped horizontally (by about 80 pixels). As usual, this did not happen with a 768x768 version of the same data.

My settings in master_file for registration are:
% registration options
ops0.doRegistration = 1; % skip (0) if data is already registered
ops0.showTargetRegistration = 1; % shows the image targets for all planes to be registered
ops0.PhaseCorrelation = 1; % set to 0 for non-whitened cross-correlation
ops0.SubPixel = Inf; % 2 is alignment by 0.5 pixel, Inf is the exact number from phase correlation
ops0.NimgFirstRegistration = 100; % was 500, number of images to include in the first registration pass
ops0.nimgbegend = 100; % was 250, frames to average at beginning and end of blocks
ops0.nonrigid = 0; % IHB added

The dataset I just tested that failed is 767x767 pixels, x 881 frames, 16-bit TIF.
The programme reported:


running rigid registration
bi-directional scanning offset = 0 pixels
Set 1, tiff 1 done in time 50.96
-0.2000 0 0 0.1000


  • Isaac

from suite2p.

carsen-stringer avatar carsen-stringer commented on August 30, 2024

What are your ops.Ly and ops.Lx? Are they 767?

from suite2p.

swift505 avatar swift505 commented on August 30, 2024

@carsen-stringer
ops1.Lx and ops1.Ly are 767, yes.
(The command I'm running is ops1 = reg2P(ops);
ops itself doesn't seem to have an Lx/Ly field so I assume these are added by the registration function.)

from suite2p.

carsen-stringer avatar carsen-stringer commented on August 30, 2024

Can you host this tiff on dropbox or google drive and share it with me ([email protected])? Sorry I don't know where the script is failing

from suite2p.

carsen-stringer avatar carsen-stringer commented on August 30, 2024

the error could not be replicated

from suite2p.

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.