summaryrefslogtreecommitdiff
path: root/ml_exp/compound.py
diff options
context:
space:
mode:
authorDavid Luevano Alvarado <55825613+luevano@users.noreply.github.com>2020-02-26 05:26:21 -0700
committerDavid Luevano Alvarado <55825613+luevano@users.noreply.github.com>2020-02-26 05:26:21 -0700
commit5a85580b5f99484b957b65326ec5a19ab627d801 (patch)
treef1fc861d13651b3399ae47507d0aff84c9058a63 /ml_exp/compound.py
parentd064df5d045a5502f273814252debdb564df3ffc (diff)
Optimize qm7db reading for the rewrite
Diffstat (limited to 'ml_exp/compound.py')
-rw-r--r--ml_exp/compound.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/ml_exp/compound.py b/ml_exp/compound.py
index 8b6af0ae9..0a8b89610 100644
--- a/ml_exp/compound.py
+++ b/ml_exp/compound.py
@@ -33,7 +33,7 @@ class Compound:
Initialization of the Compound.
xyz: (path to) the xyz file.
"""
- # empty_array = np.asarray([], dtype=float)
+ self.name = None
self.n = None
self.atoms = None
@@ -137,6 +137,7 @@ class Compound:
with open(filename, 'r') as f:
lines = f.readlines()
+ self.name = filename.split('/')[-1]
self.n = int(lines[0])
self.atoms = []
self.atoms_nc = np.empty(self.n, dtype=int)