https://kotlinlang.org logo
Docs
Join the conversationJoin Slack
Channels
100daysofcode
100daysofkotlin
100daysofkotlin-2021
advent-of-code
aem
ai
alexa
algeria
algolialibraries
amsterdam
android
android-architecture
android-databinding
android-studio
androidgithubprojects
androidthings
androidx
androidx-xprocessing
anime
anko
announcements
apollo-kotlin
appintro
arabic
argentina
arkenv
arksemdevteam
armenia
arrow
arrow-contributors
arrow-meta
ass
atlanta
atm17
atrium
austin
australia
austria
awesome-kotlin
ballast
bangladesh
barcelona
bayarea
bazel
beepiz-libraries
belgium
berlin
big-data
books
boston
brazil
brikk
budapest
build
build-tools
bulgaria
bydgoszcz
cambodia
canada
carrat
carrat-dev
carrat-feed
chicago
chile
china
chucker
cincinnati-user-group
cli
clikt
cloudfoundry
cn
cobalt
code-coverage
codeforces
codemash-precompiler
codereview
codingame
codingconventions
coimbatore
collaborations
colombia
colorado
communities
competitive-programming
competitivecoding
compiler
compose
compose-android
compose-desktop
compose-hiring
compose-ios
compose-mp
compose-ui-showcase
compose-wear
compose-web
connect-audit-events
corda
cork
coroutines
couchbase
coursera
croatia
cryptography
cscenter-course-2016
cucumber-bdd
cyprus
czech
dagger
data2viz
databinding
datascience
dckotlin
debugging
decompose
decouple
denmark
deprecated
detekt
detekt-hint
dev-core
dfw
docs-revamped
dokka
domain-driven-design
doodle
dsl
dublin
dutch
eap
eclipse
ecuador
edinburgh
education
effective-kotlin
effectivekotlin
emacs
embedded-kotlin
estatik
event21-community-content
events
exposed
failgood
fb-internal-demo
feed
firebase
flow
fluid-libraries
forkhandles
forum
fosdem
fp-in-kotlin
framework-elide
freenode
french
fritz2
fuchsia
functional
funktionale
gamedev
ge-kotlin
general-advice
georgia
geospatial
german-lang
getting-started
github-workflows-kt
glance
godot-kotlin
google-io
gradle
graphic
graphkool
graphql
graphql-kotlin
graviton-browser
greece
grpc
gsoc
gui
hackathons
hacktoberfest
hamburg
hamkrest
helios
helsinki
hexagon
hibernate
hikari-cp
hire-me
hiring
hongkong
hoplite
http4k
hungary
hyderabad
image-processing
india
indonesia
inkremental
intellij
intellij-plugins
intellij-tricks
internships
introduce-yourself
io
ios
iran
israel
istanbulcoders
italian
jackson-kotlin
jadx
japanese
jasync-sql
java-to-kotlin-refactoring
javadevelopers
javafx
javalin
javascript
jdbi
jhipster-kotlin
jobsworldwide
jpa
jshdq
juul-libraries
jvm-ir-backend-feedback
jxadapter
k2-early-adopters
kaal
kafka
kakao
kalasim
kapt
karachi
karg
karlsruhe
kash_shell
kaskade
kbuild
kdbc
kgen-doc-tools
kgraphql
kinta
klaxon
klock
kloudformation
kmdc
kmm-español
kmongo
knbt
knote
koalaql
koans
kobalt
kobweb
kodein
kodex
kohesive
koin
koin-dev
komapper
kondor-json
kong
kontent
kontributors
korau
korean
korge
korim
korio
korlibs
korte
kotest
kotest-contributors
kotless
kotlick
kotlin-asia
kotlin-beam
kotlin-by-example
kotlin-csv
kotlin-data-storage
kotlin-foundation
kotlin-fuel
kotlin-in-action
kotlin-inject
kotlin-latam
kotlin-logging
kotlin-multiplatform-contest
kotlin-mumbai
kotlin-native
kotlin-pakistan
kotlin-plugin
kotlin-pune
kotlin-roadmap
kotlin-samples
kotlin-sap
kotlin-serbia
kotlin-spark
kotlin-szeged
kotlin-website
kotlinacademy
kotlinbot
kotlinconf
kotlindl
kotlinforbeginners
kotlingforbeginners
kotlinlondon
kotlinmad
kotlinprogrammers
kotlinsu
kotlintest
kotlintest-devs
kotlintlv
kotlinultimatechallenge
kotlinx-datetime
kotlinx-files
kotlinx-html
kotrix
kotson
kovenant
kprompt
kraph
krawler
kroto-plus
ksp
ktcc
ktfmt
ktlint
ktor
ktp
kubed
kug-leads
kug-torino
kvision
kweb
lambdaworld_cadiz
lanark
language-evolution
language-proposals
latvia
leakcanary
leedskotlinusergroup
lets-have-fun
libgdx
libkgd
library-development
linkeddata
lithuania
london
losangeles
lottie
love
lychee
macedonia
machinelearningbawas
madrid
malaysia
mathematics
meetkotlin
memes
meta
metro-detroit
mexico
miami
micronaut
minnesota
minutest
mirror
mockk
moko
moldova
monsterpuzzle
montreal
moonbean
morocco
motionlayout
mpapt
mu
multiplatform
mumbai
munich
mvikotlin
mvrx
myndocs-oauth2-server
naming
navigation-architecture-component
nepal
new-mexico
new-zealand
newname
nigeria
nodejs
norway
npm-publish
nyc
oceania
ohio-kotlin-users
oldenburg
oolong
opensource
orbit-mvi
osgi
otpisani
package-search
pakistan
panamá
pattern-matching
pbandk
pdx
peru
philippines
phoenix
pinoy
pocketgitclient
polish
popkorn
portugal
practical-functional-programming
proguard
prozis-android-backup
pyhsikal
python
python-contributors
quasar
random
re
react
reaktive
realm
realworldkotlin
reductor
reduks
redux
redux-kotlin
refactoring-to-kotlin
reflect
refreshversions
reports
result
rethink
revolver
rhein-main
rocksdb
romania
room
rpi-pico
rsocket
russian
russian_feed
russian-kotlinasfirst
rx
rxjava
san-diego
science
scotland
scrcast
scrimage
script
scripting
seattle
serialization
server
sg-user-group
singapore
skia-wasm-interop-temp
skrape-it
slovak
snake
sofl-user-group
southafrica
spacemacs
spain
spanish
speaking
spek
spin
splitties
spotify-mobius
spring
spring-security
squarelibraries
stackoverflow
stacks
stayhungrystayfoolish
stdlib
stlouis
strife-discord-lib
strikt
students
stuttgart
sudan
swagger-gradle-codegen
swarm
sweden
swing
swiss-user-group
switzerland
talking-kotlin
tallinn
tampa
teamcity
tegal
tempe
tensorflow
terminal
test
testing
testtestest
texas
tgbotapi
thailand
tornadofx
touchlab-tools
training
tricity-kotlin-user-group
trójmiasto
truth
tunisia
turkey
turkiye
twitter-feed
uae
udacityindia
uk
ukrainian
uniflow
unkonf
uruguay
utah
uuid
vancouver
vankotlin
vertx
videos
vienna
vietnam
vim
vkug
vuejs
web-mpp
webassembly
webrtc
wimix_sentry
wwdc
zircon
Powered by Linen
kotlindl
  • z

    zaleslaw

    12/14/2021, 8:42 AM
    Join today's Live Webinar "*Object Detection and Image Recognition with Kotlin*". Register here. Agenda: In this webinar, we will explore a deep learning library written in Kotlin, learn how to detect objects of different types in images, and create a Kotlin Web Application using Ktor and KotlinDL that will detect objects in the images.
    j
    3 replies · 2 participants
  • a

    altavir

    12/14/2021, 4:14 PM
    modelhub[...]
    Is it a good idea to use get operation for something that could be slow or accesses the disk? Or the cache is loaded in the constructor?
    z
    a
    8 replies · 3 participants
  • a

    Alexandre Brown

    12/28/2021, 10:08 PM
    Hello, is it possible to pass in an in-memory collection of byte arrays representing a batch of images inside preprocessing
    Loading
    instead of a File on disk? Or since
    preprocessing()
    can only be applied to 1 file usually then I guess we could say a ByeArray.
    z
    2 replies · 2 participants
  • a

    asavio

    02/18/2022, 7:18 AM
    Hello! I was excited to try out KotlinDL on my M1 MacBook yesterday and I couldn't. I found out that it is not supported on the ARM architecture yet. Personally, I believe support for ARM is crucial as people that need small scale models run them on devices like the Raspberry PIs and build them on devices like the M1 Macs. I would love to know if there's a plan for ARM support and how it is coming up. Thanks in advance!
    m
    1 reply · 2 participants
  • в

    Виталий Перятин

    02/26/2022, 4:27 PM
    Hello! I can't run KotlinDL on M1 (tried versions 0.4.0-alpha-2 and 0.3.0). I faced with this error: https://github.com/JetBrains/KotlinDL/issues/164
    t
    z
    4 replies · 3 participants
  • l

    Ludwig Dickmanns

    04/18/2022, 12:16 PM
    Hello! :kotlin-intensifies: I’m trying to do some deep learning with KotlinDL and the Jupyter Kotlin Kernel. Sadly, I can’t get logging to work. Did anyone have a similar issue? Or do you know how to get logs during training in a (Kotlin) Jupyter Notebook? Thanks in advance!!
    s
    z
    2 replies · 3 participants
  • f

    Francis Mariano

    04/27/2022, 7:14 PM
    Hello everyone. Is it possible to do facial recognition with kotlindl???
    z
    a
    4 replies · 3 participants
  • a

    Alexandre Brown

    05/03/2022, 7:00 PM
    Is KotlinDL planning to add a normalize
    transformTensor
    op that could be done after the rescale for instance ? I can contribute but want to know if you already did it for 0.4 first.
    j
    9 replies · 2 participants
  • r

    Rishit Dagli

    05/11/2022, 4:58 AM
    Does KotlinDL have any plans to add GLU and GLU variants. Since I used these activations quite a few times, I recently ended up creating a library for myself (https://github.com/Rishit-dagli/GLU) and would love to contribute this to KotlinDL. This was meant to be an issue but I wanted to know if this is already in the pipeline?
    z
    2 replies · 2 participants
  • a

    Alexandre Brown

    05/12/2022, 2:18 AM
    Hello, does KotlinDL have an NMS (Non-Max Supression) method or do we have to impl it ourselves?
    z
    3 replies · 2 participants
  • r

    roman.belov

    06/06/2022, 6:18 PM
    KotlinDL 0.4 Is Here! NoTop models in the ModelHub, new layers and activation functions, better Image Preprocessing DSL and just see the GIF below! Read all in the blogpost: https://blog.jetbrains.com/kotlin/2022/06/kotlindl-0-4-is-out-with-pose-detection-api-[…]or-object-detection-and-efficientnet-for-image-recognition/
    🎉 8
    :tnx: 5
    🤘 6
    👏 5
    🙂 1
    z
    h
    8 replies · 3 participants
  • s

    smallshen

    06/25/2022, 10:38 PM
    does KotlinDL have an LSTM layer?
    z
    1 reply · 2 participants
  • a

    Ananiya

    07/19/2022, 8:48 PM
    Embedding layer ? I am currently working on sentiment classification and I was wondering if there is any layer that could be used instead of layers.Embedding() b/c it doesn't seems to be included on kotlind dl
    z
    2 replies · 2 participants
  • a

    Ananiya

    07/30/2022, 5:48 AM
    I was doing some demonstration and found out the simultaneous prediction time of object detection model is slower(relatively speaking) so my first attempt was to capture image , saved to the storage, load it and make prediction using
    detectObjects(file: File)
    function it was slow as you would normally expect but what got me thinking is instead of loading saving and reloading the image I directly fed the
    predictRaw(f: FloatArray)
    with
    FloatArray
    that came from rescaled and recolored
    BufferedImage
    at this moment the rate of data fed was about 23
    BufferedImage
    per sec (from my web cam) followed by the predicator which was 111x slower and took 6.02 - 4.4 sec to load single data(
    FloatArray
    ) I wasn't also sure about the Rescaler and color swaper I made but when I did the bench it barely have made any changes even the whole process of converting
    BufferedImage
    to
    FloatArray
    was only having a loss of 1 frames After all the only thing I could think of is that the predictor instead of getting called from the the mem it's simultaneously being fetched from the storage If that was the case is there anything that I could do to prevent that Here's the code in case you are wondering
    while(cam.isOpen){
         model.predictRaw(cam.image.toFloatArray())
    ...
    n
    4 replies · 2 participants
  • r

    Rescribet

    08/03/2022, 6:21 AM
    Was walking through the tutorials in the docs, but quickly hit the wall due to working on an Apple M1 notebook. FWICT aarch64 is supported in tensorflow since 2.3+. The Java API has seen a number of releases since the readme entry was written, are there still plans to upgrade?
    h
    j
    +1
    4 replies · 4 participants
  • a

    ayodele

    08/22/2022, 9:31 PM
    Noob question. Can I use KotlinDL for text classification?? If yes, any example or doc
    j
    a
    7 replies · 3 participants
  • s

    Stefan Oltmann

    10/10/2022, 8:02 AM
    I would like to do face detection & recognition using KotlinDL. As far as I understand I will need ArcFace for Face Recognition and as a preprocessing detect the faces first. Therefore I'm looking for a MTCNN face detector for Kotlin. At best it's an implementation that does not require a Bitmap or other like Android-specific classes and just takes a JPG stream to detect the coordinates. I want to use it on the JVM within a compose-jb app. Does someone know something like that? https://github.com/tzolov/mtcnn-java is the closest thing I found so far, but it's abandoned and seems to have a lot of depenencies. Is there something easier to use for that?
    n
    1 reply · 2 participants
  • a

    Alexandre Brown

    11/08/2022, 3:52 PM
    Hello, where can we see the changes for the 0.5.0 alpha1 ? W'ere upgrading from KotlinDL 0.4.0. https://search.maven.org/artifact/org.jetbrains.kotlinx/kotlin-deeplearning-dataset/0.5.0-alpha-1/jar Cheers!
    j
    14 replies · 2 participants
  • a

    Alexandre Brown

    11/14/2022, 6:36 PM
    Hello, how can we include the
    org.jetbrains.kotlinx:kotlin-deeplearning-dataset
    dependency for
    commonMain
    (multiplatform library) ? Thanks
    j
    9 replies · 2 participants
  • n

    Nikita Ermolenko

    11/22/2022, 12:46 PM
    A KotlinDL 0.5-alpha-2 is published. The 0.5 release focuses on creating the API for the flexible and easy-to-use deployment of ONNX models on Android. Now you can create apps that use state-of-the-art neural networks just in a few lines of simple and elegant DSL. We have reworked Preprocessing DSL, introduced support for ONNX runtime execution providers, and more. A more detailed changelog is here. There is also an Android Demo Application that shows how to use KotlinDL ONNX for Android. We would appreciate you tried it and let us know if you encounter any problems or have feedback.
    VN20221118_165306.mp4
    i
    1 reply · 2 participants
  • i

    iamsteveholmes

    11/23/2022, 2:36 AM
    Any new thoughts on Reinforcement Learning? I’m curious for trying it out for investment strategy
    h
    1 reply · 2 participants
  • s

    Stefan Oltmann

    12/06/2022, 11:07 AM
    Do you plan to implemented an ONNXInterferenceModel for https://github.com/onnx/models/tree/main/vision/body_analysis/arcface ? Should I create an issue for that?
    n
    2 replies · 2 participants
  • s

    Stefan Oltmann

    12/06/2022, 11:16 AM
    Is there a way to load my ONNX model from local resources instead of the model hub? UltraFace320 ist just 1 MB and I don't want to rely on the hub if I can just bundle it with my app.
    n
    j
    5 replies · 3 participants
  • r

    roman.belov

    12/14/2022, 12:44 PM
    Huge and exciting news! KotlinDL is now available on Android and using this release you can run practically any ONNX neural network on your device. Moreover, the data preprocessing step has also been significantly reworked and feeding data to the network is much easier, more elegant, more versatile. Also with KotlinDL 0.5, it is possible to run models on optimized hardware which is crucial to get proper performance. There is also an Android Demo Application that shows how to use KotlinDL ONNX for Android. Learn more: https://blog.jetbrains.com/kotlin/2022/12/kotlindl-0-5-has-come-to-android/
    KotlinDL05.mp4
  • h

    holgerbrandl

    12/22/2022, 6:19 PM
    Hi there, is there a an OCR (image to text) model (similar to tesseract) which I could use with kotlindl?
    j
    1 reply · 2 participants
  • d

    Dawid Dębowski

    01/06/2023, 2:59 PM
    Hi, I have a few questions and I can't seem to find an answer on the Internet: Some information for the beginning - we're creating a model that should predict whether OCR should be made using a cloud service or inside the application. Here are the questions: 1. Is it possible to create a dataset with multidimensional output? We hope the model will be able to both tell where the image should be processed, as well as it should tell how much time it will spend on processing image. I tried to use OnHeapDataset but labels have to be one-dimensional Float Array, so there's no way of doing even a data class. 2. Is it possible to do more training once the model was taught? What I mean is that we're going to train the model on the side with some data and we're wondering if it will be possible to do some additional training during the lifecycle of the application (it's an university project, so we don't care about performance of the solution as much). Will another call of
    fit
    function suffice? Thank you for the answers!
    j
    5 replies · 2 participants
  • m

    Moritz Lindner

    01/18/2023, 8:20 PM
    Hi, I am relatively new to KotlinDL and have a question regarding the usage of a custom dataset. I want to do some Object-Recognition and have a labeled dataset in the YOLO format. Meaning: dataset/images/train/*.png dataset/images/test/*.png dataset/labels/train/*.txt dataset/labels/test/*.txt A given image always corresponds to a given txt file by the name. For instance
    1.png
    in the
    /images/train/
    directory corresponds to
    1.txt
    in the
    labels/train
    directory. A txt file is either empty (if no object is in the corresponding image) or contains rows like
    0 0.403260 0.570903 0.090604 0.160194
    . Each row represents an object labeled in the corresponding image where the first element is the class and the other 4 elements describe the bounding boxes top left and bottom right coordinates. I want to use the
    OnHeapDataset
    . I was a bit confused regarding the usage of FloatArray everywhere but I think I got the
    featuresExtractor
    working:
    featuresExtractor = { basePath ->
                println("extracting features in $basePath")
                val folder = File(basePath)
    
                val res = folder.listFiles().map { image ->
                    println("converting ${image.absolutePath}")
                    val imageWithAlphaChannel = ImageIO.read(image)
    
                    val imageWithoutAlphaChannel = BufferedImage(
                        imageWithAlphaChannel.width,
                        imageWithAlphaChannel.height,
                        TYPE_INT_RGB
                    ).apply {
                        for (x in 0 until imageWithAlphaChannel.width) {
                            for (y in 0 until imageWithAlphaChannel.height) {
                                val rgb = imageWithAlphaChannel.getRGB(x, y)
                                setRGB(x, y, rgb)
                            }
                        }
                    }
    
    
                    pipline.apply(imageWithoutAlphaChannel).first
                }.toTypedArray()
                println("finished extracting features in $basePath")
                res
            }
    However, I am unsure how to build the
    labelExtractor
    since it awaits
    (String, Int) -> FloatArray
    . So I am am unable to encode the described row structure (containing class, x1, y1, x2, y2) into an
    FloatArray
    as I would need a
    Array<FloatArray>
    to encode the information for the bounding box. I hope my questions make sens and that I am not completely on the wrong track 😄
    j
    3 replies · 2 participants
  • p

    Paul Woitaschek

    01/22/2023, 11:33 AM
    Do I understand correctly that kotlinDl doesn't support m1s? https://github.com/Kotlin/kotlindl/issues/164
    j
    d
    2 replies · 3 participants
  • b

    Bastien Leveque

    01/22/2023, 5:52 PM
    Hello, Can KotlinDL allow to analyze texts rather than images? In case this is not possible, do you have a library allowing to create a neural network in order to analyze texts entered by users?
    a
    z
    2 replies · 3 participants
  • o

    oday

    02/10/2023, 9:58 AM
    I didn’t know this channel existed otherwise I would’ve asked here, so I posted an Issue instead: https://github.com/Kotlin/kotlindl/issues/519
    z
    2 replies · 2 participants
Powered by Linen
Title
o

oday

02/10/2023, 9:58 AM
I didn’t know this channel existed otherwise I would’ve asked here, so I posted an Issue instead: https://github.com/Kotlin/kotlindl/issues/519
couldn’t find anything related before posting it
z

zaleslaw

02/13/2023, 6:03 PM
We will update the guide in a few days https://github.com/Kotlin/kotlindl/issues/519
View count: 3