Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
haskell-gargantext
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
Grégoire Locqueville
haskell-gargantext
Commits
880785c0
Commit
880785c0
authored
Feb 17, 2022
by
Alexandre Delanoë
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[FIX] dot path
parent
c7ae5797
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
15 additions
and
4 deletions
+15
-4
init
bin/init
+4
-0
API.hs
src/Gargantext/Core/Viz/Phylo/API.hs
+6
-1
Tools.hs
src/Gargantext/Core/Viz/Phylo/API/Tools.hs
+2
-2
Example.hs
src/Gargantext/Core/Viz/Phylo/Example.hs
+3
-1
No files found.
bin/init
0 → 100755
View file @
880785c0
#!/bin/bash
ln
-s
$(
nix-shell
--run
"which dot"
)
~/.local/bin/dot
src/Gargantext/Core/Viz/Phylo/API.hs
View file @
880785c0
...
...
@@ -90,12 +90,17 @@ type GetPhylo = QueryParam "listId" ListId
-- Fix Filter parameters
-- TODO fix parameters to default config that should be in Node
getPhylo
::
PhyloId
->
GargServer
GetPhylo
getPhylo
phyloId
_lId
_level
_minSizeBranch
=
do
getPhylo
phyloId
_lId
_level
_minSizeBranch
=
getPhyloDataJson
phyloId
getPhyloDataJson
::
PhyloId
->
GargNoServer
Value
getPhyloDataJson
phyloId
=
do
maybePhyloData
<-
getPhyloData
phyloId
let
phyloData
=
fromMaybe
phyloExample
maybePhyloData
phyloJson
<-
liftBase
$
phylo2dot2json
phyloData
pure
phyloJson
-- getPhylo phId _lId l msb = do
-- let
-- level = fromMaybe 2 l
...
...
src/Gargantext/Core/Viz/Phylo/API/Tools.hs
View file @
880785c0
...
...
@@ -72,8 +72,8 @@ phylo2dot2json phylo = do
file_to_json
=
"/tmp/toPhylo.json"
_
<-
dotToFile
file_from
(
toPhyloExport
phylo
)
_
<-
Shell
.
callProcess
"
/usr/bin/
dot"
[
"-Tdot"
,
"-o"
,
file_dot
,
file_from
]
_
<-
Shell
.
callProcess
"
/usr/bin/
dot"
[
"-Txdot_json"
,
"-o"
,
file_to_json
,
file_dot
]
_
<-
Shell
.
callProcess
"dot"
[
"-Tdot"
,
"-o"
,
file_dot
,
file_from
]
_
<-
Shell
.
callProcess
"dot"
[
"-Txdot_json"
,
"-o"
,
file_to_json
,
file_dot
]
maybeValue
<-
decodeFileStrict
file_to_json
...
...
src/Gargantext/Core/Viz/Phylo/Example.hs
View file @
880785c0
...
...
@@ -89,7 +89,9 @@ phyloCooc = docsToTimeScaleCooc docs (foundations ^. foundations_roots)
periods
::
[(
Date
,
Date
)]
periods
=
toPeriods
(
sort
$
nub
$
map
date
docs
)
(
getTimePeriod
$
timeUnit
config
)
(
getTimeStep
$
timeUnit
config
)
periods
=
toPeriods
(
sort
$
nub
$
map
date
docs
)
(
getTimePeriod
$
timeUnit
config
)
(
getTimeStep
$
timeUnit
config
)
nbDocsByYear
::
Map
Date
Double
...
...
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