Unibox

Latest version: v0.4.13

Safety actively analyzes 685670 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 2 of 10

0.4.7

python
import unibox as ub


feat:
- `ub.concurrent_loads([uris])`: allow concurrent loading of multiple uris into a list (see notebook)
python
uris = ["s3://dataset-pixiv/sagemaker/20240228_half_pixiv_optmize_workflow/0.todo.parquet",
"s3://dataset-pixiv/sagemaker/20240228_half_pixiv_optmize_workflow/1.todo.parquet",
"s3://dataset-pixiv/sagemaker/20240228_half_pixiv_optmize_workflow/2.todo.parquet",]

result_df = pd.concat(ub.concurrent_loads(uris))


- `ub.peeks`: now supports prettier dataframe printouts:
python
df = pd.Dataframe(...)
ub.peeks(df)

- `ub.ls(...)`: new wrapper function that types faster than `ub.traverses(...)`

- `ub.gallery([image_uris])`: allow fast preview of many images within the notebook

fix:
- `ub.loads()`: fix windows loading from s3 tempfile naming issue

0.4.6

^title

this should not produce a file containing `NaN` anymore:

python
import numpy as np

test_dict = [{
"id": 1,
"name": "Alice",
"age": None, Contains a None value
"height": float('nan'),
"weight": np.nan,
}]

ub.saves(test_dict, "test_invalid_values2.jsonl") shouldn't contain "NaN" in the output file

0.4.5

tweak:
- `ub.loads()`: will attempt to convert `NaN` in jsonl lines to `null`, or skip the current line and continue, if a jsonl is partially corrupted

0.4.4

fix:
- ub.saves(list[str]): fixed a bug that causes list of string to be unable to be saved

0.4.3

tweak:
- allow any loaded `PIL.Image` file (eg. `JpegImageFile`) to be saved as png, not just standard PIL Image.

fix:
- a bug that makes `ub.loads("some_url")` not working

0.4.2

feat:
- extend include_extensions at ub.traverses() to take ending than extensions
- eg. this can work after update:

python
ub.traverses("s3://unidataset-danbooru/sagemaker/", include_extensions=[".todo.parquet"])


tweak:
- [adding debug_print parm for ub.saves()](https://github.com/trojblue/unibox/commit/1263a79c2c2df3c4935e655d5f3b200d43aea180)

Page 2 of 10

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.