MCPcopy Index your code
hub / github.com/algorithmiaio/algorithmia-python / putFile

Method putFile

Algorithmia/datafile.py:146–153  ·  view source on GitHub ↗
(self, path)

Source from the content-addressed store, hash-verified

144 return self
145
146 def putFile(self, path):
147 # Post file to data api
148 with open(path, 'rb') as f:
149 result = self.client.putHelper(self.url, f)
150 if 'error' in result:
151 raise raiseDataApiError(result)
152 else:
153 return self
154
155 def putNumpy(self, array):
156 # Post numpy array as json payload

Callers 2

putAsZipMethod · 0.95
cpMethod · 0.45

Calls 2

raiseDataApiErrorFunction · 0.90
putHelperMethod · 0.80

Tested by

no test coverage detected