point_process

Crates.iopoint_process
lib.rspoint_process
version0.13.0
sourcesrc
created_at2018-06-09 14:18:21.58251
updated_at2019-09-12 11:08:27.483683
descriptionA crate for simulating random point processes.
homepage
repositoryhttps://github.com/ManifoldFR/point-process-rust
max_upload_size
id69342
size418,974
Wilson (ManifoldFR)

documentation

README

Point processes in Rust

Crates.io Status Docs License Build Status

Point processes are stochastic processes with a wide range of applications in seismology, epidemiology, or financial mathematics. They are utilized to model the arrival of random events as a function of time.

variablepoisson

This crate provides functions to simulate point processes in Rust, built on top of ndarray. There is a Rust API available through the base crate as well as a Python library crate.

Overview

Time-dependent processes

The following time-dependent point processes have been implemented within the temporal module:

  • Poisson point process (homogeneous and inhomogeneous, with custom function)
  • Exponential-kernel Hawkes processes, using a linear-time simulation algorithm (both constant and variable background intensities supported)

cos_bg_exphawkes

Spatial processes

2dpoisson_circle

The generalized module provides functions for higher-dimensional processes.

For now, only Poisson processes have been implemented.

Estimators

The estimators module provides estimator routines for point process statistics such as the intensity.

polyexp_poisson_estimation

Python package

An Python wrapper crate is available in the pylib directory.

Examples

Run the examples with for instance

cd lib/
cargo run --example variable_poisson

Some will produce SVG image files in the lib/examples directory.

The examples show how to use the API.

They require the plotters crate for plotting.

Building locally

To compile the Rust library, do

cd lib/
cargo build

To build the Python library,

cd pylib/
cargo build --release

Warning on macOS, you might need to add the following to ~/.cargo/config (see PyO3's README):

[target.x86_64-apple-darwin]
rustflags = [
  "-C", "link-arg=-undefined",
  "-C", "link-arg=dynamic_lookup",
]

or linking with the C compiler will fail.

To compile both crates at the same time, just do

cargo build
Commit count: 222

cargo fmt