Skip to content

Commit 2a460b3

Browse files
authored
Merge pull request #45 from Exabyte-io/fix/SOF-7033
Fix/sof 7033: non-uniform convergence plotting
2 parents 73d14fb + 4a7febf commit 2a460b3

File tree

2 files changed

+11
-4
lines changed

2 files changed

+11
-4
lines changed

.github/workflows/cicd.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ jobs:
2929
uses: ./actions/yaml/lint
3030
with:
3131
python-version: 3.8
32+
targets: ./assets
3233

3334
run-js-tests:
3435
runs-on: ubuntu-latest

src/subworkflows/convergence.js

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,21 +13,27 @@ export const ConvergenceMixin = (superclass) =>
1313
return this.findUnitWithTag("hasConvergenceResult")?.operand || undefined;
1414
}
1515

16-
// TODO: investigate how scope changes between subworkflows to allow for multiple convergences per job, in different subworkflows
1716
convergenceSeries(scopeTrack) {
1817
if (!this.hasConvergence || !scopeTrack?.length) return [];
1918
let lastResult;
2019
const series = scopeTrack
21-
.map((scopeItem) => ({
22-
x: scopeItem.scope?.global[this.convergenceParam],
20+
.map((scopeItem, i) => ({
21+
x: i,
22+
param: scopeItem.scope?.global[this.convergenceParam],
2323
y: scopeItem.scope?.global[this.convergenceResult],
2424
}))
2525
.filter(({ y }) => {
2626
const isNewResult = y !== undefined && y !== lastResult;
2727
lastResult = y;
2828
return isNewResult;
2929
});
30-
return series;
30+
return series.map((item, i) => {
31+
return {
32+
x: i + 1,
33+
param: item.param,
34+
y: item.y,
35+
};
36+
});
3137
}
3238

3339
addConvergence({

0 commit comments

Comments
 (0)