반응형

파이참(Pycharm)에서 텐서플로우 예제 실행해보기



File > Settings .. 



Project 선택 > Project Intepreter > TensorFlow가 있는지 확인!

없으면, + Install > 



TensorFlow 검색 > Install Package


간단한 예제와 결과

import tensorflow as tf

# https://www.tensorflow.org/get_started/get_started
node1 = tf.constant(3.0, tf.float32)
node2 = tf.constant(4.0) # also tf.float32 implicitly print('result:', node1, node2)

/Library/Frameworks/Python.framework/Versions/3.6/bin/python3.6 /Users/aileen/PycharmProjects/test_project/TensorFlow/__init__.py result: Tensor("Const:0", shape=(), dtype=float32) Tensor("Const_1:0", shape=(), dtype=float32) Process finished with exit code 0


관련문서


반응형

+ Recent posts