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
32185ab9
Commit
32185ab9
authored
Mar 23, 2017
by
Romain Loth
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
workaround for tw bug when nodes > 1000
parent
adb2513a
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
2 deletions
+7
-2
asyncFA2.js
static/tinawebJS/asyncFA2.js
+7
-2
No files found.
static/tinawebJS/asyncFA2.js
View file @
32185ab9
...
...
@@ -394,7 +394,8 @@ var ForceAtlas2 = function(graph) {
this
.
p
.
jitterTolerance
=
0.1
;
}
if
(
graph
.
nodes
.
length
>=
1000
)
{
this
.
p
.
barnesHutOptimize
=
true
;
// can't use barnesHutOptimize because buildSubRegions is broken
this
.
p
.
barnesHutOptimize
=
false
;
}
else
{
this
.
p
.
barnesHutOptimize
=
false
;
}
...
...
@@ -846,7 +847,8 @@ var ForceAtlas2 = function(graph) {
};
// TODO "this" is undefined here => can't barnesHut
// ( pass as argument this_graph = ForceAtlas2.this)
var
updateMassAndGeometry
=
function
()
{
if
(
this
.
nodes
.
length
>
1
)
{
// Compute Mass
...
...
@@ -899,6 +901,9 @@ var Region = function(nodes, depth) {
}
// TODO "this" is undefined here => can't barnesHut
// ( pass as argument this_graph = ForceAtlas2.this)
var
buildSubRegions
=
function
()
{
if
(
this
.
nodes
.
length
>
1
)
{
var
leftNodes
=
[];
...
...
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