bitsim
Model, simulate, estimate and control robots in C++
Loading...
Searching...
No Matches
bitrl::maths::stats::TorchDistributionBase Class Referenceabstract

The TorchDistribution class. Base class to derive distributions for PyTorch. More...

#include <torch_distribution.h>

Inheritance diagram for bitrl::maths::stats::TorchDistributionBase:

Public Member Functions

virtual ~TorchDistributionBase ()=default
 Destructor.
virtual torch_tensor_t entropy () const =0
 entropy
virtual torch_tensor_t log_prob (torch_tensor_t value)=0
 log_prob
virtual torch_tensor_t sample (c10::ArrayRef< int64_t > sample_shape)=0
 Ssample. Sample from the distribution.

Protected Member Functions

 TorchDistributionBase ()=default
 Constructor.
std::vector< int64_t > extended_shape (c10::ArrayRef< int64_t > sample_shape)
 extended_shape

Protected Attributes

std::vector< int64_t > batch_shape_
 batch_shape_
std::vector< int64_t > event_shape_
 event_shape_

Detailed Description

The TorchDistribution class. Base class to derive distributions for PyTorch.

Constructor & Destructor Documentation

◆ ~TorchDistributionBase()

virtual bitrl::maths::stats::TorchDistributionBase::~TorchDistributionBase ( )
virtualdefault

Destructor.

◆ TorchDistributionBase()

bitrl::maths::stats::TorchDistributionBase::TorchDistributionBase ( )
protecteddefault

Constructor.

Member Function Documentation

◆ entropy()

◆ extended_shape()

std::vector< int64_t > bitrl::maths::stats::TorchDistributionBase::extended_shape ( c10::ArrayRef< int64_t > sample_shape)
protected

extended_shape

Parameters
sample_shape
Returns

◆ log_prob()

◆ sample()

Member Data Documentation

◆ batch_shape_

std::vector<int64_t> bitrl::maths::stats::TorchDistributionBase::batch_shape_
protected

batch_shape_

◆ event_shape_

std::vector<int64_t> bitrl::maths::stats::TorchDistributionBase::event_shape_
protected

event_shape_


The documentation for this class was generated from the following file: