{"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/python-workflow-for-segmenting-multiphase","title":"Python workflow for segmenting multiphase flow in porous rocks","arxiv_id":"2410.18937","date":"2024-10-24","proceeding":null,"authors":["Catherine Spurin","Sharon Ellman","Dane Sherburn","Tom Bultreys","Hamdi A. Tchelepi"],"abstract":"X-ray micro-computed tomography (X-ray micro-CT) is widely employed to investigate flow phenomena in porous media, providing a powerful alternative to core-scale experiments for estimating traditional petrophysical properties such as porosity, single-phase permeability or fluid connectivity. However, the segmentation process, critical for deriving these properties from greyscale images, varies significantly between studies due to the absence of a standardized workflow or any ground truth data. This introduces challenges in comparing results across different studies, especially for properties sensitive to segmentation. To address this, we present a fully open-source, automated workflow for the segmentation of a Bentheimer sandstone filled with nitrogen and brine. The workflow incorporates a traditional image processing pipeline, including non-local means filtering, image registration, watershed segmentation of grains, and a combination of differential imaging and thresholding for segmentation of the fluid phases. Our workflow enhances reproducibility by enabling other research groups to easily replicate and validate findings, fostering consistency in petrophysical property estimation. Moreover, its modular structure facilitates integration into modeling frameworks, allowing for forward-backward communication and parameter sensitivity analyses. We apply the workflow to exploring the sensitivity of the non-wetting phase volume, surface area, and connectivity to image processing. This adaptable tool paves the way for future advancements in X-ray micro-CT analysis of porous media.","url_abs":"https://arxiv.org/abs/2410.18937v2","url_pdf":"https://arxiv.org/pdf/2410.18937v2.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":"links_only","authors_date_abstract":"arXiv metadata, CC0 1.0 (https://info.arxiv.org/help/license), from the Kaggle arXiv metadata snapshot of 2026-09-12"},"code_links":[{"paper_slug":"python-workflow-for-segmenting-multiphase","repo_url":"https://github.com/cspurin/image_processing","is_official":1,"mentioned_in_paper":0,"mentioned_in_github":0,"framework":"none","reach":{"status":"ok"}}],"tasks":[],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"syntology_url":null,"atlas_url":"https://app.syntology.ai/?focus=2410.18937","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2410.18937"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-24T18:15:14+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/cspurin/image_processing","reach":{"status":"ok"}}],"summary":{"unverified":3},"by_repo_kind":{"official":{"samples":3,"ran":0,"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":3,"samples":[{"code_sha256_prefix":"e49e8d27e1d125db","entry":"load","repo":"cspurin/image_processing","repo_kind":"official","path":"utils.py","file_url":"https://github.com/cspurin/image_processing/blob/HEAD/utils.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":"e49e8d27e1d125db"}},{"code_sha256_prefix":"4d6926c81c636616","entry":"mask_with_dry","repo":"cspurin/image_processing","repo_kind":"official","path":"utils.py","file_url":"https://github.com/cspurin/image_processing/blob/HEAD/utils.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":"4d6926c81c636616"}},{"code_sha256_prefix":"2972faff8c7fcad2","entry":"preprocess","repo":"cspurin/image_processing","repo_kind":"official","path":"utils.py","file_url":"https://github.com/cspurin/image_processing/blob/HEAD/utils.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":"2972faff8c7fcad2"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}