Observed since 20 Oct, 21:24 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
A library to fetch, convert, and decode binary input data for ML models.
Here is the README.md with a complete set of examples for each supported file type and its usage, including a demo for all the supported files:
A Python library to fetch, convert, and decode binary input data for machine learning models.
agenbits simplifies the process of fetching data from URLs, converting it into a temporary binary file, and decoding it into usable formats such as images, audio, text, videos, and more for ML models.
To install agenbits from PyPI, run the following command:
pip install agenbits
agenbits provides multiple format-specific functions to fetch, convert, and decode files. Here's how you can use it:
You can fetch and convert Excel or CSV files into usable data for machine learning models:
from agenbits import Excel
# Fetch Excel data from a URL
data = Excel("https://people.sc.fsu.edu/~jburkardt/data/csv/airtravel.csv")
print(data.head()) # Show first few rows (for pandas DataFrame)
Fetch an image from a URL, convert it to binary format, and display it:
from agenbits import ImageFile
# Fetch and display image
img = ImageFile(
"https://images.pexels.com/photos/17647410/pexels-photo-17647410/free-photo-of-airplanes-flying-at-an-air-show.jpeg")
img.show() # This will open the image using the default viewer
You can also fetch and decode audio files such as WAV or FLAC:
from agenbits import Audio
# Fetch and process audio data
audio = Audio("https://example.com/audio.wav")
audio.play() # Play audio using an appropriate library like soundfile
Fetch and decode a video file (e.g., MP4) and play it or perform any video-related operation:
from agenbits import Video
# Fetch video data
video = Video("https://www.example.com/video.mp4")
video.play() # Implement using appropriate video playing library, like OpenCV or ffmpeg
You can fetch and decode text-based files such as JSON, TXT, or XML:
from agenbits import Text
# Fetch JSON data from URL
json_data = Text("https://example.com/data.json")
print(json_data) # Print decoded JSON content
For any other type of binary file (e.g., TensorFlow Record or PyTorch Model), agenbits can help fetch and convert those as well:
from agenbits import Binary
# Fetch and convert binary file
binary_data = Binary("https://example.com/model.pt")
# Handle this binary file as needed, e.g., load into PyTorch or TensorFlow
agenbits supports a wide variety of formats, including:
.xlsx and .xls.This project is licensed under the MIT License. See the LICENSE file for details.
If you want to contribute to agenbits, feel free to fork the repository and create a pull request. Please ensure that your code follows the existing style and includes tests for new features.
Author: Enos Email: enosuppada2005@gmail.com GitHub: https://github.com/dunkdumb/agenbits
---
### Explanation of Updates:
1. **General Introduction**:
- Describes the main purpose of the library.
2. **Features**:
- Lists key features, such as fetching data from URLs, converting to binary format, and automatically decoding files for machine learning models.
3. **Installation**:
- Instructions to install the package from PyPI.
4. **Usage Examples**:
- Added various examples of using the library with different file types (Excel, CSV, Image, Audio, Video, Text, Binary, etc.).
- Each example demonstrates how you can pass a URL to the library and fetch/convert/decode the file into a usable format.
5. **Supported Formats**:
- An extended list of supported file formats, including details about each file type.
6. **License**:
- Information on the MIT license.
7. **Contributing**:
- Encourages others to contribute to the library, with instructions for forking and submitting pull requests.
8. **Contact Information**:
- Author’s contact information with GitHub and email.
---
This `README.md` file should now be comprehensive and well-structured for users to understand and use your library effectively. Let me know if you need further adjustments!
Download counts and popularity will appear here as the collector receives them.
| Version | Published | Direct dependencies | Open version |
|---|---|---|---|
| 0.1.2 | 15 May 2025 | 7 |
This describes our collected data; it is not a security assessment.
Observed since 20 Oct, 21:24 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
package:1c4f2c234ce5fbf63a2521a0ae8c070161b46c1f48491126420b980e8dc4d3de