Security News
Introducing the Socket Python SDK
The initial version of the Socket Python SDK is now on PyPI, enabling developers to more easily interact with the Socket REST API in Python projects.
# https://pypi.org/project/range-compression/
pip install range-compression
from range_compression import RangeCompressedMask, mask_encode
from pathlib import Path
mtx = .... # 带有很多连续值的矩阵
rcm = mask_encode(mtx)
X, Y = ..., ... # 要查找的 X, Y
res = rcm.find_index(X, Y)
assert res.shape == X.shape
assert (mtx[Y, X] == res).all()
# 也可以 rcm.save(p)
# 之后在其他地方 rcm = RangeCompressedMask.load(p)
[] 把性能测试添加到测试和 readme 中 [x] 每个版本做性能回归测试 [ ] 添加更多说明和直接能运行的快速入门
支持 >=3.8, <=3.12
但 numba0.59 已经不再支持 Python3.8,如果以后使用到了 numba 新版本的特性,那么 Python3.8 可能不再会支持
FAQs
Unknown package
We found that range-compression demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
The initial version of the Socket Python SDK is now on PyPI, enabling developers to more easily interact with the Socket REST API in Python projects.
Security News
Floating dependency ranges in npm can introduce instability and security risks into your project by allowing unverified or incompatible versions to be installed automatically, leading to unpredictable behavior and potential conflicts.
Security News
A new Rust RFC proposes "Trusted Publishing" for Crates.io, introducing short-lived access tokens via OIDC to improve security and reduce risks associated with long-lived API tokens.