Skip to content

Instantly share code, notes, and snippets.

View quantshah's full-sized avatar

Shahnawaz Ahmed quantshah

View GitHub Profile
@quantshah
quantshah / qnn.ipynb
Last active July 10, 2024 10:52
Universal quantum classifier using Pennylane - a python library for quantum machine learning
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@quantshah
quantshah / mlphases.ipynb
Created October 17, 2019 06:20
Machine Learning Phases of Matter
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@quantshah
quantshah / cubic.py
Created December 13, 2021 16:30
Cubic phase state definition and Wigner function
import numpy as np
from qutip.wigner import wigner
from qutip import coherent, squeeze, destroy, displace
import matplotlib.pyplot as plt
from matplotlib import colors
def cubic(initial_state, squeezing, gamma):
@quantshah
quantshah / cholesky.py
Created October 7, 2022 08:04
Cholesky decomposition from a random input matrix
import numpy as np
def clean_cholesky(chi):
"""Converts a random complex-valued matrix which has a shape
(N, N) to a Hermitian matrix.
Args:
chi (array (complex)): A matrix of shape (N, N).