Skip to content
Alessio Cecconi edited this page Apr 6, 2021 · 5 revisions

Measurement Framework for Declarative Specificaions

The measurements component of Janus allows to retrieve a wide range of interestingness measures for the declarative rules composing a model. More specifically, Given in input an event log and a declarative specification, the measurement components allows to retrieve:

  • the evaluation of each rule (and the entire model) in each event of the log
  • the measurements of each rule (and the entire model) in each trace and their descriptive statistics of the distribution across the entire log
  • the measurements of each rule (and the entire model) in the entire log

Basic Command

This is the minimal command to launch the Janus measurements component:

`java -cp Janus.jar minerful.JanusMeasurementsStarter -iLF ${INPUT_LOG} -iME json -iMF ${INPUT_MODEL} -oJSON ${OUTPUT_FILE} -oCSV ${OUTPUT_FILE}`

where:

  • INPUT_LOG the path to the input log file. If the file is a TXT text file add the following option "-iLE strings"
  • INPUT_MODEL the path to the JSON file containing the model to check
  • OUTPUT_FILE the path where to save the results

-iLE,--in-log-encoding <language> input encoding language {'xes','mxml','strings'}. Default is: 'xes'

-iLF,--in-log-file <path> path to read the log file from

-iME,--input-model-encoding <language> input model encoding language {'declare-map','minerful','json'} (default: 'minerful')

-iMF,--input-model-file <path> path of the file from which the process model should be read

-oCSV,--save-as-csv <path> print results in CSV format into the specified file

-oJSON,--save-as-json <path> path of the file in which to save the discovered process model as JSON

Parameters

-h,--help print help

-encodeTasksFlag,--flag-encoding-tasks Flag if the output tasks/events should be encoded [Default: False]

-measure,--measure <measure> Measure to compute, either a specific one or all the supported ones [Default: all] possible entry:{ all,Support, Confidence, Recall, Lovinger, Specificity,Accuracy, Lift,Leverage, Compliance,Odds Ratio,Gini Index,Certainty factor,Coverage,Prevalence,Added Value, Relative Risk,Jaccard,Ylue Q,Ylue Y,Klosgen,Conviction,Interestingness Weighting Dependency,Collective Strength, Laplace Correction,J Measure,One-way Support,Two-way Support, Two-way Support Variation,Linear Correlation Coefficient,Piatetsky-Shapiro,Cosine,Information Gain, Sebag-Schoenauer,Least Contradiction,Odd Multiplier, Example and Counterexample Rate,Zhang }

-nanLogSkip,--nan-log-skip Flag to skip or not NaN values when computing trace measures decriptive statistics over the event log [Default: False]

-nanTraceSubstitute,--nan-trace-substitute Flag to substitute or not the NaN values when computing trace measures [Default: False]

-nanTraceValue,--nan-trace-value <number> Value to be substituted to NaN values in trace measures [Default: False]

-lite,--lite-flag EXPERIMENTAL Flag to use the space saving data structure

-detailsLevel,--details-level <name> levels of details of the measures to compute. {event(only events evaluation), trace(only trace measures), traceStats(only trace measures log stats), log(only log measures), allTrace(traces measures and their stats), allLog(log measures and traces measures stats), all}. Default: all. Default is: 'all'

OUTPUT

Through the parameter -detailsLevel it is possible to select up to 4 outputs:

  • Events evaluation: suffix:*.[eventsEvaluation].csv/json
  • Traces measures: suffix:*.[tracesMeasures].csv/json
  • Traces measures descriptive statistics: suffix:*.[tracesMeasuresStats].csv/json
  • Log measures: suffix:*.[logMeasures].csv/json

The supported output formats are Json and CSV (with semicolon delimiter ;)

EXPLANATION OF MODEL CHECKING OUTPUT

  • Janus uses constraints defined in a reactive form "Activator []-> Target", where both Activator and Target are arbitrary LTLpf formulas. Only a subset of DECLARE constraints is used for now.
  • For readability, regardless of the input log, the output events are encoded in characters like "A", "B", "C",...
  • The result is a 3D matrix of bytes to be read as follows: for each trace -> for each constraint -> for each event of the trace -> byte result = [activator evaluation of (event;constraint;trace)][target evaluation of (event;constraint;trace)]
  • Each byte stores the results of both Activator and target evaluation of a given constraint in a specific trace for a specific event. The left bit is for the activator, the right bit for the target,i.e.,[activator-bit][target-bit] In details:
    • 0 -> 00 -> Activator: False, Target: False
    • 1 -> 01 -> Activator: False, Target: true
    • 2 -> 10 -> Activator: True, Target: False
    • 3 -> 11 -> Activator: True, Target: True
  • Based on the single events evaluation, it is reported a set of measures for the each trace and constraint (Support, Confidence, Lovinger's measure, ...)

e.g.

{
	"TRACE-1":[
		{
            "DECLARE-CONSTRAINT-A(VARIABLE1, VAR2, ...)": [ {"EVENT-1": BYTE},{"EVENT-2": BYTE},... ]
            "Support": S.S
            "Confidence": C.C
            "Lovinger": L.L
            "...": ...
		},
		{
		    "DECLARE-CONSTRAINT-B(...)": [ ... ]
            "Support": ...
            "Confidence": ...
            "Lovinger": ...,
        },
        {...}
	],
	
	"TRACE-2":[
		{
            "DECLARE-CONSTRAINT-A(...)": [ ... ]
            "Support": ...
            "Confidence": ...
            "Lovinger": ...
		},
		{...}
	],
	...
}

Clone this wiki locally