evlib 0.9.0

Event Camera Data Processing Library
Documentation
[package]
name            = "evlib"
version         = "0.9.0"
authors         = ["Tarek Allam <t.allam.jr@gmail.com>"]
edition         = "2021"
resolver        = "2"
description     = "Event Camera Data Processing Library"
readme          = "README.md"
license         = "MIT"
repository      = "https://github.com/tallamjr/evlib"
homepage        = "https://github.com/tallamjr/evlib"
documentation   = "https://docs.rs/evlib"
keywords        = ["event-camera", "vision", "rust", "python", "pyo3"]
categories      = ["science", "multimedia"]
exclude         = [
    "data/**/*",
    "dist/**/*",
    "examples/**/*",
    "python/**/*",
    "tests/**/*",
    "*.png",
    "*.mp4",
]

[lib]
name           = "evlib"
crate-type     = ["cdylib", "rlib"]

[[bench]]
name = "memory_efficiency"
harness = false

[[bench]]
name = "streaming_performance"
harness = false

[[bench]]
name = "format_comparison"
harness = false

[[bench]]
name = "basic_performance"
harness = false

[[bench]]
name = "standalone_benchmark"
harness = false

[dependencies]
# Python bindings (optional)
numpy          = { version = "0.25.0", optional = true }
pyo3           = { version = "0.25.1", features = ["extension-module"], optional = true }
pyo3-ffi       = { version = "0.25.1", optional = true }

# Core data processing
ndarray        = "0.15.6"
ndarray-rand   = "0.14.0"
rand           = "=0.8.5"
rand_distr     = "=0.4.3"
fastrand       = "2.0"

# Torch-style tensor ops removed (was causing objc_exception compilation issues on Linux)
# candle-core    = { version = "0.9.1", default-features = false }
# candle-nn      = { version = "0.9.1", default-features = false }

# Polars for efficient event data processing (optional)
polars         = { version = "0.49.1", default-features = true, features = ["temporal", "dtype-u16", "dtype-i8", "lazy"], optional = true }
pyo3-polars    = { version = "0.22.0", optional = true }

# Apache Arrow for zero-copy data transfer (optional)
arrow          = { version = "55.0", default-features = false, optional = true }
arrow-array    = { version = "55.0", optional = true }
pyo3-arrow     = { version = "0.10.1", optional = true }

# I/O & utilities
memmap2        = "0.5"
lazy_static    = "1.4"
byteorder      = "1.5"

serde          = { version = "1.0", features = ["derive"] }
serde_json     = "1.0"
num_cpus       = "1.16"
thiserror      = "1.0"
crc32fast      = "1"
tokio          = { version = "1", features = ["net", "io-util", "rt", "macros"] }

# Platform-specific dependencies
# HDF5 and tracing only on Unix (Linux/macOS) - not available on Windows
# HDF5 crates are optional and enabled via the `hdf5` feature flag.
[target.'cfg(unix)'.dependencies]
hdf5-metno     = { version = "0.10.1", features = ["blosc-all"], optional = true }
hdf5-metno-sys = { version = "0.10.1", optional = true }
tracing        = { version = "0.1.40" }
tracing-subscriber = { version = "0.3.18", features = ["env-filter", "fmt", "json"] }

[dev-dependencies]
tempfile       = "3.8"
criterion      = { version = "0.5", features = ["html_reports"] }

[features]
# Default features - automatically platform-aware:
# - Unix (Linux/macOS): Includes all features (HDF5 and tracing available)
# - Windows: Excludes HDF5 and tracing (not in dependencies on Windows)
default        = ["polars", "python", "arrow"]

# Individual feature flags
python         = ["dep:pyo3", "dep:pyo3-ffi", "dep:numpy", "dep:pyo3-polars"]
# cuda           = ["candle-core/cuda"]  # Removed with candle dependencies
# metal          = ["candle-core/metal"]  # Removed with candle dependencies
polars         = ["dep:polars"]
arrow          = ["dep:arrow", "dep:arrow-array", "dep:pyo3-arrow"]
zero-copy      = ["arrow"]  # Alias for clarity
# HDF5 support (Unix-only). Opt-in because the hdf5-metno-sys build script
# requires a compatible system HDF5 install. On Windows the underlying deps
# aren't available, so this feature compiles to no-op stubs there.
hdf5           = ["dep:hdf5-metno", "dep:hdf5-metno-sys"]