From a5735e8910440aa5355298b8f1b6fb5446ab3243 Mon Sep 17 00:00:00 2001 From: tharvik Date: Mon, 28 Oct 2024 11:24:40 +0100 Subject: [PATCH] webapp/training: nicer graphs --- .../src/components/training/TrainingInformation.vue | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/webapp/src/components/training/TrainingInformation.vue b/webapp/src/components/training/TrainingInformation.vue index bdcf1a458..d291e0e59 100644 --- a/webapp/src/components/training/TrainingInformation.vue +++ b/webapp/src/components/training/TrainingInformation.vue @@ -271,9 +271,11 @@ const commonChartsOptions = { type: "solid", opacity: 0.6, }, - stroke: { curve: "smooth" }, + stroke: { curve: "monotoneCubic" }, grid: { show: false }, xaxis: { + type: "numeric", + decimalsInFloat: 0, labels: { show: true, style: { @@ -327,9 +329,9 @@ const accuracyChartsOptions = { ...commonChartsOptions.yaxis, max: 100, min: 0, - labels: { + labels: { ...commonChartsOptions.yaxis.labels, - formatter: (value: number) => value.toFixed(0) + formatter: (value: number) => value.toFixed(0), }, }, }; @@ -348,9 +350,9 @@ const lossChartsOptions = computed(() => { ...commonChartsOptions.yaxis, max: yAxisMax, min: 0, - labels: { + labels: { ...commonChartsOptions.yaxis.labels, - formatter: (n: number) => n.toFixed(2) + formatter: (n: number) => n.toFixed(2), }, }, };