(g *Graph, name string, dt DataType)
| 17 | package tensorflow |
| 18 | |
| 19 | func Placeholder(g *Graph, name string, dt DataType) (Output, error) { |
| 20 | op, err := g.AddOperation(OpSpec{ |
| 21 | Type: "Placeholder", |
| 22 | Name: name, |
| 23 | Attrs: map[string]interface{}{ |
| 24 | "dtype": dt, |
| 25 | }, |
| 26 | }) |
| 27 | return op.Output(0), err |
| 28 | } |
| 29 | |
| 30 | func Const(g *Graph, name string, value interface{}) (Output, error) { |
| 31 | t, ok := value.(*Tensor) |
no test coverage detected