{"id":19899144,"url":"https://github.com/tootouch/memseg","last_synced_at":"2025-10-29T05:44:39.315Z","repository":{"id":82294400,"uuid":"559731755","full_name":"TooTouch/MemSeg","owner":"TooTouch","description":"Unofficial re-implementation of MemSeg for Anomaly Detection","archived":false,"fork":false,"pushed_at":"2024-06-24T02:20:33.000Z","size":10950,"stargazers_count":195,"open_issues_count":7,"forks_count":31,"subscribers_count":5,"default_branch":"main","last_synced_at":"2025-04-13T08:21:32.192Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/TooTouch.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-10-31T01:10:58.000Z","updated_at":"2025-04-10T16:47:58.000Z","dependencies_parsed_at":null,"dependency_job_id":"ecce4958-5b2c-43bc-97e7-c41dc5b3b500","html_url":"https://github.com/TooTouch/MemSeg","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/TooTouch/MemSeg","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TooTouch%2FMemSeg","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TooTouch%2FMemSeg/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TooTouch%2FMemSeg/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TooTouch%2FMemSeg/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TooTouch","download_url":"https://codeload.github.com/TooTouch/MemSeg/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TooTouch%2FMemSeg/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":269366853,"owners_count":24405250,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-08T02:00:09.200Z","response_time":72,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-12T20:07:19.288Z","updated_at":"2025-10-29T05:44:39.251Z","avatar_url":"https://github.com/TooTouch.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"# MemSeg\nUnofficial re-implementation for [MemSeg: A semi-supervised method for image surface defect detection using differences and commonalities](https://arxiv.org/abs/2205.00908)\n\n# Environments\n\n- Docker image: nvcr.io/nvidia/pytorch:20.12-py3\n\n```\neinops==0.5.0\ntimm==0.5.4\nwandb==0.12.17\nomegaconf\nimgaug==0.4.0\n```\n\n\n# Process\n\n## 1. Anomaly Simulation Strategy \n\n- [notebook](https://github.com/TooTouch/MemSeg/blob/main/%5Bexample%5D%20anomaly_simulation_strategy.ipynb)\n- Describable Textures Dataset(DTD) [ [download](https://www.google.com/search?q=dtd+texture+dataset\u0026rlz=1C5CHFA_enKR999KR999\u0026oq=dtd+texture+dataset\u0026aqs=chrome..69i57j69i60.2253j0j7\u0026sourceid=chrome\u0026ie=UTF-8) ]\n\n\u003cp align='center'\u003e\n    \u003cimg width='700' src='https://user-images.githubusercontent.com/37654013/198960273-ba763f40-6b30-42e3-ab2c-a8e632df63e9.png'\u003e\n\u003c/p\u003e\n\n## 2. Model Process \n\n- [notebook](https://github.com/TooTouch/MemSeg/blob/main/%5Bexample%5D%20model%20overview.ipynb)\n\n\u003cp align='center'\u003e\n    \u003cimg width='1500' src='https://user-images.githubusercontent.com/37654013/198960086-fdbf39df-f680-4510-b94b-48341836f960.png'\u003e\n\u003c/p\u003e\n\n\n# Run\n\n**Example**\n\n```bash\npython main.py configs=configs.yaml DATASET.target=bottle\n```\n\n## Demo\n\n```\nvoila \"[demo] model inference.ipynb\" --port ${port} --Voila.ip ${ip}\n```\n\n![](https://github.com/TooTouch/MemSeg/blob/main/assets/memseg.gif)\n\n# Results\n\n- **Backbone**: ResNet18\n\n| target     |   AUROC-image |   AUROC-pixel |   AUPRO-pixel |\n|:-----------|--------------:|--------------:|--------------:|\n| leather    |        100    |         98.83 |         99.09 |\n| pill       |         97.05 |         98.29 |         97.96 |\n| carpet     |         99.12 |         97.54 |         97.02 |\n| hazelnut   |        100    |         97.78 |         99    |\n| tile       |         99.86 |         99.38 |         98.81 |\n| cable      |         92.5  |         82.3  |         87.31 |\n| toothbrush |        100    |         99.28 |         98.56 |\n| transistor |         96.5  |         76.29 |         86.06 |\n| zipper     |         99.95 |         97.94 |         97.26 |\n| metal_nut  |         99.46 |         88.48 |         95    |\n| grid       |         99.83 |         98.37 |         98.53 |\n| bottle     |        100    |         98.79 |         98.36 |\n| capsule    |         95.41 |         98.43 |         97.73 |\n| screw      |         94.86 |         95.08 |         94    |\n| wood       |        100    |         97.54 |         97.62 |\n| **Average**    |         98.3  |         94.96 |         96.15 |\n\n# Citation\n\n```\n@article{DBLP:journals/corr/abs-2205-00908,\n  author    = {Minghui Yang and\n               Peng Wu and\n               Jing Liu and\n               Hui Feng},\n  title     = {MemSeg: {A} semi-supervised method for image surface defect detection\n               using differences and commonalities},\n  journal   = {CoRR},\n  volume    = {abs/2205.00908},\n  year      = {2022},\n  url       = {https://doi.org/10.48550/arXiv.2205.00908},\n  doi       = {10.48550/arXiv.2205.00908},\n  eprinttype = {arXiv},\n  eprint    = {2205.00908},\n  timestamp = {Tue, 03 May 2022 15:52:06 +0200},\n  biburl    = {https://dblp.org/rec/journals/corr/abs-2205-00908.bib},\n  bibsource = {dblp computer science bibliography, https://dblp.org}\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftootouch%2Fmemseg","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftootouch%2Fmemseg","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftootouch%2Fmemseg/lists"}