{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/unleashing-the-power-of-prompt-driven-nucleus","title":"Unleashing the Power of Prompt-driven Nucleus Instance Segmentation","arxiv_id":"2311.15939","date":"2023-11-27","proceeding":null,"authors":["Zhongyi Shui","Yunlong Zhang","Kai Yao","Chenglu Zhu","Sunyi Zheng","Jingxiong Li","Honglin Li","Yuxuan Sun","Ruizhe Guo","Lin Yang"],"abstract":"Nucleus instance segmentation in histology images is crucial for a broad spectrum of clinical applications. Current dominant algorithms rely on regression of nuclear proxy maps. Distinguishing nucleus instances from the estimated maps requires carefully curated post-processing, which is error-prone and parameter-sensitive. Recently, the Segment Anything Model (SAM) has earned huge attention in medical image segmentation, owing to its impressive generalization ability and promptable property. Nevertheless, its potential on nucleus instance segmentation remains largely underexplored. In this paper, we present a novel prompt-driven framework that consists of a nucleus prompter and SAM for automatic nucleus instance segmentation. Specifically, the prompter learns to generate a unique point prompt for each nucleus while the SAM is fine-tuned to output the corresponding mask for the prompted nucleus. Furthermore, we propose the inclusion of adjacent nuclei as negative prompts to enhance the model's capability to identify overlapping nuclei. Without complicated post-processing, our proposed method sets a new state-of-the-art performance on three challenging benchmarks. Code is available at \\url{github.com/windygoo/PromptNucSeg}","url_abs":"https://arxiv.org/abs/2311.15939v4","url_pdf":"https://arxiv.org/pdf/2311.15939v4.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"abstracts"},"code_links":[{"paper_slug":"unleashing-the-power-of-prompt-driven-nucleus","repo_url":"https://github.com/windygoo/promptnucseg","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":0,"framework":"pytorch","reach":{"status":"ok"}}],"tasks":[{"task_slug":"image-segmentation","task_name":"Image Segmentation"},{"task_slug":"instance-segmentation","task_name":"Instance Segmentation"},{"task_slug":"medical-image-segmentation","task_name":"Medical Image Segmentation"},{"task_slug":"segmentation","task_name":"Segmentation"},{"task_slug":"semantic-segmentation","task_name":"Semantic Segmentation"}],"methods":[{"method_slug":"sam","method_name":"SAM"}],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"syntology_url":"https://syntology.ai/paper/2311.15939","atlas_url":"https://app.syntology.ai/?focus=2311.15939","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2311.15939"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-25T09:33:49+00:00","read_at_is":"when the build read Syntology's graph, not when any sample ran","claim":"Per-sample execution status on synthesized fixtures; not a correctness claim about the paper. Samples come from repositories linked to the paper, official or community; repo_kind says which.","repos":[{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/windygoo/promptnucseg","reach":{"status":"ok"}}],"summary":{"ran":11,"unverified":3},"by_repo_kind":{"official":{"samples":14,"ran":11,"repositories":1}},"repo_kind_vocabulary":{"official":"The archive marks this repository official for the paper","named_in_paper":"The archive records that the paper mentions this repository; it is not marked official","listed":"In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper","found_in_text":"Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted","community":"Not in the archive's code links for this paper; a community repository Syntology harvested"},"n_pointer_only_for_licence":14,"samples":[{"code_sha256_prefix":"2bf7181c523e6a5a","entry":"add_k_nearest_neg_prompt","repo":"windygoo/promptnucseg","repo_kind":"official","path":"segmentor/dataset.py","file_url":"https://github.com/windygoo/promptnucseg/blob/HEAD/segmentor/dataset.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"2bf7181c523e6a5a"}},{"code_sha256_prefix":"345f34217e670c58","entry":"all_gather","repo":"windygoo/promptnucseg","repo_kind":"official","path":"prompter/utils.py","file_url":"https://github.com/windygoo/promptnucseg/blob/HEAD/prompter/utils.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"345f34217e670c58"}},{"code_sha256_prefix":"25b255590a9b6953","entry":"average_precision","repo":"windygoo/promptnucseg","repo_kind":"official","path":"prompter/eval_map.py","file_url":"https://github.com/windygoo/promptnucseg/blob/HEAD/prompter/eval_map.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"25b255590a9b6953"}},{"code_sha256_prefix":"fe36c94f386077f0","entry":"build_matcher","repo":"windygoo/promptnucseg","repo_kind":"official","path":"prompter/matcher.py","file_url":"https://github.com/windygoo/promptnucseg/blob/HEAD/prompter/matcher.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"fe36c94f386077f0"}},{"code_sha256_prefix":"6b6d0130e0b7d88b","entry":"get_cls_results","repo":"windygoo/promptnucseg","repo_kind":"official","path":"prompter/eval_map.py","file_url":"https://github.com/windygoo/promptnucseg/blob/HEAD/prompter/eval_map.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"6b6d0130e0b7d88b"}},{"code_sha256_prefix":"70765b7c58186014","entry":"get_fast_aji","repo":"windygoo/promptnucseg","repo_kind":"official","path":"segmentor/stats_utils.py","file_url":"https://github.com/windygoo/promptnucseg/blob/HEAD/segmentor/stats_utils.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"70765b7c58186014"}},{"code_sha256_prefix":"c0c70cc921312da1","entry":"get_fast_aji_plus","repo":"windygoo/promptnucseg","repo_kind":"official","path":"segmentor/stats_utils.py","file_url":"https://github.com/windygoo/promptnucseg/blob/HEAD/segmentor/stats_utils.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"c0c70cc921312da1"}},{"code_sha256_prefix":"3e8b7f0f9b9b649c","entry":"get_fast_pq","repo":"windygoo/promptnucseg","repo_kind":"official","path":"segmentor/stats_utils.py","file_url":"https://github.com/windygoo/promptnucseg/blob/HEAD/segmentor/stats_utils.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"3e8b7f0f9b9b649c"}},{"code_sha256_prefix":"1a2dd91846e5da32","entry":"read_from_json","repo":"windygoo/promptnucseg","repo_kind":"official","path":"prompter/dataset.py","file_url":"https://github.com/windygoo/promptnucseg/blob/HEAD/prompter/dataset.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"1a2dd91846e5da32"}},{"code_sha256_prefix":"4ee45d4623a1e346","entry":"reduce_across_processes","repo":"windygoo/promptnucseg","repo_kind":"official","path":"prompter/utils.py","file_url":"https://github.com/windygoo/promptnucseg/blob/HEAD/prompter/utils.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"4ee45d4623a1e346"}},{"code_sha256_prefix":"0f432e22853a1915","entry":"reduce_dict","repo":"windygoo/promptnucseg","repo_kind":"official","path":"prompter/utils.py","file_url":"https://github.com/windygoo/promptnucseg/blob/HEAD/prompter/utils.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"0f432e22853a1915"}},{"code_sha256_prefix":"4886db9ff74b073b","entry":"load_maskfile","repo":"windygoo/promptnucseg","repo_kind":"official","path":"segmentor/dataset.py","file_url":"https://github.com/windygoo/promptnucseg/blob/HEAD/segmentor/dataset.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"4886db9ff74b073b"}},{"code_sha256_prefix":"4c64f043751302c9","entry":"tpfp_default","repo":"windygoo/promptnucseg","repo_kind":"official","path":"prompter/eval_map.py","file_url":"https://github.com/windygoo/promptnucseg/blob/HEAD/prompter/eval_map.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"4c64f043751302c9"}},{"code_sha256_prefix":"aacd1d8b1a114829","entry":"train_one_epoch","repo":"windygoo/promptnucseg","repo_kind":"official","path":"prompter/engine.py","file_url":"https://github.com/windygoo/promptnucseg/blob/HEAD/prompter/engine.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"aacd1d8b1a114829"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}