{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DerivingStrategies #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE PatternSynonyms #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
module Amazonka.Forecast.Types.OptimizationMetric
( OptimizationMetric
( ..,
OptimizationMetric_AverageWeightedQuantileLoss,
OptimizationMetric_MAPE,
OptimizationMetric_MASE,
OptimizationMetric_RMSE,
OptimizationMetric_WAPE
),
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Prelude as Prelude
newtype OptimizationMetric = OptimizationMetric'
{ OptimizationMetric -> Text
fromOptimizationMetric ::
Core.Text
}
deriving stock
( Int -> OptimizationMetric -> ShowS
[OptimizationMetric] -> ShowS
OptimizationMetric -> String
(Int -> OptimizationMetric -> ShowS)
-> (OptimizationMetric -> String)
-> ([OptimizationMetric] -> ShowS)
-> Show OptimizationMetric
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [OptimizationMetric] -> ShowS
$cshowList :: [OptimizationMetric] -> ShowS
show :: OptimizationMetric -> String
$cshow :: OptimizationMetric -> String
showsPrec :: Int -> OptimizationMetric -> ShowS
$cshowsPrec :: Int -> OptimizationMetric -> ShowS
Prelude.Show,
ReadPrec [OptimizationMetric]
ReadPrec OptimizationMetric
Int -> ReadS OptimizationMetric
ReadS [OptimizationMetric]
(Int -> ReadS OptimizationMetric)
-> ReadS [OptimizationMetric]
-> ReadPrec OptimizationMetric
-> ReadPrec [OptimizationMetric]
-> Read OptimizationMetric
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [OptimizationMetric]
$creadListPrec :: ReadPrec [OptimizationMetric]
readPrec :: ReadPrec OptimizationMetric
$creadPrec :: ReadPrec OptimizationMetric
readList :: ReadS [OptimizationMetric]
$creadList :: ReadS [OptimizationMetric]
readsPrec :: Int -> ReadS OptimizationMetric
$creadsPrec :: Int -> ReadS OptimizationMetric
Prelude.Read,
OptimizationMetric -> OptimizationMetric -> Bool
(OptimizationMetric -> OptimizationMetric -> Bool)
-> (OptimizationMetric -> OptimizationMetric -> Bool)
-> Eq OptimizationMetric
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: OptimizationMetric -> OptimizationMetric -> Bool
$c/= :: OptimizationMetric -> OptimizationMetric -> Bool
== :: OptimizationMetric -> OptimizationMetric -> Bool
$c== :: OptimizationMetric -> OptimizationMetric -> Bool
Prelude.Eq,
Eq OptimizationMetric
Eq OptimizationMetric
-> (OptimizationMetric -> OptimizationMetric -> Ordering)
-> (OptimizationMetric -> OptimizationMetric -> Bool)
-> (OptimizationMetric -> OptimizationMetric -> Bool)
-> (OptimizationMetric -> OptimizationMetric -> Bool)
-> (OptimizationMetric -> OptimizationMetric -> Bool)
-> (OptimizationMetric -> OptimizationMetric -> OptimizationMetric)
-> (OptimizationMetric -> OptimizationMetric -> OptimizationMetric)
-> Ord OptimizationMetric
OptimizationMetric -> OptimizationMetric -> Bool
OptimizationMetric -> OptimizationMetric -> Ordering
OptimizationMetric -> OptimizationMetric -> OptimizationMetric
forall a.
Eq a
-> (a -> a -> Ordering)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> a)
-> (a -> a -> a)
-> Ord a
min :: OptimizationMetric -> OptimizationMetric -> OptimizationMetric
$cmin :: OptimizationMetric -> OptimizationMetric -> OptimizationMetric
max :: OptimizationMetric -> OptimizationMetric -> OptimizationMetric
$cmax :: OptimizationMetric -> OptimizationMetric -> OptimizationMetric
>= :: OptimizationMetric -> OptimizationMetric -> Bool
$c>= :: OptimizationMetric -> OptimizationMetric -> Bool
> :: OptimizationMetric -> OptimizationMetric -> Bool
$c> :: OptimizationMetric -> OptimizationMetric -> Bool
<= :: OptimizationMetric -> OptimizationMetric -> Bool
$c<= :: OptimizationMetric -> OptimizationMetric -> Bool
< :: OptimizationMetric -> OptimizationMetric -> Bool
$c< :: OptimizationMetric -> OptimizationMetric -> Bool
compare :: OptimizationMetric -> OptimizationMetric -> Ordering
$ccompare :: OptimizationMetric -> OptimizationMetric -> Ordering
$cp1Ord :: Eq OptimizationMetric
Prelude.Ord,
(forall x. OptimizationMetric -> Rep OptimizationMetric x)
-> (forall x. Rep OptimizationMetric x -> OptimizationMetric)
-> Generic OptimizationMetric
forall x. Rep OptimizationMetric x -> OptimizationMetric
forall x. OptimizationMetric -> Rep OptimizationMetric x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep OptimizationMetric x -> OptimizationMetric
$cfrom :: forall x. OptimizationMetric -> Rep OptimizationMetric x
Prelude.Generic
)
deriving newtype
( Int -> OptimizationMetric -> Int
OptimizationMetric -> Int
(Int -> OptimizationMetric -> Int)
-> (OptimizationMetric -> Int) -> Hashable OptimizationMetric
forall a. (Int -> a -> Int) -> (a -> Int) -> Hashable a
hash :: OptimizationMetric -> Int
$chash :: OptimizationMetric -> Int
hashWithSalt :: Int -> OptimizationMetric -> Int
$chashWithSalt :: Int -> OptimizationMetric -> Int
Prelude.Hashable,
OptimizationMetric -> ()
(OptimizationMetric -> ()) -> NFData OptimizationMetric
forall a. (a -> ()) -> NFData a
rnf :: OptimizationMetric -> ()
$crnf :: OptimizationMetric -> ()
Prelude.NFData,
Text -> Either String OptimizationMetric
(Text -> Either String OptimizationMetric)
-> FromText OptimizationMetric
forall a. (Text -> Either String a) -> FromText a
fromText :: Text -> Either String OptimizationMetric
$cfromText :: Text -> Either String OptimizationMetric
Core.FromText,
OptimizationMetric -> Text
(OptimizationMetric -> Text) -> ToText OptimizationMetric
forall a. (a -> Text) -> ToText a
toText :: OptimizationMetric -> Text
$ctoText :: OptimizationMetric -> Text
Core.ToText,
OptimizationMetric -> ByteString
(OptimizationMetric -> ByteString)
-> ToByteString OptimizationMetric
forall a. (a -> ByteString) -> ToByteString a
toBS :: OptimizationMetric -> ByteString
$ctoBS :: OptimizationMetric -> ByteString
Core.ToByteString,
OptimizationMetric -> ByteStringBuilder
(OptimizationMetric -> ByteStringBuilder)
-> ToLog OptimizationMetric
forall a. (a -> ByteStringBuilder) -> ToLog a
build :: OptimizationMetric -> ByteStringBuilder
$cbuild :: OptimizationMetric -> ByteStringBuilder
Core.ToLog,
HeaderName -> OptimizationMetric -> [Header]
(HeaderName -> OptimizationMetric -> [Header])
-> ToHeader OptimizationMetric
forall a. (HeaderName -> a -> [Header]) -> ToHeader a
toHeader :: HeaderName -> OptimizationMetric -> [Header]
$ctoHeader :: HeaderName -> OptimizationMetric -> [Header]
Core.ToHeader,
OptimizationMetric -> QueryString
(OptimizationMetric -> QueryString) -> ToQuery OptimizationMetric
forall a. (a -> QueryString) -> ToQuery a
toQuery :: OptimizationMetric -> QueryString
$ctoQuery :: OptimizationMetric -> QueryString
Core.ToQuery,
Value -> Parser [OptimizationMetric]
Value -> Parser OptimizationMetric
(Value -> Parser OptimizationMetric)
-> (Value -> Parser [OptimizationMetric])
-> FromJSON OptimizationMetric
forall a.
(Value -> Parser a) -> (Value -> Parser [a]) -> FromJSON a
parseJSONList :: Value -> Parser [OptimizationMetric]
$cparseJSONList :: Value -> Parser [OptimizationMetric]
parseJSON :: Value -> Parser OptimizationMetric
$cparseJSON :: Value -> Parser OptimizationMetric
Core.FromJSON,
FromJSONKeyFunction [OptimizationMetric]
FromJSONKeyFunction OptimizationMetric
FromJSONKeyFunction OptimizationMetric
-> FromJSONKeyFunction [OptimizationMetric]
-> FromJSONKey OptimizationMetric
forall a.
FromJSONKeyFunction a -> FromJSONKeyFunction [a] -> FromJSONKey a
fromJSONKeyList :: FromJSONKeyFunction [OptimizationMetric]
$cfromJSONKeyList :: FromJSONKeyFunction [OptimizationMetric]
fromJSONKey :: FromJSONKeyFunction OptimizationMetric
$cfromJSONKey :: FromJSONKeyFunction OptimizationMetric
Core.FromJSONKey,
[OptimizationMetric] -> Encoding
[OptimizationMetric] -> Value
OptimizationMetric -> Encoding
OptimizationMetric -> Value
(OptimizationMetric -> Value)
-> (OptimizationMetric -> Encoding)
-> ([OptimizationMetric] -> Value)
-> ([OptimizationMetric] -> Encoding)
-> ToJSON OptimizationMetric
forall a.
(a -> Value)
-> (a -> Encoding)
-> ([a] -> Value)
-> ([a] -> Encoding)
-> ToJSON a
toEncodingList :: [OptimizationMetric] -> Encoding
$ctoEncodingList :: [OptimizationMetric] -> Encoding
toJSONList :: [OptimizationMetric] -> Value
$ctoJSONList :: [OptimizationMetric] -> Value
toEncoding :: OptimizationMetric -> Encoding
$ctoEncoding :: OptimizationMetric -> Encoding
toJSON :: OptimizationMetric -> Value
$ctoJSON :: OptimizationMetric -> Value
Core.ToJSON,
ToJSONKeyFunction [OptimizationMetric]
ToJSONKeyFunction OptimizationMetric
ToJSONKeyFunction OptimizationMetric
-> ToJSONKeyFunction [OptimizationMetric]
-> ToJSONKey OptimizationMetric
forall a.
ToJSONKeyFunction a -> ToJSONKeyFunction [a] -> ToJSONKey a
toJSONKeyList :: ToJSONKeyFunction [OptimizationMetric]
$ctoJSONKeyList :: ToJSONKeyFunction [OptimizationMetric]
toJSONKey :: ToJSONKeyFunction OptimizationMetric
$ctoJSONKey :: ToJSONKeyFunction OptimizationMetric
Core.ToJSONKey,
[Node] -> Either String OptimizationMetric
([Node] -> Either String OptimizationMetric)
-> FromXML OptimizationMetric
forall a. ([Node] -> Either String a) -> FromXML a
parseXML :: [Node] -> Either String OptimizationMetric
$cparseXML :: [Node] -> Either String OptimizationMetric
Core.FromXML,
OptimizationMetric -> XML
(OptimizationMetric -> XML) -> ToXML OptimizationMetric
forall a. (a -> XML) -> ToXML a
toXML :: OptimizationMetric -> XML
$ctoXML :: OptimizationMetric -> XML
Core.ToXML
)
pattern OptimizationMetric_AverageWeightedQuantileLoss :: OptimizationMetric
pattern $bOptimizationMetric_AverageWeightedQuantileLoss :: OptimizationMetric
$mOptimizationMetric_AverageWeightedQuantileLoss :: forall r. OptimizationMetric -> (Void# -> r) -> (Void# -> r) -> r
OptimizationMetric_AverageWeightedQuantileLoss = OptimizationMetric' "AverageWeightedQuantileLoss"
pattern OptimizationMetric_MAPE :: OptimizationMetric
pattern $bOptimizationMetric_MAPE :: OptimizationMetric
$mOptimizationMetric_MAPE :: forall r. OptimizationMetric -> (Void# -> r) -> (Void# -> r) -> r
OptimizationMetric_MAPE = OptimizationMetric' "MAPE"
pattern OptimizationMetric_MASE :: OptimizationMetric
pattern $bOptimizationMetric_MASE :: OptimizationMetric
$mOptimizationMetric_MASE :: forall r. OptimizationMetric -> (Void# -> r) -> (Void# -> r) -> r
OptimizationMetric_MASE = OptimizationMetric' "MASE"
pattern OptimizationMetric_RMSE :: OptimizationMetric
pattern $bOptimizationMetric_RMSE :: OptimizationMetric
$mOptimizationMetric_RMSE :: forall r. OptimizationMetric -> (Void# -> r) -> (Void# -> r) -> r
OptimizationMetric_RMSE = OptimizationMetric' "RMSE"
pattern OptimizationMetric_WAPE :: OptimizationMetric
pattern $bOptimizationMetric_WAPE :: OptimizationMetric
$mOptimizationMetric_WAPE :: forall r. OptimizationMetric -> (Void# -> r) -> (Void# -> r) -> r
OptimizationMetric_WAPE = OptimizationMetric' "WAPE"
{-# COMPLETE
OptimizationMetric_AverageWeightedQuantileLoss,
OptimizationMetric_MAPE,
OptimizationMetric_MASE,
OptimizationMetric_RMSE,
OptimizationMetric_WAPE,
OptimizationMetric'
#-}