Kaspersky Neuromorphic Platform  1.0.0
API Reference
Loading...
Searching...
No Matches
knp::devices::cpu::CPU Class Reference

The CPU class is a definition of an interface to the CPU device. More...

#include <knp/devices/cpu.h>

+ Inheritance diagram for knp::devices::cpu::CPU:
+ Collaboration diagram for knp::devices::cpu::CPU:

Public Member Functions

 CPU (const CPU &)=delete
 Avoid copy of a CPU device.
 
CPUoperator= (const CPU &)=delete
 Avoid copy assignment of a CPU device.
 
 CPU (CPU &&)
 CPU device move constructor.
 
CPUoperator= (CPU &&) noexcept
 CPU device move operator.
 
 ~CPU () override
 CPU device destructor.
 
knp::core::DeviceType get_type () const override
 Get device type.
 
const std::string & get_name () const override
 Get device name.
 
uint32_t get_socket_number () const
 Get CPU device socket number.
 
float get_power () const override
 Get power consumption details for the device.
 
- Public Member Functions inherited from knp::core::Device
virtual ~Device ()=default
 Device destructor.
 
const UIDget_uid () const
 Get device UID.
 
auto & get_tags ()
 Get tags used by the device.
 

Friends

KNP_DECLSPEC std::vector< CPUlist_processors ()
 List all processors on which backend can be initialized.
 

Additional Inherited Members

- Protected Attributes inherited from knp::core::Device
BaseData base_
 Device base data.
 

Detailed Description

The CPU class is a definition of an interface to the CPU device.

Definition at line 51 of file cpu.h.

Member Function Documentation

◆ get_name()

const std::string & knp::devices::cpu::CPU::get_name ( ) const
nodiscardoverridevirtual

Get device name.

Returns
device name in the arbitrary format.

Implements knp::core::Device.

◆ get_power()

float knp::devices::cpu::CPU::get_power ( ) const
nodiscardoverridevirtual

Get power consumption details for the device.

Returns
amount of consumed power.

Implements knp::core::Device.

◆ get_socket_number()

uint32_t knp::devices::cpu::CPU::get_socket_number ( ) const
nodiscard

Get CPU device socket number.

Returns
socket number.

◆ get_type()

knp::core::DeviceType knp::devices::cpu::CPU::get_type ( ) const
nodiscardoverridevirtual

Get device type.

Returns
device type.

Implements knp::core::Device.

◆ operator=()

CPU & knp::devices::cpu::CPU::operator= ( CPU && )
noexcept

CPU device move operator.

Returns
reference to CPU instance.

Friends And Related Symbol Documentation

◆ list_processors

KNP_DECLSPEC std::vector< CPU > list_processors ( )
friend

List all processors on which backend can be initialized.

Returns
vector of CPUs.

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