Meta Fan
Meta Fan

Reputation: 1585

What is the difference between `tensorflow.nn.np` and `numpy`?

Does tensorflow.nn.np simply call numpy or it is implemented in tensorflow's c++ back-end?

Upvotes: 3

Views: 196

Answers (1)

cel
cel

Reputation: 31349

When in doubt, print out the module.

import tensorflow
print(tensorflow.nn.np)

For me it prints:

<module 'numpy' from '/Users/ch/miniconda/envs/sb35/lib/python3.5/site-packages/numpy/__init__.py'>

So tensorflow.nn.np is just an alias for numpy.

Upvotes: 2

Related Questions