Contains the pre-processing logic for data that is used for training or queries.
Project description
lib-ml
Contains the pre-processing logic for data that is used for training or queries.
Methods
fit_transform(train, test, val, sequence_length=200): Fits the tokenizer and encoder on the training data and transforms all datasets.transform_input(url, sequence_length): Transforms new url data using the fitted tokenizer.transform_labels(raw_y): Transforms new label data using the fitted encoder.get_tokenizer(): Returns the fitted tokenizer.get_char_index(): Returns the char index of the fitted tokenizer.get_encoder(): Returns the fitted encoder.set_tokenizer(tokenizer): Sets the tokenizer to the provided tokenizer.set_encoder(encoder): Sets the encoder to the provided encoder.
Installation
pip install lib-ml-team11
Usage
from lib_ml_team11 import Preprocessing
# Create an instance of the Preprocessing class
preprocessing = Preprocessing()
...
# Transform the data
x_train, y_train, x_val, y_val, x_test, y_test = preprocessing.fit_transform(train, test, val, sequence_length=200)
Releasing
Create a new git tag and push it to the repository. The CI/CD pipeline will automatically publish the new version to PyPi.
git tag v0.1.0
git push origin v0.1.0
Note: The version number should follow the semantic versioning format, i.e., vX.Y.Z where X, Y, and Z are non-negative integers. Note that the version number should be prefixed with a v.
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 lib_ml_team11-0.0.1.tar.gz.
File metadata
- Download URL: lib_ml_team11-0.0.1.tar.gz
- Upload date:
- Size: 2.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
32c09df2052e715a00232fb547126b45b2421250abbe3264fcb5cbf91a8ae618
|
|
| MD5 |
65b110b5bbe762dede1b58cd5177a996
|
|
| BLAKE2b-256 |
7a483956e8372cc36b53559390f6829ea995a6a78e807edce317760fc8814c80
|
File details
Details for the file lib_ml_team11-0.0.1-py3-none-any.whl.
File metadata
- Download URL: lib_ml_team11-0.0.1-py3-none-any.whl
- Upload date:
- Size: 2.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
802ff6dd4768775a28677a0e0b8f7d1354eb0e614a56ac5b721ff4239ca96354
|
|
| MD5 |
5ef35df829e55f6461836297b83d4440
|
|
| BLAKE2b-256 |
c2d3a7ddd6516524b857c7feeecab282054ddb72a97b81e70e39f95973edfbda
|