Class Computer

java.lang.Object
io.deephaven.integrations.learn.Computer

public class Computer extends Object
Computer creates a new deferred calculation plus an offset (FutureOffset) every time computer is called.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Computer(io.deephaven.engine.table.Table table, Function<Object[],Object> modelFunc, Input[] inputs, int batchSize)
    Creates a new Computer.
    Computer(io.deephaven.engine.table.Table table, org.jpy.PyObject modelFunc, Input[] inputs, int batchSize)
    Creates a new Computer.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Resets the current future after each set of calculations.
    compute(long k)
    Adds new row indices to be used in the deferred calculation.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • Computer

      public Computer(io.deephaven.engine.table.Table table, org.jpy.PyObject modelFunc, Input[] inputs, int batchSize)
      Creates a new Computer.
      Parameters:
      modelFunc - python function to call on the given inputs from a table.
      inputs - inputs to the model function.
      batchSize - maximum number of rows for each deferred computation.
    • Computer

      public Computer(io.deephaven.engine.table.Table table, Function<Object[],Object> modelFunc, Input[] inputs, int batchSize)
      Creates a new Computer.
      Parameters:
      modelFunc - python function to call on the given inputs from a table.
      inputs - inputs to the model function.
      batchSize - maximum number of rows for each deferred computation.
  • Method Details

    • clear

      public boolean clear()
      Resets the current future after each set of calculations.
      Returns:
      always false, because functions used in query strings cannot return nothing.
    • compute

      public FutureOffset compute(long k)
      Adds new row indices to be used in the deferred calculation.
      Parameters:
      k - index to be added to the current index set.
      Returns:
      future offset that combines a future with the relevant row index to access result.