Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
P
pycgtool
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
James Graham
pycgtool
Commits
50ee2fe1
Commit
50ee2fe1
authored
9 years ago
by
James Graham
Browse files
Options
Downloads
Patches
Plain Diff
Added command line arg for xtc output
parent
0f2ae012
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
pycgtool.py
+4
-3
4 additions, 3 deletions
pycgtool.py
pycgtool/interface.py
+2
-2
2 additions, 2 deletions
pycgtool/interface.py
with
6 additions
and
5 deletions
pycgtool.py
+
4
−
3
View file @
50ee2fe1
...
...
@@ -53,7 +53,7 @@ def main(args, config):
if
config
.
dump_measurements
:
bonds
.
dump_values
(
config
.
dump_n_values
)
if
args
.
map
and
config
.
output_xtc
:
if
args
.
map
and
(
config
.
output_xtc
or
args
.
outputxtc
)
:
cgframe
.
flush_xtc_buffer
(
"
out.xtc
"
)
...
...
@@ -69,7 +69,7 @@ def map_only(args, config):
cgframe
=
mapping
.
apply
(
frame
,
exclude
=
{
"
SOL
"
})
cgframe
.
output
(
"
out.gro
"
,
format
=
config
.
output
)
if
args
.
xtc
and
config
.
output_xtc
:
if
args
.
xtc
and
(
config
.
output_xtc
or
args
.
outputxtc
)
:
numframes
=
frame
.
numframes
-
args
.
begin
if
args
.
end
==
-
1
else
args
.
end
-
args
.
begin
for
_
in
Progress
(
numframes
,
postwhile
=
frame
.
next_frame
):
cgframe
=
mapping
.
apply
(
frame
,
cgframe
=
cgframe
,
exclude
=
{
"
SOL
"
})
...
...
@@ -87,6 +87,7 @@ if __name__ == "__main__":
input_files
.
add_argument
(
'
-i
'
,
'
--itp
'
,
type
=
str
,
help
=
"
GROMACS ITP file
"
)
parser
.
add_argument
(
'
--interactive
'
,
default
=
False
,
action
=
'
store_true
'
)
parser
.
add_argument
(
'
--outputxtc
'
,
default
=
False
,
action
=
'
store_true
'
)
# parser.add_argument('-f', '--frames', type=int, default=-1, help="Number of frames to read")
input_files
.
add_argument
(
'
--begin
'
,
type
=
int
,
default
=
0
,
help
=
"
Frame number to begin
"
)
input_files
.
add_argument
(
'
--end
'
,
type
=
int
,
default
=-
1
,
help
=
"
Frame number to end
"
)
...
...
@@ -103,7 +104,7 @@ if __name__ == "__main__":
(
"
angle_default_fc
"
,
True
),
(
"
generate_angles
"
,
True
),
(
"
generate_dihedrals
"
,
False
),
(
"
output_xtc
"
,
False
)],
(
"
output_xtc
"
,
args
.
outputxtc
)],
args
)
if
not
args
.
bnd
:
config
.
set
(
"
map_only
"
,
True
)
...
...
This diff is collapsed.
Click to expand it.
pycgtool/interface.py
+
2
−
2
View file @
50ee2fe1
...
...
@@ -156,8 +156,8 @@ class Options:
window
.
refresh
()
pos
=
0
move
=
{
"
KEY_UP
"
:
lambda
x
:
max
(
x
-
1
,
0
)
,
"
KEY_DOWN
"
:
lambda
x
:
min
(
x
+
1
,
nrows
-
1
)
,
move
=
{
"
KEY_UP
"
:
lambda
x
:
(
x
-
1
)
%
nrows
,
"
KEY_DOWN
"
:
lambda
x
:
(
x
+
1
)
%
nrows
,
"
KEY_LEFT
"
:
lambda
x
:
x
,
"
KEY_RIGHT
"
:
lambda
x
:
x
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment