| 3 | import java.io.Serializable; |
| 4 | |
| 5 | public interface DModel<T extends ExampleRow> extends Serializable { |
| 6 | int dim(); |
| 7 | int noutcomes(); |
| 8 | |
| 9 | /** |
| 10 | * |
| 11 | * @param x model coefficients (must have length dim()) |
| 12 | * @param ei data row |
| 13 | * @param r where to write prediction results (must have length noutcomes()) |
| 14 | */ |
| 15 | void predict(final double[] x, final Datum ei, final double[] r); |
| 16 | |
| 17 | /** |
| 18 | * |
| 19 | * @param x model coefficients (must have length dim()) |
| 20 | * @param ei data row |
| 21 | * @return predictions per category |
| 22 | */ |
| 23 | double[] predict(final double[] x, final Datum ei); |
| 24 | } |
no outgoing calls
no test coverage detected