Installation
Install the current KOPR Python 3 live source on native Linux or native Windows, with Astrometry.net provided natively or through WSL 2.
Source-verified Installation requirements and commands were retained from the audited KOPR/WSL baseline; the Scientific/Compact update adds no new installation dependency.
Supported installation model
The current live build is a Python source application. KOPR can run natively on Linux and natively on Windows. On Windows, WSL 2 is used only as an optional backend for the external Astrometry.net solve-field command; the KOPR GUI, FITS files, working directories and local index library remain on the Windows side.
KOPR first prefers a native solve-field executable on PATH. When KOPR is running as a native Windows Python process and no native solver is available, it probes the default WSL distribution. A non-default distribution can be selected with KOPR_WSL_DISTRIBUTION.
kopr.py, because the application uses relative paths for icons, configuration files and data directories.Requirements
| Component | Why KOPR needs it |
|---|---|
| 64-bit Python 3.10+ | Main application and numerical pipeline. |
| PyQt5 | Desktop graphical interface. |
| NumPy, SciPy, Astropy, Matplotlib | Image arrays, calibration, WCS/FITS processing, photometry and plots. |
| Requests, urllib3, jplephem | Online data access and offline ephemeris calculations. |
| rawpy, ExifRead | Decoding supported DSLR/mirrorless RAW sources into linear TG FITS and reading their metadata. |
Astrometry.net solve-field | Local plate solving. Install it natively on Linux; on native Windows KOPR may call the copy installed inside WSL. |
| WSL 2 and an Ubuntu/Debian distribution (Windows solver backend) | Provides Linux Astrometry.net when no native Windows solve-field is available. |
astroquery (optional) | Only the High-precision position — JPL Horizons helper. KOPR remains usable offline and with the internal ephemeris without it. |
| Internet connection | Initial comet elements, online catalogues, WSL/Astrometry.net installation and missing local astrometry indexes. |
The R22 source contains alb3.py, but the approximately 32.7 MB DE440s kernel is not bundled. When data/de440s.bsp is absent, KOPR opens a first-start progress dialog for a verified download. Cancel leaves KOPR usable with the non-fatal legacy ephemeris fallback, while Retry starts another attempt without requiring an application restart. The target file is replaced atomically only after verification, and temporary .part data are cleaned up by the downloader. A manual verified attempt can be started with python de440s_fetch.py; an existing kernel can be selected with KOPR_DE440S. The removed astrolib3 directory is not an installation dependency.
Optional JPL support can be added inside the same virtual environment:
python -m pip install astroqueryDo not make astroquery a hard runtime requirement when offline WCCD operation is sufficient.
Ubuntu/Linux installation
Install operating-system packages
sudo apt update sudo apt install python3 python3-venv python3-pip unzip astrometry.netThe Ubuntu
astrometry.netpackage supplies thesolve-fieldcommand. KOPR manages its own application-local index set separately.Extract the complete source archive
Keep the directory structure intact. In the example below, replace the archive name and extracted directory name with the actual names.
mkdir -p ~/kopr cd ~/kopr unzip ~/Downloads/kopr-live-python3.zip cd path/to/the/directory/that/contains/kopr.pyConfirm the working directory:
test -f kopr.py && echo "KOPR source root found"Create an isolated Python environment
python3 -m venv .venv source .venv/bin/activate python -m pip install --upgrade pipA virtual environment avoids the externally-managed-environment/PEP 668 error produced when
pipis used against the operating-system Python.Install the Python dependencies
Download the KOPR requirements list into the source root, then run:
python -m pip install -r kopr-python-requirements.txtEquivalent direct command:
python -m pip install PyQt5 matplotlib numpy astropy requests jplephem ExifRead rawpy scipy urllib3rawpyprovides the LibRaw backend required for automatic DSLR RAW → TG FITS materialization. When pending or stale RAW representations are found without this dependency, KOPR reports DSLR RAW extraction unavailable; existing FITS may still open, but physical RAW is never loaded directly.Verify the installation
python --version command -v solve-field python -c "import PyQt5, numpy, scipy, astropy, matplotlib, requests, jplephem, exifread, rawpy; print('Python dependencies OK')"You can also download the non-destructive installation checker into the source root and run:
python check-kopr-install.py .For an R22 distribution, also run the dependency-light release validator:
python3 validate_performance_release.pyUse
--jsonwhen machine-readable output is required.Start KOPR
source .venv/bin/activate python kopr.py
Astrometry.net and local indexes
Two separate components are required:
- The solver: the external
solve-fieldprogram. - The index files: local FITS data files used by the solver.
WStack resolves a usable solver backend before it checks or downloads the large index library:
- use native
solve-fieldwhen it is onPATH; - on native Windows, otherwise probe
solve-fieldin the selected WSL distribution; - only after solver preflight succeeds, discover local 4100/4200 families and install the established 4206–4214 set when it is missing.
The application-local indexes remain in the KOPR directory on both Linux and Windows:
astrometry-index/4100/ # optional Tycho-2 family
astrometry-index/4200/ # established automatic-download family
KOPR reports the available families and wide-field recommendation in [INDEX] terminal lines. Missing 4100 indexes produce a warning only; they do not block a valid 4200 installation. Automatic downloading still installs 4206–4214.
The downloader preserves partial files after cancellation and resumes them later. Keep sufficient free disk space and make the KOPR source directory writable. Do not create an empty completion marker manually; readiness is checked against the actual index FITS files.
[solve] solver preflight: native solve-field (...) or [solve] solver preflight: WSL solve-field (/usr/bin/solve-field).Native Windows installation with the WSL Astrometry.net backend
KOPR itself runs as a normal Windows Python application. Ubuntu does not need to be opened for each observing session; WSL is started automatically when astrometry calls solve-field.
Install KOPR and Python on Windows
Extract the complete KOPR archive to a writable directory on a local disk, for example
C:\KOPR. Install a supported 64-bit Python 3.10 or newer and create a virtual environment in PowerShell:cd C:\KOPR py -3 -m venv .venv .\.venv\Scripts\Activate.ps1 python -m pip install --upgrade pip python -m pip install -r docs\files\kopr-python-requirements.txtIf PowerShell blocks activation, use
Set-ExecutionPolicy -Scope Process Bypassfor that terminal session or activate fromcmd.exewith.venv\Scripts\activate.bat.Install WSL 2 and Ubuntu
Open PowerShell as Administrator:
wsl --install -d UbuntuRestart Windows when requested. If normal download fails, use:
wsl --install --web-download -d UbuntuInitialize Ubuntu once
Open Ubuntu from the Start menu and create the Linux username and password requested during first initialization. Characters are not displayed while typing the password.
Install Astrometry.net inside Ubuntu
sudo apt update sudo apt install -y astrometry.netIf the package is not found:
sudo apt install -y software-properties-common sudo add-apt-repository universe sudo apt update sudo apt install -y astrometry.netVerify the solver in Ubuntu
command -v solve-field solve-field --helpThe command path is normally
/usr/bin/solve-field.Verify the solver from Windows
Close Ubuntu and run in ordinary PowerShell:
wsl.exe -d Ubuntu -- sh -lc "command -v solve-field" wsl.exe -d Ubuntu -- sh -lc "command -v solve-field >/dev/null && solve-field --help >/dev/null && echo ASTROMETRY_OK"The second command should print
ASTROMETRY_OK.Confirm WSL 2
wsl --list --verboseThe selected distribution must show version 2. Convert an older installation with:
wsl --set-version Ubuntu 2Select a non-default distribution when necessary
The current implementation probes the default WSL distribution unless an explicit override is supplied. For the current PowerShell session:
$env:KOPR_WSL_DISTRIBUTION = "Ubuntu-24.04"Use the exact name shown by
wsl --list --verbose. KOPR does not automatically iterate through every installed distribution.Start KOPR natively
cd C:\KOPR .\.venv\Scripts\Activate.ps1 python kopr.pyAt astrometry start, KOPR first looks for a native solver and then uses WSL if necessary. Windows paths are translated with
wslpath; resulting WCS files are written back into the original Windows working directory.
astrometry-index/4200/ on an ordinary local Windows drive such as C: or D:. No copy of the index library is required inside Ubuntu.Updating a live source installation
- Close KOPR and wait for any WStack worker to finish.
- Back up
config-files/,comet-data/andobs-data/. - Extract the new live archive into a new directory rather than overwriting a running installation blindly.
- Create or reuse a virtual environment and install the requirements.
- Copy your backed-up user-data directories into the new source root.
- Run the installation checker, then start KOPR.
WStack session state is stored with each working directory in pipeline_state.json; it is not part of the central KOPR configuration backup.
Installation diagnostics
| Symptom | Action |
|---|---|
externally-managed-environment | Create and activate .venv; do not install KOPR packages into the system Python. |
No module named ... | Activate the same virtual environment used during installation and rerun the requirements command. |
Native Linux: solve-field not found | Install the Astrometry.net command-line package and verify command -v solve-field. |
Windows: neither native solver nor wsl.exe found | Install WSL 2 or place a native solve-field on Windows PATH. |
Windows: WSL is present but solve-field is absent | Install astrometry.net inside the selected distribution. If it is not the default distribution, set KOPR_WSL_DISTRIBUTION. |
| WSL cannot translate a Windows path | Move KOPR and the data to a normal local C: or D: directory and retest. Avoid an unmounted network/UNC path. |
| Index installation fails | Check the network connection, free space and write permission on astrometry-index/4200/; retry to resume partial downloads. |
data/de440s.bsp is absent | This is normal in R22. Use the first-start progress dialog to download it, choose Cancel to continue with the legacy ephemeris fallback, or use Retry after a failed attempt. For a command-line attempt run python de440s_fetch.py; use KOPR_DE440S for an existing kernel at another path. |
| Icons or configuration files are missing | Start KOPR from the directory containing kopr.py, not from another current directory. |
| Release validation or manifest check is required | Run python3 validate_performance_release.py from the source root. The validator does not require PyQt, NumPy or Astropy. |
Run check-kopr-install.py. On native Windows it accepts either a native solver or a verified WSL solver backend.
Continue with Getting started after the required checks pass.