Py Editor MAC USER MANUALDeveloper ID · 27.0.2 (32)
REVIEWED EDITION · Developer ID 27.0.2 (32)

Run AI Vision Lab and read its report

Py Editor for Mac · Direct Developer ID edition · 27.0.2 (32)

Workflow verified 15 September 2026 with Helper 0.5.3.

AI Vision Lab trains a small image classifier on generated vertical, horizontal and diagonal patterns. You can run the example, follow its training results and inspect a visual report without supplying a dataset or an AI service account.

Prepare the example

  1. Choose File → Recent Projects → 08_AI_Vision_Lab. These steps assume the bundled example appears in your recent projects.
  2. Make sure Py Editor Helper is running. This workflow was tested with Helper 0.5.3; installing Helper itself is outside this page.
  3. If the status bar says Project .venv not created, click it and wait for the project environment to be prepared.
  4. Select main.py and leave the run selector at Current Selected File.
  5. Click the green Run triangle.
  6. If Run reports missing project dependencies, click Install Dependencies and wait for Project dependencies installed. Run the file again.

The project uses PyTorch, NumPy and Matplotlib. Package setup requires a download; training uses the locally generated dataset. Our run used a project environment with Python 3.14.6. Do not change your system Python just to match this screenshot.

Run and inspect the results

  1. If dependency installation was needed, select main.py and click Run again. If the first run already completed successfully, use its results instead; there is no need to train twice just to follow this guide.
  2. Wait for the ten training epochs to finish.
  3. Read the final test accuracy and confusion matrix in Results → Run.

Py Editor showing the convolutional model and a scrolled excerpt of completed training resultsOpen the screenshot to view it at full size.

The screenshot shows model.py opened for inspection after main.py finished. To repeat training, select main.py again before clicking Run.

The displayed 100% test result belongs to this small generated dataset. It is not a benchmark or a guarantee of accuracy on real-world images. The first run may also display a Matplotlib font-cache message.

If you need to stop before completion, use Stop active execution in the top toolbar, as described in Run and output. An existing report file is not proof that the latest run completed: read that run's final output before treating the report as its result.

Open the visual report

  1. In the Project panel, right-click the 08_AI_Vision_Lab folder.
  2. Choose Reload from Disk to refresh the file list.
  3. Right-click ai_vision_report.png and choose Open In → Finder.
  4. With the report selected in Finder, press Command-O. On the test Mac it opens in Preview.

AI Vision Lab report in macOS Preview, showing training loss, validation accuracy, a confusion matrix and sample predictionsOpen the screenshot to view it at full size.

This is the generated report displayed in macOS Preview, not an image preview inside Py Editor. In the tested build, clicking the PNG directly in Py Editor displayed “Unable to read ai_vision_report.png”; the Finder route above was verified instead.

Understand the four panels

  • Training loss: how the training error changed across epochs.
  • Validation accuracy: the fraction of validation patterns classified correctly.
  • Confusion matrix: expected classes are rows and predicted classes are columns. Values on the diagonal are correct predictions.
  • Sample predictions: a few expected and predicted labels side by side.

Keep the example unchanged for your first run. Once you can reproduce the report, inspect data.py for the generated patterns and model.py for the classifier and training functions.