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
VIGNET Pierre
cadbiom
Commits
48687051
Commit
48687051
authored
Jan 26, 2017
by
VIGNET Pierre
Browse files
Add method to generate a formula whith combinations: negate explicitly other elements in the set
parent
8ef40598
Changes
3
Hide whitespace changes
Inline
Side-by-side
Makefile
View file @
48687051
...
...
@@ -32,7 +32,7 @@ t1:
t2
:
$(CMD_PYTHON)
script_mac.py
-vv
debug compute_macs bio_models/pid_and_clock.bcx SRP9
--steps
7
--output
p2
t3
:
$(CMD_PYTHON)
script_mac.py
-vv
debug compute_macs bio_models/
pid_or_clock
.bcx SRP9
--steps
10
--output
p3
$(CMD_PYTHON)
script_mac.py
-vv
debug compute_macs
"
bio_models/
Whole NCI-PID database translated into CADBIOM formalism(and)
.bcx
"
SRP9
--all_macs
--steps
10
--output
p3
t3bis
:
$(CMD_PYTHON)
script_mac.py
-vv
info compute_macs
"bio_models/Whole NCI-PID database translated into CADBIOM formalism(and).bcx"
SRP9
--steps
10
--output
p3bis
t4
:
...
...
@@ -44,7 +44,7 @@ t6:
t7
:
$(CMD_PYTHON)
script_mac.py
-vv
debug compute_macs bio_models/pid_or_clock.bcx CCR5
--steps
7
--output
p7
real_study
:
$(CMD_PYTHON)
script_mac.py
-vv
info compute_macs
"bio_models/Whole NCI-PID database translated into CADBIOM formalism(and).bcx"
--input_file
--steps
7
--all_macs
--input_file
bio_models/input_places.txt
--combinations
$(CMD_PYTHON)
script_mac.py
-vv
info compute_macs
"bio_models/Whole NCI-PID database translated into CADBIOM formalism(and).bcx"
--steps
7
--all_macs
--input_file
bio_models/input_places.txt
--combinations
version
:
...
...
script_cluster.sh
View file @
48687051
...
...
@@ -5,19 +5,14 @@
#$ -cwd
#$ -N cadbiom_analysis_dyliss
#$ -j yes
#$ -pe make 10
# Demande de noeud sur le cluster
#qrsh
# Chargement de python 2
.
/softs/local/env/envpython-2.7.sh
.
/softs/local/env/envswig.sh
.
/softs/local/env/envgcc-5.2.0.sh
.
/softs/local/env/envcmake-3.4.3.sh
#. /softs/local/env/envswig.sh
#. /softs/local/env/envcmake-3.4.3.sh
# Chargement de la tâche
script_mac.py
View file @
48687051
...
...
@@ -119,7 +119,7 @@ def main2(chart_file, cam_file, cam_step_file, cam_complete_file, cam_strong_fil
:param arg7: Formula: Property that the solver looks for.
:param arg8: Formula: Original property (constraint) for the solver.
:param arg9: Formula: ???
:param arg10: If set to True (not default), search all
ways
macs with
:param arg10: If set to True (not default), search all macs with
less or equal steps than previous, by limiting steps.
:type arg1: <str>
:type arg2: <str>
...
...
@@ -434,10 +434,26 @@ def compute_combinations(final_properties):
:rtype: <list <str>>
"""
final_properties
=
set
(
final_properties
)
def
get_formula
(
data
):
"""Include all elements in the combinations and exclude explicitely,
all other elements.
"""
negated_places
=
' and not '
.
join
(
final_properties
-
data
)
return
"{}{}{}"
.
format
(
' and '
.
join
(
data
),
' and not '
if
negated_places
!=
''
else
''
,
negated_places
)
all_combinations
=
list
()
for
i
in
range
(
1
,
len
(
final_properties
)
+
1
):
all_combinations
.
append
(
[
' and '
.
join
(
comb
)
for
comb
in
it
.
combinations
(
final_properties
,
i
)
]
{
get_formula
(
set
(
comb
)
)
for
comb
in
it
.
combinations
(
final_properties
,
i
)
}
)
# Unpack combinations
...
...
@@ -449,6 +465,7 @@ def compute_combinations(final_properties):
)
LOGGER
.
info
(
"Number of computed combinations: "
+
\
str
(
len
(
all_combinations
)))
return
all_combinations
...
...
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