Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
MDANSE
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
4
Issues
4
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Scientific Software
MDANSE
Commits
70af3d2b
Commit
70af3d2b
authored
Nov 29, 2016
by
eric pellegrini
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'hotfix-1.0.4.rc4'
parents
7c0d220c
e8291af2
Pipeline
#1201
passed with stages
in 16 minutes and 47 seconds
Changes
5
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
26 additions
and
10 deletions
+26
-10
CHANGELOG
CHANGELOG
+6
-1
MDANSE/Framework/Configurators/AtomSelectionConfigurator.py
MDANSE/Framework/Configurators/AtomSelectionConfigurator.py
+6
-3
MDANSE/Framework/Configurators/AtomTransmutationConfigurator.py
.../Framework/Configurators/AtomTransmutationConfigurator.py
+9
-3
MDANSE/Framework/Jobs/CoordinationNumber.py
MDANSE/Framework/Jobs/CoordinationNumber.py
+3
-1
MDANSE/__pkginfo__.py
MDANSE/__pkginfo__.py
+2
-2
No files found.
CHANGELOG
View file @
70af3d2b
version 1.0.4.rc2
version 1.0.4.rc4
----------------
* bug fix in coordination number analysis: some pairs were never taken into account
* bug fix when transmutating atoms from an atom selection different to 'all'
version 1.0.4.rc3
----------------
* bug fix in debian packager: add the python-setuptools dependency
* improved LAMMPS converter: the parsing of the config file is more tolerance in term of required keyword format
...
...
MDANSE/Framework/Configurators/AtomSelectionConfigurator.py
View file @
70af3d2b
...
...
@@ -105,14 +105,17 @@ class AtomSelectionConfigurator(IConfigurator):
parser
=
AtomSelectionParser
(
trajConfig
[
"instance"
])
indexes
.
update
(
parser
.
parse
(
v
))
indexes
=
sorted
(
list
(
indexes
))
self
[
"flatten_indexes"
]
=
sorted
(
list
(
indexes
))
trajConfig
=
self
.
_configurable
[
self
.
_dependencies
[
'trajectory'
]]
atoms
=
sorted
(
trajConfig
[
"universe"
].
atomList
(),
key
=
operator
.
attrgetter
(
'index'
))
selectedAtoms
=
[
atoms
[
idx
]
for
idx
in
indexes
]
self
[
"selection_length"
]
=
len
(
indexes
)
self
[
"selection_length"
]
=
len
(
self
[
"flatten_indexes"
])
self
[
'indexes'
]
=
[[
idx
]
for
idx
in
self
[
"flatten_indexes"
]]
self
[
'elements'
]
=
[[
at
.
symbol
]
for
at
in
selectedAtoms
]
self
[
'indexes'
]
=
[[
idx
]
for
idx
in
indexes
]
self
[
'names'
]
=
[
at
.
symbol
for
at
in
selectedAtoms
]
self
[
'unique_names'
]
=
sorted
(
set
(
self
[
'names'
]))
self
[
'masses'
]
=
[[
ELEMENTS
[
n
,
'atomic_weight'
]]
for
n
in
self
[
'names'
]]
...
...
MDANSE/Framework/Configurators/AtomTransmutationConfigurator.py
View file @
70af3d2b
...
...
@@ -112,12 +112,18 @@ class AtomTransmutationConfigurator(IConfigurator):
raise
ConfiguratorError
(
"the element %r is not registered in the database"
%
element
,
self
)
atomSelConfigurator
=
self
.
_configurable
[
self
.
_dependencies
[
'atom_selection'
]]
for
idx
in
selection
:
atomSelConfigurator
[
"names"
][
idx
]
=
element
atomSelConfigurator
[
"elements"
][
idx
]
=
[
element
]
try
:
idxInSelection
=
atomSelConfigurator
[
"flatten_indexes"
].
index
(
idx
)
except
ValueError
:
pass
else
:
atomSelConfigurator
[
"names"
][
idxInSelection
]
=
element
atomSelConfigurator
[
"elements"
][
idxInSelection
]
=
[
element
]
atomSelConfigurator
[
'unique_names'
]
=
sorted
(
set
(
atomSelConfigurator
[
'names'
]))
atomSelConfigurator
[
'masses'
]
=
[[
ELEMENTS
[
n
,
'atomic_weight'
]]
for
n
in
atomSelConfigurator
[
'names'
]]
def
get_information
(
self
):
'''
...
...
MDANSE/Framework/Jobs/CoordinationNumber.py
View file @
70af3d2b
...
...
@@ -93,7 +93,8 @@ class CoordinationNumber(DistanceHistogram):
self
.
_concentrations
[
k
]
/=
nFrames
nAtomsPerElement
=
self
.
configuration
[
'atom_selection'
].
get_natoms
()
for
at1
,
at2
in
self
.
_elementsPairs
:
for
pair
in
self
.
_elementsPairs
:
at1
,
at2
=
pair
ni
=
nAtomsPerElement
[
at1
]
nj
=
nAtomsPerElement
[
at2
]
...
...
@@ -120,6 +121,7 @@ class CoordinationNumber(DistanceHistogram):
cBeta
=
self
.
_concentrations
[
pair
[
1
]]
invPair
=
pair
[::
-
1
]
print
pair
,
cnIntra
self
.
_outputData
[
"cn_intra_%s%s"
%
pair
][:]
=
self
.
averageDensity
*
cBeta
*
cnIntra
self
.
_outputData
[
"cn_inter_%s%s"
%
pair
][:]
=
self
.
averageDensity
*
cBeta
*
cnInter
self
.
_outputData
[
"cn_total_%s%s"
%
pair
][:]
=
self
.
averageDensity
*
cBeta
*
cnTotal
...
...
MDANSE/__pkginfo__.py
View file @
70af3d2b
__version__
=
"1.0.4.rc
3
"
__version__
=
"1.0.4.rc
4
"
__date__
=
"2
8
-11-2016"
__date__
=
"2
9
-11-2016"
__author__
=
"Eric Pellegrini"
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