{"id":16841361,"url":"https://github.com/gmelodie/silentmoire","last_synced_at":"2025-10-07T21:50:11.615Z","repository":{"id":43574305,"uuid":"186718964","full_name":"gmelodie/silentMoire","owner":"gmelodie","description":"Moiré pattern denoiser for screen pictures","archived":false,"fork":false,"pushed_at":"2021-03-26T18:40:49.000Z","size":15035,"stargazers_count":55,"open_issues_count":3,"forks_count":15,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-18T08:22:24.950Z","etag":null,"topics":["denoising","image-processing","moire","numpy","python3"],"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/gmelodie.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}},"created_at":"2019-05-15T00:14:10.000Z","updated_at":"2025-03-03T08:20:11.000Z","dependencies_parsed_at":"2022-09-14T21:50:25.325Z","dependency_job_id":null,"html_url":"https://github.com/gmelodie/silentMoire","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gmelodie%2FsilentMoire","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gmelodie%2FsilentMoire/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gmelodie%2FsilentMoire/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gmelodie%2FsilentMoire/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gmelodie","download_url":"https://codeload.github.com/gmelodie/silentMoire/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244912800,"owners_count":20530764,"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","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":["denoising","image-processing","moire","numpy","python3"],"created_at":"2024-10-13T12:41:39.257Z","updated_at":"2025-10-07T21:50:11.499Z","avatar_url":"https://github.com/gmelodie.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"# silentMoire\n\nMoiré pattern denoiser for scanned photos\n\n\n## The problem (or Abstract)\n\nWhenever you try to take a picture of a screen or monitor they always end up with some weird patterns. These patterns, the Moiré patterns, can be removed by using image restoration techniques. The aim of this project is to create an application that allows you to easily denoise your scanned pictures in order to remove this types of patterns.\n\n## In other words...\n\nYou are too lazy to take a proper screenshot of your screen. You see your phone nearby and decide to do the most stupid thing ever: take a pic of your screen with your phone. You end up with this:\n\n![Noisy photo](https://user-images.githubusercontent.com/23103524/57874836-d8cd6180-77e7-11e9-8cda-cdf32e0b2f82.png)\n\nWe've all been there, enter silentMoire: using silentMoire you should be able to restore the image back to something more like the original picture:\n\n![Restored photo](https://user-images.githubusercontent.com/23103524/57874787-c6ebbe80-77e7-11e9-899e-c72f5756e1df.png)\n\n(Example images are inside the images folder)\n\n## Moiré Patterns\nA moiré pattern is an interference pattern created when an observer observes through two overlapping periodic structures, in our case it ocours when someone tries to take a picture of a screen or monitor.\nFor this project we have decided to remove horizontal and vertical Moiré patterns.\n\n## Techniques\n\n### Noising\nTaking pictures containing Moiré patterns can be quite difficult, as it depends a lot on your camera and the refresh rate of your monitor. Because of that, the patterns will be artificially generated, adding black vertical, horizontal and/or diagonal lines in the image. It is important to notice that the images used will be in grayscale.\n\n### Denoising (with example)\nRemoving the Moiré pattern from the image is based on changing the domain of the image using the Fast Fourier Transform. \n\n![Example image](https://user-images.githubusercontent.com/23103524/60060175-cdfacc00-96c5-11e9-9ca0-bb7cb03d0054.jpg)\n![Example fourier](https://user-images.githubusercontent.com/23103524/60060476-28e0f300-96c7-11e9-8e31-9f5d30fbb73b.png)\n\nThen, three options of filters can be chosen to denoise: a low-pass filter (used in the example), a bandstop filter using threshold and a simple cut on the noise spectre. One or more filters are applied on the shifted Fourier of the noisy image, removing noises, verified to appear on the edges of the shifted Fourier image. The filter and filtered image can be seen below.\n\n![Low-pass filter](https://user-images.githubusercontent.com/23103524/60060167-bde2ec80-96c5-11e9-8a04-4ec8a5c96bef.jpg)\n![Filtered fourier](https://user-images.githubusercontent.com/23103524/60060475-267e9900-96c7-11e9-9313-e55062442521.png)\n\nThe original image essential frequencies are kept, denoising it back to the original (almost).\n\n![Denoised](https://user-images.githubusercontent.com/23103524/60060190-e10d9c00-96c5-11e9-97cb-03a1f6e396ec.jpg)\n\n## Code\nThere is a step-by-step example on a [Jupyter Notebook](https://github.com/gmelodie/silentMoire/blob/master/report.ipynb) inside this repo.\nYou can also run the all.py document to see some images and results.\n\n## Run yourself\nIf you want to run the script yourself, simply execute\n`python silent.py \u003cINPUT IMAGE\u003e`\non the project root folder e follow the steps to apply some noise and denoise the image. Images are shown to accompany you through the process.\n\n## Images source\nAll the images used in this project were taken from [Pexels](https://www.pexels.com/) and [Unsplash](https://unsplash.com/).\n\n## Authors\n\n- Gabriel de Melo Cruz\n- Murilo Baldi\n- Rafael Amaro Rolfsen\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgmelodie%2Fsilentmoire","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgmelodie%2Fsilentmoire","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgmelodie%2Fsilentmoire/lists"}