---
title: "saveImage"
sidebar_label: "saveImage"
description: "Kotlin binding reference: saveImage."
---

<!-- Generated by tools/api_reference/generate_api_docs.py. Do not edit. -->

//[clika-runtime](../../../index.md)/[io.clika.runtime](../index.md)/[Io](index.md)/[saveImage](saveImage.md)

# saveImage

[common]\
fun [saveImage](saveImage.md)(image: [Tensor](../Tensor/index.md), path: [String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html))

Write an image tensor to [path](saveImage.md) in the format its extension asks for: `.png` (or none), `.jpg` / `.jpeg`, `.bmp` or `.tga`; a 16-bit image writes as PNG only. Another extension is refused (`UNSUPPORTED`) with nothing written.