# VIPR Framework - CLI Installation This guide covers installing VIPR Core and plugins for command-line usage. ## Table of Contents 1. [Prerequisites](#prerequisites) 2. [Installation](#installation) 3. [Environment Setup](#environment-setup) 4. [Verify Installation](#verify-installation) 5. [Quick Start Example](#quick-start-example) --- ## Prerequisites - **Python**: 3.10 or higher --- ## Installation ### VIPR Core + Reflectometry Plugin ```bash # Create virtual environment python3.10 -m venv myenv source myenv/bin/activate # Install VIPR Core pip install git+https://codebase.helmholtz.cloud/vipr/vipr-core.git # Install Reflectometry Plugin pip install git+https://codebase.helmholtz.cloud/vipr/vipr-reflectorch-plugin.git ``` --- ## Environment Setup ### Optional Variables ```bash # Reflectorch storage directory (defaults to ${PWD}/storage/reflectorch) export REFLECTORCH_ROOT_DIR=${PWD}/storage/reflectorch # HuggingFace cache directory export HF_HOME=${PWD}/storage/huggingface_cache # Device selection (defaults to auto-detect) export CUDA_VISIBLE_DEVICES=0 ``` **Tip:** Add these to your `~/.bashrc` or `~/.zshrc` for permanent setup. --- ## Verify Installation ### Check VIPR Version ```bash vipr --version ``` ### List Installed Plugins ```bash vipr plugins list ``` Expected output should include: - `reflectometry` (if installed) - Other installed plugins ### Test Registry ```bash # List all registered components vipr discovery components # List available predictors vipr discovery predictors ``` --- ## Quick Start Example ### Run Example Prediction Prediction for PTCDI-C3 (config from [reflectorch examples](https://codebase.helmholtz.cloud/vipr/vipr-reflectorch-plugin/-/blob/master/vipr_reflectometry/reflectorch/examples/configs/PTCDI-C3.yaml)): ```bash vipr --config @vipr_reflectometry/reflectorch/examples/configs/PTCDI-C3.yaml inference run ``` ### Test with Custom Config ```bash # Using relative path (from current working directory) vipr --config ./my-config.yaml inference run # Using absolute path vipr --config /path/to/config.yaml inference run ``` **Note:** To use your own experimental data file, set the `data_path` value in the `load_data` section to the relative path of your data file (relative to PWD). ### Check Results ```bash # Results are typically stored in the storage directory ls storage/results/ ``` ---