Metrics logging and analysis
Project description
🔬 Scope
Scalable metrics logging and analysis.
Features
- 🚀 Scalable: Quickly log and view petabytes of metrics, thousands of keys, and large videos.
- 🎞️ Formats: Log and view scalars, text, images, and videos. Easy to extend with custom formats.
- 🧑🏻🔬 Productivity: Metrics viewer with focus on power users with full keyboard support.
- ☁️ Cloud support: Directly write to and read from Cloud storage via pathlib interface.
- 🍃 Lightweight: The writer and reader measure only ~400 lines of Python code.
- 🧱 Reliable: Unit tested and used across diverse research projects.
Usage
Installation
pip install scope
Writing
import scope
writer = scope.Writer(logdir)
for step in range(3):
writer.add(step, {
'foo': 42,
'bar': np.zeros((100, 640, 360, 3), np.uint8),
'baz': 'Hello World',
})
writer.flush()
Viewing
python -m scope.viewer --basedir ... --port 8000
Reading
import scope
reader = scope.Reader(logdir)
print(reader.keys()) # ('foo', 'bar', 'baz')
print(reader.length('foo')) # 3
steps, values = reader['foo']
print(steps) # np.array([0, 1, 2], np.int64)
print(values) # np.array([42, 42, 42], np.float64)
steps, filenames = reader['bar']
reader.load('bar', filenames[-1]) # np.zeros((100, 640, 360, 3), np.uint8)
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
scope-0.6.3.tar.gz
(491.5 kB
view details)
File details
Details for the file scope-0.6.3.tar.gz
.
File metadata
- Download URL: scope-0.6.3.tar.gz
- Upload date:
- Size: 491.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
0230861e4d2bd7cc11890c33adffbb2e9b9d1899975a44984de745972002992a
|
|
MD5 |
75f95a039ecdd7a8a864222d3afaf31b
|
|
BLAKE2b-256 |
9fb93a29cb5d1d0bdd3878d89881958feb5535ac424e860b8c4a67db3a38ce35
|