Skip to content

Commit

Permalink
conv2float
Browse files Browse the repository at this point in the history
  • Loading branch information
Carlos Hernandez committed Jan 14, 2015
1 parent 7cebbd6 commit 411166b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions dihedral_tent.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,18 +34,18 @@ def ent(H):


def ent1D(X, r=rbins()):
H = np.histogram(X, r)[0]
H = np.histogram(X, r)[0].astype(float)
return ent(H)


def ent2D(X, Y, r=rbins()):
H = np.histogram2d(X, Y, 2*[r])[0]
H = np.histogram2d(X, Y, 2*[r])[0].astype(float)
return ent(H)


def ent3D(X, Y, Z, r=rbins()):
W = np.vstack((X, Y, Z)).T
H = np.histogramdd(W, 3*[r])[0]
H = np.histogramdd(W, 3*[r])[0].astype(float)
return ent(H)


Expand Down

0 comments on commit 411166b

Please sign in to comment.