Skip to content

Commit

Permalink
fix pylint
Browse files Browse the repository at this point in the history
  • Loading branch information
LuisAlfredoNu committed Dec 7, 2024
1 parent 86c0fce commit ccf6e40
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pennylane_lightning/lightning_tensor/_tensornet.py
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ def set_bond_dims(num_qubits: int, max_bond_dim: int) -> List:

log_max_bond_dim = np.log2(max_bond_dim)
limit_dimension = 2 ** int(log_max_bond_dim)
localBondDims = [limit_dimension for _ in range(num_qubits - 1)]
localBondDims = [limit_dimension] * (num_qubits - 1)

Check notice on line 128 in pennylane_lightning/lightning_tensor/_tensornet.py

View check run for this annotation

codefactor.io / CodeFactor

pennylane_lightning/lightning_tensor/_tensornet.py#L128

Consider using enumerate instead of iterating with range and len (consider-using-enumerate)

for i in range(len(localBondDims)):
bondDim = min(i + 1, num_qubits - i - 1)
Expand Down

0 comments on commit ccf6e40

Please sign in to comment.