{"id":26820410,"url":"https://github.com/zvdy/imagegodracula","last_synced_at":"2025-03-30T06:32:13.034Z","repository":{"id":207028937,"uuid":"718255435","full_name":"zvdy/ImageGoDracula","owner":"zvdy","description":null,"archived":false,"fork":false,"pushed_at":"2024-08-22T18:43:49.000Z","size":4191,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-08-22T20:59:55.809Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","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/zvdy.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":"2023-11-13T17:52:32.000Z","updated_at":"2024-08-08T13:33:23.000Z","dependencies_parsed_at":"2024-10-10T22:15:19.492Z","dependency_job_id":null,"html_url":"https://github.com/zvdy/ImageGoDracula","commit_stats":null,"previous_names":["zvdy/imagegodracula"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zvdy%2FImageGoDracula","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zvdy%2FImageGoDracula/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zvdy%2FImageGoDracula/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zvdy%2FImageGoDracula/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zvdy","download_url":"https://codeload.github.com/zvdy/ImageGoDracula/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246285645,"owners_count":20752947,"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":[],"created_at":"2025-03-30T06:31:55.541Z","updated_at":"2025-03-30T06:32:13.025Z","avatar_url":"https://github.com/zvdy.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🧛 ImageGoDracula  \n\nDue to the lack of Dracula themed wallpapers, I decided to create a simple API that converts images to the Dracula color palette.\n\nThe project consists of a Flask API that uses the [ImageGoNord](https://github.com/TylerYep/ImageGoNord) library to convert uploaded images to the [Dracula](https://draculatheme.com/) color palette.\n\n## 📸 Examples\n\n![Image](images/converted.jpg)\n\n![Image](images/converted0.jpg)\n\n## ⚙️ Installation\n\n1. Clone this repository to your local machine.\n2. Install the required modules using `pip install -r requirements.txt`.\n3. Run the Flask app using `python main.py`.\n\n## 🐳 Docker\n\nYou can also run the Flask app in a Docker container. To do so, follow these steps:\n\n1. Build the Docker image using the following command:\n\n   ```\n   docker build -t imagegodracula .\n   ```\n\n2. Run the Docker container using the following command:\n\n   ```\n   docker run -p 5000:5000 imagegodracula\n   ```\n\n   This command runs the Docker container and maps port 5000 on the host to port 5000 in the container. You can then access the Flask app by visiting `http://localhost:5000` in your web browser.\n\n\u003e You can also docker pull the Docker image from my [Docker Hub](https://hub.docker.com/u/zvdy) \n\n## 🔨 Usage\n\nYou can use `curl` to test the API by sending a POST request with an image file. Here's an example command:\n\n```bash\ncurl -X POST -F \"file=@/path/to/image.jpg\" http://localhost:5000/convert --output converted.jpg\n```\n\nReplace `/path/to/image.jpg` with the actual path to your image file. This command sends a POST request to the `/convert` endpoint of the API with the image file as a form field. The API will convert the image using the Nord color palette and return the converted image file as a response.\n\nYou can modify the color palette and colors used by the API by modifying the `GoNord` instance in `main.py`. The default palette and colors are:\n\n```python\ngo_nord.reset_palette()\ngo_nord.add_color_to_palette('#282a36')\ngo_nord.add_color_to_palette('#44475a')\ngo_nord.add_color_to_palette('#F8F8F2')\ngo_nord.add_color_to_palette('#6272A4')\ngo_nord.add_color_to_palette('#BD93F9')\ngo_nord.add_color_to_palette('#8BE9FD')\ngo_nord.add_color_to_palette('#50FA7B')\ngo_nord.add_color_to_palette('#FFB86C')\ngo_nord.add_color_to_palette('#FF79C6')\ngo_nord.add_color_to_palette('#FF5555')\ngo_nord.add_color_to_palette('#F1FA8C')\n```\n\n\u003e You can add or remove colors from the palette by calling `go_nord.add_color_to_palette()` or `go_nord.remove_color_from_palette()`, respectively.\n\n## 📰 License\n\nThis project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzvdy%2Fimagegodracula","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzvdy%2Fimagegodracula","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzvdy%2Fimagegodracula/lists"}