---
name: "mlpack_image_converter"
section: "1"
platform: "linux"
package: "mlpack-bin"
version: "3.4.2-1+b2"
release: "Debian 11 (Bullseye)"
platforms: ["linux"]
url: "https://new.carta.tech/mlpack_image_converter"
---

# mlpack\_image\_converter(1)

image converter

## NAME

**mlpack\_image\_converter** - image converter

## SYNOPSIS

```
 mlpack_image_converter -i vector [-c int] [-I string] [-H int] [-q int] [-s bool] [-V bool] [-w int] [-o string] [-h -v]
```

## DESCRIPTION

This utility takes an image or an array of images and loads them to a matrix. You can optionally specify the height '**--height** (**-H**)' width '**--width** (**-w**)' and channel '**--channels** (**-c**)' of the images that needs to be loaded; otherwise, these parameters will be automatically detected from the image. There are other options too, that can be specified such as '**--quality** (**-q**)'.

You can also provide a dataset and save them as images using '**--dataset\_file** (**-I**)' and '**--save** (**-s**)' as an parameter.

```
  An example to load an image :
```

$ **mlpack\_image\_converter** **--input** X **--height** 256 **--width** 256 **--channels** 3 **--output\_file** Y.csv

An example to save an image is :

$ **mlpack\_image\_converter** **--input** X **--height** 256 **--width** 256 **--channels** 3 **--dataset\_file** Y.csv **--save**

## REQUIRED INPUT OPTIONS

- **--input (-i) \[*vector*\]**

  Image filenames which have to be loaded/saved.

## OPTIONAL INPUT OPTIONS

- **--channels (-c) \[*int*\]**

  Number of channels in the image. Default value 0.  **--dataset\_file** (**-I**) \[*string*\] Input matrix to save as images.

- **--height (-H) \[*int*\]**

  Height of the images. Default value 0.

- **--help (-h) \[*bool*\]**

  Default help info.

- **--info \[*string*\]**

  Print help on a specific option. Default value ''.

- **--quality (-q) \[*int*\]**

  Compression of the image if saved as jpg (0-100). Default value 90.

- **--save (-s) \[*bool*\]**

  Save a dataset as images.

- **--verbose (-v) \[*bool*\]**

  Display informational messages and the full list of parameters and timers at the end of execution.

- **--version (-V) \[*bool*\]**

  Display the version of mlpack.

- **--width (-w) \[*int*\]**

  Width of the image. Default value 0.

## OPTIONAL OUTPUT OPTIONS

- **--output\_file (-o) \[*string*\]**

  Matrix to save images data to, Onlyneeded if you are specifying 'save' option.

## ADDITIONAL INFORMATION

For further information, including relevant papers, citations, and theory, consult the documentation found at http://www.mlpack.org or included with your distribution of mlpack.
