Package org.jetbrains.kotlinx.dl.api.core.util

Types

TF
Link copied to clipboard
class TF

Helper class that emulates Keras functions from tensorflow.keras.

Functions

mapOfNotNull
Link copied to clipboard
fun <K, V> mapOfNotNull(vararg mapping: Pair<K?, V?>): Map<K, V>

Create a new read-only map from a list of pairs, if both values in the pair are not null.

serializeLabelsToBuffer
Link copied to clipboard
fun serializeLabelsToBuffer(src: FloatArray, amountOfClasses: Long): FloatBuffer

Converts src to FloatBuffer.

serializeToBuffer
Link copied to clipboard
fun serializeToBuffer(src: Array<FloatArray>): FloatBuffer
fun serializeToBuffer(src: FloatArray): FloatBuffer

Converts src to FloatBuffer.

fun serializeToBuffer(src: Array<FloatArray>, start: Int, length: Int): FloatBuffer

Converts src to FloatBuffer from start position for the next length positions.