37 BOOST_ASSERT(inferredShapes.size() == 1);
39 ConditionalThrowIfNotEqual<LayerValidationException>(
40 "LogSoftmaxLayer: TensorShape set on OutputSlot[0] does not match the inferred shape.",
const char * GetName() const override
std::vector< TensorShape > InferOutputShapes(const std::vector< TensorShape > &inputShapes) const override
virtual const TensorInfo & GetTensorInfo() const =0
virtual void VisitLogSoftmaxLayer(const IConnectableLayer *layer, const LogSoftmaxDescriptor &logSoftmaxDescriptor, const char *name=nullptr)=0
This layer represents a log softmax operation.
void ValidateTensorShapesFromInputs() override
const LogSoftmaxDescriptor & GetParameters() const
virtual std::unique_ptr< IWorkload > CreateWorkload(const IWorkloadFactory &factory) const override
LogSoftmaxDescriptor m_Param
The parameters for the layer (not including tensor-valued weights etc.).
void VerifyLayerConnections(unsigned int expectedConnections, const CheckLocation &location) const
WorkloadInfo PrepInfoAndDesc(QueueDescriptor &descriptor) const
Helper function to reduce duplication in *LayerCreateWorkload.
A SoftmaxDescriptor for the SoftmaxLayer.
virtual std::unique_ptr< IWorkload > CreateLogSoftmax(const LogSoftmaxQueueDescriptor &descriptor, const WorkloadInfo &info) const
LogSoftmaxLayer(const LogSoftmaxDescriptor ¶m, const char *name)
void Accept(ILayerVisitor &visitor) const override
const TensorShape & GetShape() const
const TensorInfo & GetTensorInfo() const override
const OutputSlot & GetOutputSlot(unsigned int index=0) const override
void LogSoftmax(Decoder< float > &input, Encoder< float > &output, const TensorInfo &inputInfo, const LogSoftmaxDescriptor &descriptor)
const InputSlot & GetInputSlot(unsigned int index) const override
LogSoftmaxLayer * Clone(Graph &graph) const override