# BufferInfo

```cpp
#include <qbruntime/type.h>

struct mobilint::BufferInfo
```

Struct representing input/output buffer information.

## Attributes

| Member | Description |
| --- | --- |
| [`original_height`](<#original-height>) |  |
| [`original_width`](<#original-width>) |  |
| [`original_channel`](<#original-channel>) |  |
| [`reshaped_height`](<#reshaped-height>) |  |
| [`reshaped_width`](<#reshaped-width>) |  |
| [`reshaped_channel`](<#reshaped-channel>) |  |
| [`height`](<#height>) |  |
| [`width`](<#width>) |  |
| [`channel`](<#channel>) |  |
| [`max_height`](<#max-height>) |  |
| [`max_width`](<#max-width>) |  |
| [`max_channel`](<#max-channel>) |  |
| [`max_cache_size`](<#max-cache-size>) |  |

### original\_height

```cpp
uint32_t original_height
```

Height of original input/output

### original\_width

```cpp
uint32_t original_width
```

Width of original input/output

### original\_channel

```cpp
uint32_t original_channel
```

Channel of original input/output

### reshaped\_height

```cpp
uint32_t reshaped_height
```

Height of reshaped input/output

### reshaped\_width

```cpp
uint32_t reshaped_width
```

Width of reshaped input/output

### reshaped\_channel

```cpp
uint32_t reshaped_channel
```

Channel of reshaped input/output

### height

```cpp
uint32_t height
```

Height of NPU input/output

### width

```cpp
uint32_t width
```

Width of NPU input/output

### channel

```cpp
uint32_t channel
```

Channel of NPU input/output

### max\_height

```cpp
uint32_t max_height
```

Maximum height of original input/output if data is sequential.

### max\_width

```cpp
uint32_t max_width
```

Maximum width of original input/output if data is sequential.

### max\_channel

```cpp
uint32_t max_channel
```

Maximum channel of original input/output if data is sequential.

### max\_cache\_size

```cpp
uint32_t max_cache_size
```

Maximum KV-cache size, relevant for LLM models using KV cache.

## Member functions

| Member | Description |
| --- | --- |
| [`original_size`](<#original-size>) | Returns the total size of the original input/output. |
| [`reshaped_size`](<#reshaped-size>) | Returns the total size of the reshaped input/output. |
| [`size`](<#size>) | Returns the total size of the NPU input/output. |

### original\_size

```cpp
uint32_t original_size() const
```

Returns the total size of the original input/output.

**Returns**

The data size.

### reshaped\_size

```cpp
uint32_t reshaped_size() const
```

Returns the total size of the reshaped input/output.

**Returns**

The data size.

### size

```cpp
uint32_t size() const
```

Returns the total size of the NPU input/output.

**Returns**

The data size.
