{-# LANGUAGE ScopedTypeVariables, DataKinds, TypeFamilies, UndecidableInstances, GeneralizedNewtypeDeriving, MultiParamTypeClasses, FlexibleContexts, FlexibleInstances, PatternSynonyms, MagicHash, NoImplicitPrelude, DataKinds, BangPatterns, TypeApplications, OverloadedStrings, DerivingStrategies#-}
{-# OPTIONS_GHC -Wno-unused-imports#-}
{-# OPTIONS_GHC -Wno-duplicate-exports#-}
{-# OPTIONS_GHC -Wno-dodgy-exports#-}
module Proto.Tensorflow.Core.Framework.NodeDef (
NodeDef(), NodeDef'AttrEntry(), NodeDef'ExperimentalDebugInfo()
) where
import qualified Data.ProtoLens.Runtime.Control.DeepSeq as Control.DeepSeq
import qualified Data.ProtoLens.Runtime.Data.ProtoLens.Prism as Data.ProtoLens.Prism
import qualified Data.ProtoLens.Runtime.Prelude as Prelude
import qualified Data.ProtoLens.Runtime.Data.Int as Data.Int
import qualified Data.ProtoLens.Runtime.Data.Monoid as Data.Monoid
import qualified Data.ProtoLens.Runtime.Data.Word as Data.Word
import qualified Data.ProtoLens.Runtime.Data.ProtoLens as Data.ProtoLens
import qualified Data.ProtoLens.Runtime.Data.ProtoLens.Encoding.Bytes as Data.ProtoLens.Encoding.Bytes
import qualified Data.ProtoLens.Runtime.Data.ProtoLens.Encoding.Growing as Data.ProtoLens.Encoding.Growing
import qualified Data.ProtoLens.Runtime.Data.ProtoLens.Encoding.Parser.Unsafe as Data.ProtoLens.Encoding.Parser.Unsafe
import qualified Data.ProtoLens.Runtime.Data.ProtoLens.Encoding.Wire as Data.ProtoLens.Encoding.Wire
import qualified Data.ProtoLens.Runtime.Data.ProtoLens.Field as Data.ProtoLens.Field
import qualified Data.ProtoLens.Runtime.Data.ProtoLens.Message.Enum as Data.ProtoLens.Message.Enum
import qualified Data.ProtoLens.Runtime.Data.ProtoLens.Service.Types as Data.ProtoLens.Service.Types
import qualified Data.ProtoLens.Runtime.Lens.Family2 as Lens.Family2
import qualified Data.ProtoLens.Runtime.Lens.Family2.Unchecked as Lens.Family2.Unchecked
import qualified Data.ProtoLens.Runtime.Data.Text as Data.Text
import qualified Data.ProtoLens.Runtime.Data.Map as Data.Map
import qualified Data.ProtoLens.Runtime.Data.ByteString as Data.ByteString
import qualified Data.ProtoLens.Runtime.Data.ByteString.Char8 as Data.ByteString.Char8
import qualified Data.ProtoLens.Runtime.Data.Text.Encoding as Data.Text.Encoding
import qualified Data.ProtoLens.Runtime.Data.Vector as Data.Vector
import qualified Data.ProtoLens.Runtime.Data.Vector.Generic as Data.Vector.Generic
import qualified Data.ProtoLens.Runtime.Data.Vector.Unboxed as Data.Vector.Unboxed
import qualified Data.ProtoLens.Runtime.Text.Read as Text.Read
import qualified Proto.Tensorflow.Core.Framework.AttrValue
data NodeDef
= NodeDef'_constructor {NodeDef -> Text
_NodeDef'name :: !Data.Text.Text,
NodeDef -> Text
_NodeDef'op :: !Data.Text.Text,
NodeDef -> Vector Text
_NodeDef'input :: !(Data.Vector.Vector Data.Text.Text),
NodeDef -> Text
_NodeDef'device :: !Data.Text.Text,
NodeDef -> Map Text AttrValue
_NodeDef'attr :: !(Data.Map.Map Data.Text.Text Proto.Tensorflow.Core.Framework.AttrValue.AttrValue),
NodeDef -> Maybe NodeDef'ExperimentalDebugInfo
_NodeDef'experimentalDebugInfo :: !(Prelude.Maybe NodeDef'ExperimentalDebugInfo),
NodeDef -> FieldSet
_NodeDef'_unknownFields :: !Data.ProtoLens.FieldSet}
deriving stock (NodeDef -> NodeDef -> Bool
(NodeDef -> NodeDef -> Bool)
-> (NodeDef -> NodeDef -> Bool) -> Eq NodeDef
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: NodeDef -> NodeDef -> Bool
$c/= :: NodeDef -> NodeDef -> Bool
== :: NodeDef -> NodeDef -> Bool
$c== :: NodeDef -> NodeDef -> Bool
Prelude.Eq, Eq NodeDef
Eq NodeDef =>
(NodeDef -> NodeDef -> Ordering)
-> (NodeDef -> NodeDef -> Bool)
-> (NodeDef -> NodeDef -> Bool)
-> (NodeDef -> NodeDef -> Bool)
-> (NodeDef -> NodeDef -> Bool)
-> (NodeDef -> NodeDef -> NodeDef)
-> (NodeDef -> NodeDef -> NodeDef)
-> Ord NodeDef
NodeDef -> NodeDef -> Bool
NodeDef -> NodeDef -> Ordering
NodeDef -> NodeDef -> NodeDef
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 :: NodeDef -> NodeDef -> NodeDef
$cmin :: NodeDef -> NodeDef -> NodeDef
max :: NodeDef -> NodeDef -> NodeDef
$cmax :: NodeDef -> NodeDef -> NodeDef
>= :: NodeDef -> NodeDef -> Bool
$c>= :: NodeDef -> NodeDef -> Bool
> :: NodeDef -> NodeDef -> Bool
$c> :: NodeDef -> NodeDef -> Bool
<= :: NodeDef -> NodeDef -> Bool
$c<= :: NodeDef -> NodeDef -> Bool
< :: NodeDef -> NodeDef -> Bool
$c< :: NodeDef -> NodeDef -> Bool
compare :: NodeDef -> NodeDef -> Ordering
$ccompare :: NodeDef -> NodeDef -> Ordering
$cp1Ord :: Eq NodeDef
Prelude.Ord)
instance Prelude.Show NodeDef where
showsPrec :: Int -> NodeDef -> ShowS
showsPrec _ __x :: NodeDef
__x __s :: String
__s
= Char -> ShowS
Prelude.showChar
'{'
(String -> ShowS
Prelude.showString
(NodeDef -> String
forall msg. Message msg => msg -> String
Data.ProtoLens.showMessageShort NodeDef
__x) (Char -> ShowS
Prelude.showChar '}' String
__s))
instance Data.ProtoLens.Field.HasField NodeDef "name" Data.Text.Text where
fieldOf :: Proxy# "name" -> (Text -> f Text) -> NodeDef -> f NodeDef
fieldOf _
= ((Text -> f Text) -> NodeDef -> f NodeDef)
-> ((Text -> f Text) -> Text -> f Text)
-> (Text -> f Text)
-> NodeDef
-> f NodeDef
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
((NodeDef -> Text)
-> (NodeDef -> Text -> NodeDef) -> Lens NodeDef NodeDef Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
NodeDef -> Text
_NodeDef'name (\ x__ :: NodeDef
x__ y__ :: Text
y__ -> NodeDef
x__ {_NodeDef'name :: Text
_NodeDef'name = Text
y__}))
(Text -> f Text) -> Text -> f Text
forall a. a -> a
Prelude.id
instance Data.ProtoLens.Field.HasField NodeDef "op" Data.Text.Text where
fieldOf :: Proxy# "op" -> (Text -> f Text) -> NodeDef -> f NodeDef
fieldOf _
= ((Text -> f Text) -> NodeDef -> f NodeDef)
-> ((Text -> f Text) -> Text -> f Text)
-> (Text -> f Text)
-> NodeDef
-> f NodeDef
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
((NodeDef -> Text)
-> (NodeDef -> Text -> NodeDef) -> Lens NodeDef NodeDef Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
NodeDef -> Text
_NodeDef'op (\ x__ :: NodeDef
x__ y__ :: Text
y__ -> NodeDef
x__ {_NodeDef'op :: Text
_NodeDef'op = Text
y__}))
(Text -> f Text) -> Text -> f Text
forall a. a -> a
Prelude.id
instance Data.ProtoLens.Field.HasField NodeDef "input" [Data.Text.Text] where
fieldOf :: Proxy# "input" -> ([Text] -> f [Text]) -> NodeDef -> f NodeDef
fieldOf _
= ((Vector Text -> f (Vector Text)) -> NodeDef -> f NodeDef)
-> (([Text] -> f [Text]) -> Vector Text -> f (Vector Text))
-> ([Text] -> f [Text])
-> NodeDef
-> f NodeDef
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
((NodeDef -> Vector Text)
-> (NodeDef -> Vector Text -> NodeDef)
-> Lens NodeDef NodeDef (Vector Text) (Vector Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
NodeDef -> Vector Text
_NodeDef'input (\ x__ :: NodeDef
x__ y__ :: Vector Text
y__ -> NodeDef
x__ {_NodeDef'input :: Vector Text
_NodeDef'input = Vector Text
y__}))
((Vector Text -> [Text])
-> (Vector Text -> [Text] -> Vector Text)
-> Lens (Vector Text) (Vector Text) [Text] [Text]
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
Vector Text -> [Text]
forall (v :: * -> *) a. Vector v a => v a -> [a]
Data.Vector.Generic.toList
(\ _ y__ :: [Text]
y__ -> [Text] -> Vector Text
forall (v :: * -> *) a. Vector v a => [a] -> v a
Data.Vector.Generic.fromList [Text]
y__))
instance Data.ProtoLens.Field.HasField NodeDef "vec'input" (Data.Vector.Vector Data.Text.Text) where
fieldOf :: Proxy# "vec'input"
-> (Vector Text -> f (Vector Text)) -> NodeDef -> f NodeDef
fieldOf _
= ((Vector Text -> f (Vector Text)) -> NodeDef -> f NodeDef)
-> ((Vector Text -> f (Vector Text))
-> Vector Text -> f (Vector Text))
-> (Vector Text -> f (Vector Text))
-> NodeDef
-> f NodeDef
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
((NodeDef -> Vector Text)
-> (NodeDef -> Vector Text -> NodeDef)
-> Lens NodeDef NodeDef (Vector Text) (Vector Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
NodeDef -> Vector Text
_NodeDef'input (\ x__ :: NodeDef
x__ y__ :: Vector Text
y__ -> NodeDef
x__ {_NodeDef'input :: Vector Text
_NodeDef'input = Vector Text
y__}))
(Vector Text -> f (Vector Text)) -> Vector Text -> f (Vector Text)
forall a. a -> a
Prelude.id
instance Data.ProtoLens.Field.HasField NodeDef "device" Data.Text.Text where
fieldOf :: Proxy# "device" -> (Text -> f Text) -> NodeDef -> f NodeDef
fieldOf _
= ((Text -> f Text) -> NodeDef -> f NodeDef)
-> ((Text -> f Text) -> Text -> f Text)
-> (Text -> f Text)
-> NodeDef
-> f NodeDef
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
((NodeDef -> Text)
-> (NodeDef -> Text -> NodeDef) -> Lens NodeDef NodeDef Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
NodeDef -> Text
_NodeDef'device (\ x__ :: NodeDef
x__ y__ :: Text
y__ -> NodeDef
x__ {_NodeDef'device :: Text
_NodeDef'device = Text
y__}))
(Text -> f Text) -> Text -> f Text
forall a. a -> a
Prelude.id
instance Data.ProtoLens.Field.HasField NodeDef "attr" (Data.Map.Map Data.Text.Text Proto.Tensorflow.Core.Framework.AttrValue.AttrValue) where
fieldOf :: Proxy# "attr"
-> (Map Text AttrValue -> f (Map Text AttrValue))
-> NodeDef
-> f NodeDef
fieldOf _
= ((Map Text AttrValue -> f (Map Text AttrValue))
-> NodeDef -> f NodeDef)
-> ((Map Text AttrValue -> f (Map Text AttrValue))
-> Map Text AttrValue -> f (Map Text AttrValue))
-> (Map Text AttrValue -> f (Map Text AttrValue))
-> NodeDef
-> f NodeDef
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
((NodeDef -> Map Text AttrValue)
-> (NodeDef -> Map Text AttrValue -> NodeDef)
-> Lens NodeDef NodeDef (Map Text AttrValue) (Map Text AttrValue)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
NodeDef -> Map Text AttrValue
_NodeDef'attr (\ x__ :: NodeDef
x__ y__ :: Map Text AttrValue
y__ -> NodeDef
x__ {_NodeDef'attr :: Map Text AttrValue
_NodeDef'attr = Map Text AttrValue
y__}))
(Map Text AttrValue -> f (Map Text AttrValue))
-> Map Text AttrValue -> f (Map Text AttrValue)
forall a. a -> a
Prelude.id
instance Data.ProtoLens.Field.HasField NodeDef "experimentalDebugInfo" NodeDef'ExperimentalDebugInfo where
fieldOf :: Proxy# "experimentalDebugInfo"
-> (NodeDef'ExperimentalDebugInfo
-> f NodeDef'ExperimentalDebugInfo)
-> NodeDef
-> f NodeDef
fieldOf _
= ((Maybe NodeDef'ExperimentalDebugInfo
-> f (Maybe NodeDef'ExperimentalDebugInfo))
-> NodeDef -> f NodeDef)
-> ((NodeDef'ExperimentalDebugInfo
-> f NodeDef'ExperimentalDebugInfo)
-> Maybe NodeDef'ExperimentalDebugInfo
-> f (Maybe NodeDef'ExperimentalDebugInfo))
-> (NodeDef'ExperimentalDebugInfo
-> f NodeDef'ExperimentalDebugInfo)
-> NodeDef
-> f NodeDef
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
((NodeDef -> Maybe NodeDef'ExperimentalDebugInfo)
-> (NodeDef -> Maybe NodeDef'ExperimentalDebugInfo -> NodeDef)
-> Lens
NodeDef
NodeDef
(Maybe NodeDef'ExperimentalDebugInfo)
(Maybe NodeDef'ExperimentalDebugInfo)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
NodeDef -> Maybe NodeDef'ExperimentalDebugInfo
_NodeDef'experimentalDebugInfo
(\ x__ :: NodeDef
x__ y__ :: Maybe NodeDef'ExperimentalDebugInfo
y__ -> NodeDef
x__ {_NodeDef'experimentalDebugInfo :: Maybe NodeDef'ExperimentalDebugInfo
_NodeDef'experimentalDebugInfo = Maybe NodeDef'ExperimentalDebugInfo
y__}))
(NodeDef'ExperimentalDebugInfo
-> Lens'
(Maybe NodeDef'ExperimentalDebugInfo) NodeDef'ExperimentalDebugInfo
forall b. b -> Lens' (Maybe b) b
Data.ProtoLens.maybeLens NodeDef'ExperimentalDebugInfo
forall msg. Message msg => msg
Data.ProtoLens.defMessage)
instance Data.ProtoLens.Field.HasField NodeDef "maybe'experimentalDebugInfo" (Prelude.Maybe NodeDef'ExperimentalDebugInfo) where
fieldOf :: Proxy# "maybe'experimentalDebugInfo"
-> (Maybe NodeDef'ExperimentalDebugInfo
-> f (Maybe NodeDef'ExperimentalDebugInfo))
-> NodeDef
-> f NodeDef
fieldOf _
= ((Maybe NodeDef'ExperimentalDebugInfo
-> f (Maybe NodeDef'ExperimentalDebugInfo))
-> NodeDef -> f NodeDef)
-> ((Maybe NodeDef'ExperimentalDebugInfo
-> f (Maybe NodeDef'ExperimentalDebugInfo))
-> Maybe NodeDef'ExperimentalDebugInfo
-> f (Maybe NodeDef'ExperimentalDebugInfo))
-> (Maybe NodeDef'ExperimentalDebugInfo
-> f (Maybe NodeDef'ExperimentalDebugInfo))
-> NodeDef
-> f NodeDef
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
((NodeDef -> Maybe NodeDef'ExperimentalDebugInfo)
-> (NodeDef -> Maybe NodeDef'ExperimentalDebugInfo -> NodeDef)
-> Lens
NodeDef
NodeDef
(Maybe NodeDef'ExperimentalDebugInfo)
(Maybe NodeDef'ExperimentalDebugInfo)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
NodeDef -> Maybe NodeDef'ExperimentalDebugInfo
_NodeDef'experimentalDebugInfo
(\ x__ :: NodeDef
x__ y__ :: Maybe NodeDef'ExperimentalDebugInfo
y__ -> NodeDef
x__ {_NodeDef'experimentalDebugInfo :: Maybe NodeDef'ExperimentalDebugInfo
_NodeDef'experimentalDebugInfo = Maybe NodeDef'ExperimentalDebugInfo
y__}))
(Maybe NodeDef'ExperimentalDebugInfo
-> f (Maybe NodeDef'ExperimentalDebugInfo))
-> Maybe NodeDef'ExperimentalDebugInfo
-> f (Maybe NodeDef'ExperimentalDebugInfo)
forall a. a -> a
Prelude.id
instance Data.ProtoLens.Message NodeDef where
messageName :: Proxy NodeDef -> Text
messageName _ = String -> Text
Data.Text.pack "tensorflow.NodeDef"
packedMessageDescriptor :: Proxy NodeDef -> ByteString
packedMessageDescriptor _
= "\n\
\\aNodeDef\DC2\DC2\n\
\\EOTname\CAN\SOH \SOH(\tR\EOTname\DC2\SO\n\
\\STXop\CAN\STX \SOH(\tR\STXop\DC2\DC4\n\
\\ENQinput\CAN\ETX \ETX(\tR\ENQinput\DC2\SYN\n\
\\ACKdevice\CAN\EOT \SOH(\tR\ACKdevice\DC21\n\
\\EOTattr\CAN\ENQ \ETX(\v2\GS.tensorflow.NodeDef.AttrEntryR\EOTattr\DC2a\n\
\\ETBexperimental_debug_info\CAN\ACK \SOH(\v2).tensorflow.NodeDef.ExperimentalDebugInfoR\NAKexperimentalDebugInfo\SUBN\n\
\\tAttrEntry\DC2\DLE\n\
\\ETXkey\CAN\SOH \SOH(\tR\ETXkey\DC2+\n\
\\ENQvalue\CAN\STX \SOH(\v2\NAK.tensorflow.AttrValueR\ENQvalue:\STX8\SOH\SUBw\n\
\\NAKExperimentalDebugInfo\DC2.\n\
\\DC3original_node_names\CAN\SOH \ETX(\tR\DC1originalNodeNames\DC2.\n\
\\DC3original_func_names\CAN\STX \ETX(\tR\DC1originalFuncNames"
packedFileDescriptor :: Proxy NodeDef -> ByteString
packedFileDescriptor _ = ByteString
packedFileDescriptor
fieldsByTag :: Map Tag (FieldDescriptor NodeDef)
fieldsByTag
= let
name__field_descriptor :: FieldDescriptor NodeDef
name__field_descriptor
= String
-> FieldTypeDescriptor Text
-> FieldAccessor NodeDef Text
-> FieldDescriptor NodeDef
forall value msg.
String
-> FieldTypeDescriptor value
-> FieldAccessor msg value
-> FieldDescriptor msg
Data.ProtoLens.FieldDescriptor
"name"
(ScalarField Text -> FieldTypeDescriptor Text
forall value. ScalarField value -> FieldTypeDescriptor value
Data.ProtoLens.ScalarField ScalarField Text
Data.ProtoLens.StringField ::
Data.ProtoLens.FieldTypeDescriptor Data.Text.Text)
(WireDefault Text
-> Lens NodeDef NodeDef Text Text -> FieldAccessor NodeDef Text
forall value msg.
WireDefault value -> Lens' msg value -> FieldAccessor msg value
Data.ProtoLens.PlainField
WireDefault Text
forall value. (FieldDefault value, Eq value) => WireDefault value
Data.ProtoLens.Optional (forall s a (f :: * -> *).
(HasField s "name" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"name")) ::
Data.ProtoLens.FieldDescriptor NodeDef
op__field_descriptor :: FieldDescriptor NodeDef
op__field_descriptor
= String
-> FieldTypeDescriptor Text
-> FieldAccessor NodeDef Text
-> FieldDescriptor NodeDef
forall value msg.
String
-> FieldTypeDescriptor value
-> FieldAccessor msg value
-> FieldDescriptor msg
Data.ProtoLens.FieldDescriptor
"op"
(ScalarField Text -> FieldTypeDescriptor Text
forall value. ScalarField value -> FieldTypeDescriptor value
Data.ProtoLens.ScalarField ScalarField Text
Data.ProtoLens.StringField ::
Data.ProtoLens.FieldTypeDescriptor Data.Text.Text)
(WireDefault Text
-> Lens NodeDef NodeDef Text Text -> FieldAccessor NodeDef Text
forall value msg.
WireDefault value -> Lens' msg value -> FieldAccessor msg value
Data.ProtoLens.PlainField
WireDefault Text
forall value. (FieldDefault value, Eq value) => WireDefault value
Data.ProtoLens.Optional (forall s a (f :: * -> *).
(HasField s "op" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"op")) ::
Data.ProtoLens.FieldDescriptor NodeDef
input__field_descriptor :: FieldDescriptor NodeDef
input__field_descriptor
= String
-> FieldTypeDescriptor Text
-> FieldAccessor NodeDef Text
-> FieldDescriptor NodeDef
forall value msg.
String
-> FieldTypeDescriptor value
-> FieldAccessor msg value
-> FieldDescriptor msg
Data.ProtoLens.FieldDescriptor
"input"
(ScalarField Text -> FieldTypeDescriptor Text
forall value. ScalarField value -> FieldTypeDescriptor value
Data.ProtoLens.ScalarField ScalarField Text
Data.ProtoLens.StringField ::
Data.ProtoLens.FieldTypeDescriptor Data.Text.Text)
(Packing -> Lens' NodeDef [Text] -> FieldAccessor NodeDef Text
forall msg value.
Packing -> Lens' msg [value] -> FieldAccessor msg value
Data.ProtoLens.RepeatedField
Packing
Data.ProtoLens.Unpacked (forall s a (f :: * -> *).
(HasField s "input" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"input")) ::
Data.ProtoLens.FieldDescriptor NodeDef
device__field_descriptor :: FieldDescriptor NodeDef
device__field_descriptor
= String
-> FieldTypeDescriptor Text
-> FieldAccessor NodeDef Text
-> FieldDescriptor NodeDef
forall value msg.
String
-> FieldTypeDescriptor value
-> FieldAccessor msg value
-> FieldDescriptor msg
Data.ProtoLens.FieldDescriptor
"device"
(ScalarField Text -> FieldTypeDescriptor Text
forall value. ScalarField value -> FieldTypeDescriptor value
Data.ProtoLens.ScalarField ScalarField Text
Data.ProtoLens.StringField ::
Data.ProtoLens.FieldTypeDescriptor Data.Text.Text)
(WireDefault Text
-> Lens NodeDef NodeDef Text Text -> FieldAccessor NodeDef Text
forall value msg.
WireDefault value -> Lens' msg value -> FieldAccessor msg value
Data.ProtoLens.PlainField
WireDefault Text
forall value. (FieldDefault value, Eq value) => WireDefault value
Data.ProtoLens.Optional (forall s a (f :: * -> *).
(HasField s "device" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"device")) ::
Data.ProtoLens.FieldDescriptor NodeDef
attr__field_descriptor :: FieldDescriptor NodeDef
attr__field_descriptor
= String
-> FieldTypeDescriptor NodeDef'AttrEntry
-> FieldAccessor NodeDef NodeDef'AttrEntry
-> FieldDescriptor NodeDef
forall value msg.
String
-> FieldTypeDescriptor value
-> FieldAccessor msg value
-> FieldDescriptor msg
Data.ProtoLens.FieldDescriptor
"attr"
(MessageOrGroup -> FieldTypeDescriptor NodeDef'AttrEntry
forall value.
Message value =>
MessageOrGroup -> FieldTypeDescriptor value
Data.ProtoLens.MessageField MessageOrGroup
Data.ProtoLens.MessageType ::
Data.ProtoLens.FieldTypeDescriptor NodeDef'AttrEntry)
(Lens' NodeDef'AttrEntry Text
-> Lens' NodeDef'AttrEntry AttrValue
-> Lens NodeDef NodeDef (Map Text AttrValue) (Map Text AttrValue)
-> FieldAccessor NodeDef NodeDef'AttrEntry
forall key value value1 msg.
(Ord key, Message value) =>
Lens' value key
-> Lens' value value1
-> Lens' msg (Map key value1)
-> FieldAccessor msg value
Data.ProtoLens.MapField
(forall s a (f :: * -> *).
(HasField s "key" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"key")
(forall s a (f :: * -> *).
(HasField s "value" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"value")
(forall s a (f :: * -> *).
(HasField s "attr" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"attr")) ::
Data.ProtoLens.FieldDescriptor NodeDef
experimentalDebugInfo__field_descriptor :: FieldDescriptor NodeDef
experimentalDebugInfo__field_descriptor
= String
-> FieldTypeDescriptor NodeDef'ExperimentalDebugInfo
-> FieldAccessor NodeDef NodeDef'ExperimentalDebugInfo
-> FieldDescriptor NodeDef
forall value msg.
String
-> FieldTypeDescriptor value
-> FieldAccessor msg value
-> FieldDescriptor msg
Data.ProtoLens.FieldDescriptor
"experimental_debug_info"
(MessageOrGroup -> FieldTypeDescriptor NodeDef'ExperimentalDebugInfo
forall value.
Message value =>
MessageOrGroup -> FieldTypeDescriptor value
Data.ProtoLens.MessageField MessageOrGroup
Data.ProtoLens.MessageType ::
Data.ProtoLens.FieldTypeDescriptor NodeDef'ExperimentalDebugInfo)
(Lens
NodeDef
NodeDef
(Maybe NodeDef'ExperimentalDebugInfo)
(Maybe NodeDef'ExperimentalDebugInfo)
-> FieldAccessor NodeDef NodeDef'ExperimentalDebugInfo
forall msg value.
Lens' msg (Maybe value) -> FieldAccessor msg value
Data.ProtoLens.OptionalField
(forall s a (f :: * -> *).
(HasField s "maybe'experimentalDebugInfo" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"maybe'experimentalDebugInfo")) ::
Data.ProtoLens.FieldDescriptor NodeDef
in
[(Tag, FieldDescriptor NodeDef)]
-> Map Tag (FieldDescriptor NodeDef)
forall k a. Ord k => [(k, a)] -> Map k a
Data.Map.fromList
[(Int -> Tag
Data.ProtoLens.Tag 1, FieldDescriptor NodeDef
name__field_descriptor),
(Int -> Tag
Data.ProtoLens.Tag 2, FieldDescriptor NodeDef
op__field_descriptor),
(Int -> Tag
Data.ProtoLens.Tag 3, FieldDescriptor NodeDef
input__field_descriptor),
(Int -> Tag
Data.ProtoLens.Tag 4, FieldDescriptor NodeDef
device__field_descriptor),
(Int -> Tag
Data.ProtoLens.Tag 5, FieldDescriptor NodeDef
attr__field_descriptor),
(Int -> Tag
Data.ProtoLens.Tag 6, FieldDescriptor NodeDef
experimentalDebugInfo__field_descriptor)]
unknownFields :: LensLike' f NodeDef FieldSet
unknownFields
= (NodeDef -> FieldSet)
-> (NodeDef -> FieldSet -> NodeDef) -> Lens' NodeDef FieldSet
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
NodeDef -> FieldSet
_NodeDef'_unknownFields
(\ x__ :: NodeDef
x__ y__ :: FieldSet
y__ -> NodeDef
x__ {_NodeDef'_unknownFields :: FieldSet
_NodeDef'_unknownFields = FieldSet
y__})
defMessage :: NodeDef
defMessage
= $WNodeDef'_constructor :: Text
-> Text
-> Vector Text
-> Text
-> Map Text AttrValue
-> Maybe NodeDef'ExperimentalDebugInfo
-> FieldSet
-> NodeDef
NodeDef'_constructor
{_NodeDef'name :: Text
_NodeDef'name = Text
forall value. FieldDefault value => value
Data.ProtoLens.fieldDefault,
_NodeDef'op :: Text
_NodeDef'op = Text
forall value. FieldDefault value => value
Data.ProtoLens.fieldDefault,
_NodeDef'input :: Vector Text
_NodeDef'input = Vector Text
forall (v :: * -> *) a. Vector v a => v a
Data.Vector.Generic.empty,
_NodeDef'device :: Text
_NodeDef'device = Text
forall value. FieldDefault value => value
Data.ProtoLens.fieldDefault,
_NodeDef'attr :: Map Text AttrValue
_NodeDef'attr = Map Text AttrValue
forall k a. Map k a
Data.Map.empty,
_NodeDef'experimentalDebugInfo :: Maybe NodeDef'ExperimentalDebugInfo
_NodeDef'experimentalDebugInfo = Maybe NodeDef'ExperimentalDebugInfo
forall a. Maybe a
Prelude.Nothing,
_NodeDef'_unknownFields :: FieldSet
_NodeDef'_unknownFields = []}
parseMessage :: Parser NodeDef
parseMessage
= let
loop ::
NodeDef
-> Data.ProtoLens.Encoding.Growing.Growing Data.Vector.Vector Data.ProtoLens.Encoding.Growing.RealWorld Data.Text.Text
-> Data.ProtoLens.Encoding.Bytes.Parser NodeDef
loop :: NodeDef -> Growing Vector RealWorld Text -> Parser NodeDef
loop x :: NodeDef
x mutable'input :: Growing Vector RealWorld Text
mutable'input
= do Bool
end <- Parser Bool
Data.ProtoLens.Encoding.Bytes.atEnd
if Bool
end then
do Vector Text
frozen'input <- IO (Vector Text) -> Parser (Vector Text)
forall a. IO a -> Parser a
Data.ProtoLens.Encoding.Parser.Unsafe.unsafeLiftIO
(Growing Vector (PrimState IO) Text -> IO (Vector Text)
forall (m :: * -> *) (v :: * -> *) a.
(PrimMonad m, Vector v a) =>
Growing v (PrimState m) a -> m (v a)
Data.ProtoLens.Encoding.Growing.unsafeFreeze Growing Vector RealWorld Text
Growing Vector (PrimState IO) Text
mutable'input)
(let missing :: [a]
missing = []
in
if [Any] -> Bool
forall (t :: * -> *) a. Foldable t => t a -> Bool
Prelude.null [Any]
forall a. [a]
missing then
() -> Parser ()
forall (m :: * -> *) a. Monad m => a -> m a
Prelude.return ()
else
String -> Parser ()
forall (m :: * -> *) a. MonadFail m => String -> m a
Prelude.fail
(String -> ShowS
forall a. [a] -> [a] -> [a]
(Prelude.++)
"Missing required fields: "
([String] -> String
forall a. Show a => a -> String
Prelude.show ([String]
forall a. [a]
missing :: [Prelude.String]))))
NodeDef -> Parser NodeDef
forall (m :: * -> *) a. Monad m => a -> m a
Prelude.return
(Setter NodeDef NodeDef FieldSet FieldSet
-> (FieldSet -> FieldSet) -> NodeDef -> NodeDef
forall s t a b. Setter s t a b -> (a -> b) -> s -> t
Lens.Family2.over
forall msg. Message msg => Lens' msg FieldSet
Setter NodeDef NodeDef FieldSet FieldSet
Data.ProtoLens.unknownFields
(\ !FieldSet
t -> FieldSet -> FieldSet
forall a. [a] -> [a]
Prelude.reverse FieldSet
t)
(Setter NodeDef NodeDef (Vector Text) (Vector Text)
-> Vector Text -> NodeDef -> NodeDef
forall s t a b. Setter s t a b -> b -> s -> t
Lens.Family2.set
(forall s a (f :: * -> *).
(HasField s "vec'input" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"vec'input") Vector Text
frozen'input NodeDef
x))
else
do Word64
tag <- Parser Word64
Data.ProtoLens.Encoding.Bytes.getVarInt
case Word64
tag of
10
-> do Text
y <- Parser Text -> String -> Parser Text
forall a. Parser a -> String -> Parser a
(Data.ProtoLens.Encoding.Bytes.<?>)
(do ByteString
value <- do Word64
len <- Parser Word64
Data.ProtoLens.Encoding.Bytes.getVarInt
Int -> Parser ByteString
Data.ProtoLens.Encoding.Bytes.getBytes
(Word64 -> Int
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral Word64
len)
Either String Text -> Parser Text
forall a. Either String a -> Parser a
Data.ProtoLens.Encoding.Bytes.runEither
(case ByteString -> Either UnicodeException Text
Data.Text.Encoding.decodeUtf8' ByteString
value of
(Prelude.Left err :: UnicodeException
err)
-> String -> Either String Text
forall a b. a -> Either a b
Prelude.Left (UnicodeException -> String
forall a. Show a => a -> String
Prelude.show UnicodeException
err)
(Prelude.Right r :: Text
r) -> Text -> Either String Text
forall a b. b -> Either a b
Prelude.Right Text
r))
"name"
NodeDef -> Growing Vector RealWorld Text -> Parser NodeDef
loop
(Setter NodeDef NodeDef Text Text -> Text -> NodeDef -> NodeDef
forall s t a b. Setter s t a b -> b -> s -> t
Lens.Family2.set (forall s a (f :: * -> *).
(HasField s "name" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"name") Text
y NodeDef
x)
Growing Vector RealWorld Text
mutable'input
18
-> do Text
y <- Parser Text -> String -> Parser Text
forall a. Parser a -> String -> Parser a
(Data.ProtoLens.Encoding.Bytes.<?>)
(do ByteString
value <- do Word64
len <- Parser Word64
Data.ProtoLens.Encoding.Bytes.getVarInt
Int -> Parser ByteString
Data.ProtoLens.Encoding.Bytes.getBytes
(Word64 -> Int
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral Word64
len)
Either String Text -> Parser Text
forall a. Either String a -> Parser a
Data.ProtoLens.Encoding.Bytes.runEither
(case ByteString -> Either UnicodeException Text
Data.Text.Encoding.decodeUtf8' ByteString
value of
(Prelude.Left err :: UnicodeException
err)
-> String -> Either String Text
forall a b. a -> Either a b
Prelude.Left (UnicodeException -> String
forall a. Show a => a -> String
Prelude.show UnicodeException
err)
(Prelude.Right r :: Text
r) -> Text -> Either String Text
forall a b. b -> Either a b
Prelude.Right Text
r))
"op"
NodeDef -> Growing Vector RealWorld Text -> Parser NodeDef
loop
(Setter NodeDef NodeDef Text Text -> Text -> NodeDef -> NodeDef
forall s t a b. Setter s t a b -> b -> s -> t
Lens.Family2.set (forall s a (f :: * -> *).
(HasField s "op" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"op") Text
y NodeDef
x)
Growing Vector RealWorld Text
mutable'input
26
-> do !Text
y <- Parser Text -> String -> Parser Text
forall a. Parser a -> String -> Parser a
(Data.ProtoLens.Encoding.Bytes.<?>)
(do ByteString
value <- do Word64
len <- Parser Word64
Data.ProtoLens.Encoding.Bytes.getVarInt
Int -> Parser ByteString
Data.ProtoLens.Encoding.Bytes.getBytes
(Word64 -> Int
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral Word64
len)
Either String Text -> Parser Text
forall a. Either String a -> Parser a
Data.ProtoLens.Encoding.Bytes.runEither
(case ByteString -> Either UnicodeException Text
Data.Text.Encoding.decodeUtf8' ByteString
value of
(Prelude.Left err :: UnicodeException
err)
-> String -> Either String Text
forall a b. a -> Either a b
Prelude.Left (UnicodeException -> String
forall a. Show a => a -> String
Prelude.show UnicodeException
err)
(Prelude.Right r :: Text
r) -> Text -> Either String Text
forall a b. b -> Either a b
Prelude.Right Text
r))
"input"
Growing Vector RealWorld Text
v <- IO (Growing Vector RealWorld Text)
-> Parser (Growing Vector RealWorld Text)
forall a. IO a -> Parser a
Data.ProtoLens.Encoding.Parser.Unsafe.unsafeLiftIO
(Growing Vector (PrimState IO) Text
-> Text -> IO (Growing Vector (PrimState IO) Text)
forall (m :: * -> *) (v :: * -> *) a.
(PrimMonad m, Vector v a) =>
Growing v (PrimState m) a -> a -> m (Growing v (PrimState m) a)
Data.ProtoLens.Encoding.Growing.append Growing Vector RealWorld Text
Growing Vector (PrimState IO) Text
mutable'input Text
y)
NodeDef -> Growing Vector RealWorld Text -> Parser NodeDef
loop NodeDef
x Growing Vector RealWorld Text
v
34
-> do Text
y <- Parser Text -> String -> Parser Text
forall a. Parser a -> String -> Parser a
(Data.ProtoLens.Encoding.Bytes.<?>)
(do ByteString
value <- do Word64
len <- Parser Word64
Data.ProtoLens.Encoding.Bytes.getVarInt
Int -> Parser ByteString
Data.ProtoLens.Encoding.Bytes.getBytes
(Word64 -> Int
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral Word64
len)
Either String Text -> Parser Text
forall a. Either String a -> Parser a
Data.ProtoLens.Encoding.Bytes.runEither
(case ByteString -> Either UnicodeException Text
Data.Text.Encoding.decodeUtf8' ByteString
value of
(Prelude.Left err :: UnicodeException
err)
-> String -> Either String Text
forall a b. a -> Either a b
Prelude.Left (UnicodeException -> String
forall a. Show a => a -> String
Prelude.show UnicodeException
err)
(Prelude.Right r :: Text
r) -> Text -> Either String Text
forall a b. b -> Either a b
Prelude.Right Text
r))
"device"
NodeDef -> Growing Vector RealWorld Text -> Parser NodeDef
loop
(Setter NodeDef NodeDef Text Text -> Text -> NodeDef -> NodeDef
forall s t a b. Setter s t a b -> b -> s -> t
Lens.Family2.set (forall s a (f :: * -> *).
(HasField s "device" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"device") Text
y NodeDef
x)
Growing Vector RealWorld Text
mutable'input
42
-> do !(NodeDef'AttrEntry
entry :: NodeDef'AttrEntry) <- Parser NodeDef'AttrEntry -> String -> Parser NodeDef'AttrEntry
forall a. Parser a -> String -> Parser a
(Data.ProtoLens.Encoding.Bytes.<?>)
(do Word64
len <- Parser Word64
Data.ProtoLens.Encoding.Bytes.getVarInt
Int -> Parser NodeDef'AttrEntry -> Parser NodeDef'AttrEntry
forall a. Int -> Parser a -> Parser a
Data.ProtoLens.Encoding.Bytes.isolate
(Word64 -> Int
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral Word64
len)
Parser NodeDef'AttrEntry
forall msg. Message msg => Parser msg
Data.ProtoLens.parseMessage)
"attr"
(let
key :: Text
key = FoldLike Text NodeDef'AttrEntry NodeDef'AttrEntry Text Text
-> NodeDef'AttrEntry -> Text
forall a s t b. FoldLike a s t a b -> s -> a
Lens.Family2.view (forall s a (f :: * -> *).
(HasField s "key" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"key") NodeDef'AttrEntry
entry
value :: AttrValue
value
= FoldLike
AttrValue NodeDef'AttrEntry NodeDef'AttrEntry AttrValue AttrValue
-> NodeDef'AttrEntry -> AttrValue
forall a s t b. FoldLike a s t a b -> s -> a
Lens.Family2.view (forall s a (f :: * -> *).
(HasField s "value" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"value") NodeDef'AttrEntry
entry
in
NodeDef -> Growing Vector RealWorld Text -> Parser NodeDef
loop
(Setter NodeDef NodeDef (Map Text AttrValue) (Map Text AttrValue)
-> (Map Text AttrValue -> Map Text AttrValue) -> NodeDef -> NodeDef
forall s t a b. Setter s t a b -> (a -> b) -> s -> t
Lens.Family2.over
(forall s a (f :: * -> *).
(HasField s "attr" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"attr")
(\ !Map Text AttrValue
t -> Text -> AttrValue -> Map Text AttrValue -> Map Text AttrValue
forall k a. Ord k => k -> a -> Map k a -> Map k a
Data.Map.insert Text
key AttrValue
value Map Text AttrValue
t)
NodeDef
x)
Growing Vector RealWorld Text
mutable'input)
50
-> do NodeDef'ExperimentalDebugInfo
y <- Parser NodeDef'ExperimentalDebugInfo
-> String -> Parser NodeDef'ExperimentalDebugInfo
forall a. Parser a -> String -> Parser a
(Data.ProtoLens.Encoding.Bytes.<?>)
(do Word64
len <- Parser Word64
Data.ProtoLens.Encoding.Bytes.getVarInt
Int
-> Parser NodeDef'ExperimentalDebugInfo
-> Parser NodeDef'ExperimentalDebugInfo
forall a. Int -> Parser a -> Parser a
Data.ProtoLens.Encoding.Bytes.isolate
(Word64 -> Int
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral Word64
len) Parser NodeDef'ExperimentalDebugInfo
forall msg. Message msg => Parser msg
Data.ProtoLens.parseMessage)
"experimental_debug_info"
NodeDef -> Growing Vector RealWorld Text -> Parser NodeDef
loop
(Setter
NodeDef
NodeDef
NodeDef'ExperimentalDebugInfo
NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> NodeDef -> NodeDef
forall s t a b. Setter s t a b -> b -> s -> t
Lens.Family2.set
(forall s a (f :: * -> *).
(HasField s "experimentalDebugInfo" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"experimentalDebugInfo") NodeDef'ExperimentalDebugInfo
y NodeDef
x)
Growing Vector RealWorld Text
mutable'input
wire :: Word64
wire
-> do !TaggedValue
y <- Word64 -> Parser TaggedValue
Data.ProtoLens.Encoding.Wire.parseTaggedValueFromWire
Word64
wire
NodeDef -> Growing Vector RealWorld Text -> Parser NodeDef
loop
(Setter NodeDef NodeDef FieldSet FieldSet
-> (FieldSet -> FieldSet) -> NodeDef -> NodeDef
forall s t a b. Setter s t a b -> (a -> b) -> s -> t
Lens.Family2.over
forall msg. Message msg => Lens' msg FieldSet
Setter NodeDef NodeDef FieldSet FieldSet
Data.ProtoLens.unknownFields (\ !FieldSet
t -> (:) TaggedValue
y FieldSet
t) NodeDef
x)
Growing Vector RealWorld Text
mutable'input
in
Parser NodeDef -> String -> Parser NodeDef
forall a. Parser a -> String -> Parser a
(Data.ProtoLens.Encoding.Bytes.<?>)
(do Growing Vector RealWorld Text
mutable'input <- IO (Growing Vector RealWorld Text)
-> Parser (Growing Vector RealWorld Text)
forall a. IO a -> Parser a
Data.ProtoLens.Encoding.Parser.Unsafe.unsafeLiftIO
IO (Growing Vector RealWorld Text)
forall (m :: * -> *) (v :: * -> *) a.
(PrimMonad m, Vector v a) =>
m (Growing v (PrimState m) a)
Data.ProtoLens.Encoding.Growing.new
NodeDef -> Growing Vector RealWorld Text -> Parser NodeDef
loop NodeDef
forall msg. Message msg => msg
Data.ProtoLens.defMessage Growing Vector RealWorld Text
mutable'input)
"NodeDef"
buildMessage :: NodeDef -> Builder
buildMessage
= \ _x :: NodeDef
_x
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(let _v :: Text
_v = FoldLike Text NodeDef NodeDef Text Text -> NodeDef -> Text
forall a s t b. FoldLike a s t a b -> s -> a
Lens.Family2.view (forall s a (f :: * -> *).
(HasField s "name" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"name") NodeDef
_x
in
if Text -> Text -> Bool
forall a. Eq a => a -> a -> Bool
(Prelude.==) Text
_v Text
forall value. FieldDefault value => value
Data.ProtoLens.fieldDefault then
Builder
forall a. Monoid a => a
Data.Monoid.mempty
else
Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt 10)
((ByteString -> Builder) -> (Text -> ByteString) -> Text -> Builder
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
(\ bs :: ByteString
bs
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt
(Int -> Word64
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral (ByteString -> Int
Data.ByteString.length ByteString
bs)))
(ByteString -> Builder
Data.ProtoLens.Encoding.Bytes.putBytes ByteString
bs))
Text -> ByteString
Data.Text.Encoding.encodeUtf8
Text
_v))
(Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(let _v :: Text
_v = FoldLike Text NodeDef NodeDef Text Text -> NodeDef -> Text
forall a s t b. FoldLike a s t a b -> s -> a
Lens.Family2.view (forall s a (f :: * -> *).
(HasField s "op" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"op") NodeDef
_x
in
if Text -> Text -> Bool
forall a. Eq a => a -> a -> Bool
(Prelude.==) Text
_v Text
forall value. FieldDefault value => value
Data.ProtoLens.fieldDefault then
Builder
forall a. Monoid a => a
Data.Monoid.mempty
else
Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt 18)
((ByteString -> Builder) -> (Text -> ByteString) -> Text -> Builder
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
(\ bs :: ByteString
bs
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt
(Int -> Word64
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral (ByteString -> Int
Data.ByteString.length ByteString
bs)))
(ByteString -> Builder
Data.ProtoLens.Encoding.Bytes.putBytes ByteString
bs))
Text -> ByteString
Data.Text.Encoding.encodeUtf8
Text
_v))
(Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
((Text -> Builder) -> Vector Text -> Builder
forall (v :: * -> *) a.
Vector v a =>
(a -> Builder) -> v a -> Builder
Data.ProtoLens.Encoding.Bytes.foldMapBuilder
(\ _v :: Text
_v
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt 26)
((ByteString -> Builder) -> (Text -> ByteString) -> Text -> Builder
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
(\ bs :: ByteString
bs
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt
(Int -> Word64
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral (ByteString -> Int
Data.ByteString.length ByteString
bs)))
(ByteString -> Builder
Data.ProtoLens.Encoding.Bytes.putBytes ByteString
bs))
Text -> ByteString
Data.Text.Encoding.encodeUtf8
Text
_v))
(FoldLike (Vector Text) NodeDef NodeDef (Vector Text) (Vector Text)
-> NodeDef -> Vector Text
forall a s t b. FoldLike a s t a b -> s -> a
Lens.Family2.view (forall s a (f :: * -> *).
(HasField s "vec'input" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"vec'input") NodeDef
_x))
(Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(let
_v :: Text
_v = FoldLike Text NodeDef NodeDef Text Text -> NodeDef -> Text
forall a s t b. FoldLike a s t a b -> s -> a
Lens.Family2.view (forall s a (f :: * -> *).
(HasField s "device" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"device") NodeDef
_x
in
if Text -> Text -> Bool
forall a. Eq a => a -> a -> Bool
(Prelude.==) Text
_v Text
forall value. FieldDefault value => value
Data.ProtoLens.fieldDefault then
Builder
forall a. Monoid a => a
Data.Monoid.mempty
else
Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt 34)
((ByteString -> Builder) -> (Text -> ByteString) -> Text -> Builder
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
(\ bs :: ByteString
bs
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt
(Int -> Word64
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral (ByteString -> Int
Data.ByteString.length ByteString
bs)))
(ByteString -> Builder
Data.ProtoLens.Encoding.Bytes.putBytes ByteString
bs))
Text -> ByteString
Data.Text.Encoding.encodeUtf8
Text
_v))
(Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
([Builder] -> Builder
forall a. Monoid a => [a] -> a
Data.Monoid.mconcat
(((Text, AttrValue) -> Builder) -> [(Text, AttrValue)] -> [Builder]
forall a b. (a -> b) -> [a] -> [b]
Prelude.map
(\ _v :: (Text, AttrValue)
_v
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt 42)
((ByteString -> Builder)
-> (NodeDef'AttrEntry -> ByteString)
-> NodeDef'AttrEntry
-> Builder
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
(\ bs :: ByteString
bs
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt
(Int -> Word64
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral
(ByteString -> Int
Data.ByteString.length ByteString
bs)))
(ByteString -> Builder
Data.ProtoLens.Encoding.Bytes.putBytes ByteString
bs))
NodeDef'AttrEntry -> ByteString
forall msg. Message msg => msg -> ByteString
Data.ProtoLens.encodeMessage
(Setter NodeDef'AttrEntry NodeDef'AttrEntry Text Text
-> Text -> NodeDef'AttrEntry -> NodeDef'AttrEntry
forall s t a b. Setter s t a b -> b -> s -> t
Lens.Family2.set
(forall s a (f :: * -> *).
(HasField s "key" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"key")
((Text, AttrValue) -> Text
forall a b. (a, b) -> a
Prelude.fst (Text, AttrValue)
_v)
(Setter NodeDef'AttrEntry NodeDef'AttrEntry AttrValue AttrValue
-> AttrValue -> NodeDef'AttrEntry -> NodeDef'AttrEntry
forall s t a b. Setter s t a b -> b -> s -> t
Lens.Family2.set
(forall s a (f :: * -> *).
(HasField s "value" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"value")
((Text, AttrValue) -> AttrValue
forall a b. (a, b) -> b
Prelude.snd (Text, AttrValue)
_v)
(NodeDef'AttrEntry
forall msg. Message msg => msg
Data.ProtoLens.defMessage :: NodeDef'AttrEntry)))))
(Map Text AttrValue -> [(Text, AttrValue)]
forall k a. Map k a -> [(k, a)]
Data.Map.toList
(FoldLike
(Map Text AttrValue)
NodeDef
NodeDef
(Map Text AttrValue)
(Map Text AttrValue)
-> NodeDef -> Map Text AttrValue
forall a s t b. FoldLike a s t a b -> s -> a
Lens.Family2.view (forall s a (f :: * -> *).
(HasField s "attr" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"attr") NodeDef
_x))))
(Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(case
FoldLike
(Maybe NodeDef'ExperimentalDebugInfo)
NodeDef
NodeDef
(Maybe NodeDef'ExperimentalDebugInfo)
(Maybe NodeDef'ExperimentalDebugInfo)
-> NodeDef -> Maybe NodeDef'ExperimentalDebugInfo
forall a s t b. FoldLike a s t a b -> s -> a
Lens.Family2.view
(forall s a (f :: * -> *).
(HasField s "maybe'experimentalDebugInfo" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"maybe'experimentalDebugInfo") NodeDef
_x
of
Prelude.Nothing -> Builder
forall a. Monoid a => a
Data.Monoid.mempty
(Prelude.Just _v :: NodeDef'ExperimentalDebugInfo
_v)
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt 50)
((ByteString -> Builder)
-> (NodeDef'ExperimentalDebugInfo -> ByteString)
-> NodeDef'ExperimentalDebugInfo
-> Builder
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
(\ bs :: ByteString
bs
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt
(Int -> Word64
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral
(ByteString -> Int
Data.ByteString.length ByteString
bs)))
(ByteString -> Builder
Data.ProtoLens.Encoding.Bytes.putBytes ByteString
bs))
NodeDef'ExperimentalDebugInfo -> ByteString
forall msg. Message msg => msg -> ByteString
Data.ProtoLens.encodeMessage
NodeDef'ExperimentalDebugInfo
_v))
(FieldSet -> Builder
Data.ProtoLens.Encoding.Wire.buildFieldSet
(FoldLike FieldSet NodeDef NodeDef FieldSet FieldSet
-> NodeDef -> FieldSet
forall a s t b. FoldLike a s t a b -> s -> a
Lens.Family2.view FoldLike FieldSet NodeDef NodeDef FieldSet FieldSet
forall msg. Message msg => Lens' msg FieldSet
Data.ProtoLens.unknownFields NodeDef
_x)))))))
instance Control.DeepSeq.NFData NodeDef where
rnf :: NodeDef -> ()
rnf
= \ x__ :: NodeDef
x__
-> FieldSet -> () -> ()
forall a b. NFData a => a -> b -> b
Control.DeepSeq.deepseq
(NodeDef -> FieldSet
_NodeDef'_unknownFields NodeDef
x__)
(Text -> () -> ()
forall a b. NFData a => a -> b -> b
Control.DeepSeq.deepseq
(NodeDef -> Text
_NodeDef'name NodeDef
x__)
(Text -> () -> ()
forall a b. NFData a => a -> b -> b
Control.DeepSeq.deepseq
(NodeDef -> Text
_NodeDef'op NodeDef
x__)
(Vector Text -> () -> ()
forall a b. NFData a => a -> b -> b
Control.DeepSeq.deepseq
(NodeDef -> Vector Text
_NodeDef'input NodeDef
x__)
(Text -> () -> ()
forall a b. NFData a => a -> b -> b
Control.DeepSeq.deepseq
(NodeDef -> Text
_NodeDef'device NodeDef
x__)
(Map Text AttrValue -> () -> ()
forall a b. NFData a => a -> b -> b
Control.DeepSeq.deepseq
(NodeDef -> Map Text AttrValue
_NodeDef'attr NodeDef
x__)
(Maybe NodeDef'ExperimentalDebugInfo -> () -> ()
forall a b. NFData a => a -> b -> b
Control.DeepSeq.deepseq
(NodeDef -> Maybe NodeDef'ExperimentalDebugInfo
_NodeDef'experimentalDebugInfo NodeDef
x__) ()))))))
data NodeDef'AttrEntry
= NodeDef'AttrEntry'_constructor {NodeDef'AttrEntry -> Text
_NodeDef'AttrEntry'key :: !Data.Text.Text,
NodeDef'AttrEntry -> Maybe AttrValue
_NodeDef'AttrEntry'value :: !(Prelude.Maybe Proto.Tensorflow.Core.Framework.AttrValue.AttrValue),
NodeDef'AttrEntry -> FieldSet
_NodeDef'AttrEntry'_unknownFields :: !Data.ProtoLens.FieldSet}
deriving stock (NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool
(NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool)
-> (NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool)
-> Eq NodeDef'AttrEntry
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool
$c/= :: NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool
== :: NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool
$c== :: NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool
Prelude.Eq, Eq NodeDef'AttrEntry
Eq NodeDef'AttrEntry =>
(NodeDef'AttrEntry -> NodeDef'AttrEntry -> Ordering)
-> (NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool)
-> (NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool)
-> (NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool)
-> (NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool)
-> (NodeDef'AttrEntry -> NodeDef'AttrEntry -> NodeDef'AttrEntry)
-> (NodeDef'AttrEntry -> NodeDef'AttrEntry -> NodeDef'AttrEntry)
-> Ord NodeDef'AttrEntry
NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool
NodeDef'AttrEntry -> NodeDef'AttrEntry -> Ordering
NodeDef'AttrEntry -> NodeDef'AttrEntry -> NodeDef'AttrEntry
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 :: NodeDef'AttrEntry -> NodeDef'AttrEntry -> NodeDef'AttrEntry
$cmin :: NodeDef'AttrEntry -> NodeDef'AttrEntry -> NodeDef'AttrEntry
max :: NodeDef'AttrEntry -> NodeDef'AttrEntry -> NodeDef'AttrEntry
$cmax :: NodeDef'AttrEntry -> NodeDef'AttrEntry -> NodeDef'AttrEntry
>= :: NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool
$c>= :: NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool
> :: NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool
$c> :: NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool
<= :: NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool
$c<= :: NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool
< :: NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool
$c< :: NodeDef'AttrEntry -> NodeDef'AttrEntry -> Bool
compare :: NodeDef'AttrEntry -> NodeDef'AttrEntry -> Ordering
$ccompare :: NodeDef'AttrEntry -> NodeDef'AttrEntry -> Ordering
$cp1Ord :: Eq NodeDef'AttrEntry
Prelude.Ord)
instance Prelude.Show NodeDef'AttrEntry where
showsPrec :: Int -> NodeDef'AttrEntry -> ShowS
showsPrec _ __x :: NodeDef'AttrEntry
__x __s :: String
__s
= Char -> ShowS
Prelude.showChar
'{'
(String -> ShowS
Prelude.showString
(NodeDef'AttrEntry -> String
forall msg. Message msg => msg -> String
Data.ProtoLens.showMessageShort NodeDef'AttrEntry
__x) (Char -> ShowS
Prelude.showChar '}' String
__s))
instance Data.ProtoLens.Field.HasField NodeDef'AttrEntry "key" Data.Text.Text where
fieldOf :: Proxy# "key"
-> (Text -> f Text) -> NodeDef'AttrEntry -> f NodeDef'AttrEntry
fieldOf _
= ((Text -> f Text) -> NodeDef'AttrEntry -> f NodeDef'AttrEntry)
-> ((Text -> f Text) -> Text -> f Text)
-> (Text -> f Text)
-> NodeDef'AttrEntry
-> f NodeDef'AttrEntry
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
((NodeDef'AttrEntry -> Text)
-> (NodeDef'AttrEntry -> Text -> NodeDef'AttrEntry)
-> Lens' NodeDef'AttrEntry Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
NodeDef'AttrEntry -> Text
_NodeDef'AttrEntry'key
(\ x__ :: NodeDef'AttrEntry
x__ y__ :: Text
y__ -> NodeDef'AttrEntry
x__ {_NodeDef'AttrEntry'key :: Text
_NodeDef'AttrEntry'key = Text
y__}))
(Text -> f Text) -> Text -> f Text
forall a. a -> a
Prelude.id
instance Data.ProtoLens.Field.HasField NodeDef'AttrEntry "value" Proto.Tensorflow.Core.Framework.AttrValue.AttrValue where
fieldOf :: Proxy# "value"
-> (AttrValue -> f AttrValue)
-> NodeDef'AttrEntry
-> f NodeDef'AttrEntry
fieldOf _
= ((Maybe AttrValue -> f (Maybe AttrValue))
-> NodeDef'AttrEntry -> f NodeDef'AttrEntry)
-> ((AttrValue -> f AttrValue)
-> Maybe AttrValue -> f (Maybe AttrValue))
-> (AttrValue -> f AttrValue)
-> NodeDef'AttrEntry
-> f NodeDef'AttrEntry
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
((NodeDef'AttrEntry -> Maybe AttrValue)
-> (NodeDef'AttrEntry -> Maybe AttrValue -> NodeDef'AttrEntry)
-> Lens
NodeDef'AttrEntry
NodeDef'AttrEntry
(Maybe AttrValue)
(Maybe AttrValue)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
NodeDef'AttrEntry -> Maybe AttrValue
_NodeDef'AttrEntry'value
(\ x__ :: NodeDef'AttrEntry
x__ y__ :: Maybe AttrValue
y__ -> NodeDef'AttrEntry
x__ {_NodeDef'AttrEntry'value :: Maybe AttrValue
_NodeDef'AttrEntry'value = Maybe AttrValue
y__}))
(AttrValue -> Lens' (Maybe AttrValue) AttrValue
forall b. b -> Lens' (Maybe b) b
Data.ProtoLens.maybeLens AttrValue
forall msg. Message msg => msg
Data.ProtoLens.defMessage)
instance Data.ProtoLens.Field.HasField NodeDef'AttrEntry "maybe'value" (Prelude.Maybe Proto.Tensorflow.Core.Framework.AttrValue.AttrValue) where
fieldOf :: Proxy# "maybe'value"
-> (Maybe AttrValue -> f (Maybe AttrValue))
-> NodeDef'AttrEntry
-> f NodeDef'AttrEntry
fieldOf _
= ((Maybe AttrValue -> f (Maybe AttrValue))
-> NodeDef'AttrEntry -> f NodeDef'AttrEntry)
-> ((Maybe AttrValue -> f (Maybe AttrValue))
-> Maybe AttrValue -> f (Maybe AttrValue))
-> (Maybe AttrValue -> f (Maybe AttrValue))
-> NodeDef'AttrEntry
-> f NodeDef'AttrEntry
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
((NodeDef'AttrEntry -> Maybe AttrValue)
-> (NodeDef'AttrEntry -> Maybe AttrValue -> NodeDef'AttrEntry)
-> Lens
NodeDef'AttrEntry
NodeDef'AttrEntry
(Maybe AttrValue)
(Maybe AttrValue)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
NodeDef'AttrEntry -> Maybe AttrValue
_NodeDef'AttrEntry'value
(\ x__ :: NodeDef'AttrEntry
x__ y__ :: Maybe AttrValue
y__ -> NodeDef'AttrEntry
x__ {_NodeDef'AttrEntry'value :: Maybe AttrValue
_NodeDef'AttrEntry'value = Maybe AttrValue
y__}))
(Maybe AttrValue -> f (Maybe AttrValue))
-> Maybe AttrValue -> f (Maybe AttrValue)
forall a. a -> a
Prelude.id
instance Data.ProtoLens.Message NodeDef'AttrEntry where
messageName :: Proxy NodeDef'AttrEntry -> Text
messageName _ = String -> Text
Data.Text.pack "tensorflow.NodeDef.AttrEntry"
packedMessageDescriptor :: Proxy NodeDef'AttrEntry -> ByteString
packedMessageDescriptor _
= "\n\
\\tAttrEntry\DC2\DLE\n\
\\ETXkey\CAN\SOH \SOH(\tR\ETXkey\DC2+\n\
\\ENQvalue\CAN\STX \SOH(\v2\NAK.tensorflow.AttrValueR\ENQvalue:\STX8\SOH"
packedFileDescriptor :: Proxy NodeDef'AttrEntry -> ByteString
packedFileDescriptor _ = ByteString
packedFileDescriptor
fieldsByTag :: Map Tag (FieldDescriptor NodeDef'AttrEntry)
fieldsByTag
= let
key__field_descriptor :: FieldDescriptor NodeDef'AttrEntry
key__field_descriptor
= String
-> FieldTypeDescriptor Text
-> FieldAccessor NodeDef'AttrEntry Text
-> FieldDescriptor NodeDef'AttrEntry
forall value msg.
String
-> FieldTypeDescriptor value
-> FieldAccessor msg value
-> FieldDescriptor msg
Data.ProtoLens.FieldDescriptor
"key"
(ScalarField Text -> FieldTypeDescriptor Text
forall value. ScalarField value -> FieldTypeDescriptor value
Data.ProtoLens.ScalarField ScalarField Text
Data.ProtoLens.StringField ::
Data.ProtoLens.FieldTypeDescriptor Data.Text.Text)
(WireDefault Text
-> Lens' NodeDef'AttrEntry Text
-> FieldAccessor NodeDef'AttrEntry Text
forall value msg.
WireDefault value -> Lens' msg value -> FieldAccessor msg value
Data.ProtoLens.PlainField
WireDefault Text
forall value. (FieldDefault value, Eq value) => WireDefault value
Data.ProtoLens.Optional (forall s a (f :: * -> *).
(HasField s "key" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"key")) ::
Data.ProtoLens.FieldDescriptor NodeDef'AttrEntry
value__field_descriptor :: FieldDescriptor NodeDef'AttrEntry
value__field_descriptor
= String
-> FieldTypeDescriptor AttrValue
-> FieldAccessor NodeDef'AttrEntry AttrValue
-> FieldDescriptor NodeDef'AttrEntry
forall value msg.
String
-> FieldTypeDescriptor value
-> FieldAccessor msg value
-> FieldDescriptor msg
Data.ProtoLens.FieldDescriptor
"value"
(MessageOrGroup -> FieldTypeDescriptor AttrValue
forall value.
Message value =>
MessageOrGroup -> FieldTypeDescriptor value
Data.ProtoLens.MessageField MessageOrGroup
Data.ProtoLens.MessageType ::
Data.ProtoLens.FieldTypeDescriptor Proto.Tensorflow.Core.Framework.AttrValue.AttrValue)
(Lens
NodeDef'AttrEntry
NodeDef'AttrEntry
(Maybe AttrValue)
(Maybe AttrValue)
-> FieldAccessor NodeDef'AttrEntry AttrValue
forall msg value.
Lens' msg (Maybe value) -> FieldAccessor msg value
Data.ProtoLens.OptionalField
(forall s a (f :: * -> *).
(HasField s "maybe'value" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"maybe'value")) ::
Data.ProtoLens.FieldDescriptor NodeDef'AttrEntry
in
[(Tag, FieldDescriptor NodeDef'AttrEntry)]
-> Map Tag (FieldDescriptor NodeDef'AttrEntry)
forall k a. Ord k => [(k, a)] -> Map k a
Data.Map.fromList
[(Int -> Tag
Data.ProtoLens.Tag 1, FieldDescriptor NodeDef'AttrEntry
key__field_descriptor),
(Int -> Tag
Data.ProtoLens.Tag 2, FieldDescriptor NodeDef'AttrEntry
value__field_descriptor)]
unknownFields :: LensLike' f NodeDef'AttrEntry FieldSet
unknownFields
= (NodeDef'AttrEntry -> FieldSet)
-> (NodeDef'AttrEntry -> FieldSet -> NodeDef'AttrEntry)
-> Lens' NodeDef'AttrEntry FieldSet
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
NodeDef'AttrEntry -> FieldSet
_NodeDef'AttrEntry'_unknownFields
(\ x__ :: NodeDef'AttrEntry
x__ y__ :: FieldSet
y__ -> NodeDef'AttrEntry
x__ {_NodeDef'AttrEntry'_unknownFields :: FieldSet
_NodeDef'AttrEntry'_unknownFields = FieldSet
y__})
defMessage :: NodeDef'AttrEntry
defMessage
= $WNodeDef'AttrEntry'_constructor :: Text -> Maybe AttrValue -> FieldSet -> NodeDef'AttrEntry
NodeDef'AttrEntry'_constructor
{_NodeDef'AttrEntry'key :: Text
_NodeDef'AttrEntry'key = Text
forall value. FieldDefault value => value
Data.ProtoLens.fieldDefault,
_NodeDef'AttrEntry'value :: Maybe AttrValue
_NodeDef'AttrEntry'value = Maybe AttrValue
forall a. Maybe a
Prelude.Nothing,
_NodeDef'AttrEntry'_unknownFields :: FieldSet
_NodeDef'AttrEntry'_unknownFields = []}
parseMessage :: Parser NodeDef'AttrEntry
parseMessage
= let
loop ::
NodeDef'AttrEntry
-> Data.ProtoLens.Encoding.Bytes.Parser NodeDef'AttrEntry
loop :: NodeDef'AttrEntry -> Parser NodeDef'AttrEntry
loop x :: NodeDef'AttrEntry
x
= do Bool
end <- Parser Bool
Data.ProtoLens.Encoding.Bytes.atEnd
if Bool
end then
do (let missing :: [a]
missing = []
in
if [Any] -> Bool
forall (t :: * -> *) a. Foldable t => t a -> Bool
Prelude.null [Any]
forall a. [a]
missing then
() -> Parser ()
forall (m :: * -> *) a. Monad m => a -> m a
Prelude.return ()
else
String -> Parser ()
forall (m :: * -> *) a. MonadFail m => String -> m a
Prelude.fail
(String -> ShowS
forall a. [a] -> [a] -> [a]
(Prelude.++)
"Missing required fields: "
([String] -> String
forall a. Show a => a -> String
Prelude.show ([String]
forall a. [a]
missing :: [Prelude.String]))))
NodeDef'AttrEntry -> Parser NodeDef'AttrEntry
forall (m :: * -> *) a. Monad m => a -> m a
Prelude.return
(Setter NodeDef'AttrEntry NodeDef'AttrEntry FieldSet FieldSet
-> (FieldSet -> FieldSet) -> NodeDef'AttrEntry -> NodeDef'AttrEntry
forall s t a b. Setter s t a b -> (a -> b) -> s -> t
Lens.Family2.over
forall msg. Message msg => Lens' msg FieldSet
Setter NodeDef'AttrEntry NodeDef'AttrEntry FieldSet FieldSet
Data.ProtoLens.unknownFields (\ !FieldSet
t -> FieldSet -> FieldSet
forall a. [a] -> [a]
Prelude.reverse FieldSet
t) NodeDef'AttrEntry
x)
else
do Word64
tag <- Parser Word64
Data.ProtoLens.Encoding.Bytes.getVarInt
case Word64
tag of
10
-> do Text
y <- Parser Text -> String -> Parser Text
forall a. Parser a -> String -> Parser a
(Data.ProtoLens.Encoding.Bytes.<?>)
(do ByteString
value <- do Word64
len <- Parser Word64
Data.ProtoLens.Encoding.Bytes.getVarInt
Int -> Parser ByteString
Data.ProtoLens.Encoding.Bytes.getBytes
(Word64 -> Int
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral Word64
len)
Either String Text -> Parser Text
forall a. Either String a -> Parser a
Data.ProtoLens.Encoding.Bytes.runEither
(case ByteString -> Either UnicodeException Text
Data.Text.Encoding.decodeUtf8' ByteString
value of
(Prelude.Left err :: UnicodeException
err)
-> String -> Either String Text
forall a b. a -> Either a b
Prelude.Left (UnicodeException -> String
forall a. Show a => a -> String
Prelude.show UnicodeException
err)
(Prelude.Right r :: Text
r) -> Text -> Either String Text
forall a b. b -> Either a b
Prelude.Right Text
r))
"key"
NodeDef'AttrEntry -> Parser NodeDef'AttrEntry
loop (Setter NodeDef'AttrEntry NodeDef'AttrEntry Text Text
-> Text -> NodeDef'AttrEntry -> NodeDef'AttrEntry
forall s t a b. Setter s t a b -> b -> s -> t
Lens.Family2.set (forall s a (f :: * -> *).
(HasField s "key" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"key") Text
y NodeDef'AttrEntry
x)
18
-> do AttrValue
y <- Parser AttrValue -> String -> Parser AttrValue
forall a. Parser a -> String -> Parser a
(Data.ProtoLens.Encoding.Bytes.<?>)
(do Word64
len <- Parser Word64
Data.ProtoLens.Encoding.Bytes.getVarInt
Int -> Parser AttrValue -> Parser AttrValue
forall a. Int -> Parser a -> Parser a
Data.ProtoLens.Encoding.Bytes.isolate
(Word64 -> Int
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral Word64
len) Parser AttrValue
forall msg. Message msg => Parser msg
Data.ProtoLens.parseMessage)
"value"
NodeDef'AttrEntry -> Parser NodeDef'AttrEntry
loop (Setter NodeDef'AttrEntry NodeDef'AttrEntry AttrValue AttrValue
-> AttrValue -> NodeDef'AttrEntry -> NodeDef'AttrEntry
forall s t a b. Setter s t a b -> b -> s -> t
Lens.Family2.set (forall s a (f :: * -> *).
(HasField s "value" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"value") AttrValue
y NodeDef'AttrEntry
x)
wire :: Word64
wire
-> do !TaggedValue
y <- Word64 -> Parser TaggedValue
Data.ProtoLens.Encoding.Wire.parseTaggedValueFromWire
Word64
wire
NodeDef'AttrEntry -> Parser NodeDef'AttrEntry
loop
(Setter NodeDef'AttrEntry NodeDef'AttrEntry FieldSet FieldSet
-> (FieldSet -> FieldSet) -> NodeDef'AttrEntry -> NodeDef'AttrEntry
forall s t a b. Setter s t a b -> (a -> b) -> s -> t
Lens.Family2.over
forall msg. Message msg => Lens' msg FieldSet
Setter NodeDef'AttrEntry NodeDef'AttrEntry FieldSet FieldSet
Data.ProtoLens.unknownFields (\ !FieldSet
t -> (:) TaggedValue
y FieldSet
t) NodeDef'AttrEntry
x)
in
Parser NodeDef'AttrEntry -> String -> Parser NodeDef'AttrEntry
forall a. Parser a -> String -> Parser a
(Data.ProtoLens.Encoding.Bytes.<?>)
(do NodeDef'AttrEntry -> Parser NodeDef'AttrEntry
loop NodeDef'AttrEntry
forall msg. Message msg => msg
Data.ProtoLens.defMessage) "AttrEntry"
buildMessage :: NodeDef'AttrEntry -> Builder
buildMessage
= \ _x :: NodeDef'AttrEntry
_x
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(let _v :: Text
_v = FoldLike Text NodeDef'AttrEntry NodeDef'AttrEntry Text Text
-> NodeDef'AttrEntry -> Text
forall a s t b. FoldLike a s t a b -> s -> a
Lens.Family2.view (forall s a (f :: * -> *).
(HasField s "key" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"key") NodeDef'AttrEntry
_x
in
if Text -> Text -> Bool
forall a. Eq a => a -> a -> Bool
(Prelude.==) Text
_v Text
forall value. FieldDefault value => value
Data.ProtoLens.fieldDefault then
Builder
forall a. Monoid a => a
Data.Monoid.mempty
else
Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt 10)
((ByteString -> Builder) -> (Text -> ByteString) -> Text -> Builder
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
(\ bs :: ByteString
bs
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt
(Int -> Word64
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral (ByteString -> Int
Data.ByteString.length ByteString
bs)))
(ByteString -> Builder
Data.ProtoLens.Encoding.Bytes.putBytes ByteString
bs))
Text -> ByteString
Data.Text.Encoding.encodeUtf8
Text
_v))
(Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(case
FoldLike
(Maybe AttrValue)
NodeDef'AttrEntry
NodeDef'AttrEntry
(Maybe AttrValue)
(Maybe AttrValue)
-> NodeDef'AttrEntry -> Maybe AttrValue
forall a s t b. FoldLike a s t a b -> s -> a
Lens.Family2.view (forall s a (f :: * -> *).
(HasField s "maybe'value" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"maybe'value") NodeDef'AttrEntry
_x
of
Prelude.Nothing -> Builder
forall a. Monoid a => a
Data.Monoid.mempty
(Prelude.Just _v :: AttrValue
_v)
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt 18)
((ByteString -> Builder)
-> (AttrValue -> ByteString) -> AttrValue -> Builder
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
(\ bs :: ByteString
bs
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt
(Int -> Word64
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral (ByteString -> Int
Data.ByteString.length ByteString
bs)))
(ByteString -> Builder
Data.ProtoLens.Encoding.Bytes.putBytes ByteString
bs))
AttrValue -> ByteString
forall msg. Message msg => msg -> ByteString
Data.ProtoLens.encodeMessage
AttrValue
_v))
(FieldSet -> Builder
Data.ProtoLens.Encoding.Wire.buildFieldSet
(FoldLike
FieldSet NodeDef'AttrEntry NodeDef'AttrEntry FieldSet FieldSet
-> NodeDef'AttrEntry -> FieldSet
forall a s t b. FoldLike a s t a b -> s -> a
Lens.Family2.view FoldLike
FieldSet NodeDef'AttrEntry NodeDef'AttrEntry FieldSet FieldSet
forall msg. Message msg => Lens' msg FieldSet
Data.ProtoLens.unknownFields NodeDef'AttrEntry
_x)))
instance Control.DeepSeq.NFData NodeDef'AttrEntry where
rnf :: NodeDef'AttrEntry -> ()
rnf
= \ x__ :: NodeDef'AttrEntry
x__
-> FieldSet -> () -> ()
forall a b. NFData a => a -> b -> b
Control.DeepSeq.deepseq
(NodeDef'AttrEntry -> FieldSet
_NodeDef'AttrEntry'_unknownFields NodeDef'AttrEntry
x__)
(Text -> () -> ()
forall a b. NFData a => a -> b -> b
Control.DeepSeq.deepseq
(NodeDef'AttrEntry -> Text
_NodeDef'AttrEntry'key NodeDef'AttrEntry
x__)
(Maybe AttrValue -> () -> ()
forall a b. NFData a => a -> b -> b
Control.DeepSeq.deepseq (NodeDef'AttrEntry -> Maybe AttrValue
_NodeDef'AttrEntry'value NodeDef'AttrEntry
x__) ()))
data NodeDef'ExperimentalDebugInfo
= NodeDef'ExperimentalDebugInfo'_constructor {NodeDef'ExperimentalDebugInfo -> Vector Text
_NodeDef'ExperimentalDebugInfo'originalNodeNames :: !(Data.Vector.Vector Data.Text.Text),
NodeDef'ExperimentalDebugInfo -> Vector Text
_NodeDef'ExperimentalDebugInfo'originalFuncNames :: !(Data.Vector.Vector Data.Text.Text),
NodeDef'ExperimentalDebugInfo -> FieldSet
_NodeDef'ExperimentalDebugInfo'_unknownFields :: !Data.ProtoLens.FieldSet}
deriving stock (NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool
(NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool)
-> (NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool)
-> Eq NodeDef'ExperimentalDebugInfo
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool
$c/= :: NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool
== :: NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool
$c== :: NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool
Prelude.Eq, Eq NodeDef'ExperimentalDebugInfo
Eq NodeDef'ExperimentalDebugInfo =>
(NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Ordering)
-> (NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool)
-> (NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool)
-> (NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool)
-> (NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool)
-> (NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> NodeDef'ExperimentalDebugInfo)
-> (NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> NodeDef'ExperimentalDebugInfo)
-> Ord NodeDef'ExperimentalDebugInfo
NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool
NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Ordering
NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> NodeDef'ExperimentalDebugInfo
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 :: NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> NodeDef'ExperimentalDebugInfo
$cmin :: NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> NodeDef'ExperimentalDebugInfo
max :: NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> NodeDef'ExperimentalDebugInfo
$cmax :: NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> NodeDef'ExperimentalDebugInfo
>= :: NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool
$c>= :: NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool
> :: NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool
$c> :: NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool
<= :: NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool
$c<= :: NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool
< :: NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool
$c< :: NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Bool
compare :: NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Ordering
$ccompare :: NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo -> Ordering
$cp1Ord :: Eq NodeDef'ExperimentalDebugInfo
Prelude.Ord)
instance Prelude.Show NodeDef'ExperimentalDebugInfo where
showsPrec :: Int -> NodeDef'ExperimentalDebugInfo -> ShowS
showsPrec _ __x :: NodeDef'ExperimentalDebugInfo
__x __s :: String
__s
= Char -> ShowS
Prelude.showChar
'{'
(String -> ShowS
Prelude.showString
(NodeDef'ExperimentalDebugInfo -> String
forall msg. Message msg => msg -> String
Data.ProtoLens.showMessageShort NodeDef'ExperimentalDebugInfo
__x) (Char -> ShowS
Prelude.showChar '}' String
__s))
instance Data.ProtoLens.Field.HasField NodeDef'ExperimentalDebugInfo "originalNodeNames" [Data.Text.Text] where
fieldOf :: Proxy# "originalNodeNames"
-> ([Text] -> f [Text])
-> NodeDef'ExperimentalDebugInfo
-> f NodeDef'ExperimentalDebugInfo
fieldOf _
= ((Vector Text -> f (Vector Text))
-> NodeDef'ExperimentalDebugInfo
-> f NodeDef'ExperimentalDebugInfo)
-> (([Text] -> f [Text]) -> Vector Text -> f (Vector Text))
-> ([Text] -> f [Text])
-> NodeDef'ExperimentalDebugInfo
-> f NodeDef'ExperimentalDebugInfo
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
((NodeDef'ExperimentalDebugInfo -> Vector Text)
-> (NodeDef'ExperimentalDebugInfo
-> Vector Text -> NodeDef'ExperimentalDebugInfo)
-> Lens
NodeDef'ExperimentalDebugInfo
NodeDef'ExperimentalDebugInfo
(Vector Text)
(Vector Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
NodeDef'ExperimentalDebugInfo -> Vector Text
_NodeDef'ExperimentalDebugInfo'originalNodeNames
(\ x__ :: NodeDef'ExperimentalDebugInfo
x__ y__ :: Vector Text
y__
-> NodeDef'ExperimentalDebugInfo
x__ {_NodeDef'ExperimentalDebugInfo'originalNodeNames :: Vector Text
_NodeDef'ExperimentalDebugInfo'originalNodeNames = Vector Text
y__}))
((Vector Text -> [Text])
-> (Vector Text -> [Text] -> Vector Text)
-> Lens (Vector Text) (Vector Text) [Text] [Text]
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
Vector Text -> [Text]
forall (v :: * -> *) a. Vector v a => v a -> [a]
Data.Vector.Generic.toList
(\ _ y__ :: [Text]
y__ -> [Text] -> Vector Text
forall (v :: * -> *) a. Vector v a => [a] -> v a
Data.Vector.Generic.fromList [Text]
y__))
instance Data.ProtoLens.Field.HasField NodeDef'ExperimentalDebugInfo "vec'originalNodeNames" (Data.Vector.Vector Data.Text.Text) where
fieldOf :: Proxy# "vec'originalNodeNames"
-> (Vector Text -> f (Vector Text))
-> NodeDef'ExperimentalDebugInfo
-> f NodeDef'ExperimentalDebugInfo
fieldOf _
= ((Vector Text -> f (Vector Text))
-> NodeDef'ExperimentalDebugInfo
-> f NodeDef'ExperimentalDebugInfo)
-> ((Vector Text -> f (Vector Text))
-> Vector Text -> f (Vector Text))
-> (Vector Text -> f (Vector Text))
-> NodeDef'ExperimentalDebugInfo
-> f NodeDef'ExperimentalDebugInfo
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
((NodeDef'ExperimentalDebugInfo -> Vector Text)
-> (NodeDef'ExperimentalDebugInfo
-> Vector Text -> NodeDef'ExperimentalDebugInfo)
-> Lens
NodeDef'ExperimentalDebugInfo
NodeDef'ExperimentalDebugInfo
(Vector Text)
(Vector Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
NodeDef'ExperimentalDebugInfo -> Vector Text
_NodeDef'ExperimentalDebugInfo'originalNodeNames
(\ x__ :: NodeDef'ExperimentalDebugInfo
x__ y__ :: Vector Text
y__
-> NodeDef'ExperimentalDebugInfo
x__ {_NodeDef'ExperimentalDebugInfo'originalNodeNames :: Vector Text
_NodeDef'ExperimentalDebugInfo'originalNodeNames = Vector Text
y__}))
(Vector Text -> f (Vector Text)) -> Vector Text -> f (Vector Text)
forall a. a -> a
Prelude.id
instance Data.ProtoLens.Field.HasField NodeDef'ExperimentalDebugInfo "originalFuncNames" [Data.Text.Text] where
fieldOf :: Proxy# "originalFuncNames"
-> ([Text] -> f [Text])
-> NodeDef'ExperimentalDebugInfo
-> f NodeDef'ExperimentalDebugInfo
fieldOf _
= ((Vector Text -> f (Vector Text))
-> NodeDef'ExperimentalDebugInfo
-> f NodeDef'ExperimentalDebugInfo)
-> (([Text] -> f [Text]) -> Vector Text -> f (Vector Text))
-> ([Text] -> f [Text])
-> NodeDef'ExperimentalDebugInfo
-> f NodeDef'ExperimentalDebugInfo
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
((NodeDef'ExperimentalDebugInfo -> Vector Text)
-> (NodeDef'ExperimentalDebugInfo
-> Vector Text -> NodeDef'ExperimentalDebugInfo)
-> Lens
NodeDef'ExperimentalDebugInfo
NodeDef'ExperimentalDebugInfo
(Vector Text)
(Vector Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
NodeDef'ExperimentalDebugInfo -> Vector Text
_NodeDef'ExperimentalDebugInfo'originalFuncNames
(\ x__ :: NodeDef'ExperimentalDebugInfo
x__ y__ :: Vector Text
y__
-> NodeDef'ExperimentalDebugInfo
x__ {_NodeDef'ExperimentalDebugInfo'originalFuncNames :: Vector Text
_NodeDef'ExperimentalDebugInfo'originalFuncNames = Vector Text
y__}))
((Vector Text -> [Text])
-> (Vector Text -> [Text] -> Vector Text)
-> Lens (Vector Text) (Vector Text) [Text] [Text]
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
Vector Text -> [Text]
forall (v :: * -> *) a. Vector v a => v a -> [a]
Data.Vector.Generic.toList
(\ _ y__ :: [Text]
y__ -> [Text] -> Vector Text
forall (v :: * -> *) a. Vector v a => [a] -> v a
Data.Vector.Generic.fromList [Text]
y__))
instance Data.ProtoLens.Field.HasField NodeDef'ExperimentalDebugInfo "vec'originalFuncNames" (Data.Vector.Vector Data.Text.Text) where
fieldOf :: Proxy# "vec'originalFuncNames"
-> (Vector Text -> f (Vector Text))
-> NodeDef'ExperimentalDebugInfo
-> f NodeDef'ExperimentalDebugInfo
fieldOf _
= ((Vector Text -> f (Vector Text))
-> NodeDef'ExperimentalDebugInfo
-> f NodeDef'ExperimentalDebugInfo)
-> ((Vector Text -> f (Vector Text))
-> Vector Text -> f (Vector Text))
-> (Vector Text -> f (Vector Text))
-> NodeDef'ExperimentalDebugInfo
-> f NodeDef'ExperimentalDebugInfo
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
((NodeDef'ExperimentalDebugInfo -> Vector Text)
-> (NodeDef'ExperimentalDebugInfo
-> Vector Text -> NodeDef'ExperimentalDebugInfo)
-> Lens
NodeDef'ExperimentalDebugInfo
NodeDef'ExperimentalDebugInfo
(Vector Text)
(Vector Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
NodeDef'ExperimentalDebugInfo -> Vector Text
_NodeDef'ExperimentalDebugInfo'originalFuncNames
(\ x__ :: NodeDef'ExperimentalDebugInfo
x__ y__ :: Vector Text
y__
-> NodeDef'ExperimentalDebugInfo
x__ {_NodeDef'ExperimentalDebugInfo'originalFuncNames :: Vector Text
_NodeDef'ExperimentalDebugInfo'originalFuncNames = Vector Text
y__}))
(Vector Text -> f (Vector Text)) -> Vector Text -> f (Vector Text)
forall a. a -> a
Prelude.id
instance Data.ProtoLens.Message NodeDef'ExperimentalDebugInfo where
messageName :: Proxy NodeDef'ExperimentalDebugInfo -> Text
messageName _
= String -> Text
Data.Text.pack "tensorflow.NodeDef.ExperimentalDebugInfo"
packedMessageDescriptor :: Proxy NodeDef'ExperimentalDebugInfo -> ByteString
packedMessageDescriptor _
= "\n\
\\NAKExperimentalDebugInfo\DC2.\n\
\\DC3original_node_names\CAN\SOH \ETX(\tR\DC1originalNodeNames\DC2.\n\
\\DC3original_func_names\CAN\STX \ETX(\tR\DC1originalFuncNames"
packedFileDescriptor :: Proxy NodeDef'ExperimentalDebugInfo -> ByteString
packedFileDescriptor _ = ByteString
packedFileDescriptor
fieldsByTag :: Map Tag (FieldDescriptor NodeDef'ExperimentalDebugInfo)
fieldsByTag
= let
originalNodeNames__field_descriptor :: FieldDescriptor NodeDef'ExperimentalDebugInfo
originalNodeNames__field_descriptor
= String
-> FieldTypeDescriptor Text
-> FieldAccessor NodeDef'ExperimentalDebugInfo Text
-> FieldDescriptor NodeDef'ExperimentalDebugInfo
forall value msg.
String
-> FieldTypeDescriptor value
-> FieldAccessor msg value
-> FieldDescriptor msg
Data.ProtoLens.FieldDescriptor
"original_node_names"
(ScalarField Text -> FieldTypeDescriptor Text
forall value. ScalarField value -> FieldTypeDescriptor value
Data.ProtoLens.ScalarField ScalarField Text
Data.ProtoLens.StringField ::
Data.ProtoLens.FieldTypeDescriptor Data.Text.Text)
(Packing
-> Lens' NodeDef'ExperimentalDebugInfo [Text]
-> FieldAccessor NodeDef'ExperimentalDebugInfo Text
forall msg value.
Packing -> Lens' msg [value] -> FieldAccessor msg value
Data.ProtoLens.RepeatedField
Packing
Data.ProtoLens.Unpacked
(forall s a (f :: * -> *).
(HasField s "originalNodeNames" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"originalNodeNames")) ::
Data.ProtoLens.FieldDescriptor NodeDef'ExperimentalDebugInfo
originalFuncNames__field_descriptor :: FieldDescriptor NodeDef'ExperimentalDebugInfo
originalFuncNames__field_descriptor
= String
-> FieldTypeDescriptor Text
-> FieldAccessor NodeDef'ExperimentalDebugInfo Text
-> FieldDescriptor NodeDef'ExperimentalDebugInfo
forall value msg.
String
-> FieldTypeDescriptor value
-> FieldAccessor msg value
-> FieldDescriptor msg
Data.ProtoLens.FieldDescriptor
"original_func_names"
(ScalarField Text -> FieldTypeDescriptor Text
forall value. ScalarField value -> FieldTypeDescriptor value
Data.ProtoLens.ScalarField ScalarField Text
Data.ProtoLens.StringField ::
Data.ProtoLens.FieldTypeDescriptor Data.Text.Text)
(Packing
-> Lens' NodeDef'ExperimentalDebugInfo [Text]
-> FieldAccessor NodeDef'ExperimentalDebugInfo Text
forall msg value.
Packing -> Lens' msg [value] -> FieldAccessor msg value
Data.ProtoLens.RepeatedField
Packing
Data.ProtoLens.Unpacked
(forall s a (f :: * -> *).
(HasField s "originalFuncNames" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"originalFuncNames")) ::
Data.ProtoLens.FieldDescriptor NodeDef'ExperimentalDebugInfo
in
[(Tag, FieldDescriptor NodeDef'ExperimentalDebugInfo)]
-> Map Tag (FieldDescriptor NodeDef'ExperimentalDebugInfo)
forall k a. Ord k => [(k, a)] -> Map k a
Data.Map.fromList
[(Int -> Tag
Data.ProtoLens.Tag 1, FieldDescriptor NodeDef'ExperimentalDebugInfo
originalNodeNames__field_descriptor),
(Int -> Tag
Data.ProtoLens.Tag 2, FieldDescriptor NodeDef'ExperimentalDebugInfo
originalFuncNames__field_descriptor)]
unknownFields :: LensLike' f NodeDef'ExperimentalDebugInfo FieldSet
unknownFields
= (NodeDef'ExperimentalDebugInfo -> FieldSet)
-> (NodeDef'ExperimentalDebugInfo
-> FieldSet -> NodeDef'ExperimentalDebugInfo)
-> Lens' NodeDef'ExperimentalDebugInfo FieldSet
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.Family2.Unchecked.lens
NodeDef'ExperimentalDebugInfo -> FieldSet
_NodeDef'ExperimentalDebugInfo'_unknownFields
(\ x__ :: NodeDef'ExperimentalDebugInfo
x__ y__ :: FieldSet
y__
-> NodeDef'ExperimentalDebugInfo
x__ {_NodeDef'ExperimentalDebugInfo'_unknownFields :: FieldSet
_NodeDef'ExperimentalDebugInfo'_unknownFields = FieldSet
y__})
defMessage :: NodeDef'ExperimentalDebugInfo
defMessage
= $WNodeDef'ExperimentalDebugInfo'_constructor :: Vector Text
-> Vector Text -> FieldSet -> NodeDef'ExperimentalDebugInfo
NodeDef'ExperimentalDebugInfo'_constructor
{_NodeDef'ExperimentalDebugInfo'originalNodeNames :: Vector Text
_NodeDef'ExperimentalDebugInfo'originalNodeNames = Vector Text
forall (v :: * -> *) a. Vector v a => v a
Data.Vector.Generic.empty,
_NodeDef'ExperimentalDebugInfo'originalFuncNames :: Vector Text
_NodeDef'ExperimentalDebugInfo'originalFuncNames = Vector Text
forall (v :: * -> *) a. Vector v a => v a
Data.Vector.Generic.empty,
_NodeDef'ExperimentalDebugInfo'_unknownFields :: FieldSet
_NodeDef'ExperimentalDebugInfo'_unknownFields = []}
parseMessage :: Parser NodeDef'ExperimentalDebugInfo
parseMessage
= let
loop ::
NodeDef'ExperimentalDebugInfo
-> Data.ProtoLens.Encoding.Growing.Growing Data.Vector.Vector Data.ProtoLens.Encoding.Growing.RealWorld Data.Text.Text
-> Data.ProtoLens.Encoding.Growing.Growing Data.Vector.Vector Data.ProtoLens.Encoding.Growing.RealWorld Data.Text.Text
-> Data.ProtoLens.Encoding.Bytes.Parser NodeDef'ExperimentalDebugInfo
loop :: NodeDef'ExperimentalDebugInfo
-> Growing Vector RealWorld Text
-> Growing Vector RealWorld Text
-> Parser NodeDef'ExperimentalDebugInfo
loop x :: NodeDef'ExperimentalDebugInfo
x mutable'originalFuncNames :: Growing Vector RealWorld Text
mutable'originalFuncNames mutable'originalNodeNames :: Growing Vector RealWorld Text
mutable'originalNodeNames
= do Bool
end <- Parser Bool
Data.ProtoLens.Encoding.Bytes.atEnd
if Bool
end then
do Vector Text
frozen'originalFuncNames <- IO (Vector Text) -> Parser (Vector Text)
forall a. IO a -> Parser a
Data.ProtoLens.Encoding.Parser.Unsafe.unsafeLiftIO
(Growing Vector (PrimState IO) Text -> IO (Vector Text)
forall (m :: * -> *) (v :: * -> *) a.
(PrimMonad m, Vector v a) =>
Growing v (PrimState m) a -> m (v a)
Data.ProtoLens.Encoding.Growing.unsafeFreeze
Growing Vector RealWorld Text
Growing Vector (PrimState IO) Text
mutable'originalFuncNames)
Vector Text
frozen'originalNodeNames <- IO (Vector Text) -> Parser (Vector Text)
forall a. IO a -> Parser a
Data.ProtoLens.Encoding.Parser.Unsafe.unsafeLiftIO
(Growing Vector (PrimState IO) Text -> IO (Vector Text)
forall (m :: * -> *) (v :: * -> *) a.
(PrimMonad m, Vector v a) =>
Growing v (PrimState m) a -> m (v a)
Data.ProtoLens.Encoding.Growing.unsafeFreeze
Growing Vector RealWorld Text
Growing Vector (PrimState IO) Text
mutable'originalNodeNames)
(let missing :: [a]
missing = []
in
if [Any] -> Bool
forall (t :: * -> *) a. Foldable t => t a -> Bool
Prelude.null [Any]
forall a. [a]
missing then
() -> Parser ()
forall (m :: * -> *) a. Monad m => a -> m a
Prelude.return ()
else
String -> Parser ()
forall (m :: * -> *) a. MonadFail m => String -> m a
Prelude.fail
(String -> ShowS
forall a. [a] -> [a] -> [a]
(Prelude.++)
"Missing required fields: "
([String] -> String
forall a. Show a => a -> String
Prelude.show ([String]
forall a. [a]
missing :: [Prelude.String]))))
NodeDef'ExperimentalDebugInfo
-> Parser NodeDef'ExperimentalDebugInfo
forall (m :: * -> *) a. Monad m => a -> m a
Prelude.return
(Setter
NodeDef'ExperimentalDebugInfo
NodeDef'ExperimentalDebugInfo
FieldSet
FieldSet
-> (FieldSet -> FieldSet)
-> NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo
forall s t a b. Setter s t a b -> (a -> b) -> s -> t
Lens.Family2.over
forall msg. Message msg => Lens' msg FieldSet
Setter
NodeDef'ExperimentalDebugInfo
NodeDef'ExperimentalDebugInfo
FieldSet
FieldSet
Data.ProtoLens.unknownFields
(\ !FieldSet
t -> FieldSet -> FieldSet
forall a. [a] -> [a]
Prelude.reverse FieldSet
t)
(Setter
NodeDef'ExperimentalDebugInfo
NodeDef'ExperimentalDebugInfo
(Vector Text)
(Vector Text)
-> Vector Text
-> NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo
forall s t a b. Setter s t a b -> b -> s -> t
Lens.Family2.set
(forall s a (f :: * -> *).
(HasField s "vec'originalFuncNames" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"vec'originalFuncNames")
Vector Text
frozen'originalFuncNames
(Setter
NodeDef'ExperimentalDebugInfo
NodeDef'ExperimentalDebugInfo
(Vector Text)
(Vector Text)
-> Vector Text
-> NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo
forall s t a b. Setter s t a b -> b -> s -> t
Lens.Family2.set
(forall s a (f :: * -> *).
(HasField s "vec'originalNodeNames" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"vec'originalNodeNames")
Vector Text
frozen'originalNodeNames
NodeDef'ExperimentalDebugInfo
x)))
else
do Word64
tag <- Parser Word64
Data.ProtoLens.Encoding.Bytes.getVarInt
case Word64
tag of
10
-> do !Text
y <- Parser Text -> String -> Parser Text
forall a. Parser a -> String -> Parser a
(Data.ProtoLens.Encoding.Bytes.<?>)
(do ByteString
value <- do Word64
len <- Parser Word64
Data.ProtoLens.Encoding.Bytes.getVarInt
Int -> Parser ByteString
Data.ProtoLens.Encoding.Bytes.getBytes
(Word64 -> Int
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral Word64
len)
Either String Text -> Parser Text
forall a. Either String a -> Parser a
Data.ProtoLens.Encoding.Bytes.runEither
(case ByteString -> Either UnicodeException Text
Data.Text.Encoding.decodeUtf8' ByteString
value of
(Prelude.Left err :: UnicodeException
err)
-> String -> Either String Text
forall a b. a -> Either a b
Prelude.Left (UnicodeException -> String
forall a. Show a => a -> String
Prelude.show UnicodeException
err)
(Prelude.Right r :: Text
r) -> Text -> Either String Text
forall a b. b -> Either a b
Prelude.Right Text
r))
"original_node_names"
Growing Vector RealWorld Text
v <- IO (Growing Vector RealWorld Text)
-> Parser (Growing Vector RealWorld Text)
forall a. IO a -> Parser a
Data.ProtoLens.Encoding.Parser.Unsafe.unsafeLiftIO
(Growing Vector (PrimState IO) Text
-> Text -> IO (Growing Vector (PrimState IO) Text)
forall (m :: * -> *) (v :: * -> *) a.
(PrimMonad m, Vector v a) =>
Growing v (PrimState m) a -> a -> m (Growing v (PrimState m) a)
Data.ProtoLens.Encoding.Growing.append
Growing Vector RealWorld Text
Growing Vector (PrimState IO) Text
mutable'originalNodeNames Text
y)
NodeDef'ExperimentalDebugInfo
-> Growing Vector RealWorld Text
-> Growing Vector RealWorld Text
-> Parser NodeDef'ExperimentalDebugInfo
loop NodeDef'ExperimentalDebugInfo
x Growing Vector RealWorld Text
mutable'originalFuncNames Growing Vector RealWorld Text
v
18
-> do !Text
y <- Parser Text -> String -> Parser Text
forall a. Parser a -> String -> Parser a
(Data.ProtoLens.Encoding.Bytes.<?>)
(do ByteString
value <- do Word64
len <- Parser Word64
Data.ProtoLens.Encoding.Bytes.getVarInt
Int -> Parser ByteString
Data.ProtoLens.Encoding.Bytes.getBytes
(Word64 -> Int
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral Word64
len)
Either String Text -> Parser Text
forall a. Either String a -> Parser a
Data.ProtoLens.Encoding.Bytes.runEither
(case ByteString -> Either UnicodeException Text
Data.Text.Encoding.decodeUtf8' ByteString
value of
(Prelude.Left err :: UnicodeException
err)
-> String -> Either String Text
forall a b. a -> Either a b
Prelude.Left (UnicodeException -> String
forall a. Show a => a -> String
Prelude.show UnicodeException
err)
(Prelude.Right r :: Text
r) -> Text -> Either String Text
forall a b. b -> Either a b
Prelude.Right Text
r))
"original_func_names"
Growing Vector RealWorld Text
v <- IO (Growing Vector RealWorld Text)
-> Parser (Growing Vector RealWorld Text)
forall a. IO a -> Parser a
Data.ProtoLens.Encoding.Parser.Unsafe.unsafeLiftIO
(Growing Vector (PrimState IO) Text
-> Text -> IO (Growing Vector (PrimState IO) Text)
forall (m :: * -> *) (v :: * -> *) a.
(PrimMonad m, Vector v a) =>
Growing v (PrimState m) a -> a -> m (Growing v (PrimState m) a)
Data.ProtoLens.Encoding.Growing.append
Growing Vector RealWorld Text
Growing Vector (PrimState IO) Text
mutable'originalFuncNames Text
y)
NodeDef'ExperimentalDebugInfo
-> Growing Vector RealWorld Text
-> Growing Vector RealWorld Text
-> Parser NodeDef'ExperimentalDebugInfo
loop NodeDef'ExperimentalDebugInfo
x Growing Vector RealWorld Text
v Growing Vector RealWorld Text
mutable'originalNodeNames
wire :: Word64
wire
-> do !TaggedValue
y <- Word64 -> Parser TaggedValue
Data.ProtoLens.Encoding.Wire.parseTaggedValueFromWire
Word64
wire
NodeDef'ExperimentalDebugInfo
-> Growing Vector RealWorld Text
-> Growing Vector RealWorld Text
-> Parser NodeDef'ExperimentalDebugInfo
loop
(Setter
NodeDef'ExperimentalDebugInfo
NodeDef'ExperimentalDebugInfo
FieldSet
FieldSet
-> (FieldSet -> FieldSet)
-> NodeDef'ExperimentalDebugInfo
-> NodeDef'ExperimentalDebugInfo
forall s t a b. Setter s t a b -> (a -> b) -> s -> t
Lens.Family2.over
forall msg. Message msg => Lens' msg FieldSet
Setter
NodeDef'ExperimentalDebugInfo
NodeDef'ExperimentalDebugInfo
FieldSet
FieldSet
Data.ProtoLens.unknownFields (\ !FieldSet
t -> (:) TaggedValue
y FieldSet
t) NodeDef'ExperimentalDebugInfo
x)
Growing Vector RealWorld Text
mutable'originalFuncNames
Growing Vector RealWorld Text
mutable'originalNodeNames
in
Parser NodeDef'ExperimentalDebugInfo
-> String -> Parser NodeDef'ExperimentalDebugInfo
forall a. Parser a -> String -> Parser a
(Data.ProtoLens.Encoding.Bytes.<?>)
(do Growing Vector RealWorld Text
mutable'originalFuncNames <- IO (Growing Vector RealWorld Text)
-> Parser (Growing Vector RealWorld Text)
forall a. IO a -> Parser a
Data.ProtoLens.Encoding.Parser.Unsafe.unsafeLiftIO
IO (Growing Vector RealWorld Text)
forall (m :: * -> *) (v :: * -> *) a.
(PrimMonad m, Vector v a) =>
m (Growing v (PrimState m) a)
Data.ProtoLens.Encoding.Growing.new
Growing Vector RealWorld Text
mutable'originalNodeNames <- IO (Growing Vector RealWorld Text)
-> Parser (Growing Vector RealWorld Text)
forall a. IO a -> Parser a
Data.ProtoLens.Encoding.Parser.Unsafe.unsafeLiftIO
IO (Growing Vector RealWorld Text)
forall (m :: * -> *) (v :: * -> *) a.
(PrimMonad m, Vector v a) =>
m (Growing v (PrimState m) a)
Data.ProtoLens.Encoding.Growing.new
NodeDef'ExperimentalDebugInfo
-> Growing Vector RealWorld Text
-> Growing Vector RealWorld Text
-> Parser NodeDef'ExperimentalDebugInfo
loop
NodeDef'ExperimentalDebugInfo
forall msg. Message msg => msg
Data.ProtoLens.defMessage
Growing Vector RealWorld Text
mutable'originalFuncNames
Growing Vector RealWorld Text
mutable'originalNodeNames)
"ExperimentalDebugInfo"
buildMessage :: NodeDef'ExperimentalDebugInfo -> Builder
buildMessage
= \ _x :: NodeDef'ExperimentalDebugInfo
_x
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
((Text -> Builder) -> Vector Text -> Builder
forall (v :: * -> *) a.
Vector v a =>
(a -> Builder) -> v a -> Builder
Data.ProtoLens.Encoding.Bytes.foldMapBuilder
(\ _v :: Text
_v
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt 10)
((ByteString -> Builder) -> (Text -> ByteString) -> Text -> Builder
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
(\ bs :: ByteString
bs
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt
(Int -> Word64
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral (ByteString -> Int
Data.ByteString.length ByteString
bs)))
(ByteString -> Builder
Data.ProtoLens.Encoding.Bytes.putBytes ByteString
bs))
Text -> ByteString
Data.Text.Encoding.encodeUtf8
Text
_v))
(FoldLike
(Vector Text)
NodeDef'ExperimentalDebugInfo
NodeDef'ExperimentalDebugInfo
(Vector Text)
(Vector Text)
-> NodeDef'ExperimentalDebugInfo -> Vector Text
forall a s t b. FoldLike a s t a b -> s -> a
Lens.Family2.view
(forall s a (f :: * -> *).
(HasField s "vec'originalNodeNames" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"vec'originalNodeNames") NodeDef'ExperimentalDebugInfo
_x))
(Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
((Text -> Builder) -> Vector Text -> Builder
forall (v :: * -> *) a.
Vector v a =>
(a -> Builder) -> v a -> Builder
Data.ProtoLens.Encoding.Bytes.foldMapBuilder
(\ _v :: Text
_v
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt 18)
((ByteString -> Builder) -> (Text -> ByteString) -> Text -> Builder
forall b c a. (b -> c) -> (a -> b) -> a -> c
(Prelude..)
(\ bs :: ByteString
bs
-> Builder -> Builder -> Builder
forall a. Semigroup a => a -> a -> a
(Data.Monoid.<>)
(Word64 -> Builder
Data.ProtoLens.Encoding.Bytes.putVarInt
(Int -> Word64
forall a b. (Integral a, Num b) => a -> b
Prelude.fromIntegral (ByteString -> Int
Data.ByteString.length ByteString
bs)))
(ByteString -> Builder
Data.ProtoLens.Encoding.Bytes.putBytes ByteString
bs))
Text -> ByteString
Data.Text.Encoding.encodeUtf8
Text
_v))
(FoldLike
(Vector Text)
NodeDef'ExperimentalDebugInfo
NodeDef'ExperimentalDebugInfo
(Vector Text)
(Vector Text)
-> NodeDef'ExperimentalDebugInfo -> Vector Text
forall a s t b. FoldLike a s t a b -> s -> a
Lens.Family2.view
(forall s a (f :: * -> *).
(HasField s "vec'originalFuncNames" a, Functor f) =>
(a -> f a) -> s -> f s
forall (x :: Symbol) s a (f :: * -> *).
(HasField s x a, Functor f) =>
(a -> f a) -> s -> f s
Data.ProtoLens.Field.field @"vec'originalFuncNames") NodeDef'ExperimentalDebugInfo
_x))
(FieldSet -> Builder
Data.ProtoLens.Encoding.Wire.buildFieldSet
(FoldLike
FieldSet
NodeDef'ExperimentalDebugInfo
NodeDef'ExperimentalDebugInfo
FieldSet
FieldSet
-> NodeDef'ExperimentalDebugInfo -> FieldSet
forall a s t b. FoldLike a s t a b -> s -> a
Lens.Family2.view FoldLike
FieldSet
NodeDef'ExperimentalDebugInfo
NodeDef'ExperimentalDebugInfo
FieldSet
FieldSet
forall msg. Message msg => Lens' msg FieldSet
Data.ProtoLens.unknownFields NodeDef'ExperimentalDebugInfo
_x)))
instance Control.DeepSeq.NFData NodeDef'ExperimentalDebugInfo where
rnf :: NodeDef'ExperimentalDebugInfo -> ()
rnf
= \ x__ :: NodeDef'ExperimentalDebugInfo
x__
-> FieldSet -> () -> ()
forall a b. NFData a => a -> b -> b
Control.DeepSeq.deepseq
(NodeDef'ExperimentalDebugInfo -> FieldSet
_NodeDef'ExperimentalDebugInfo'_unknownFields NodeDef'ExperimentalDebugInfo
x__)
(Vector Text -> () -> ()
forall a b. NFData a => a -> b -> b
Control.DeepSeq.deepseq
(NodeDef'ExperimentalDebugInfo -> Vector Text
_NodeDef'ExperimentalDebugInfo'originalNodeNames NodeDef'ExperimentalDebugInfo
x__)
(Vector Text -> () -> ()
forall a b. NFData a => a -> b -> b
Control.DeepSeq.deepseq
(NodeDef'ExperimentalDebugInfo -> Vector Text
_NodeDef'ExperimentalDebugInfo'originalFuncNames NodeDef'ExperimentalDebugInfo
x__) ()))
packedFileDescriptor :: Data.ByteString.ByteString
packedFileDescriptor :: ByteString
packedFileDescriptor
= "\n\
\(tensorflow/core/framework/node_def.proto\DC2\n\
\tensorflow\SUB*tensorflow/core/framework/attr_value.proto\"\186\ETX\n\
\\aNodeDef\DC2\DC2\n\
\\EOTname\CAN\SOH \SOH(\tR\EOTname\DC2\SO\n\
\\STXop\CAN\STX \SOH(\tR\STXop\DC2\DC4\n\
\\ENQinput\CAN\ETX \ETX(\tR\ENQinput\DC2\SYN\n\
\\ACKdevice\CAN\EOT \SOH(\tR\ACKdevice\DC21\n\
\\EOTattr\CAN\ENQ \ETX(\v2\GS.tensorflow.NodeDef.AttrEntryR\EOTattr\DC2a\n\
\\ETBexperimental_debug_info\CAN\ACK \SOH(\v2).tensorflow.NodeDef.ExperimentalDebugInfoR\NAKexperimentalDebugInfo\SUBN\n\
\\tAttrEntry\DC2\DLE\n\
\\ETXkey\CAN\SOH \SOH(\tR\ETXkey\DC2+\n\
\\ENQvalue\CAN\STX \SOH(\v2\NAK.tensorflow.AttrValueR\ENQvalue:\STX8\SOH\SUBw\n\
\\NAKExperimentalDebugInfo\DC2.\n\
\\DC3original_node_names\CAN\SOH \ETX(\tR\DC1originalNodeNames\DC2.\n\
\\DC3original_func_names\CAN\STX \ETX(\tR\DC1originalFuncNamesB{\n\
\\CANorg.tensorflow.frameworkB\tNodeProtoP\SOHZOgithub.com/tensorflow/tensorflow/tensorflow/go/core/framework/node_def_go_proto\248\SOH\SOHJ\231\FS\n\
\\ACK\DC2\EOT\NUL\NULW\SOH\n\
\\b\n\
\\SOH\f\DC2\ETX\NUL\NUL\DC2\n\
\\b\n\
\\SOH\STX\DC2\ETX\STX\NUL\DC3\n\
\\t\n\
\\STX\ETX\NUL\DC2\ETX\EOT\NUL4\n\
\\b\n\
\\SOH\b\DC2\ETX\ACK\NUL\US\n\
\\t\n\
\\STX\b\US\DC2\ETX\ACK\NUL\US\n\
\\b\n\
\\SOH\b\DC2\ETX\a\NUL*\n\
\\t\n\
\\STX\b\b\DC2\ETX\a\NUL*\n\
\\b\n\
\\SOH\b\DC2\ETX\b\NUL\"\n\
\\t\n\
\\STX\b\n\
\\DC2\ETX\b\NUL\"\n\
\\b\n\
\\SOH\b\DC2\ETX\t\NUL1\n\
\\t\n\
\\STX\b\SOH\DC2\ETX\t\NUL1\n\
\\b\n\
\\SOH\b\DC2\ETX\n\
\\NULf\n\
\\t\n\
\\STX\b\v\DC2\ETX\n\
\\NULf\n\
\\n\
\\n\
\\STX\EOT\NUL\DC2\EOT\f\NULW\SOH\n\
\\n\
\\n\
\\ETX\EOT\NUL\SOH\DC2\ETX\f\b\SI\n\
\\191\SOH\n\
\\EOT\EOT\NUL\STX\NUL\DC2\ETX\DLE\STX\DC2\SUB\177\SOH The name given to this operator. Used for naming inputs,\n\
\ logging, visualization, etc. Unique within a single GraphDef.\n\
\ Must match the regexp \"[A-Za-z0-9.][A-Za-z0-9_>./]*\".\n\
\\n\
\\f\n\
\\ENQ\EOT\NUL\STX\NUL\ENQ\DC2\ETX\DLE\STX\b\n\
\\f\n\
\\ENQ\EOT\NUL\STX\NUL\SOH\DC2\ETX\DLE\t\r\n\
\\f\n\
\\ENQ\EOT\NUL\STX\NUL\ETX\DC2\ETX\DLE\DLE\DC1\n\
\\146\SOH\n\
\\EOT\EOT\NUL\STX\SOH\DC2\ETX\DC4\STX\DLE\SUB\132\SOH The operation name. There may be custom parameters in attrs.\n\
\ Op names starting with an underscore are reserved for internal use.\n\
\\n\
\\f\n\
\\ENQ\EOT\NUL\STX\SOH\ENQ\DC2\ETX\DC4\STX\b\n\
\\f\n\
\\ENQ\EOT\NUL\STX\SOH\SOH\DC2\ETX\DC4\t\v\n\
\\f\n\
\\ENQ\EOT\NUL\STX\SOH\ETX\DC2\ETX\DC4\SO\SI\n\
\\167\STX\n\
\\EOT\EOT\NUL\STX\STX\DC2\ETX\ESC\STX\FS\SUB\153\STX Each input is \"node:src_output\" with \"node\" being a string name and\n\
\ \"src_output\" indicating which output tensor to use from \"node\". If\n\
\ \"src_output\" is 0 the \":0\" suffix can be omitted. Regular inputs\n\
\ may optionally be followed by control inputs that have the format\n\
\ \"^node\".\n\
\\n\
\\f\n\
\\ENQ\EOT\NUL\STX\STX\EOT\DC2\ETX\ESC\STX\n\
\\n\
\\f\n\
\\ENQ\EOT\NUL\STX\STX\ENQ\DC2\ETX\ESC\v\DC1\n\
\\f\n\
\\ENQ\EOT\NUL\STX\STX\SOH\DC2\ETX\ESC\DC2\ETB\n\
\\f\n\
\\ENQ\EOT\NUL\STX\STX\ETX\DC2\ETX\ESC\SUB\ESC\n\
\\161\ACK\n\
\\EOT\EOT\NUL\STX\ETX\DC2\ETX1\STX\DC4\SUB\147\ACK A (possibly partial) specification for the device on which this\n\
\ node should be placed.\n\
\ The expected syntax for this string is as follows:\n\
\\n\
\ DEVICE_SPEC ::= PARTIAL_SPEC\n\
\\n\
\ PARTIAL_SPEC ::= (\"/\" CONSTRAINT) *\n\
\ CONSTRAINT ::= (\"job:\" JOB_NAME)\n\
\ | (\"replica:\" [1-9][0-9]*)\n\
\ | (\"task:\" [1-9][0-9]*)\n\
\ | (\"device:\" [A-Za-z]* \":\" ([1-9][0-9]* | \"*\") )\n\
\\n\
\ Valid values for this string include:\n\
\ * \"/job:worker/replica:0/task:1/device:GPU:3\" (full specification)\n\
\ * \"/job:worker/device:GPU:3\" (partial specification)\n\
\ * \"\" (no specification)\n\
\\n\
\ If the constraints do not resolve to a single device (or if this\n\
\ field is empty or not present), the runtime will attempt to\n\
\ choose a device automatically.\n\
\\n\
\\f\n\
\\ENQ\EOT\NUL\STX\ETX\ENQ\DC2\ETX1\STX\b\n\
\\f\n\
\\ENQ\EOT\NUL\STX\ETX\SOH\DC2\ETX1\t\SI\n\
\\f\n\
\\ENQ\EOT\NUL\STX\ETX\ETX\DC2\ETX1\DC2\DC3\n\
\\148\ENQ\n\
\\EOT\EOT\NUL\STX\EOT\DC2\ETX?\STX\"\SUB\134\ENQ Operation-specific graph-construction-time configuration.\n\
\ Note that this should include all attrs defined in the\n\
\ corresponding OpDef, including those with a value matching\n\
\ the default -- this allows the default to change and makes\n\
\ NodeDefs easier to interpret on their own. However, if\n\
\ an attr with a default is not specified in this list, the\n\
\ default will be used.\n\
\ The \"names\" (keys) must match the regexp \"[a-z][a-z0-9_]+\" (and\n\
\ one of the names from the corresponding OpDef's attr field).\n\
\ The values must have a type matching the corresponding OpDef\n\
\ attr's type field.\n\
\ TODO(josh11b): Add some examples here showing best practices.\n\
\\n\
\\f\n\
\\ENQ\EOT\NUL\STX\EOT\ACK\DC2\ETX?\STX\CAN\n\
\\f\n\
\\ENQ\EOT\NUL\STX\EOT\SOH\DC2\ETX?\EM\GS\n\
\\f\n\
\\ENQ\EOT\NUL\STX\EOT\ETX\DC2\ETX? !\n\
\\f\n\
\\EOT\EOT\NUL\ETX\SOH\DC2\EOTA\STXS\ETX\n\
\\f\n\
\\ENQ\EOT\NUL\ETX\SOH\SOH\DC2\ETXA\n\
\\US\n\
\\163\ETX\n\
\\ACK\EOT\NUL\ETX\SOH\STX\NUL\DC2\ETXI\EOT,\SUB\147\ETX Opaque string inserted into error messages created by the runtime.\n\
\\n\
\ This is intended to store the list of names of the nodes from the\n\
\ original graph that this node was derived. For example if this node, say\n\
\ C, was result of a fusion of 2 nodes A and B, then 'original_node' would\n\
\ be {A, B}. This information can be used to map errors originating at the\n\
\ current node to some top level source code.\n\
\\n\
\\SO\n\
\\a\EOT\NUL\ETX\SOH\STX\NUL\EOT\DC2\ETXI\EOT\f\n\
\\SO\n\
\\a\EOT\NUL\ETX\SOH\STX\NUL\ENQ\DC2\ETXI\r\DC3\n\
\\SO\n\
\\a\EOT\NUL\ETX\SOH\STX\NUL\SOH\DC2\ETXI\DC4'\n\
\\SO\n\
\\a\EOT\NUL\ETX\SOH\STX\NUL\ETX\DC2\ETXI*+\n\
\\236\ETX\n\
\\ACK\EOT\NUL\ETX\SOH\STX\SOH\DC2\ETXR\EOT,\SUB\220\ETX This is intended to store the list of names of the functions from the\n\
\ original graph that this node was derived. For example if this node, say\n\
\ C, was result of a fusion of node A in function FA and node B in function\n\
\ FB, then `original_funcs` would be {FA, FB}. If the node is in the top\n\
\ level graph, the `original_func` is empty. This information, with the\n\
\ `original_node_names` can be used to map errors originating at the\n\
\ current ndoe to some top level source code.\n\
\\n\
\\SO\n\
\\a\EOT\NUL\ETX\SOH\STX\SOH\EOT\DC2\ETXR\EOT\f\n\
\\SO\n\
\\a\EOT\NUL\ETX\SOH\STX\SOH\ENQ\DC2\ETXR\r\DC3\n\
\\SO\n\
\\a\EOT\NUL\ETX\SOH\STX\SOH\SOH\DC2\ETXR\DC4'\n\
\\SO\n\
\\a\EOT\NUL\ETX\SOH\STX\SOH\ETX\DC2\ETXR*+\n\
\F\n\
\\EOT\EOT\NUL\STX\ENQ\DC2\ETXV\STX4\SUB9 This stores debug information associated with the node.\n\
\\n\
\\f\n\
\\ENQ\EOT\NUL\STX\ENQ\ACK\DC2\ETXV\STX\ETB\n\
\\f\n\
\\ENQ\EOT\NUL\STX\ENQ\SOH\DC2\ETXV\CAN/\n\
\\f\n\
\\ENQ\EOT\NUL\STX\ENQ\ETX\DC2\ETXV23b\ACKproto3"