From predictions to a labels file
Export predictions with their IDs as a CSV file, predict photos with no known answer, and check the file before submitting.
A prediction needs an identity
A label such as mug is not useful in a batch of thirty photos unless you know which photo it describes. So every input gets a stable ID, a name that stays attached to it through prediction, review, and submission. Never rename or reorder IDs based on your guesses.
Suppose three practice photos are named practice01.jpg, practice02.jpg, and practice03.jpg. A predictions file for them could look like this:
id,labelpractice01,mugpractice02,glasspractice03,mugThis format is called CSV, short for comma-separated values. It is plain text laid out as a table: each line is a row, and commas separate the columns. The first line is the header, which names the two columns. Every later line has one ID, a comma, and one allowed label. A spreadsheet can open a CSV file as a grid, but the file itself is still plain text. These labels are made up to show the layout; they are not answers to any course task.
Build with me · 1
Download the predictions as a CSV file
After any prediction run, a Download predictions.csv button appears in Test & export. It writes the header id,label, then one line per result shown, in the same order. You do not need a spreadsheet or a text editor to make it.
The file holds the model's predictions exactly as they are. For development and final-test photos the lab knows the actual labels, but it never swaps them in to fix a wrong prediction. The file records what the model said, right or wrong.
Each ID comes from the uploaded filename without its ending: practice01.jpg becomes practice01. If two files share a name, the lab adds a number to the second so IDs stay unique. When a task gives you required filenames, upload files with exactly those names and check the IDs the lab shows, rather than retyping them from memory.
Test & export Predict this collection: Development (20) Predict collection Download predictions.csvThe file: one header line, then one line per result shownPredict one collection and press Download predictions.csv. Count the results shown in the lab; the file has one line for each, after the header. In Notes, write the filename, the run name, and which collection it came from.
What to look for
One predicted label per ID, with no percentages or comments in the label column, and exactly as many lines as results.
Make it yours
An ID such as p001 must stay p001, never 1. Explain why, even though part of it looks like a number. (An ID is a name, like the label on a locker.)
Build with me · 2
Predict photos whose answers you do not know
You can predict a photo without knowing its answer; that is what a model is for. Scoring the prediction is another matter. It needs a trusted correct label under your rule, and targets do not have one. So for Unlabelled targets, the lab shows predictions but no correct marks and no accuracy. A high confidence score cannot stand in for the missing answer.
Keep target photos out of Training. Guessing their labels, adding them to Training, and training on your guesses changes the method and spoils a held-out challenge. When a task supplies target photos, predict them with the model you chose and submit what it predicted.
Photos These photos are for: Unlabelled targets, then Upload imagesTest & export Predict this collection: Unlabelled targets, then Predict collectionYou get: IDs, scores, predicted labelsYou do not get: actual labels, correct marks, or accuracyIn Photos, choose Unlabelled targets and upload a few practice photos with distinct filenames; no label buttons appear for targets. In Test & export, choose Unlabelled targets, predict, and download the CSV after checking which collection is selected.
What to look for
The target results show predictions and score bars, but no actual labels, correct marks, or accuracy.
Make it yours
In Notes, describe how you would record a person correcting one of these predictions without claiming the model made the correction. Keep that note apart from the raw predictions file.
Keep human decisions visible
Some tasks allow a person to review the model's answers. If yours does, keep three things apart: the model's original prediction, any corrected label, and the reason for the change. A low confidence score can prompt a review; a high one does not prove a review is unnecessary.
A file improved by human corrections measures the person and the model together, not the model alone. Report both when you can, and never present the corrected score as the model's own.
Check before you submit
Before you hand in a file, check it on its own terms, separately from how good the predictions are.
Build with me · 3
Check the file as a strict table
A program that reads a CSV file (often called a parser) takes it literally. It cannot guess that "Predictions for my project" is a title to skip, or that "mug (probably)" means mug. Before submitting, count the lines (not counting the header) and compare them with the photos you were asked to predict. Every requested ID should appear once, with an allowed label, keeping any leading zeros.
A file can be perfectly formed and still describe the wrong photos. If you meant to export targets but had Development selected, every line is valid and the file is useless. So keep two checks apart. A wrong header, a repeated ID, an extra space, or an unknown label is a file problem: fix the file. A low score on a file that was accepted is a model problem: work on the model or its photos. Telling them apart stops you retraining a good model to fix a broken file.
Required header: id,labelAllowed labels: mug or glassEach requested ID: exactly one lineNot allowed: a title line, a percentage after a label, a missing or repeated IDCompare the IDs shown in the lab with the collection you meant to export. In Notes, write the required header and the allowed labels. Keep the run name with the filename so you can trace which model made the file.
What to look for
You can explain why an excellent model still fails a submission with missing IDs, and why fixing a header does not make the model any better.
Make it yours
Invent one broken line in your notes, such as dev03,mug 85%. Say which rule it breaks, then write the correct version.
A rule-based rehearsal uses the same discipline
The next exercise asks you to build a rule, clause by clause, instead of training a model. A rule is a list of conditions applied the same way to every row. For example, in an unrelated parcel-sorting task: if the weight is above some amount, choose one label; otherwise choose the other.
Read the fields and the label choices. Set a condition, check it against the labelled practice rows, and improve the rule using those rows. Then apply the same finished rule to the target rows. Do not invent a different explanation for each target row after the fact.
The point is to practise a prediction method you can repeat. A hand-written rule and a trained model produce labels in different ways, but both need honest evaluation and intact IDs.
Full reference solution
The whole Level 2 workflow on one page. Each reading covers part of it; this list shows where that part fits. The numbers in the readings are examples, and your own results will differ.
1. Name the two classes and write a one-sentence rule for each.2. Reserve objects or sessions for Development and Final test before collecting.3. In Photos, choose Training and a label, then add varied photos of both classes.4. Add reserved photos under Development and Final test, never under Training.5. In Notes, record label rules, objects, conditions, the split, and a run name.6. In Train, check both counts, keep 20 rounds for the first run, and press Train model.7. Download project and Download model, with matching run names.8. In Test & export, predict Development and read every ID, actual label, prediction, and score.9. Work out accuracy yourself, read the confusion matrix, and compare with the Always- baseline.10. Write one hypothesis. Change only the Training photos (or one stated setting), retrain, and predict the same Development collection.11. Choose a version using Development results. Open its saved model if needed.12. Predict Final test once, after choosing, and report its fraction, conditions, and limits.13. For photos with no known answer, use Unlabelled targets, predict, and Download predictions.csv.14. Keep project, model, notes, and predictions file together under one run name. None of them replaces another.Compare this with your version. Different names and personal choices are fine when the program follows the same logic.
Keep your progress
Sign in and every reading, quiz, and exercise you finish is saved.