Skip to content

Commit

Permalink
Merge branch 'v0.6.17' of https://github.com/bytedance/gpu4pyscf into…
Browse files Browse the repository at this point in the history
… v0.6.17
  • Loading branch information
wxj6000 committed Jan 18, 2024
2 parents 05bd483 + edef5bd commit bea6772
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion dockerfiles/manylinux/build_wheels.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export PATH=$CUDA_HOME/bin:$PATH
export LD_LIBRARY_PATH=$CUDA_HOME/lib64:$LD_LIBRARY_PATH

# blas is required by DFTD3 and DFTD4
yum install openblas-devel
yum install -y openblas-devel

# Compile wheels
rm -rf /gpu4pyscf/wheelhouse
Expand Down
1 change: 1 addition & 0 deletions gpu4pyscf/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
from . import lib, grad, hessian, solvent, scf, dft

__version__ = '0.6.17'

# monkey patch libxc reference due to a bug in nvcc
Expand Down
3 changes: 3 additions & 0 deletions gpu4pyscf/lib/dftd3.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ def __init__(self, mol, xc, version='d3bj', atm=False):
err,
ctypes.create_string_buffer(xc.encode(), size=50),
ctypes.c_bool(atm))

libdftd3.dftd3_delete_error(ctypes.byref(err))

def __del__(self):
Expand Down Expand Up @@ -106,5 +107,7 @@ def get_dispersion(self, grad=False):
res.update(gradient=_gradient)
if _sigma is not None:
res.update(virial=_sigma)

libdftd3.dftd3_delete_error(ctypes.byref(err))

return res
3 changes: 3 additions & 0 deletions gpu4pyscf/lib/dftd4.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ def __init__(self, mol, xc, atm=False):
err,
ctypes.create_string_buffer(xc.encode(), size=50),
ctypes.c_bool(atm))

libdftd4.dftd4_delete_error(ctypes.byref(err))

def __del__(self):
Expand Down Expand Up @@ -94,5 +95,7 @@ def get_dispersion(self, grad=False):
res.update(gradient=_gradient)
if _sigma is not None:
res.update(virial=_sigma)

libdftd4.dftd4_delete_error(ctypes.byref(err))

return res

0 comments on commit bea6772

Please sign in to comment.