Skip to main content

⛏pyromorphite💎

Process mining in python.

Get the Source Code

Pyromorphite is actively developed on GitHub, where the code is always available.

You can clone the public repository:

$ git clone git://github.com/xcavation/pyromorphite.git 

Once you have a copy of the source, you can embed it in your own Python package, or install it into your site-packages easily:

$ cd requests
$ pip install .

Quickstart

This is a quick introduction to Pyromorphite. Before proceeding, make sure that Pyromorphite is installed.

Import a Log 📜

Reading in event log files in Pyromorphite is super easy. It supports XES, CSV, and Excel files.

XES Files

Begin by importing the Pyromorphite module:

>>> import pyromorphite as pm

We'll try now to get an xes file from a web repository. For this dataset:

>>> log = pm.read_xes("https://data.4tu.nl/repository/uuid:c1e9137e-2877-410d-a76a-21ce7f97a239/DATA1")

Similarly we would do if we would like to read a local file. Let's assume that under /path/to/file.xes lies our file. We can then do:

>>> log = pm.read_xes("/path/to/file.xes")

CSV Files

Although not part of Pyromorphite, reading a csv file can be done with the pandas library.

Begin by import the pandas module:

>>> import pandas as pd

We'll try now to get an xes file from a web repository. For this dataset:

>>> log = pd.read_csv("https://data.4tu.nl/repository/uuid:d5ccb355-ca67-480f-8739-289b9b593aaf/DATA")

Construct a Bag 🎒

Having parsed a log into a pandas DataFrame we can simply extract the traces of events, with togehter with their frequency in the log.

>>> bag = pm.as_bag(log)

If we consider that everybody might use different column names, we can specify the case, timestamp and activity columns when creating the bag in the following way:

>>> bag = pm.as_bag(log, case='CI Name (aff)', time='Actual Start', activity='Change Type')

Does this Trace Conform to the Event Log?

For this task we are going to use a model called Log Skeleton.

>>> bag = pm.as_bag(pm.read_xes(os.path.join("B1.xes")))
>>> traces = [("a1", "a4", "a5", "a7")]
>>> pred = pm.skeleton.classify(bag, traces)
>>> [False]

NOTE: Log B1.xes is equal to the multiset that can be found here.

Metadata

Release files for pyromorphite 0.0.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pyromorphite 0.0.3
File Size Uploaded Provenance
pyromorphite-0.0.3.tar.gz 12.4 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for pyromorphite 0.0.3
File Interpreter ABI Platform
pyromorphite-0.0.3-py3-none-any.whl Python 3 none any Details

Total release size: 25.9 kB

Release files / pyromorphite-0.0.3.tar.gz

Download URL pyromorphite-0.0.3.tar.gz
Size 12.4 kB
Tags Source
SHA-256 checksum
How to use checksums
e0f6224f3ae8bfa215067bc7d7a97864ac929c19c4928ad12ae07d20db5e57aa
BLAKE2b-256 checksum
How to use checksums
f57f9ec4cc5e22dcd28c1539dd9bf4fad857904205778d5c6ad4f236ece1b59f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.8.2

Release files / pyromorphite-0.0.3-py3-none-any.whl

Download URL pyromorphite-0.0.3-py3-none-any.whl
Size 13.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
aa67195f9fc64789aac16d70d11789b9275a4de27d86d66b5dd8000d29afd6e1
BLAKE2b-256 checksum
How to use checksums
f612704e2ad09565a34b651d9ce5b74668953d2a566cb6ba2e7cbbdff0f5a065
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.8.2

Security for pyromorphite 0.0.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Release history Release notifications | RSS feed

This release

0.0.3 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page