Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
nomad-lab
parser-lib-atoms
Commits
d7bfc62d
Commit
d7bfc62d
authored
Mar 02, 2019
by
Daniel Speckhard
Browse files
Commented Trajectory Information.
parent
b3f6f3a8
Changes
2
Hide whitespace changes
Inline
Side-by-side
libatomsparser/libAtomsParser.py
View file @
d7bfc62d
...
...
@@ -27,13 +27,13 @@ from contextlib import contextmanager
from
libatomsparser.libLibAtomsParser
import
*
try
:
from
libMomo
import
osio
,
endl
,
flush
osio
.
ConnectToFile
(
'parser.osio.log'
)
green
=
osio
.
mg
except
:
osio
=
endl
=
flush
=
None
green
=
None
#
try:
#
from libMomo import osio, endl, flush
#
osio.ConnectToFile('parser.osio.log')
#
green = osio.mg
#
except:
osio
=
endl
=
flush
=
None
green
=
None
parser_info
=
{
"name"
:
"parser-lib-atoms"
,
...
...
libatomsparser/libLibAtomsParser.py
View file @
d7bfc62d
...
...
@@ -287,15 +287,15 @@ class LibAtomsGapParser(LibAtomsParser):
node
=
child_nodes
[
key
][
0
]
text
=
XmlGetText
(
node
)
trj_file
=
'lib-atoms-gap.from-xml.xyz'
ofs
=
open
(
trj_file
,
'w'
)
for
child
in
node
.
childNodes
:
if
child
.
nodeValue
==
None
:
continue
ln
=
child
.
nodeValue
.
strip
(
'
\n
'
)
if
ln
==
''
:
continue
ofs
.
write
(
ln
+
'
\n
'
)
ofs
.
close
()
#
ofs = open(trj_file, 'w')
#
for child in node.childNodes:
#
if child.nodeValue == None: continue
#
ln = child.nodeValue.strip(' \n')
#
if ln == '': continue
#
ofs.write(ln+'\n')
#
ofs.close()
self
.
trj
=
LibAtomsTrajectory
(
self
.
log
)
self
.
trj
.
ParseOutput
(
trj_file
)
#
self.trj.ParseOutput(trj_file)
return
class
LibAtomsTrajectory
(
LibAtomsParser
):
...
...
@@ -356,11 +356,6 @@ class LibAtomsFrame(LibAtomsParser):
if
key
in
self
.
ase_config
.
info
:
self
.
has_virial
=
True
self
.
virial
=
np
.
array
(
self
.
ase_config
.
info
[
key
])
return
# ===================
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment