Working with Tensorflow from the JVM #bbuzz
summary
Shows how Java jobs start TensorFlow per partition using TF on Spark and pandas UDF wrappers, forcing a Java→pickle→socket→Python→C++ chase that doubles serialization and breaks scheduler restarts. Replacing pickles with Apache Arrow trades cross-language copies for fast in-memory interchange; someone claims "242×" speedups but realistic gains look closer to ~3× today. Uses Sparkling ML glue or DL4J as alternatives, and recommends TF Transform on Beam for feature‑prep that compiles the analysis into the serving graph, though TF Transform currently runs best on Google Cloud.
AI-written summary · about
chapters (15)
- 0:00Start
- 10:14Rewriting your code because why not
- 11:01Which becomes
- 13:15Arrow (a poorly drawn big data view)
- 13:39Multi-language pipelines?!?
- 15:48What's the boilerplate in Java?
- 17:40And from the JVM
- 18:04Sparkling ML Mixed Language Pipeline
- 19:16Scala side
- 20:13A possible future
- 22:25Another possible future
- 23:14Defining a Transform processing function
- 24:50BEAM Beyond the JVM: Master branch
- 25:44So how TF does this relate to TF?
- 26:56High Performance Spark!
related talks
01h 56mA Quick Primer on TensorFrames: Apache Spark and TensorFlow Together
30mImproving PySpark Performance: Spark performance beyond the JVM
34mLeveraging Apache Arrow for ML Workflows
36mNo more struggles with Apache Spark (PySpark) workloads in production
35mBuilding Cross-Cloud ML Pipelines with Kubeflow with Spark & Tensorflow
42mScalable Data Science in Python and R on Apache Spark
36mIn-memory data pipeline and warehouse at scale
01h 00mTensorFlow training on the JVM
