Add documentation and better autodetect

This commit is contained in:
Richard Berger
2020-09-17 16:38:01 -04:00
parent c06d5f7fb7
commit ab6b69d6bd
2 changed files with 41 additions and 3 deletions

View File

@ -128,8 +128,8 @@ class PythonNumpy(unittest.TestCase):
ntypes = self.lmp.extract_global("ntypes")
self.assertEqual(ntypes, 1)
x = self.lmp.numpy.extract_atom("x", dim=3)
v = self.lmp.numpy.extract_atom("v", dim=3)
x = self.lmp.numpy.extract_atom("x")
v = self.lmp.numpy.extract_atom("v")
self.assertEqual(len(x), 2)
self.assertTrue((x[0] == (1.0, 1.0, 1.0)).all())
self.assertTrue((x[1] == (1.0, 1.0, 1.5)).all())