Skip to content

Commit

Permalink
black formatted
Browse files Browse the repository at this point in the history
  • Loading branch information
Gopal-Dahale committed Jun 6, 2024
1 parent 11e5029 commit 75955c6
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions torchquantum/algorithm/qcbm.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ def k_expval(self, px, py):
Kernel expectation value
Args:
px: First probability distribution
py: Second probability distribution
px: First probability distribution
py: Second probability distribution
Returns:
Expectation value of the RBF Kernel.
Expand All @@ -45,7 +45,8 @@ def k_expval(self, px, py):
def forward(self, px, py):
"""
Squared MMD loss.
Args:
Args:
px: First probability distribution
py: Second probability distribution
Expand All @@ -61,22 +62,21 @@ class QCBM(nn.Module):
Quantum Circuit Born Machine (QCBM)
Attributes:
ansatz: An Ansatz object
n_wires: Number of wires in the ansatz used.
ansatz: An Ansatz object
n_wires: Number of wires in the ansatz used.
Methods:
__init__: Initialize the QCBM object.
forward: Returns the probability distribution (output from measurement).
__init__: Initialize the QCBM object.
forward: Returns the probability distribution (output from measurement).
"""

def __init__(self, n_wires, ansatz):
"""
Initialize QCBM object
Args:
ansatz (Ansatz): An Ansatz object
n_wires (int): Number of wires in the ansatz used.
ansatz (Ansatz): An Ansatz object
n_wires (int): Number of wires in the ansatz used.
"""
super().__init__()

Expand Down

0 comments on commit 75955c6

Please sign in to comment.