Data preprocessing scripts for sky-video-PV pairs and modified VideoMAEv2 for regression and PV output forecasting from 15-minute sky videos, with a forecast horizon of 15 minutes.
- Python 3.13
- NVIDIA GPU with CUDA support (recommended for training)
- CUDA 12.6+ (version compatible with Pytorch)
- Git
git clone https://github.com/ph3rro/PVOutputPrediction
cd PVOutputPredictionInstall Python 3.13 and add to PATH.
You will need two separate virtual environments—one for the preprocessing notebooks and one for VideoMAEv2
python3.13 -m venv preprocessing-env
cd models/VideoMAEv2
python3.13 -m venv VideoMAE-envInstall PyTorch first (on both environments), as it requires specific CUDA versions. Visit PyTorch Get Started to get the appropriate command for your system.
For CUDA 13.0 (as used in this project):
pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu130Install the main project dependencies in two separate virtual environments for preprocessing notebooks and VideoMAE:
preprocessing-env\Scripts\activate
pip install -r requirements.txt
deactivate
cd models/VideoMAEv2
VideoMAE-env\Scripts\activate
pip install -r requirements-MAE.txtsource preprocessing-env/bin/activate
pip install -r requirements.txt
deactivate
cd models/VideoMAEv2
source VideoMAE-env/bin/activate
pip install -r requirements-MAE.txtThis will install:
- Core libraries: numpy, pandas, scipy
- Deep learning: scikit-learn, timm, transformers
- Computer vision: opencv-python, pillow
- Data handling: h5py, hdf5plugin
- Utilities: CRPS, tqdm, tensorboard, matplotlib
- Jupyter notebook support
Check that PyTorch can access your GPU:
import torch
print(f"PyTorch version: {torch.__version__}")
print(f"CUDA available: {torch.cuda.is_available()}")
print(f"CUDA version: {torch.version.cuda}")
if torch.cuda.is_available():
print(f"GPU: {torch.cuda.get_device_name(0)}")python run_class_finetuning.py --batch_size=3 --lr=1e-3 --num_workers=0 --mixup=0 --cutmix=0python run_class_finetuning.py --batch_size=3 --lr=1e-3 --num_workers=0 --mixup=0 --cutmix=0 --device='cpu'python run_class_pretraining.py