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
120
Issues
120
List
Board
Labels
Milestones
Merge Requests
7
Merge Requests
7
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
gargantext
haskell-gargantext
Commits
f98437bf
Commit
f98437bf
authored
Jun 20, 2023
by
Alexandre Delanoë
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[FIX] Update Node Phylo
parent
138d2f86
Pipeline
#4252
passed with stages
in 111 minutes and 3 seconds
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
14 deletions
+9
-14
Update.hs
src/Gargantext/API/Node/Update.hs
+5
-11
Phylo.hs
src/Gargantext/Core/Viz/Phylo.hs
+3
-2
API.hs
src/Gargantext/Core/Viz/Phylo/API.hs
+1
-1
No files found.
src/Gargantext/API/Node/Update.hs
View file @
f98437bf
...
@@ -43,7 +43,7 @@ import Gargantext.Database.Query.Table.Node (defaultList, getNode)
...
@@ -43,7 +43,7 @@ import Gargantext.Database.Query.Table.Node (defaultList, getNode)
import
Gargantext.Database.Query.Table.Node.UpdateOpaleye
(
updateHyperdata
)
import
Gargantext.Database.Query.Table.Node.UpdateOpaleye
(
updateHyperdata
)
import
Gargantext.Database.Schema.Ngrams
(
NgramsType
(
NgramsTerms
))
import
Gargantext.Database.Schema.Ngrams
(
NgramsType
(
NgramsTerms
))
import
Gargantext.Database.Schema.Node
(
node_parent_id
)
import
Gargantext.Database.Schema.Node
(
node_parent_id
)
import
Gargantext.Prelude
(
Bool
(
..
),
Ord
,
Eq
,
(
<$>
),
(
$
),
{-printDebug,-}
pure
,
show
,
cs
,
(
<>
),
panic
,
(
<*>
))
import
Gargantext.Prelude
(
Bool
(
..
),
Ord
,
Eq
,
(
<$>
),
(
$
),
printDebug
,
pure
,
show
,
cs
,
(
<>
),
panic
,
(
<*>
))
import
Gargantext.Utils.Jobs
(
serveJobsAPI
,
MonadJobStatus
(
..
))
import
Gargantext.Utils.Jobs
(
serveJobsAPI
,
MonadJobStatus
(
..
))
import
Prelude
(
Enum
,
Bounded
,
minBound
,
maxBound
)
import
Prelude
(
Enum
,
Bounded
,
minBound
,
maxBound
)
import
Servant
import
Servant
...
@@ -155,25 +155,19 @@ updateNode _uId lId (UpdateNodeParamsList _mode) jobHandle = do
...
@@ -155,25 +155,19 @@ updateNode _uId lId (UpdateNodeParamsList _mode) jobHandle = do
updateNode
_userId
phyloId
(
UpdateNodePhylo
config
)
jobHandle
=
do
updateNode
_userId
phyloId
(
UpdateNodePhylo
config
)
jobHandle
=
do
markStarted
3
jobHandle
markStarted
3
jobHandle
corpusId'
<-
view
node_parent_id
<$>
getNode
phyloId
corpusId'
<-
view
node_parent_id
<$>
getNode
phyloId
let
corpusId
=
fromMaybe
(
panic
"UpdateNodePhylo: no corpusId"
)
corpusId'
let
corpusId
=
fromMaybe
(
panic
""
)
corpusId'
let
config'
=
subConfig2config
config
printDebug
"UpdateNodePhylo"
config'
phy
<-
flowPhyloAPI
(
subConfig2config
config
)
corpusId
phy
<-
flowPhyloAPI
config'
corpusId
markProgress
1
jobHandle
markProgress
1
jobHandle
_
<-
updateHyperdata
phyloId
(
HyperdataPhylo
Nothing
(
Just
phy
))
_
<-
updateHyperdata
phyloId
(
HyperdataPhylo
Nothing
(
Just
phy
))
markComplete
jobHandle
markComplete
jobHandle
updateNode
_uId
tId
(
UpdateNodeParamsTexts
_mode
)
jobHandle
=
do
updateNode
_uId
tId
(
UpdateNodeParamsTexts
_mode
)
jobHandle
=
do
markStarted
3
jobHandle
markStarted
3
jobHandle
corpusId
<-
view
node_parent_id
<$>
getNode
tId
corpusId
<-
view
node_parent_id
<$>
getNode
tId
lId
<-
defaultList
$
fromMaybe
(
panic
"[G.A.N.Update] updateNode/UpdateNodeParamsTexts: no defaultList"
)
corpusId
lId
<-
defaultList
$
fromMaybe
(
panic
"[G.A.N.Update] updateNode/UpdateNodeParamsTexts: no defaultList"
)
corpusId
markProgress
1
jobHandle
markProgress
1
jobHandle
_
<-
case
corpusId
of
_
<-
case
corpusId
of
...
...
src/Gargantext/Core/Viz/Phylo.hs
View file @
f98437bf
...
@@ -212,6 +212,7 @@ subConfig2config subConfig = defaultConfig { similarity = WeightedLogJaccard
...
@@ -212,6 +212,7 @@ subConfig2config subConfig = defaultConfig { similarity = WeightedLogJaccard
,
phyloQuality
=
Quality
(
_sc_phyloQuality
subConfig
)
1
,
phyloQuality
=
Quality
(
_sc_phyloQuality
subConfig
)
1
,
timeUnit
=
_sc_timeUnit
subConfig
,
timeUnit
=
_sc_timeUnit
subConfig
,
clique
=
_sc_clique
subConfig
,
clique
=
_sc_clique
subConfig
,
defaultMode
=
_sc_defaultMode
subConfig
,
exportFilter
=
[
ByBranchSize
$
_sc_exportFilter
subConfig
]
,
exportFilter
=
[
ByBranchSize
$
_sc_exportFilter
subConfig
]
}
}
...
@@ -230,9 +231,9 @@ defaultConfig =
...
@@ -230,9 +231,9 @@ defaultConfig =
,
defaultMode
=
False
,
defaultMode
=
False
,
findAncestors
=
False
,
findAncestors
=
False
,
phyloSynchrony
=
ByProximityThreshold
0.5
0
AllBranches
MergeAllGroups
,
phyloSynchrony
=
ByProximityThreshold
0.5
0
AllBranches
MergeAllGroups
,
phyloQuality
=
Quality
0.
5
1
,
phyloQuality
=
Quality
0.
3
1
,
timeUnit
=
Year
3
1
5
,
timeUnit
=
Year
3
1
5
,
clique
=
MaxClique
5
0.0001
ByThreshold
,
clique
=
Fis
3
1
--
MaxClique 5 0.0001 ByThreshold
,
exportLabel
=
[
BranchLabel
MostEmergentTfIdf
2
,
GroupLabel
MostEmergentInclusive
2
]
,
exportLabel
=
[
BranchLabel
MostEmergentTfIdf
2
,
GroupLabel
MostEmergentInclusive
2
]
,
exportSort
=
ByHierarchy
Desc
,
exportSort
=
ByHierarchy
Desc
,
exportFilter
=
[
ByBranchSize
3
]
,
exportFilter
=
[
ByBranchSize
3
]
...
...
src/Gargantext/Core/Viz/Phylo/API.hs
View file @
f98437bf
...
@@ -162,7 +162,7 @@ getPhyloDataJson phyloId = do
...
@@ -162,7 +162,7 @@ getPhyloDataJson phyloId = do
------------------------------------------------------------------------
------------------------------------------------------------------------
type
PostPhylo
=
QueryParam
"listId"
ListId
type
PostPhylo
=
QueryParam
"listId"
ListId
--
:> ReqBody '[JSON] PhyloQueryBuild
--
:> ReqBody '[JSON] PhyloQueryBuild
:>
(
Post
'[
J
SON
]
NodeId
)
:>
(
Post
'[
J
SON
]
NodeId
)
postPhylo
::
PhyloId
->
UserId
->
GargServer
PostPhylo
postPhylo
::
PhyloId
->
UserId
->
GargServer
PostPhylo
...
...
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