Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
vidjil
vidjil
Commits
d140068b
Commit
d140068b
authored
Oct 05, 2018
by
Mikaël Salson
Browse files
sample_set.py: Make sure key exists before accessing it
parent
c35e3ab7
Pipeline
#42634
failed with stages
in 0 seconds
Changes
1
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
server/web2py/applications/vidjil/controllers/sample_set.py
View file @
d140068b
...
...
@@ -735,7 +735,7 @@ def getFusedStats(file_name, res, dest):
#dest['bool'] = False
#dest['bool_true'] = True
dest
[
'loci'
]
=
sorted
([
x
for
x
in
data
[
'reads'
][
'germline'
]
if
data
[
'reads'
][
'germline'
][
x
][
result_index
]
>
0
])
dest
[
'clones_five_percent'
]
=
sum
([
data
[
'reads'
][
'distribution'
][
key
][
result_index
]
for
key
in
data
[
'reads'
][
'germline'
]])
dest
[
'clones_five_percent'
]
=
sum
([
data
[
'reads'
][
'distribution'
][
key
][
result_index
]
for
key
in
data
[
'reads'
][
'germline'
]
if
key
in
data
[
'reads'
][
'distribution'
]
])
return
dest
def
getResultsStats
(
file_name
,
dest
):
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment