Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
esdw_1_materials
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
David W.H. Swenson
esdw_1_materials
Commits
461ce35a
Verified
Commit
461ce35a
authored
Nov 11, 2016
by
David W.H. Swenson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add empty_pathmover; empty_strategy
parent
45b7ccd1
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
37 additions
and
0 deletions
+37
-0
ops_intro_usage/empty_pathmover.py
ops_intro_usage/empty_pathmover.py
+24
-0
ops_intro_usage/empty_strategy.py
ops_intro_usage/empty_strategy.py
+13
-0
No files found.
ops_intro_usage/empty_pathmover.py
0 → 100644
View file @
461ce35a
class
MyPathMover
(
paths
.
PathMover
):
def
__init__
(
self
,
ensemble
,
my_option
):
# addition ensembles possible,
super
(
MyPathMover
,
self
).
__init__
()
self
.
ensemble
=
ensemble
self
.
my_option
=
my_option
def
_called_ensembles
(
self
):
# ensemble for input samples to __call__
return
[
self
.
ensemble
]
def
_get_in_ensembles
(
self
):
# input ensembles
return
[
self
.
ensemble
]
# _get_out_ensembles defaults to _get_in_ensembles
def
__call__
(
self
,
sample_for_ensemble
):
# additional samples possible
# do the stuff to make trial samples
details
=
{
'my_detail'
:
'value'
}
return
[
sample
],
details
ops_intro_usage/empty_strategy.py
0 → 100644
View file @
461ce35a
from
openpathsampling.high_level
import
move_strategy
class
MyStrategy
(
move_strategy
.
MoveStrategy
):
_level
=
move_strategy
.
levels
.
MOVER
def
__init__
(
self
,
my_option
,
ensembles
=
None
,
group
=
"group_name"
,
replace
=
True
):
super
(
MyStrategy
,
self
).
__init__
(
ensembles
,
group
,
replace
)
self
.
my_option
=
my_option
def
make_movers
(
self
,
scheme
):
ensemble_list
=
self
.
get_init_ensembles
(
scheme
)
# make a list of the movers
return
mover_list
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