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

Where can I save the segmentation results separately #294

Closed
wangk98 opened this issue May 5, 2022 Discussed in #88 · 12 comments
Closed

Where can I save the segmentation results separately #294

wangk98 opened this issue May 5, 2022 Discussed in #88 · 12 comments
Assignees
Milestone

Comments

@wangk98
Copy link

wangk98 commented May 5, 2022

sorry to bother you ! Where can I save the segmentation results separately?Because I want to get the specific coordinates of the defect. And I can't find the presion and recall, I also want to output them.

@djdameln djdameln self-assigned this May 13, 2022
@djdameln djdameln added this to the v0.3.2 milestone May 13, 2022
@samet-akcay
Copy link
Contributor

samet-akcay commented May 16, 2022

@wangk98, PR #298 would potentially addresses your issue. Once merged, we could add some documentation

@samet-akcay
Copy link
Contributor

Regarding setting different metrics, you could modify the configuration as follows:
image

@samet-akcay
Copy link
Contributor

@wangk98, regarding the segmenttaion results, do you want the segmentation mask to be saved separately? Or would like to have access to the annotations from the inferencer?

@nguyenanhtuan1008
Copy link

nguyenanhtuan1008 commented Jul 12, 2022

@samet-akcay when running python tools/inference.py we can get the result that looks like
image(1st image)
But we would want to have an option for getting the segmentation result also (without overlay), it looks like below:
image(2nd image)
There is an argument: "--overlay_mask" in inference.py but when I set it to True then it will be saved as a result with both overlay and segmentation.
image(3rd image)

We would also get segmentation results (like as 2nd image) when running inference.
Could you tell us how to do it?

@wangk98
Copy link
Author

wangk98 commented Jul 12, 2022

@wangk98, regarding the segmenttaion results, do you want the segmentation mask to be saved separately? Or would like to have access to the annotations from the inferencer?

yes, I want the segmentation mask to be saved separately. If possible, I would also like to be able to plot the PR curve and AUC curve directly

@samet-akcay
Copy link
Contributor

yes, I want the segmentation mask to be saved separately. If possible, I would also like to be able to plot the PR curve and AUC curve directly

You could follow PR #429 for metric visualization

@samet-akcay
Copy link
Contributor

@nguyenanhtuan1008, have you tried the new inference? If you use tools/inference/lightning_inference.py, you could get that output. For instance, this is what I get when I use the new lightning inference
000

@samet-akcay
Copy link
Contributor

Closing this due to inactivity. Fee free to re-open if you still encounter any issues.

@FaDavid98
Copy link

For me the tools/inference/lightning_inference.py won't work with cflow model

@samet-akcay
Copy link
Contributor

Could be related to #568. I'll check it out

@FaDavid98
Copy link

FaDavid98 commented Sep 26, 2022

I am getting this error, while running lightning_inference.py with cflow model
in superimpose_anomaly_map
superimposed_map = cv2.addWeighted(anomaly_map, alpha, image, (1 - alpha), gamma)
cv2.error: OpenCV(4.6.0) /io/opencv/modules/core/src/arithm.cpp:647: error: (-209:Sizes of input arguments do not match) The operation is neither 'array op array' (where arrays have the same size and the same number of channels), nor 'array op scalar', nor 'scalar op array' in function 'arithm_op'

Predicting DataLoader 0: 0%| | 0/1 [00:00<?, ?it/s]

@samet-akcay
Copy link
Contributor

I've just checked. This issue is related to #568. You could follow the progress there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants