Skip to content

Commit

Permalink
Fixed noop grid return
Browse files Browse the repository at this point in the history
  • Loading branch information
ceriottm committed Nov 29, 2024
1 parent 2df0718 commit ee1111c
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 9 deletions.
2 changes: 1 addition & 1 deletion ipi/utils/mathtools.py
Original file line number Diff line number Diff line change
Expand Up @@ -603,7 +603,7 @@ def roots_legendre(L):
def get_rotation_quadrature_legendre(L):
if L == 1:
# returns the identity (for some reason this algo below generates a different rotation)
return [(np.eye(3), 2.0)]
return [(np.eye(3), 2.0, [0, 0, 0])]
quads = []
for theta_index in range(0, 2 * L - 1):
for w_index in range(0, 2 * L - 1):
Expand Down
15 changes: 7 additions & 8 deletions ipi_tests/test_tools.py
Original file line number Diff line number Diff line change
Expand Up @@ -186,17 +186,16 @@ def modify_xml_4_dummy_test(
root = tree.getroot()
clients = list()

ff_roots = [root]
if len(root.findall("ffcommittee")) > 0:
ff_roots = root.findall("ffcommittee")
else:
ff_roots = [root]
ff_roots += root.findall("ffcommittee")
if len(root.findall("ffrotations")) > 0:
ff_roots += root.findall("ffrotations")

ff_sockets = []
for ff_root in ff_roots:
for ff_socket in ff_root.findall("ffsocket"):
ff_sockets.append(ff_socket)
for ff_socket in ff_root.findall("ffrotations"):
ff_sockets.append(ff_socket)
for ff_socket in ff_root.findall("ffcavphsocket"):
ff_sockets.append(ff_socket)

Expand Down Expand Up @@ -325,7 +324,7 @@ def run(self, cwd, nid):
print("List all files /tmp/ipi_*")
for filename in glob.glob("/tmp/ipi_*"):
print(filename)
ipi_error = ipi.communicate(timeout=120)[1].decode("ascii")
ipi_error = ipi.communicate(timeout=10)[1].decode("ascii")
print(ipi_error)
return "Could not find the i-PI UNIX socket"

Expand Down Expand Up @@ -378,13 +377,13 @@ def run(self, cwd, nid):
drivers.append(driver)

# check i-pi errors
ipi_out, ipi_error = ipi.communicate(timeout=60)
ipi_out, ipi_error = ipi.communicate(timeout=10)
assert ipi.returncode == 0, "i-PI error occurred: {}".format(ipi_error)

# check driver errors
for driver in drivers:
# if i-PI has ended, we can wait for the driver to quit
driver_out, driver_err = driver.communicate(timeout=60)
driver_out, driver_err = driver.communicate(timeout=10)
assert (
driver.returncode == 0
), "Driver error occurred: {}\n Driver Output: {}".format(
Expand Down

0 comments on commit ee1111c

Please sign in to comment.