From 662e1f658890ac04a04cd71271772509070b648b Mon Sep 17 00:00:00 2001 From: Anton Romanov Date: Wed, 11 Aug 2021 14:30:33 +0400 Subject: [PATCH] #5 -- restore warning message and fix readme --- README.md | 2 +- src/main/java/ru/ulstu/score/Smape.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 38e680d..147dd73 100644 --- a/README.md +++ b/README.md @@ -4,4 +4,4 @@ Build with gradle API http://localhost:8080/swagger-ui.html -Demo http://193.110.3.124:8010 \ No newline at end of file +Demo http://time-series.athene.tech/ \ No newline at end of file diff --git a/src/main/java/ru/ulstu/score/Smape.java b/src/main/java/ru/ulstu/score/Smape.java index e3d9f90..4b5af9e 100644 --- a/src/main/java/ru/ulstu/score/Smape.java +++ b/src/main/java/ru/ulstu/score/Smape.java @@ -28,7 +28,7 @@ public class Smape extends ScoreMethod { //double actualValue = getValueOnSameDate(modelValue, original).getValue(); double actualValue = Optional.ofNullable(tsValues.get(modelValue.getDate())) .orElseThrow(() -> new ModelingException("Значение модельного ряда не найдено в оригинальном ряде: " - + modelValue.getDate() + " " + tsValues + " " + model)); + + modelValue.getDate())); sum += abs(modelValue.getValue() - actualValue) / ((abs(actualValue) + abs(modelValue.getValue())) / 2); }