@platforma-open/milaboratories.top-antibodies.workflow 1.4.0 → 1.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.turbo/turbo-build.log +6 -6
- package/CHANGELOG.md +13 -0
- package/dist/tengo/tpl/main.plj.gz +0 -0
- package/package.json +4 -4
- package/src/main.tpl.tengo +77 -40
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
WARN Issue while reading "/home/runner/work/
|
|
1
|
+
WARN Issue while reading "/home/runner/work/antibody-tcr-lead-selection/antibody-tcr-lead-selection/.npmrc". Failed to replace env in config: ${NPMJS_TOKEN}
|
|
2
2
|
|
|
3
|
-
> @platforma-open/milaboratories.top-antibodies.workflow@1.
|
|
3
|
+
> @platforma-open/milaboratories.top-antibodies.workflow@1.6.0 build /home/runner/work/antibody-tcr-lead-selection/antibody-tcr-lead-selection/workflow
|
|
4
4
|
> rm -rf dist && pl-tengo check && pl-tengo build
|
|
5
5
|
|
|
6
6
|
Processing "src/main.tpl.tengo"...
|
|
@@ -9,9 +9,9 @@ Processing "src/pf-vj-usage-conv.lib.tengo"...
|
|
|
9
9
|
Processing "src/sampled-cols-conv.lib.tengo"...
|
|
10
10
|
No syntax errors found.
|
|
11
11
|
info: Compiling 'dist'...
|
|
12
|
-
info: - writing /home/runner/work/
|
|
13
|
-
info: - writing /home/runner/work/
|
|
14
|
-
info: - writing /home/runner/work/
|
|
15
|
-
info: - writing /home/runner/work/
|
|
12
|
+
info: - writing /home/runner/work/antibody-tcr-lead-selection/antibody-tcr-lead-selection/workflow/dist/tengo/lib/pf-spectratype-conv.lib.tengo
|
|
13
|
+
info: - writing /home/runner/work/antibody-tcr-lead-selection/antibody-tcr-lead-selection/workflow/dist/tengo/lib/pf-vj-usage-conv.lib.tengo
|
|
14
|
+
info: - writing /home/runner/work/antibody-tcr-lead-selection/antibody-tcr-lead-selection/workflow/dist/tengo/lib/sampled-cols-conv.lib.tengo
|
|
15
|
+
info: - writing /home/runner/work/antibody-tcr-lead-selection/antibody-tcr-lead-selection/workflow/dist/tengo/tpl/main.plj.gz
|
|
16
16
|
info: Template Pack build done.
|
|
17
17
|
info: Template Pack build done.
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,18 @@
|
|
|
1
1
|
# @platforma-open/milaboratories.top-antibodies.workflow
|
|
2
2
|
|
|
3
|
+
## 1.6.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- d32234f: Support batch system
|
|
8
|
+
|
|
9
|
+
## 1.5.0
|
|
10
|
+
|
|
11
|
+
### Minor Changes
|
|
12
|
+
|
|
13
|
+
- bf454d4: Default ranking column in case user does not select one
|
|
14
|
+
- 4990fd8: Fix empty top and ranking cases
|
|
15
|
+
|
|
3
16
|
## 1.4.0
|
|
4
17
|
|
|
5
18
|
### Minor Changes
|
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@platforma-open/milaboratories.top-antibodies.workflow",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.6.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Block Workflow",
|
|
6
6
|
"dependencies": {
|
|
7
|
-
"@platforma-sdk/workflow-tengo": "^4.7.
|
|
7
|
+
"@platforma-sdk/workflow-tengo": "^4.7.4",
|
|
8
8
|
"@platforma-open/milaboratories.top-antibodies.spectratype": "1.3.2",
|
|
9
9
|
"@platforma-open/milaboratories.top-antibodies.umap": "1.0.3",
|
|
10
10
|
"@platforma-open/milaboratories.top-antibodies.sample-clonotypes": "1.0.3"
|
|
11
11
|
},
|
|
12
12
|
"devDependencies": {
|
|
13
|
-
"@platforma-sdk/tengo-builder": "^2.1.
|
|
14
|
-
"@platforma-sdk/test": "
|
|
13
|
+
"@platforma-sdk/tengo-builder": "^2.1.10",
|
|
14
|
+
"@platforma-sdk/test": "1.32.11",
|
|
15
15
|
"vitest": "^2.1.8"
|
|
16
16
|
},
|
|
17
17
|
"scripts": {
|
package/src/main.tpl.tengo
CHANGED
|
@@ -16,10 +16,17 @@ wf.prepare(func(args){
|
|
|
16
16
|
bundleBuilder.ignoreMissingDomains() // to make query work for both bulk and single cell data
|
|
17
17
|
bundleBuilder.addAnchor("main", args.inputAnchor)
|
|
18
18
|
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
19
|
+
if len(args.rankingOrder) > 0 {
|
|
20
|
+
for col in args.rankingOrder {
|
|
21
|
+
bundleBuilder.addAnchor(col.value.anchorName, col.value.anchorRef)
|
|
22
|
+
bundleBuilder.addSingle(col.value.column)
|
|
23
|
+
}
|
|
24
|
+
} else {
|
|
25
|
+
bundleBuilder.addAnchor(args.rankingOrderDefault.value.anchorName,
|
|
26
|
+
args.rankingOrderDefault.value.anchorRef)
|
|
27
|
+
bundleBuilder.addSingle(args.rankingOrderDefault.value.column)
|
|
22
28
|
}
|
|
29
|
+
|
|
23
30
|
|
|
24
31
|
// Add linker column
|
|
25
32
|
bundleBuilder.addMulti({
|
|
@@ -89,46 +96,68 @@ wf.body(func(args) {
|
|
|
89
96
|
|
|
90
97
|
////////// Clonotype Filtering //////////
|
|
91
98
|
|
|
92
|
-
|
|
93
|
-
cloneTable := pframes.csvFileBuilder()
|
|
94
|
-
cloneTable.setAxisHeader(datasetSpec.axesSpec[1].name, "clonotypeKey")
|
|
95
|
-
|
|
96
|
-
for i, col in args.rankingOrder {
|
|
97
|
-
cloneTable.add(columns.getColumn(col.value.column), {header: "Col" + string(i)})
|
|
98
|
-
|
|
99
|
-
// If column does not have main anchor axis we have to include theirs
|
|
100
|
-
colsSpec := columns.getSpec(col.value.column)
|
|
101
|
-
axesNames := slices.map(colsSpec.axesSpec, func (a) { return a.name})
|
|
102
|
-
if !slices.hasElement(axesNames, datasetSpec.axesSpec[1].name) {
|
|
103
|
-
for na, ax in colsSpec.axesSpec {
|
|
104
|
-
if ax.name != datasetSpec.axesSpec[1].name {
|
|
105
|
-
cloneTable.setAxisHeader(ax.name, "cluster_" + string(i) + string(na))
|
|
106
|
-
}
|
|
107
|
-
}
|
|
108
|
-
}
|
|
109
|
-
}
|
|
99
|
+
topClonotypesCsv := undefined
|
|
110
100
|
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
101
|
+
if topClonotypes != undefined {
|
|
102
|
+
// Build clonotype table
|
|
103
|
+
cloneTable := pframes.csvFileBuilder()
|
|
104
|
+
cloneTable.setAxisHeader(datasetSpec.axesSpec[1].name, "clonotypeKey")
|
|
105
|
+
|
|
106
|
+
if len(args.rankingOrder) > 0 {
|
|
107
|
+
for i, col in args.rankingOrder {
|
|
108
|
+
cloneTable.add(columns.getColumn(col.value.column), {header: "Col" + string(i)})
|
|
109
|
+
|
|
110
|
+
// If column does not have main anchor axis we have to include theirs
|
|
111
|
+
colsSpec := columns.getSpec(col.value.column)
|
|
112
|
+
axesNames := slices.map(colsSpec.axesSpec, func (a) { return a.name})
|
|
113
|
+
if !slices.hasElement(axesNames, datasetSpec.axesSpec[1].name) {
|
|
114
|
+
for na, ax in colsSpec.axesSpec {
|
|
115
|
+
if ax.name != datasetSpec.axesSpec[1].name {
|
|
116
|
+
cloneTable.setAxisHeader(ax.name, "cluster_" + string(i) + string(na))
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
} else {
|
|
122
|
+
i := 0
|
|
123
|
+
cloneTable.add(columns.getColumn(args.rankingOrderDefault.value.column), {header: "Col" + string(i)})
|
|
124
|
+
|
|
125
|
+
// If column does not have main anchor axis we have to include theirs
|
|
126
|
+
colsSpec := columns.getSpec(args.rankingOrderDefault.value.column)
|
|
127
|
+
axesNames := slices.map(colsSpec.axesSpec, func (a) { return a.name})
|
|
128
|
+
if !slices.hasElement(axesNames, datasetSpec.axesSpec[1].name) {
|
|
129
|
+
for na, ax in colsSpec.axesSpec {
|
|
130
|
+
if ax.name != datasetSpec.axesSpec[1].name {
|
|
131
|
+
cloneTable.setAxisHeader(ax.name, "cluster_" + string(i) + string(na))
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
}
|
|
122
135
|
}
|
|
123
|
-
}
|
|
124
|
-
cloneTable = cloneTable.build()
|
|
125
136
|
|
|
126
|
-
|
|
137
|
+
// Columns gotten by query require .key
|
|
138
|
+
linkerAxisSpec := {}
|
|
139
|
+
if len(columns.getColumns("linkers")) > 0 {
|
|
140
|
+
for i, col in columns.getColumns("linkers") {
|
|
141
|
+
if datasetSpec.axesSpec[1].name == col.spec.axesSpec[1].name {
|
|
142
|
+
cloneTable.add(col, {header: "linker." + string(i)})
|
|
143
|
+
cloneTable.setAxisHeader(col.spec.axesSpec[0].name, "cluster_" + string(i))
|
|
144
|
+
linkerAxisSpec["cluster_" + string(i)] = col.spec.axesSpec[0]
|
|
145
|
+
} else if datasetSpec.axesSpec[1].name == col.spec.axesSpec[0].name {
|
|
146
|
+
cloneTable.add(col, {header: "linker." + string(i)})
|
|
147
|
+
cloneTable.setAxisHeader(col.spec.axesSpec[1].name, "cluster_" + string(i))
|
|
148
|
+
linkerAxisSpec["cluster_" + string(i)] = col.spec.axesSpec[1]
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
}
|
|
152
|
+
cloneTable.mem("16GiB")
|
|
153
|
+
cloneTable.cpu(1)
|
|
154
|
+
cloneTable = cloneTable.build()
|
|
127
155
|
|
|
128
|
-
if topClonotypes != undefined {
|
|
129
156
|
// Run sampling script
|
|
130
157
|
sampleClones := exec.builder().
|
|
131
158
|
software(assets.importSoftware("@platforma-open/milaboratories.top-antibodies.sample-clonotypes:main")).
|
|
159
|
+
mem("16GiB").
|
|
160
|
+
cpu(1).
|
|
132
161
|
addFile("filteredClonotypes.csv", cloneTable).
|
|
133
162
|
arg("--csv").arg("filteredClonotypes.csv").
|
|
134
163
|
arg("--n").arg(string(topClonotypes)).
|
|
@@ -144,7 +173,8 @@ wf.body(func(args) {
|
|
|
144
173
|
|
|
145
174
|
// Store outputs
|
|
146
175
|
sampledColsParams := sampledColsConv.getColumns(datasetSpec)
|
|
147
|
-
sampledColumnsPf := xsv.importFile(topClonotypesCsv, "csv", sampledColsParams
|
|
176
|
+
sampledColumnsPf := xsv.importFile(topClonotypesCsv, "csv", sampledColsParams,
|
|
177
|
+
{cpu: 1, mem: "16GiB"})
|
|
148
178
|
outputs["sampledRows"] = pframes.exportFrame(sampledColumnsPf)
|
|
149
179
|
}
|
|
150
180
|
|
|
@@ -203,11 +233,14 @@ wf.body(func(args) {
|
|
|
203
233
|
headerName := makeHeaderName(col, "jGene", isSingleCell)
|
|
204
234
|
cdr3SeqTable.add(col, {header: headerName})
|
|
205
235
|
}
|
|
206
|
-
|
|
236
|
+
cdr3SeqTable.mem("16GiB")
|
|
237
|
+
cdr3SeqTable.cpu(1)
|
|
207
238
|
cdr3SeqTableBuilt := cdr3SeqTable.build()
|
|
208
239
|
|
|
209
240
|
cdr3VspectratypeCmd := exec.builder().
|
|
210
241
|
software(assets.importSoftware("@platforma-open/milaboratories.top-antibodies.spectratype:main")).
|
|
242
|
+
mem("16GiB").
|
|
243
|
+
cpu(1).
|
|
211
244
|
addFile("cdr3_sequences_input.tsv", cdr3SeqTableBuilt).
|
|
212
245
|
arg("--input_tsv").arg("cdr3_sequences_input.tsv").
|
|
213
246
|
arg("--spectratype_tsv").arg("spectratype.tsv").
|
|
@@ -231,11 +264,15 @@ wf.body(func(args) {
|
|
|
231
264
|
|
|
232
265
|
// For spectratype structure is [chain][cdr3Length][vGene] -> count
|
|
233
266
|
|
|
234
|
-
cdr3VspectratypePf := xsv.importFile(cdr3VspectratypeCmd.getFile("spectratype.tsv"),
|
|
267
|
+
cdr3VspectratypePf := xsv.importFile(cdr3VspectratypeCmd.getFile("spectratype.tsv"),
|
|
268
|
+
"tsv", spectratypeConv.getColumns(),
|
|
269
|
+
{cpu: 1, mem: "16GiB"})
|
|
235
270
|
outputs["cdr3VspectratypePf"] = pframes.exportFrame(cdr3VspectratypePf)
|
|
236
271
|
|
|
237
272
|
// For vjUsage structure is [chain][vGene][jGene] -> count
|
|
238
|
-
vjUsagePf := xsv.importFile(cdr3VspectratypeCmd.getFile("vj_usage.tsv"),
|
|
273
|
+
vjUsagePf := xsv.importFile(cdr3VspectratypeCmd.getFile("vj_usage.tsv"),
|
|
274
|
+
"tsv", vjUsageConv.getColumns(),
|
|
275
|
+
{cpu: 1, mem: "16GiB"})
|
|
239
276
|
outputs["vjUsagePf"] = pframes.exportFrame(vjUsagePf)
|
|
240
277
|
|
|
241
278
|
return {
|