A Python library for simplifying tasks and enhancing generative AI workflows.
Project description
taizun
taizun is a Python library that simplifies machine learning tasks by providing utility functions for Natural Language Processing (NLP) and Computer Vision. It leverages free pre-trained models from Hugging Face, making advanced AI tasks accessible and easy to use.
Installation
Install the library using pip:
pip install taizun
Features
Natural Language Processing (NLP)
-
Summarize Text
- Summarize long texts into concise, readable summaries.
- Usage:
from taizun import summarize_text summary = summarize_text("Your long text here...") print(summary)
-
Named Entity Recognition (NER)
- Identify entities like people, locations, and organizations in text.
- Usage:
from taizun import named_entity_recognition entities = named_entity_recognition("Barack Obama was the 44th President of the United States.") print(entities)
-
Text Generation
- Generate text from a prompt using GPT-2.
- Usage:
from taizun import text_generation generated_text = text_generation("Once upon a time,") print(generated_text)
-
Sentiment Analysis
- Analyze the sentiment of text (positive, negative, neutral).
- Usage:
from taizun import sentiment_analysis sentiment = sentiment_analysis("I love this library!") print(sentiment)
-
Remove Stopwords
- Remove common stopwords from text.
- Usage:
from taizun import remove_stopwords cleaned_text = remove_stopwords("This is a sample text with stopwords.") print(cleaned_text)
-
Word Frequency Analysis
- Analyze the frequency of words in a text.
- Usage:
from taizun import word_frequency_analysis frequency = word_frequency_analysis("This is a test. This test is only a test.") print(frequency)
Computer Vision
-
Generate Image Caption
- Generate a natural language caption for an image.
- Usage:
from taizun import generate_image_caption caption = generate_image_caption("path/to/image.jpg") print(caption)
-
Classify Image
- Classify an image using a Vision Transformer (ViT) model.
- Usage:
from taizun import classify_image label = classify_image("path/to/image.jpg") print(label)
-
Detect Objects
- Detect objects in an image with bounding boxes and labels.
- Usage:
from taizun import detect_objects objects = detect_objects("path/to/image.jpg") print(objects)
-
Resize Image
- Resize an image to specified dimensions.
- Usage:
from taizun import resize_image resized = resize_image("path/to/image.jpg", "path/to/output.jpg", size=(300, 300)) print(resized)
-
Convert to Grayscale
- Convert an image to grayscale.
- Usage:
from taizun import convert_to_grayscale grayscale = convert_to_grayscale("path/to/image.jpg", "path/to/output_grayscale.jpg") print(grayscale)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file taizun-0.1.1.tar.gz.
File metadata
- Download URL: taizun-0.1.1.tar.gz
- Upload date:
- Size: 7.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6a57eeddcfc4603ce54115d1ce5d66a42f65806ebe4f37bb21d76b5ec3bf5c57
|
|
| MD5 |
a4f58d3c1abebff5a11f67b5bf7d8909
|
|
| BLAKE2b-256 |
f06ed8418bbcaa5b21451792c525f787a856c0bdb3d8775bb4eb047ecd43d8ea
|
File details
Details for the file taizun-0.1.1-py3-none-any.whl.
File metadata
- Download URL: taizun-0.1.1-py3-none-any.whl
- Upload date:
- Size: 7.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
da7b1606518677e69803b17f4cf248ba9872bf8c8069465c21330554c27ad0d0
|
|
| MD5 |
e02d18e2b71d26bd1a56fd2e5b0e064b
|
|
| BLAKE2b-256 |
3b8a243dffccf4e1c1eb62a378fc3cf779e22b5a772fb12a5158b975e07b1835
|