Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
clinicaltrials
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
david Chavalarias
clinicaltrials
Commits
b8b1a0a5
Commit
b8b1a0a5
authored
8 years ago
by
Romain Loth
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
term => kwstr (TODO term occurrences)
parent
e9c4bd09
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
3 deletions
+7
-3
extractDataCustom.py
comex_install/extractDataCustom.py
+7
-3
No files found.
comex_install/extractDataCustom.py
View file @
b8b1a0a5
...
@@ -408,12 +408,16 @@ class MyExtractor:
...
@@ -408,12 +408,16 @@ class MyExtractor:
for
idNode
in
graph
.
nodes_iter
():
for
idNode
in
graph
.
nodes_iter
():
if
idNode
[
0
]
==
"N"
:
#If it is NGram
if
idNode
[
0
]
==
"N"
:
#If it is NGram
print
(
"terms idNode:"
,
idNode
)
numID
=
int
(
idNode
.
split
(
"::"
)[
1
])
numID
=
int
(
idNode
.
split
(
"::"
)[
1
])
#
print("DBG terms_dict:", self.terms_dict)
print
(
"DBG terms_dict:"
,
self
.
terms_dict
)
try
:
try
:
nodeLabel
=
self
.
terms_dict
[
numID
][
'
term
'
]
.
replace
(
"&"
,
" and "
)
nodeLabel
=
self
.
terms_dict
[
numID
][
'
kwstr
'
]
.
replace
(
"&"
,
" and "
)
colorg
=
max
(
0
,
180
-
(
100
*
self
.
terms_colors
[
numID
]))
colorg
=
max
(
0
,
180
-
(
100
*
self
.
terms_colors
[
numID
]))
term_occ
=
self
.
terms_dict
[
numID
][
'occurrences'
]
# TODO restore keywords.occurrences
# term_occ = self.terms_dict[numID]['occurrences']
term_occ
=
1
except
KeyError
:
except
KeyError
:
print
(
"WARN: couldn't find label and meta for term "
+
str
(
numID
))
print
(
"WARN: couldn't find label and meta for term "
+
str
(
numID
))
...
...
This diff is collapsed.
Click to expand it.
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