
Security News
Open Source Maintainers Feeling the Weight of the EU’s Cyber Resilience Act
The EU Cyber Resilience Act is prompting compliance requests that open source maintainers may not be obligated or equipped to handle.
pythonGraphicalManipulator
Advanced tools
pythonGraphicalManipulator is a Python library designed for advanced image manipulation using pixel grids. It offers functions for resizing, cropping, color adjustments, and creative effects such as black-and-white conversion, color isolation, and brightness control. This library is ideal for developers working with custom image processing workflows.
Image Manipulation
Resize and crop images.
Flip images horizontally or vertically.
Color Transformations
Convert images to black and white.
Isolate or remove specific colors.
Replace specific colors with new ones.
Adjustments
Brightness, shadow intensity, and black point adjustments.
Warmth and fade effects for aesthetic modifications.
I/O Operations
Convert images to pixel grids and vice versa.
Export pixel grids to text files for external processing.
Install the library using pip
:
pip install pythonGraphicalManipulator
Here’s how to get started with pythonGraphicalManipulator
:
from pythonGraphicalManipulator import imageToPixelGrid
pixelGrid = imageToPixelGrid("example.jpg")
from pythonGraphicalManipulator import bnw
bnwGrid = bnw(pixelGrid)
from pythonGraphicalManipulator import pixelGridToImage
pixelGridToImage(bnwGrid, "output.jpg")
imageToPixelGrid(imagePath, outputToTextFile=False, textFile=None)
pixelGridToImage(pixelGrid, outputImagePath)
resizeImage(pixelGrid, length, width)
cropImage(pixelGrid, top, left, right, bottom)
flipHoriz(pixelGrid)
flipVert(pixelGrid)
bnw(pixelGrid)
singleColorPop(pixelGrid, r, g, b, threshold=50)
singleColorRemove(pixelGrid, r, g, b, threshold=50)
changeColor(pixelGrid, r1, g1, b1, r2, g2, b2, threshold=0)
adjustBrightness(pixelGrid, factor)
adjustShadowIntensity(pixelGrid, factor)
adjustBlackPoint(pixelGrid, level)
adjustWarmth(pixelGrid, factor)
The tests folder includes unit tests to validate the functionality of the library. To run the tests:
python -m unittest discover tests
Contributions are welcome! Please fork this repository and submit a pull request for any bug fixes or enhancements.
This project is licensed under the MIT License. See the LICENSE file for details.
Developed by Dharyansh Achlas For any queries, feel free to contact https://github.com/salchaD-27
FAQs
A python library for graphical image manipulation
We found that pythonGraphicalManipulator demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
The EU Cyber Resilience Act is prompting compliance requests that open source maintainers may not be obligated or equipped to handle.
Security News
Crates.io adds Trusted Publishing support, enabling secure GitHub Actions-based crate releases without long-lived API tokens.
Research
/Security News
Undocumented protestware found in 28 npm packages disrupts UI for Russian-language users visiting Russian and Belarusian domains.