Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SpotsDetector parameters not being validated correctly #29

Open
lacan opened this issue Feb 4, 2021 · 3 comments
Open

SpotsDetector parameters not being validated correctly #29

lacan opened this issue Feb 4, 2021 · 3 comments
Labels
bug Something isn't working

Comments

@lacan
Copy link
Member

lacan commented Feb 4, 2021

2 things

  1. Detecting spots with auto threshold does not work. need to define manual threshold even if we do not use it
def spots = EasyXT.Spots.create(1)
        .setDiameterXYZ(0.310, 0.620)
        .isRegionsFromLocalContrast(true)
        .isSubtractBackground(true)
        .setFilter("\"Quality\" above 50.0")
        .isRegionsSpotsDiameterFromVolume(true)
        .isCreateRegionsChannel(false)
        .enableRegionsThresholdAutomatic()
        .build().detect()

Gives error: SpotsDetector : Please specify all parameters!

def spots = EasyXT.Spots.create(1)
        .setDiameterXYZ(0.310, 0.620)
        .isRegionsFromLocalContrast(true)
        .isSubtractBackground(true)
        .setFilter("\"Quality\" above 50.0")
        .isRegionsSpotsDiameterFromVolume(true)
        .isCreateRegionsChannel(false)
        .setRegionsThresholdManual(0) // ADDING THIS
        .enableRegionsThresholdAutomatic()
        .build().detect()

Now works

Same for aRegionsCreateChannel. if it is null, it gets set to a defualt but still throws an error...

@lacan lacan added the bug Something isn't working label Feb 4, 2021
@romainGuiet
Copy link
Member

romainGuiet commented Feb 8, 2021

for aRegionsCreateChannel. if it is null, it gets set to a defualt but still throws an error...

that's what you asked for, isn't it ?

if (this.aRegionsCreateChannel == null) {
                    this.aRegionsCreateChannel = false; // it useless (as far as we know) and set to false by default imaris wizard
                    log.accept("aRegionsCreateChannel was set to false (Default Imaris behaviour), use isCreateRegionChannel(boolean flag) to change its status!");
                    throwError = true;
}

@romainGuiet
Copy link
Member

romainGuiet commented Feb 8, 2021

Detecting spots with auto threshold does not work. need to define manual threshold

Never tested it as I never use auto threshold in Imaris

@lacan
Copy link
Member Author

lacan commented Feb 8, 2021

Yes but it should not throw an error and jsut continue processing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants