Web Analytics

kp value


Information of one connected device from USB perspectives.

property firmware(: str)

str: Firmware description.

get_member_variable_dict()

Represent member variables with Dict format.

property is_connectable(: bool)

bool: Indicate if this device is connectable.

property kn_number(: int)

int: KN number.

UsbSpeed: Enum for USB speed mode.

property product_id(: int)

int: USB PID (Product ID).

property usb_port_id(: int)

int: An unique ID representing for a Kneron device, can be used as input while connecting devices.

property usb_port_path(: str)

str: “busNo-hub_portNo-device_portNo” (ex: “1-2-3”, means bus 1 - (hub) port 2 - (device) port 3)

property vendor_id(: int)

int: Supposed to be 0x3231.


class kp.DeviceDescriptorList(device_descriptor_list=[])

Information of connected devices from USB perspectives.

property device_descriptor_list(: List[kp.KPValue.DeviceDescriptor])

List[kp.DeviceDescriptor]: DeviceDescriptor objects list, contain information of connected devices from USB perspectives.

property device_descriptor_number(: int)

int: Number of connected devices.

get_member_variable_dict()

Represent member variables with Dict format.


class kp.DeviceGroup(address)

A handle represent connected Kneron device.

property address(: int)

int: Memory address of connected Kneron device handler.

get_member_variable_dict()

Represent member variables with Dict format.


class kp.FirmwareVersion(reserved=0, major=0, minor=0, update=0, build=0)

Information of firmware version.

get_member_variable_dict()

Represent member variables with Dict format.

property reserved(: int)

int: Reserved version number for backward compatibility.


class kp.GenericRawBypassPreProcImageHeader(model_id=0, inference_number=0, image_buffer_size=0)

Inference descriptor for images bypass pre-processing.

get_member_variable_dict()

Represent member variables with Dict format.

property image_buffer_size(: int)

int: Inference image buffer size.

property inference_number(: int)

int: Inference sequence number.

property model_id(: int)

int: Target inference model ID.


class kp.GenericRawBypassPreProcResult(buffer_size)

Generic inference raw result for bypass pre-processing.

get_member_variable_dict()

Represent member variables with Dict format.

property header(: kp.KPValue.GenericRawBypassPreProcResultHeader)

kp.GenericRawBypassPreProcResultHeader: Inference raw output descriptor for bypass pre-processing.

property raw_result(: kp.KPValue.GenericRawResultNDArray)

kp.GenericRawResultNDArray: Inference raw result buffer.


class kp.GenericRawBypassPreProcResultHeader(inference_number=0, crop_number=0, num_output_node=0)

Inference raw output descriptor for bypass pre-processing.

property crop_number(: int)

int: Crop box sequence number.

get_member_variable_dict()

Represent member variables with Dict format.

property inference_number(: int)

int: Inference sequence number.

property num_output_node(: int)

int: Total number of output nodes.


class kp.GenericRawImageHeader(model_id=0, resize_mode=ResizeMode.KP_RESIZE_ENABLE, padding_mode=PaddingMode.KP_PADDING_CORNER, normalize_mode=NormalizeMode.KP_NORMALIZE_KNERON, inference_number=0, inference_crop_box_list=[], width=0, height=0, image_format=ImageFormat.KP_IMAGE_FORMAT_RGB565)

Inference descriptor for images.

property crop_count(: int)

int: Number of crop box.

get_member_variable_dict()

Represent member variables with Dict format.

property height(: int)

int: Inference image height.

property image_format(: kp.KPEnum.ImageFormat)

kp.ImageFormat: Inference image format, refer to ImageFormat.

property inference_crop_box_list(: List[kp.KPValue.InferenceCropBox])

List[kp.InferenceCropBox]: Box information to crop.

property inference_number(: int)

int: Inference sequence number.

property model_id(: int)

int: Target inference model ID.

property normalize_mode(: kp.KPEnum.NormalizeMode)

kp.NormalizeMode: Inference normalization, refer to NormalizeMode.

property padding_mode(: kp.KPEnum.PaddingMode)

kp.PaddingMode: Preprocess padding mode, none or auto refer to PaddingMode.

property resize_mode(: kp.KPEnum.ResizeMode)

kp.ResizeMode: Preprocess resize mode, refer to ResizeMode.

property width(: int)

int: Inference image width.


class kp.GenericRawResult(buffer_size)

Generic inference raw result.

get_member_variable_dict()

Represent member variables with Dict format.

property header(: kp.KPValue.GenericRawResultHeader)

kp.GenericRawResultHeader: Inference raw output descriptor.

property raw_result(: kp.KPValue.GenericRawResultNDArray)

kp.GenericRawResultNDArray: Inference raw result buffer.


class kp.GenericRawResultHeader(inference_number=0, crop_number=0, num_output_node=0)

Inference raw output descriptor.

property crop_number(: int)

int: Crop box sequence number.

get_member_variable_dict()

Represent member variables with Dict format.

property inference_number(: int)

int: Inference sequence number.

property num_output_node(: int)

int: Total number of output nodes.


class kp.GenericRawResultNDArray(buffer_size)

Inference raw result buffer.

property buffer_size(: int)

int: Size of generic inference raw result buffer.

get_member_variable_dict()

Represent member variables with Dict format.


class kp.InferenceConfiguration(enable_frame_drop=False)

Inference configurations.

property enable_frame_drop(: bool)

bool: Enable this to keep inference non-blocking by dropping oldest and unprocessed frames.

get_member_variable_dict()

Represent member variables with Dict format.


class kp.InferenceCropBox(crop_box_index=0, x=0, y=0, width=0, height=0)

Class for an image crop region.

property crop_box_index(: int)

int: Index number of crop box.

get_member_variable_dict()

Represent member variables with Dict format.

property height(: int)

int: Height coordinate of crop box.

property width(: int)

int: Width coordinate of crop box.

property x(: int)

int: X coordinate of crop box top-left corner.

property y(: int)

int: Y coordinate of crop box top-left corner.


class kp.InferenceFixedNodeOutput(width=0, height=0, channel=0, radix=0, scale=0, factor=0, num_data=0, data=array([], dtype=float64), channels_ordering=ChannelOrdering.KP_CHANNEL_ORDERING_CHW)

Generic inference node output in fixed-point format.

property channel(: int)

int: Channel of output node.

property channels_ordering(: kp.KPEnum.ChannelOrdering)

kp.ChannelOrdering: Channel ordering of feature map. (Options: KP_CHANNEL_ORDERING_HCW, KP_CHANNEL_ORDERING_CHW)

property factor(: float)

float: Conversion factor for fixed-point to floating-point conversion - formulation: 1 / (scale * (2 ^ radix)).

get_member_variable_dict()

Represent member variables with Dict format.

property height(: int)

int: Height of output node.

property ndarray(: numpy.ndarray)

numpy.ndarray: N-dimensional numpy.ndarray of feature map.

property num_data(: int)

int: Total number of fixed-point values.

property radix(: int)

int: Radix for fixed/floating point conversion.

property scale(: float)

float: Scale for fixed/floating point conversion.

to_float_node_output()

Convert fixed-point node output to floating-point node output.

property width(: int)

int: Width of output node.


class kp.InferenceFloatNodeOutput(width=0, height=0, channel=0, num_data=0, data=array([], dtype=float64), channels_ordering=ChannelOrdering.KP_CHANNEL_ORDERING_CHW)

Generic inference node output in floating-point format.

property channel(: int)

int: Channel of output node.

property channels_ordering(: kp.KPEnum.ChannelOrdering)

kp.ChannelOrdering: Channel ordering of feature map. (Options: KP_CHANNEL_ORDERING_HCW, KP_CHANNEL_ORDERING_CHW)

get_member_variable_dict()

Represent member variables with Dict format.

property height(: int)

int: Height of output node.

property ndarray(: numpy.ndarray)

numpy.ndarray: N-dimensional numpy.ndarray of feature map.

property num_data(: int)

int: Total number of floating-point values.

property width(: int)

int: Width of output node.


class kp.ModelNefDescriptor(crc=0, num_models=0, models=[])

A basic descriptor for a NEF.

property crc(: int)

int: The CRC of all models.

get_member_variable_dict()

Represent member variables with Dict format.

property models(: List[kp.KPValue.SingleModelDescriptor])

List[kp.SingleModelDescriptor]: SingleModelDescriptor objects list, contain information of uploaded NEF information.

property num_models(: int)

int: The number of models contains in NEF.


class kp.SingleModelDescriptor(id=0, max_raw_out_size=0, width=0, height=0, channel=0, img_format=ImageFormat.KP_IMAGE_FORMAT_RGBA8888)

A basic descriptor for a model.

property channel(: int)

int: The input channel of this model.

get_member_variable_dict()

Represent member variables with Dict format.

property height(: int)

int: input height of this model.

property id(: int)

int: Model ID.

property img_format(: kp.KPEnum.ImageFormat)

kp.ImageFormat: The input image format of this model.

property max_raw_out_size(: int)

int: Needed raw output buffer size for this model.

property width(: int)

int: The input width of this model.


class kp.SystemInfo(kn_number=0, firmware_version={'firmware_version': '0.0.0-build.0'})

System Information of Kneron device.

property firmware_version()

kp.FirmwareVersion: Firmware version of Kneron device.

get_member_variable_dict()

Represent member variables with Dict format.

property kn_number()

int: Unique Kneron device ID.