{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DerivingStrategies #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE LambdaCase #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE PatternSynonyms #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.SageMaker.Types.HyperParameterTuningJobStrategyType
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.SageMaker.Types.HyperParameterTuningJobStrategyType
  ( HyperParameterTuningJobStrategyType
      ( ..,
        HyperParameterTuningJobStrategyType_Bayesian,
        HyperParameterTuningJobStrategyType_Grid,
        HyperParameterTuningJobStrategyType_Hyperband,
        HyperParameterTuningJobStrategyType_Random
      ),
  )
where

import qualified Amazonka.Core as Core
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude

-- | The strategy hyperparameter tuning uses to find the best combination of
-- hyperparameters for your model. Currently, the only supported value is
-- @Bayesian@.
newtype HyperParameterTuningJobStrategyType = HyperParameterTuningJobStrategyType'
  { HyperParameterTuningJobStrategyType -> Text
fromHyperParameterTuningJobStrategyType ::
      Data.Text
  }
  deriving stock
    ( Int -> HyperParameterTuningJobStrategyType -> ShowS
[HyperParameterTuningJobStrategyType] -> ShowS
HyperParameterTuningJobStrategyType -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [HyperParameterTuningJobStrategyType] -> ShowS
$cshowList :: [HyperParameterTuningJobStrategyType] -> ShowS
show :: HyperParameterTuningJobStrategyType -> String
$cshow :: HyperParameterTuningJobStrategyType -> String
showsPrec :: Int -> HyperParameterTuningJobStrategyType -> ShowS
$cshowsPrec :: Int -> HyperParameterTuningJobStrategyType -> ShowS
Prelude.Show,
      ReadPrec [HyperParameterTuningJobStrategyType]
ReadPrec HyperParameterTuningJobStrategyType
Int -> ReadS HyperParameterTuningJobStrategyType
ReadS [HyperParameterTuningJobStrategyType]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [HyperParameterTuningJobStrategyType]
$creadListPrec :: ReadPrec [HyperParameterTuningJobStrategyType]
readPrec :: ReadPrec HyperParameterTuningJobStrategyType
$creadPrec :: ReadPrec HyperParameterTuningJobStrategyType
readList :: ReadS [HyperParameterTuningJobStrategyType]
$creadList :: ReadS [HyperParameterTuningJobStrategyType]
readsPrec :: Int -> ReadS HyperParameterTuningJobStrategyType
$creadsPrec :: Int -> ReadS HyperParameterTuningJobStrategyType
Prelude.Read,
      HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType -> Bool
$c/= :: HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType -> Bool
== :: HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType -> Bool
$c== :: HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType -> Bool
Prelude.Eq,
      Eq HyperParameterTuningJobStrategyType
HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType -> Bool
HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType -> Ordering
HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType
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 :: HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType
$cmin :: HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType
max :: HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType
$cmax :: HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType
>= :: HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType -> Bool
$c>= :: HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType -> Bool
> :: HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType -> Bool
$c> :: HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType -> Bool
<= :: HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType -> Bool
$c<= :: HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType -> Bool
< :: HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType -> Bool
$c< :: HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType -> Bool
compare :: HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType -> Ordering
$ccompare :: HyperParameterTuningJobStrategyType
-> HyperParameterTuningJobStrategyType -> Ordering
Prelude.Ord,
      forall x.
Rep HyperParameterTuningJobStrategyType x
-> HyperParameterTuningJobStrategyType
forall x.
HyperParameterTuningJobStrategyType
-> Rep HyperParameterTuningJobStrategyType x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep HyperParameterTuningJobStrategyType x
-> HyperParameterTuningJobStrategyType
$cfrom :: forall x.
HyperParameterTuningJobStrategyType
-> Rep HyperParameterTuningJobStrategyType x
Prelude.Generic
    )
  deriving newtype
    ( Eq HyperParameterTuningJobStrategyType
Int -> HyperParameterTuningJobStrategyType -> Int
HyperParameterTuningJobStrategyType -> Int
forall a. Eq a -> (Int -> a -> Int) -> (a -> Int) -> Hashable a
hash :: HyperParameterTuningJobStrategyType -> Int
$chash :: HyperParameterTuningJobStrategyType -> Int
hashWithSalt :: Int -> HyperParameterTuningJobStrategyType -> Int
$chashWithSalt :: Int -> HyperParameterTuningJobStrategyType -> Int
Prelude.Hashable,
      HyperParameterTuningJobStrategyType -> ()
forall a. (a -> ()) -> NFData a
rnf :: HyperParameterTuningJobStrategyType -> ()
$crnf :: HyperParameterTuningJobStrategyType -> ()
Prelude.NFData,
      Text -> Either String HyperParameterTuningJobStrategyType
forall a. (Text -> Either String a) -> FromText a
fromText :: Text -> Either String HyperParameterTuningJobStrategyType
$cfromText :: Text -> Either String HyperParameterTuningJobStrategyType
Data.FromText,
      HyperParameterTuningJobStrategyType -> Text
forall a. (a -> Text) -> ToText a
toText :: HyperParameterTuningJobStrategyType -> Text
$ctoText :: HyperParameterTuningJobStrategyType -> Text
Data.ToText,
      HyperParameterTuningJobStrategyType -> ByteString
forall a. (a -> ByteString) -> ToByteString a
toBS :: HyperParameterTuningJobStrategyType -> ByteString
$ctoBS :: HyperParameterTuningJobStrategyType -> ByteString
Data.ToByteString,
      HyperParameterTuningJobStrategyType -> ByteStringBuilder
forall a. (a -> ByteStringBuilder) -> ToLog a
build :: HyperParameterTuningJobStrategyType -> ByteStringBuilder
$cbuild :: HyperParameterTuningJobStrategyType -> ByteStringBuilder
Data.ToLog,
      HeaderName -> HyperParameterTuningJobStrategyType -> [Header]
forall a. (HeaderName -> a -> [Header]) -> ToHeader a
toHeader :: HeaderName -> HyperParameterTuningJobStrategyType -> [Header]
$ctoHeader :: HeaderName -> HyperParameterTuningJobStrategyType -> [Header]
Data.ToHeader,
      HyperParameterTuningJobStrategyType -> QueryString
forall a. (a -> QueryString) -> ToQuery a
toQuery :: HyperParameterTuningJobStrategyType -> QueryString
$ctoQuery :: HyperParameterTuningJobStrategyType -> QueryString
Data.ToQuery,
      Value -> Parser [HyperParameterTuningJobStrategyType]
Value -> Parser HyperParameterTuningJobStrategyType
forall a.
(Value -> Parser a) -> (Value -> Parser [a]) -> FromJSON a
parseJSONList :: Value -> Parser [HyperParameterTuningJobStrategyType]
$cparseJSONList :: Value -> Parser [HyperParameterTuningJobStrategyType]
parseJSON :: Value -> Parser HyperParameterTuningJobStrategyType
$cparseJSON :: Value -> Parser HyperParameterTuningJobStrategyType
Data.FromJSON,
      FromJSONKeyFunction [HyperParameterTuningJobStrategyType]
FromJSONKeyFunction HyperParameterTuningJobStrategyType
forall a.
FromJSONKeyFunction a -> FromJSONKeyFunction [a] -> FromJSONKey a
fromJSONKeyList :: FromJSONKeyFunction [HyperParameterTuningJobStrategyType]
$cfromJSONKeyList :: FromJSONKeyFunction [HyperParameterTuningJobStrategyType]
fromJSONKey :: FromJSONKeyFunction HyperParameterTuningJobStrategyType
$cfromJSONKey :: FromJSONKeyFunction HyperParameterTuningJobStrategyType
Data.FromJSONKey,
      [HyperParameterTuningJobStrategyType] -> Encoding
[HyperParameterTuningJobStrategyType] -> Value
HyperParameterTuningJobStrategyType -> Encoding
HyperParameterTuningJobStrategyType -> Value
forall a.
(a -> Value)
-> (a -> Encoding)
-> ([a] -> Value)
-> ([a] -> Encoding)
-> ToJSON a
toEncodingList :: [HyperParameterTuningJobStrategyType] -> Encoding
$ctoEncodingList :: [HyperParameterTuningJobStrategyType] -> Encoding
toJSONList :: [HyperParameterTuningJobStrategyType] -> Value
$ctoJSONList :: [HyperParameterTuningJobStrategyType] -> Value
toEncoding :: HyperParameterTuningJobStrategyType -> Encoding
$ctoEncoding :: HyperParameterTuningJobStrategyType -> Encoding
toJSON :: HyperParameterTuningJobStrategyType -> Value
$ctoJSON :: HyperParameterTuningJobStrategyType -> Value
Data.ToJSON,
      ToJSONKeyFunction [HyperParameterTuningJobStrategyType]
ToJSONKeyFunction HyperParameterTuningJobStrategyType
forall a.
ToJSONKeyFunction a -> ToJSONKeyFunction [a] -> ToJSONKey a
toJSONKeyList :: ToJSONKeyFunction [HyperParameterTuningJobStrategyType]
$ctoJSONKeyList :: ToJSONKeyFunction [HyperParameterTuningJobStrategyType]
toJSONKey :: ToJSONKeyFunction HyperParameterTuningJobStrategyType
$ctoJSONKey :: ToJSONKeyFunction HyperParameterTuningJobStrategyType
Data.ToJSONKey,
      [Node] -> Either String HyperParameterTuningJobStrategyType
forall a. ([Node] -> Either String a) -> FromXML a
parseXML :: [Node] -> Either String HyperParameterTuningJobStrategyType
$cparseXML :: [Node] -> Either String HyperParameterTuningJobStrategyType
Data.FromXML,
      HyperParameterTuningJobStrategyType -> XML
forall a. (a -> XML) -> ToXML a
toXML :: HyperParameterTuningJobStrategyType -> XML
$ctoXML :: HyperParameterTuningJobStrategyType -> XML
Data.ToXML
    )

pattern HyperParameterTuningJobStrategyType_Bayesian :: HyperParameterTuningJobStrategyType
pattern $bHyperParameterTuningJobStrategyType_Bayesian :: HyperParameterTuningJobStrategyType
$mHyperParameterTuningJobStrategyType_Bayesian :: forall {r}.
HyperParameterTuningJobStrategyType
-> ((# #) -> r) -> ((# #) -> r) -> r
HyperParameterTuningJobStrategyType_Bayesian = HyperParameterTuningJobStrategyType' "Bayesian"

pattern HyperParameterTuningJobStrategyType_Grid :: HyperParameterTuningJobStrategyType
pattern $bHyperParameterTuningJobStrategyType_Grid :: HyperParameterTuningJobStrategyType
$mHyperParameterTuningJobStrategyType_Grid :: forall {r}.
HyperParameterTuningJobStrategyType
-> ((# #) -> r) -> ((# #) -> r) -> r
HyperParameterTuningJobStrategyType_Grid = HyperParameterTuningJobStrategyType' "Grid"

pattern HyperParameterTuningJobStrategyType_Hyperband :: HyperParameterTuningJobStrategyType
pattern $bHyperParameterTuningJobStrategyType_Hyperband :: HyperParameterTuningJobStrategyType
$mHyperParameterTuningJobStrategyType_Hyperband :: forall {r}.
HyperParameterTuningJobStrategyType
-> ((# #) -> r) -> ((# #) -> r) -> r
HyperParameterTuningJobStrategyType_Hyperband = HyperParameterTuningJobStrategyType' "Hyperband"

pattern HyperParameterTuningJobStrategyType_Random :: HyperParameterTuningJobStrategyType
pattern $bHyperParameterTuningJobStrategyType_Random :: HyperParameterTuningJobStrategyType
$mHyperParameterTuningJobStrategyType_Random :: forall {r}.
HyperParameterTuningJobStrategyType
-> ((# #) -> r) -> ((# #) -> r) -> r
HyperParameterTuningJobStrategyType_Random = HyperParameterTuningJobStrategyType' "Random"

{-# COMPLETE
  HyperParameterTuningJobStrategyType_Bayesian,
  HyperParameterTuningJobStrategyType_Grid,
  HyperParameterTuningJobStrategyType_Hyperband,
  HyperParameterTuningJobStrategyType_Random,
  HyperParameterTuningJobStrategyType'
  #-}