clipcrop
- Extract sections of images from your image by using OpenAI's CLIP and YoloSmall implemented on HuggingFace Transformers
- Added new capability for segmentation using CLIP and Detr segmentation models
Installation
pip install clipcrop
Clip Crop
Extract sections of images from your image by using OpenAI's CLIP and YoloSmall implemented on HuggingFace Transformers
Extraction
from clipcrop import clipcrop
cc = clipcrop.ClipCrop("/content/sample.jpg")
DFE, DM, CLIPM, CLIPP = cc.load_models()
result = cc.extract_image(DFE, DM, CLIPM, CLIPP, "text content", num=2)
Captcha
Solve captacha images using CLIP and Object detection models. Ensure Tesseract is installed and executable in your path
from clipcrop import clipcrop
cc = clipcrop.ClipCrop(image_path)
DFE, DM, CLIPM, CLIPP = cc.load_models()
result = cc.auto_captcha(CLIPM, CLIPP, 4)
Clip Segmentation
Segment out images using Detr Panoptic segmentation pipeline and leverage CLIP models to derive the most probable one for your query
Extraction
from clipcrop import clipcrop
clipseg = clipcrop.ClipSeg("/content/input.png", "black colored car")
segmentor, clipmodel, clipprocessor = clipseg.load_models()
result = clipseg.segment_image(segmentor, clipmodel, clipprocessor)
Remove Background
from clipcrop import clipcrop
clipseg = clipcrop.ClipSeg("/content/input.png", "black colored car")
result = clipseg.remove_background()
Other projects
- SnapCode : Extract code blocks from images mixed with normal text
- HuggingFaceInference: Inference of different uses cases of finetued models
Contact
- Feel free to contact me on "nkumarvishnu25@gmail.com"
Metadata
Release files for clipcrop 2.5.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| clipcrop-2.5.0.tar.gz | 5.7 kB | Without provenance | Details for clipcrop-2.5.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| clipcrop-2.5.0-py3-none-any.whl | Python 3 | none | any | Details for clipcrop-2.5.0-py3-none-any.whl |
Total release size: 12.0 kB
Release files / clipcrop-2.5.0.tar.gz
| Download URL | clipcrop-2.5.0.tar.gz |
|---|---|
| Size | 5.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
8c43076578872459c54439c8c29510421111331d13f6a5454ebe763a48efcc45
|
|
BLAKE2b-256 checksum How to use checksums |
7523a069505386ee143d3d9605f508d24f218d0aab3107e245dc503ae0c29588
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.9.19
|
Release files / clipcrop-2.5.0-py3-none-any.whl
| Download URL | clipcrop-2.5.0-py3-none-any.whl |
|---|---|
| Size | 6.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
96e69a9854c17b464545f85d9b92b3ffe63a68678ee3849fe0c4b75ba20072cc
|
|
BLAKE2b-256 checksum How to use checksums |
8d021181a48499e49e17bc28b70d14ad1a9c4e7b20c1ee2c69f540de2815978a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.9.19
|
Security for clipcrop 2.5.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.