Skip to content

README.md - Library imports #67

@lgleznah

Description

@lgleznah

Good morning.

I write this issue because I've had some trouble getting the library to work. The thing is, in the main README file, there is this piece of code:

// This will be all that you need
import io.radicalbit.flink.pmml.scala._

import org.apache.flink.ml.math.Vector
import org.apache.flink.streaming.api.scala._

object FlinkJpmmlExample {
  def main(args: Array[String]): Unit = {

    // your model can reside in any Flink supported backend
    val pathToPmml = "/even/to/distributed/systems"

    val env = StreamExecutionEnvironment.getExecutionEnvironment
    val events = env.yourInputStream

    //  a lazy reader implementation
    val reader = ModelReader(pathToPmml)

However, I couldn't get this piece of code to work. After searching through the repo, I found that an additional import was required:

import io.radicalbit.flink.pmml.scala.api.reader.ModelReader

Could this import be added to the README example? I know it's already in the examples, but not having it in the main README file could be misleading.

For reference, I tried this on an Ubuntu 18.04 VM, working with Flink 1.9.0 and Scala 2.11.12, compiled with sbt 1.0.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions