rexlib 0.1.0
Device-agnostic array computing library for CryoEM and CryoET image processing, with a pluggable backend architecture
Loading...
Searching...
No Matches
Public Types | Static Public Attributes | List of all members
rexlib::operand_shape_rule< Pivots, Outputs, Inputs, Placement, Batch > Struct Template Reference

Declarative shape rule for the operands of an operation. More...

#include <rexlib/core/operation/shape_rule/operand_shape_rule.hpp>

Public Types

using pivot_list_type = Pivots
 
using output_core_list_type = Outputs
 
using input_core_list_type = Inputs
 
using placement_type = Placement
 

Static Public Attributes

static REXLIB_CONST_CONSTEXPR output_batch batch = Batch
 
static REXLIB_CONST_CONSTEXPR std::size_t pivot_count
 
static REXLIB_CONST_CONSTEXPR std::size_t output_count
 
static REXLIB_CONST_CONSTEXPR std::size_t input_count
 
static REXLIB_CONST_CONSTEXPR bool requires_parameters
 Whether the rule reads values of the operation instance.
 

Detailed Description

template<typename Pivots, typename Outputs, typename Inputs, typename Placement = trailing_core, output_batch Batch = output_batch::exact>
struct rexlib::operand_shape_rule< Pivots, Outputs, Inputs, Placement, Batch >

Declarative shape rule for the operands of an operation.

Every axis of an operand is either a batch axis or a core axis. The batch axes of all operands broadcast together, while the core axes are declared per operand by a core_dimensions, whose slots relate them through a small set of extent variables. Core axes never broadcast: every axis naming an extent variable must agree with it.

The rule is lowered to tables, so a single interpreter serves every operation. Values that depend on the operation instance, such as the axes it names, are read through the accessors the rule declares.

Template Parameters
Pivotstype_list of extent_pivot declarations.
Outputstype_list of core_dimensions, one per output operand, in signature order.
Inputstype_list of core_dimensions, one per input operand, in signature order.
PlacementWhere the core axes lie: trailing_core or named_core.
BatchWhich batch axes an output supplied in advance may have.
See also
extent_pivot
core_dimensions

Member Data Documentation

◆ input_count

template<typename Pivots , typename Outputs , typename Inputs , typename Placement = trailing_core, output_batch Batch = output_batch::exact>
REXLIB_CONST_CONSTEXPR std::size_t rexlib::operand_shape_rule< Pivots, Outputs, Inputs, Placement, Batch >::input_count
static
Initial value:
=
type_list_size<Inputs>::value

◆ output_count

template<typename Pivots , typename Outputs , typename Inputs , typename Placement = trailing_core, output_batch Batch = output_batch::exact>
REXLIB_CONST_CONSTEXPR std::size_t rexlib::operand_shape_rule< Pivots, Outputs, Inputs, Placement, Batch >::output_count
static
Initial value:
=
type_list_size<Outputs>::value

◆ pivot_count

template<typename Pivots , typename Outputs , typename Inputs , typename Placement = trailing_core, output_batch Batch = output_batch::exact>
REXLIB_CONST_CONSTEXPR std::size_t rexlib::operand_shape_rule< Pivots, Outputs, Inputs, Placement, Batch >::pivot_count
static
Initial value:
=
type_list_size<Pivots>::value

◆ requires_parameters

template<typename Pivots , typename Outputs , typename Inputs , typename Placement = trailing_core, output_batch Batch = output_batch::exact>
REXLIB_CONST_CONSTEXPR bool rexlib::operand_shape_rule< Pivots, Outputs, Inputs, Placement, Batch >::requires_parameters
static
Initial value:
=
Placement::placement == core_placement::named ||
detail::extents_from_operation<Pivots>::value
@ named
The axes the operation instance names.

Whether the rule reads values of the operation instance.


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