What the evaluation says and does not say

Ingence’s results describe how files relate. This page says how the current test measures how often they are right. It also says what that test can show and what it cannot. Read it before you decide how far to trust what Ingence shows you.

In short

  • Ingence was tested on invented laboratories. The program that invents the files also writes the right answers, the ground truth. The test gives counts for each kind of question. It never gives one score.

  • The scorer doesn’t count “no result” as a mistake. So it always shows the number of answers the engine found beside the number that were right.

  • A command that ships with Ingence makes a free sample collection of an invented laboratory (below). Anyone can try it and test against it.

How the engine is checked today

The test has two halves. This page describes the public half, and anyone can run it. The private half is the same scorer run on a real folder. A laboratory can run it for itself (see the end of this page).

Invented laboratories. A program called the generator writes a folder of invented files. The files have the shapes laboratories have:

  • dated experiment folders holding raw, processed and analysis files;

  • replicates, copies and backups;

  • a folder that moved;

  • an installed program among the experiments, laid out as programs are;

  • a readme that names other files;

  • scripts and their outputs, and empty outputs;

  • a file whose ending says one thing and whose contents say another;

  • dates written in several forms;

  • results that two sets of raw data could each have produced.

Each name is an invented word, or an ordinary word such as raw or analysis. Every file has its format’s structure with invented values. The files don’t hold any real measurement.

A ground truth. Beside the invented folder, and never inside it, the generator writes the ground truth, answer_key.json. It holds what a person who knew the laboratory would say from the files and their names. It says which stage each file is at and which folders are experiments. It says which files are replicates, copies or made from one another. It also says which files name one another, and which folder is a program. Where the files alone cannot settle an answer, the ground truth says so, and the right output is no result. Ingence never opens the ground truth while it scans.

A scorer. The scorer runs Ingence over the invented folder and compares each rule’s results with the ground truth. It reports each kind of question on its own. The kinds are stage, experiment folder, program, empty file, and an ending contradicted by the contents. The others are the date a name states, replicates, copies, groups of experiments, references and derivations. A derivation is one file made from another.

How a result is counted

The scorer counts each answer in one of these ways, and never adds the counts together.

  • Right: the answer matches the ground truth. This includes the engine and the ground truth both saying there isn’t a value. For pairs, it also includes refusing a pair the ground truth does not have. The scorer counts these two, but precision leaves them out: it looks only at the answers that could be wrong.

  • Wrong: a different value, or a value where the ground truth says there isn’t one. It is also the engine saying there isn’t a value where the ground truth has one. For a pair of files, it is a pair the engine proposed that the ground truth does not have. It is also a pair the engine refused that the ground truth has.

  • No claim (no result): the engine didn’t give a result where the ground truth has an answer. This happens because the engine does not know, or has not read the file. The scorer never counts this as wrong. How Ingence works explains “unknown” and “not read yet”.

  • Conflicting: the engine looked, found answers that disagree, and said so.

  • Missed, for pairs: a pair the ground truth has and the engine did not propose. The scorer also counts a pair as missed when the engine refused it or found it conflicting.

  • Outside and ignored: a ground truth for a real folder names only some paths. So the scorer counts what the engine says about the other paths apart, as outside, and never as wrong. Where the ground truth itself leaves a path out of the score, any answer is acceptable. The scorer counts that answer as ignored.

  • Undecidable: where the ground truth marks a question that the files alone cannot settle, the right output is no result. The scorer counts whatever the engine does there apart, and never as wrong: an answer, a refusal or a conflict.

From these the scorer reports two proportions for each rule.

  • Precision: of the answers that are right or wrong, the share that are right.

  • Recall: of the answers the ground truth expects, the share the engine got right.

The scorer doesn’t count “no result” as an error, because it is a valid answer. That has a cost. An engine that didn’t say anything wouldn’t make mistakes, and wouldn’t find anything. So the scorer always shows both proportions. Read precision and recall together, and read the “no claim” count beside them.

The scorer doesn’t give a single score. Every figure is a count with its total: “right in 18 of 20”, never a bare percentage. Every proportion carries a 95% confidence interval. This is the range of rates that the evidence cannot rule out, given only this many cases. The scorer computes it by the Wilson method. A small number of cases gives a wide range. The picture below shows why you should never read a figure without its 95% confidence interval.

right in 5 of 5 right in 18 of 20 right in 180 of 200 0 0.5 1
A made-up example, not a result: three rules' records, each with its 95% confidence interval.

Each row is one rule’s record on a scale from 0 (never right) to 1 (always right). The ring is the share that were right in the cases seen. It is all of 5, nine in ten of 20 and nine in ten of 200. The bar is the 95% confidence interval around it. The 5 of 5 row reaches 1, but its bar starts at 0.57. So five cases cannot rule out a rule that is wrong more than four times in ten. The 180 of 200 row has the same share as the 18 of 20 row. Its bar runs only from 0.85 to 0.93, because the scorer saw ten times as many cases.

The full report, report.json, also splits the counts by the standing the engine gave each result. A reader can then check whether the results it holds more firmly are right more often. The short summary, summary.txt, does not show the split. Rules whose results are classes of files, such as replicates and copies, give every result the same standing. For them, the split says little.

What the evaluation says

It says, rule by rule, whether the rules do what their authors meant. It says this for data collections of the kind the authors imagined. When a rule’s behavior changes, the counts show it at once. The scorer lists examples of each rule’s wrong answers, so the rule can be fixed or its wording corrected.

The invented folder is there to show changes in the engine’s behavior. The authors shouldn’t tune a rule to it. The generator and its tests hold a written rule. It says: don’t change a shape because the engine and the ground truth disagree. People keep that rule. The software does not enforce it.

What it does not say

  • The invented laboratories are the authors’ picture of a laboratory’s data. The people who wrote the rules also wrote the generator and its ground truth. A pass shows that the engine reads the laboratory the authors imagined. It does not show that the engine is right about yours. The ground truth is one person’s judgment of what the files alone can settle. Another person could judge some answers differently. The invented folders have also served partly as development data. The written reasons of a few rules name cases that first appeared in them. So the authors wrote those rules with those cases in view.

  • A small count says little. A row built on a few cases has a wide 95% confidence interval. Compare the totals of two figures before you compare the figures.

  • The scorer doesn’t score some questions yet. The sample collection also lists answers that a person would give and the scorer does not score yet (below). This test leaves out whole parts of the engine, such as themes and the No analysis found list.

  • It doesn’t claim scientific validity. The test is about files: whether a table was linked to its raw data, or whether two folders are copies. It doesn’t say anything about whether an experiment was sound or its outcome is true.

  • Runs on public archives are scored against predictions. Before each run, the authors wrote down what Ingence should find. They then scored the run against it. The results are on Zenodo (doi.org/10.5281/zenodo.23756685).

The sample collection

The invented folders above are small and plain. A command that ships with Ingence writes a larger one, the sample collection. It is the data collection of an invented research laboratory over several years, with several invented people. The command writes it into a folder you name:

python -m ingence.evaluation sample-lab sample-collection --tier S --seed 1

The invented files are in the new folder’s pool folder, and you can scan it like any other data folder. The collection holds what real data collections hold:

  • instrument files in the shapes of their formats, tables, scripts, notebooks, documents and slides;

  • names in several conventions that change over the years;

  • files saved again as _v2, _final and _final_v2;

  • folders copied whole into a backup;

  • links that don’t point at anything, and folders that moved;

  • experiments that were abandoned;

  • analysis whose raw data is gone, and raw data that was never analyzed;

  • a program installed inside a data folder;

  • the folder of a member who left.

It comes in three sizes.

Size

About how many files

What it is for

S

500

The tutorial, the examples in the documentation and tests.

M

10,000

Examples and screenshots.

L

100,000

A test of speed and memory.

The command needs only a size and a seed. The same size and seed give the same files, byte for byte, with the same names and modification times. Beside pool, and never inside it, the command writes:

  • its ground truth, answer_key.json, in the format the scorer reads;

  • answer_key_unscored.json, with answers a person would also give that the scorer does not score yet;

  • manifest.json, a record of the generator’s version, the size and the seed;

  • DATASHEET.md, a datasheet that answers the questions of “Datasheets for Datasets”. That standard form says what a collection is for, how it was made and what it cannot do.

Everything in it is invented. The people, projects and conditions are made up. The words in a name, such as techniques, stages, cell lines and stains, are ordinary ones. The files don’t come from anybody’s disk. The files shaped like Zeiss CZI, Leica LIF and Olympus OIB files hold only a header or an empty container. The programs that save those formats cannot read them.

The collection is open source, under CC0 1.0, on Zenodo (doi.org/10.5281/zenodo.23756685).

What it cannot test. It cannot tell you how Ingence does on your data. It is one model of a laboratory’s data. It doesn’t hold real instrument data or the real habits of any one laboratory. Its ground truth has the limits described above.

Run the public check yourself

The scorer ships with Ingence. Run it in the environment where Ingence is installed:

python -m ingence.evaluation run evaluation-run --seed 1 --size 1

This writes an invented folder, pool, and its ground truth, answer_key.json, into the folder evaluation-run. It scans pool with a project of its own, in evaluation-run/work, and prints the counts for each question. It also saves them as report.json and summary.txt in evaluation-run. Name a folder that does not exist yet. The command will not write over an invented folder that is already there.

The seed picks one version of the invented folder. The size is how many times each shape is written, each time with words of its own. A different seed gives the same words to other shapes, with new dates and numbers. So a new seed doesn’t give a new kind of data. It cannot show how the engine does on data that the shapes do not describe.

To write only the invented folder and its ground truth, use generate in place of run.

A laboratory can also score Ingence on a real folder of its own. Someone who knows the folder writes a ground truth for part of it, in the same format as answer_key.json. The project command then scores a finished project against it. It takes the ground truth file, the project and a folder for the report:

python -m ingence.evaluation project --key KEY --project PROJECT --out REPORT-FOLDER

Keep the ground truth file outside the folder it describes: the scorer refuses one saved inside it. It also refuses a report folder inside a data folder or inside the project, except the project’s exports folder. Run this way, the test stays on that laboratory’s computer.