semvec/pypi-packages huggingface dataset:
rustpdf-compress 2026.1.0
基于 Rust 的高性能 PDF 压缩库，支持三种压缩级别
License: MIT
Requires Python: >=3.8
Keywords: pdf, 压缩, compress, rust

# rustpdf-compress

基于 Rust 的高性能 PDF 压缩库，支持 Python 调用。

## 安装

```bash
pip install rustpdf-compress
```

## 使用方法

### 压缩文件

```python
import rustpdf_compress

# 压缩文件，返回 (原始大小, 压缩后大小, 压缩率)
original, compressed, reduction = rustpdf_compress.compress_file(
    "input.pdf",
    "output.pdf",
    level="recommended"  # extreme / recommended / low
)
print(f"压缩了 {reduction:.1f}%")
```

### 压缩字节数据

```python
import rustpdf_compress

with open("input.pdf", "rb") as f:
    data = f.read()

compressed = rustpdf_compress.compress(data, level="recommended")

with open("output.pdf", "wb") as f:
    f.write(compressed)
```

## 压缩级别

| 级别 | 说明 | 图片质量 | 缩放比例 |
|------|------|---------|---------|
| `extreme` | 极限压缩 | 30% | 50% |
| `recommended` | 推荐（默认） | 60% | 75% |
| `low` | 低压缩 | 85% | 100% |

## 特性

- 🚀 基于 Rust，性能优异
- 📦 支持 Python 3.8+
- 🖥️ 支持 macOS (ARM64) 和 Linux (x86_64)
- 🔧 三种压缩级别可选

## License

MIT
virtuous 0.0.7
Runtime loader for Virtuous Python clients
License: MIT
Requires Python: >=3.12

# Using Virtuous in Python

Zero-dependency loader for Virtuous runtime-generated Python clients.

## Install

```bash
pip install virtuous
```

## Usage

```python
from virtuous import load_module, load_module_to_disk, get_remote_hash

module = load_module("https://api.example.com/client.gen.py")
client = module.create_client("https://api.example.com")

# Optional: write to disk and import later
module = load_module_to_disk(
    "https://api.example.com/client.gen.py",
    "/tmp/client.gen.py",
)

# Optional: fetch the server-provided hash
remote_hash = get_remote_hash("https://api.example.com/client.gen.py")
```

## Notes

- This loader executes remote Python code. Use trusted endpoints only.
- `get_remote_hash` reads from `<url>.sha256`.
- Loaded modules expose `__virtuous_hash__` with the computed SHA-256 digest.
rtsp-network-scanner 2.5.4
Scan networks for RTSP cameras, test streams, discover channels
License: MIT
Requires Python: >=3.7
Keywords: rtsp, scanner, network, camera, security, debug

# RTSP Network Scanner

Scan networks for RTSP cameras - finds hosts, ports, and channels in one command.

## Install

```bash
pip install rtsp-network-scanner
```

## Usage

```bash
# Scan local network (auto-detected) - finds cameras, ports, and channels
rtsp-network-scanner scan

# Scan specific network
rtsp-network-scanner scan 192.168.1.0/24

# Scan single host
rtsp-network-scanner scan 192.168.1.100

# Scan with credentials (validates auth, shows codec/resolution)
rtsp-network-scanner scan -u admin -p password

# Check if cameras are actually working (requires ffmpeg)
rtsp-network-scanner scan --check

# Detailed output (all info)
rtsp-network-scanner scan --detailed

# Skip channel discovery (ports only)
rtsp-network-scanner scan --skip-channels
```

## What it does

One command scans everything:
1. Finds hosts with open RTSP ports (554, 8554, 7447, etc.)
2. Discovers available channels on each camera (supports Hikvision, Dahua, Axis, etc.)
3. Shows channel status: ✓ OK, ✗ Auth Error, etc.
4. Validates credentials and shows codec/resolution

**Example output:**
```
Found 1 camera(s) with 8 channel(s)

+--------------+------+-------------------------+-------------+--------+
| host         | port | path                    | stream_type | status |
+--------------+------+-------------------------+-------------+--------+
| 192.168.1.10 | 554  | /Streaming/Channels/101 | Main        | ✓ OK   |
| 192.168.1.10 | 554  | /Streaming/Channels/102 | Sub         | ✓ OK   |
| 192.168.1.10 | 554  | /Streaming/Channels/201 | Main        | ✗ Auth |
+--------------+------+-------------------------+-------------+--------+
```

**Status indicators:**
- `✓ OK` - Channel accessible with provided credentials
- `✗ Auth` - Channel exists but credentials are wrong/missing
- `⊘ Forbidden` - Access denied

## Options

| Option | Description |
|--------|-------------|
| `-u, --username` | Username for authentication |
| `-p, --password` | Password for authentication |
| `--check` | Verify cameras work using ffmpeg |
| `--detailed` | Full output (codec, resolution, fps, bitrate) |
| `--skip-channels` | Skip channel discovery (ports only) |
| `--timeout SECONDS` | Connection timeout (default: 2.0s) |
| `--workers NUM` | Concurrent workers (default: 50) |
| `--output FILE` | Export results (JSON/CSV) |
| `--debug` | Enable debug logging |
| `--log-file FILE` | Log to file |

## Supported Cameras

- **Hikvision** - All 8 channels (101-802)
- **Dahua / Amcrest** - Multiple channels
- **Axis** - VAPIX streams
- **Foscam** - Main/Sub streams
- **Generic** - Common RTSP paths

## Links

- [GitHub](https://github.com/sssanjaya/rtsp-network-scanner)
- [PyPI](https://pypi.org/project/rtsp-network-scanner/)

## License

MIT

## Author

Sanjay H