Skip to content

Repository files navigation

PyTorchExperiments

This repository contains projects and experiments for the purposes of gaining familiarity involving PyTorch.

Getting Started

This repository was created using PyCharm Community Edition allowing to run PyTorchExperiments on a local computer. In order to run on a local pc you will need to install the following libraries to the local Python environment. (This will install to the .venv folder if using PyCharm IDE).

Required

Run the following commands in the terminal to install PyTorch libraries to the local Python environment.

pip3 install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118
pip install "ray[tune]" torch torchvision
pip install optuna
pip install numpy
pip install pandas
pip install tabulate
pip install tqdm
pip install matplotlib

see requirements.txt file for the Compute Canada python wheels.

To install MATLAB CVX see https://cvxr.com/cvx/doc/install.html for instructions.

Test Run

To check if PyTorch installed correctly run: quickstart.py.

Description

Descriptions of the Python projects, directories, and content included in this repository.

MATLAB

MATLAB (version 2022a) is used to generate a dataset for a simulated RIS communication system model, i.e. channel matrices, pilots, receive signal, etc.

  • generateHDRISData.m
    • Run this MATLAB script to generate data for a Half-Duplex RIS model
  • showChannels.m
    • show the channels and corresponding optimal RIS phase shifts as 2D images
  • src/
    • directory containing MATLAB scripts and functions to generate RIS data
    • To change the parameters of the system model change contents of: src/systemModelParameters.m
  • datasets/
    • directory to store the generated datasets.
    • for Python scripts use the .csv files from this directory to easily load the datasets into a numpy array.

Quick Start

A simple autoencoder neural network classifier on MNIST data. Code was obtained from: https://pytorch.org/tutorials/beginner/basics/quickstart_tutorial.html.

SISO Convolutional Neural Network AutoEncoder with Quantization

Simple autoencoder to quantize optimal RIS phases into bits for phase shift feedback in a SISO RIS-assisted communication system model.

MU-MISO Neural Network AutoEncoder with Quantization

Autoencoder to quantize optimal RIS phases into bits for phase shift feedback of a multi-user multiple-input-single-output RIS-assisted communication system model.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages