choosehappy / QuickAnnotator

An open-source digital pathology based rapid image annotation tool
BSD 3-Clause Clear License
74 stars 27 forks source link

Getting rollback error when dropping an svs file for patch creation #16

Closed darshats closed 2 years ago

darshats commented 2 years ago

Hi, First of all thank you for creating this wonderful utility that speeds the workflow from UI--->GPU-->UI. It is perfect, and really nice to see features like intelligent patch suggestion. Kudos! I hope it will work for me.

I installed in a new conda environment and started the app. Then connecting to port 5555, created a project and tried to drop a file. Thats when I see this error in the logs (the file drop is not successful). These are the last few lines in the log. Any pointers what might be wrong?

I tried the docker route too, but there is some error with that also.

Thanks, Darshat

FROM job WHERE job."projId" = ? AND job."imageId" IS NULL AND job.cmd = ? AND job.status IN (?, ?) LIMIT ? OFFSET ? 2022-01-27 21:24:21,420 [INFO] ('1', 'make_embed', 'RUNNING', 'QUEUE', 1, 0) 2022-01-27 21:24:21,426 [INFO] SELECT count() AS count_1 FROM (SELECT job.id AS job_id, job."projId" AS "job_projId", job."imageId" AS "job_imageId", job.cmd AS job_cmd, job.params AS job_params, job.status AS job_status, job.retval AS job_retval, job.start_date AS job_start_date FROM job WHERE job."projId" = ? AND job."imageId" IS NULL AND job.cmd = ? AND job.status IN (?, ?) ORDER BY job.id ASC LIMIT ? OFFSET ?) AS anon_1 2022-01-27 21:24:21,426 [INFO] ('1', 'make_embed', 'RUNNING', 'QUEUE', 1, 0) 2022-01-27 21:24:21,427 [INFO] ROLLBACK*

choosehappy commented 2 years ago

Thanks for your interest in our tool!

The subject of your issue is a bit curious: "dropping an svs file", as quick annotator does not yet support SVS files directly : )

You should extract the associated tiles as png/tif and upload those; we provide a script for exactly this purpose.

Have you seen this part of the wiki? https://github.com/choosehappy/QuickAnnotator/wiki/Image-List-Page

On Thu, Jan 27, 2022 at 9:04 AM darshats @.***> wrote:

Hi, First of all thank you for creating this wonderful utility that speeds the workflow from UI--->GPU-->UI. It is perfect, and really nice to see features like intelligent patch suggestion. Kudos! I hope it will work for me.

I installed in a new conda environment and started the app. Then connecting to port 5555, created a project and tried to drop a file. Thats when I see this error in the logs (the file drop is not successful). These are the last few lines in the log. Any pointers what might be wrong?

I tried the docker route too, but there is some error with that also.

Thanks, Darshat

FROM job WHERE job."projId" = ? AND job."imageId" IS NULL AND job.cmd = ? AND job.status IN (?, ?) LIMIT ? OFFSET ? 2022-01-27 21:24:21,420 [INFO] ('1', 'make_embed', 'RUNNING', 'QUEUE', 1, 0) 2022-01-27 21:24:21,426 [INFO] SELECT count() AS count_1 FROM (SELECT job.id AS job_id, job."projId" AS "job_projId", job."imageId" AS "job_imageId", job.cmd AS job_cmd, job.params AS job_params, job.status AS job_status, job.retval AS job_retval, job.start_date AS job_start_date FROM job WHERE job."projId" = ? AND job."imageId" IS NULL AND job.cmd = ? AND job.status IN (?, ?) ORDER BY job.id ASC LIMIT ? OFFSET ?) AS anon_1 2022-01-27 21:24:21,426 [INFO] ('1', 'make_embed', 'RUNNING', 'QUEUE', 1, 0) 2022-01-27 21:24:21,427 [INFO] ROLLBACK*

— Reply to this email directly, view it on GitHub https://github.com/choosehappy/QuickAnnotator/issues/16, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACJ3XTDOVAMFQZ6L2QUOH3DUYFUIZANCNFSM5M6LFHBQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you are subscribed to this thread.Message ID: @.***>

darshats commented 2 years ago

Great, I'm happy to know its not some version issue. I will try this out and revert back. Thanks for your prompt response!

darshats commented 2 years ago

It is working now. This is a great tool! It allows to reuse all the IP we have in python with a minimal setup. Code is neatly factored, and the db based workflow engine is really perfect to bridge UI to GPU. I did realize that it doesnt support multi category annotations which will be restrictive. Is there any plan to update this so we can annotate more than one class type?

choosehappy commented 2 years ago

Thanks for the feedback!

Multi-class is somewhere on our development list, but it will be an undertaking and we're waiting to see how well adoption of the tool is to determine if the investment is worthwhile

Practically speaking, my preference lately has in fact been to make numerous binary classifiers (1 vs all), i.e., 1 "segmentor" per target class.

The logic there is multi-fold: 1) its easier to lock down a single classifier when it works, and then move on to the next class without impacting the first class 2) training tends to be faster and converge more quickly 3) usually the best way to improve the model requires getting more samples of a specific sample, and "fully annotating" each every ROI for each multi-class quickly becomes onerous. If one only annotates one class and labels the rest as "unknown", this would work but very quickly you end up with a large amount of computation time which isn't involved in backpropogation, leading to 100h of training time that could have been equally accomplished with 1-2hs of a targeted model 4) when (eventually) someone wants to add yet another class to their dataset, instead of fully retraining a large model with a large dataset in a multi-class situation, they only need to train a smaller model (since less complexity is involved in detecting a single class), with less data, and can do it more quickly without "disturbing" previously validated models

Some quick thoughts, but this is the motivation of why quick annotator was initially designed to use a single class instead of multi class