Returns a platform-specific implementation of fetch.
fetch
If fetch is defined on the global object (window, process, etc.), tf.util.fetch returns that function.
window
process
tf.util.fetch
If not, tf.util.fetch returns a platform-specific solution.
const resource = await tf.util.fetch('https://cdn.jsdelivr.net/npm/@tensorflow/tfjs');// handle response Copy
const resource = await tf.util.fetch('https://cdn.jsdelivr.net/npm/@tensorflow/tfjs');// handle response
Optional
Generated using TypeDoc
Returns a platform-specific implementation of
fetch.If
fetchis defined on the global object (window,process, etc.),tf.util.fetchreturns that function.If not,
tf.util.fetchreturns a platform-specific solution.