Files
OpenSpace/support/assetvalidation/readme.md
Andreas Engberg 0fc9265837 Feature/assetvalidation (#3396)
# To run the script
Make sure to install the latest Python API version `openspace-api 0.1.2`
The script is located in `OpenSpace/support/assetvalidation`, the main script takes a few command line arguments

`--dir` - specify the OpenSpace directory 
`--filter` - optionally supply a regex string to filter which assets to validate
`--verbose` - flag to print debug info to log and also console (default off), if off only warnings and errors are logged
`--start` - flag to start OpenSpace as a subprocess (default on) if this is off it assumes OpenSpace is already running, useful if you want to run OpenSpace via Visual Studio for example. 
`--at` - specify an index to start at a specific asset

run eg: 
`python main.py --dir="C:/User/Desktop/OpenSpace" --filter="examples" --verbose=True --start=False --at=35`
2024-10-10 15:55:53 +02:00

955 B

Description

This script validates all* assets files by loading them one at a time into an empty scene in OpenSpace. The assets are loaded from scratch and then from cache and any errors are logged.

Setup

The project provides a requirements.txt with the necessary dependencies. Install using e.g., pip pip install -r /path/to/requirements.txt

Running validation tests

Parameter Description
--dir Points to the base folder of the OpenSpace version that is used to execute the validation. There needs to be a compiled version of OpenSpace available in the folder such that bin/RelWithDebInfo/OpenSpace.exe(on Windows) or bin/OpenSpace (on Linux) exists and is executable.
--filter Regex string to filter the assets to validate
--verbose If set to True output messages will also be printed to the console.

Example `python main.py --dir "C:/Development/OpenSpace" --filter "examples/*"