Using MATLAB with Python
AI for wireless when using MATLAB® with Python®
Collaborate with colleagues who work in other deep learning frameworks to train and test PyTorch®, TensorFlow™, or ONNX™ models using Python coexecution or the import and export functions. For more information, see PyTorch Coexecution.
These examples demonstrate channel state information (CSI) feedback compression and CSI prediction techniques using artificial intelligence (AI) in 5G wireless communication systems. Workflow steps include data generation, data preparation, deep neural training, compression, system testing, and deployment.
Topics
Introduction
- PyTorch Coexecution
AI for wireless workflows using coexecution of MATLAB and PyTorch. (Since R2025a)
Model Training
- Train PyTorch Channel Prediction Models (5G Toolbox)
Train a PyTorch neural network for channel prediction by using data generated in MATLAB. (Since R2025a) - Train PyTorch Channel Prediction Models with Online Training (5G Toolbox)
Enable real‐time adaptation to time‐varying wireless channels by generating each training batch in MATLAB on-the-fly to train a PyTorch GRU channel prediction network online. (Since R2026a) - Offline Training and Testing of PyTorch Model for CSI Feedback Compression (5G Toolbox)
Train an autoencoder-based PyTorch neural network offline and test for CSI compression. (Since R2025a) - Online Training and Testing of PyTorch Model for CSI Feedback Compression (5G Toolbox)
Train an autoencoder-based PyTorch neural network online and test for CSI compression. (Since R2025a)
Model Testing
- Test AI-based CSI Compression Techniques for Enhanced PDSCH Throughput (5G Toolbox)
Measure physical downlink shared channel (PDSCH) throughput in a 5G New Radio (NR) system, with a primary focus on AI-based compression methods for CSI feedback. (Since R2026a) - Apply Transfer Learning on PyTorch Model to Identify 5G and LTE Signals (5G Toolbox)
Coexecution with Python to identify 5G NR and LTE signals by using the transfer learning technique on a pre-trained PyTorch™ semantic segmentation network for spectrum sensing. (Since R2025a) - Verify Performance of 6G AI-Native Receiver Using MATLAB and PyTorch Coexecution (5G Toolbox)
Integrate a trained PyTorch network with MATLAB-based data generation to simulate an AI-native air interface. (Since R2025a)
Model Deployment
- Import TensorFlow Channel Feedback Compression Network and Deploy to GPU (5G Toolbox)
Generate GPU specific C++ code for a pretrained TensorFlow channel state feedback autoencoder. (Since R2023b)