{"id":34077423,"url":"https://github.com/mamdasn/im2dhisteq","last_synced_at":"2025-12-14T10:03:55.380Z","repository":{"id":41541740,"uuid":"354757680","full_name":"Mamdasn/im2dhisteq","owner":"Mamdasn","description":"This module attempts to enhance contrast of a given image by equalizing its two dimensional histogram.","archived":false,"fork":false,"pushed_at":"2024-03-11T15:27:51.000Z","size":34831,"stargazers_count":27,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-09-19T16:48:26.946Z","etag":null,"topics":["2dhist","contrast-enhancement","hist2d","histogram","histogram-equalization","im2dhisteq","image-contrast-enhancement","image-processing","imhist","python","two-dimensional-histogram"],"latest_commit_sha":null,"homepage":"https://pypi.org/project/im2dhisteq/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Mamdasn.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":"2021-04-05T07:44:48.000Z","updated_at":"2025-07-08T07:09:24.000Z","dependencies_parsed_at":"2024-01-27T23:28:32.464Z","dependency_job_id":"2136f84d-c3fa-4577-a7ce-84acbd347b9b","html_url":"https://github.com/Mamdasn/im2dhisteq","commit_stats":{"total_commits":81,"total_committers":3,"mean_commits":27.0,"dds":"0.11111111111111116","last_synced_commit":"d31c815c9679b8afe7eaa492a4e2f1655c3fc1c9"},"previous_names":[],"tags_count":15,"template":false,"template_full_name":null,"purl":"pkg:github/Mamdasn/im2dhisteq","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Mamdasn%2Fim2dhisteq","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Mamdasn%2Fim2dhisteq/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Mamdasn%2Fim2dhisteq/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Mamdasn%2Fim2dhisteq/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Mamdasn","download_url":"https://codeload.github.com/Mamdasn/im2dhisteq/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Mamdasn%2Fim2dhisteq/sbom","scorecard":{"id":89159,"data":{"date":"2025-08-11","repo":{"name":"github.com/Mamdasn/im2dhisteq","commit":"d6e2f19fb75bec2dc84f37e5b4f8ba6e344d882e"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.7,"checks":[{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Token-Permissions","score":10,"reason":"GitHub workflow tokens follow principle of least privilege","details":["Info: topLevel 'contents' permission set to 'read': .github/workflows/python-publish.yml:8","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Code-Review","score":0,"reason":"Found 0/30 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/python-publish.yml:16: update your workflow using https://app.stepsecurity.io/secureworkflow/Mamdasn/im2dhisteq/python-publish.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/python-publish.yml:19: update your workflow using https://app.stepsecurity.io/secureworkflow/Mamdasn/im2dhisteq/python-publish.yml/main?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/python-publish.yml:39: update your workflow using https://app.stepsecurity.io/secureworkflow/Mamdasn/im2dhisteq/python-publish.yml/main?enable=pin","Warn: pipCommand not pinned by hash: .github/workflows/python-publish.yml:25","Info:   0 out of   2 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   1 third-party GitHubAction dependencies pinned","Info:   0 out of   1 pipCommand dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: GNU General Public License v3.0: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":0,"reason":"Project has not signed or included provenance with any releases.","details":["Warn: release artifact v1.1.0 not signed: https://api.github.com/repos/Mamdasn/im2dhisteq/releases/142466000","Warn: release artifact v1.0.12 not signed: https://api.github.com/repos/Mamdasn/im2dhisteq/releases/135478134","Warn: release artifact v1.1.0 does not have provenance: https://api.github.com/repos/Mamdasn/im2dhisteq/releases/142466000","Warn: release artifact v1.0.12 does not have provenance: https://api.github.com/repos/Mamdasn/im2dhisteq/releases/135478134"],"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'main'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Vulnerabilities","score":7,"reason":"3 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-qr4w-53vh-m672","Warn: Project is vulnerable to: PYSEC-2023-183","Warn: Project is vulnerable to: GHSA-g7vv-2v7x-gj9p"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-15T07:33:27.181Z","repository_id":41541740,"created_at":"2025-08-15T07:33:27.181Z","updated_at":"2025-08-15T07:33:27.181Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":27725940,"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-12-14T02:00:11.348Z","response_time":56,"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":["2dhist","contrast-enhancement","hist2d","histogram","histogram-equalization","im2dhisteq","image-contrast-enhancement","image-processing","imhist","python","two-dimensional-histogram"],"created_at":"2025-12-14T10:03:54.243Z","updated_at":"2025-12-14T10:03:55.372Z","avatar_url":"https://github.com/Mamdasn.png","language":"Python","readme":"[![PyPI Latest Release](https://img.shields.io/pypi/v/im2dhisteq.svg)](https://pypi.org/project/im2dhisteq/) [![Package Status](https://img.shields.io/pypi/status/im2dhisteq.svg)](https://pypi.org/project/im2dhisteq/) [![Downloads](https://pepy.tech/badge/im2dhisteq)](https://pepy.tech/project/im2dhisteq) [![License](https://img.shields.io/pypi/l/im2dhisteq.svg)](https://github.com/Mamdasn/im2dhisteq/blob/main/LICENSE) ![Repository Size](https://img.shields.io/github/repo-size/mamdasn/im2dhisteq)\r\n\r\n# im2dhisteq\r\nThis module attempts to enhance contrast of a given image by equalizing its two dimensional histogram. An easy way to enhance quality of a given image is to just equalize its histogram, but despite using minimum resources and a very short process time, there are a lot of drawbacks to it.\r\nOne of the ways to tackle drawbacks of `histogram equalization method` is to instead equalize the image's `two dimensional histogram`, as one dimensional histogram of a given image does not contain the image's contextual information. Tests on a multitude of images has shown, by taking contextual information of an image in addition to the image's histogram into account when attempting to enhance contrast, output images are significantly better in quality in compare to histogram equalizaion and a handful of other known methods.\r\n\r\nYou can access the article that came up with this method [here](https://www.researchgate.net/publication/256822485_Two-dimensional_histogram_equalization_and_contrast_enhancement).\r\n\r\n## Two Dimensional Histogram\r\n[Here](https://github.com/Mamdasn/im2dhist) is the source code for the im2dhist python library with a short description on how it's done.\r\n\r\n## Installation\r\n\r\nRun the following to install:\r\n\r\n```python\r\npip install im2dhisteq\r\n```\r\n\r\n## Usage\r\n\r\nFor images\r\n```Bash\r\nim2dhisteq --input 'cloudy-day.jpg' --output 'assets/cloudy-day-2dhisteq.jpg' --w 6\r\n```\r\nFor videos\r\n```Bash\r\nvid2dhisteq --input 'video-input.mp4' --output 'video-output-enhanced.mp4' --w 6\r\n```\r\n### Speed up\r\nThe speed of the program can be significantly increased if the go library `lib-im2dhist.go` in src/go_libs in the package is compiled and moved to a dir in the system path.\r\nTo compile, first make sure `go` is installed on your system. Then run\r\n```Bash\r\ngo mod init lib-im2dhist.go\r\ngo mod tidy\r\n```\r\nfollowed by running the script `make-library`.\r\n\r\n#### Download binary\r\nInstead of compiling the go library `lib-im2dhist.go`, you can download the library based on your system configuration:\r\n* [lib-im2dhist-linux-amd64.so](https://github.com/Mamdasn/im2dhisteq/releases/download/v1.1.0/lib-im2dhist-linux-amd64.so)\r\n* [lib-im2dhist-linux-386.so](https://github.com/Mamdasn/im2dhisteq/releases/download/v1.1.0/lib-im2dhist-linux-386.so)\r\n* [lib-im2dhist-darwin-amd64.dylib](https://github.com/Mamdasn/im2dhisteq/releases/download/v1.1.0/lib-im2dhist-darwin-amd64.dylib)\r\n* [lib-im2dhist-darwin-arm64.dylib](https://github.com/Mamdasn/im2dhisteq/releases/download/v1.1.0/lib-im2dhist-darwin-arm64.dylib)\r\n\r\n## Showcase\r\n* A one minute comparative video: https://youtu.be/7LrzX2ZpLAQ\r\n* This is a sample image and its corresponding 2d-histogram equalized image.\r\n![cloudy-day-original-im2dhisteq.jpg Image](https://raw.githubusercontent.com/Mamdasn/im2dhisteq/main/assets/cloudy-day-original-im2dhisteq.jpg \"cloudy-day-original-im2dhisteq.jpg Image\")\r\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmamdasn%2Fim2dhisteq","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmamdasn%2Fim2dhisteq","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmamdasn%2Fim2dhisteq/lists"}