Skip to content

Commit

Permalink
Refactor code
Browse files Browse the repository at this point in the history
  • Loading branch information
mofeing authored Jul 12, 2023
1 parent 71365d9 commit 3999f40
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/TensorNetwork.jl
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,8 @@ struct TensorNetwork{A<:Ansatz,M<:NamedTuple}

# Check for inconsistent dimensions
for (index, idxs) in indices
sizes = [size(tensors[i], index) for i in idxs]
if !all(x -> x == sizes[1], sizes)
allequal(i -> size(tensors[i], index), idxs) ||
throw(DimensionMismatch("Different sizes specified for index $index"))
end
end

M = Tenet.metadata(A)
Expand Down

0 comments on commit 3999f40

Please sign in to comment.