MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / Put

Method Put

tensorflow/go/genop/internal/api_def_map.go:86–96  ·  view source on GitHub ↗

Updates apiDefMap with the overrides specified in `data`. data - ApiDef text proto.

(data string)

Source from the content-addressed store, hash-verified

84//
85// data - ApiDef text proto.
86func (m *apiDefMap) Put(data string) error {
87 cdata := C.CString(data)
88 defer C.free(unsafe.Pointer(cdata))
89 status := C.TF_NewStatus()
90 defer C.TF_DeleteStatus(status)
91 C.TF_ApiDefMapPut(m.c, cdata, C.size_t(len(data)), status)
92 if C.TF_GetCode(status) != C.TF_OK {
93 return errors.New(C.GoString(C.TF_Message(status)))
94 }
95 return nil
96}
97
98// Returns ApiDef proto instance for the TensorFlow operation
99// named `opname`.

Callers 2

updateAPIDefsFunction · 0.45
GetAPIDefFunction · 0.45

Calls 2

freeMethod · 0.80
NewMethod · 0.45

Tested by 1

GetAPIDefFunction · 0.36