10
0
mirror of https://github.com/LCPQ/EMSL_Basis_Set_Exchange_Local synced 2024-12-22 12:23:39 +01:00

Little optimisation

This commit is contained in:
Thomas Applencourt 2015-03-17 16:11:01 +01:00
parent baebe0de19
commit 496ef739b3
3 changed files with 9 additions and 6 deletions

View File

@ -17,9 +17,9 @@ Usage:
[--check=<program_name>]
[--treat_l]
EMSL_api.py list_formats
EMSL_api.py create_db --db_path=<db_path>
--format=<format>
[--no-contraction]
EMSL_api.py create_db --format=<format>
[--db_path=<db_path>]
[--no-contraction]
EMSL_api.py (-h | --help)
EMSL_api.py --version

View File

@ -39,7 +39,6 @@ class EMSL_dump:
"""
def __init__(self, db_path=None, format="GAMESS-US", contraction="True"):
self.db_path = db_path
if format not in format_dict:
print >> sys.stderr, "Format {0} doesn't exist. Choose in:".format(
@ -57,6 +56,12 @@ class EMSL_dump:
print >> sys.stderr, "You just need to add a function like"
print >> sys.stderr, "'parse_basis_data_gamess_us' to parse you'r format"
if db_path:
self.db_path = db_path
else:
head_path = os.path.dirname(__file__)
self.db_path = "{0}/../db/{1}.db".format(head_path, self.format)
self.contraction = str(contraction)
self.debug = True
@ -233,7 +238,6 @@ class EMSL_dump:
basis_data = self.parser(text, name, des, elts,
self.debug)
except:
raise
time.sleep(0.1)
attemps += 1
else:

View File

@ -119,7 +119,6 @@ class EMSL_local:
# Else Get name,description
# 3) Parse it
# ~#~#~#~#~#~ #
# F i l t e r #
# ~#~#~#~#~#~ #