aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/python/framework/errors.py
Commit message (Collapse)AuthorAge
* Seal errors interface.Gravatar Patrick Nguyen2016-11-06
| | | | Change: 138332031
* Python error reporting: Copy primary error to bottom of error output.Gravatar Vijay Vasudevan2016-09-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes https://twitter.com/karpathy/status/765681445637533696 Example new output for a CPU-only binary that executes: ``` import tensorflow as tf s = tf.Session() with tf.device("/gpu:0"): s.run(tf.constant(1.0) + tf.constant(2.0)) ``` is: Traceback (most recent call last): File "baz.py", line 5, in <module> s.run([c]) File "REDACTED/local/lib/python2.7/site-packages/tensorflow/python/client/session.py", line 717, in run run_metadata_ptr) File "REDACTED/local/lib/python2.7/site-packages/tensorflow/python/client/session.py", line 855, in _run raise RuntimeError('The Session graph is empty. Add operations to the ' RuntimeError: The Session graph is empty. Add operations to the graph before calling run(). (tf)vrv@vijay-linux:~/vrv.tensorflow/tf$ python baz.py Traceback (most recent call last): File "baz.py", line 4, in <module> s.run(tf.constant(1.0) + tf.constant(2.0)) File "REDACTED/local/lib/python2.7/site-packages/tensorflow/python/client/session.py", line 717, in run run_metadata_ptr) File "REDACTED/local/lib/python2.7/site-packages/tensorflow/python/client/session.py", line 915, in _run feed_dict_string, options, run_metadata) File "REDACTED/local/lib/python2.7/site-packages/tensorflow/python/client/session.py", line 965, in _do_run target_list, options, run_metadata) File "REDACTED/local/lib/python2.7/site-packages/tensorflow/python/client/session.py", line 985, in _do_call raise type(e)(node_def, op, message) tensorflow.python.framework.errors.InvalidArgumentError: Cannot assign a device to node 'add': Could not satisfy explicit device specification '/device:GPU:0' because no devices matching that specification are registered in this process; available devices: /job:localhost/replica:0/task:0/cpu:0 [[Node: add = Add[T=DT_FLOAT, _device="/device:GPU:0"](Const, Const_1)]] Caused by op u'add', defined at: File "baz.py", line 4, in <module> s.run(tf.constant(1.0) + tf.constant(2.0)) File "REDACTED/local/lib/python2.7/site-packages/tensorflow/python/ops/math_ops.py", line 748, in binary_op_wrapper return func(x, y, name=name) File "REDACTED/local/lib/python2.7/site-packages/tensorflow/python/ops/gen_math_ops.py", line 71, in add result = _op_def_lib.apply_op("Add", x=x, y=y, name=name) File "REDACTED/local/lib/python2.7/site-packages/tensorflow/python/framework/op_def_library.py", line 749, in apply_op op_def=op_def) File "REDACTED/local/lib/python2.7/site-packages/tensorflow/python/framework/ops.py", line 2372, in create_op original_op=self._default_original_op, op_def=op_def) File "REDACTED/local/lib/python2.7/site-packages/tensorflow/python/framework/ops.py", line 1298, in __init__ self._traceback = _extract_stack() InvalidArgumentError (see above for traceback): Cannot assign a device to node 'add': Could not satisfy explicit device specification '/device:GPU:0' because no devices matching that specification are registered in this process; available devices: /job:localhost/replica:0/task:0/cpu:0 [[Node: add = Add[T=DT_FLOAT, _device="/device:GPU:0"](Const, Const_1)]] The main error now shows up at the end, which is where people are likely to find it more easily. Change: 133429936
* Add new QueueRunner optional argument: queue_closed_exception_types.Gravatar Eugene Brevdo2016-08-30
| | | | | | | | * This is a backwards compatible change. * Includes some extra helper functions in the tf.errors module. * Includes extension to the QueueRunner proto * Includes tests that QueueRunner.{from,to}_proto are backwards compatible. Change: 131791267
* Split NodeDef out of graph.proto into node_def.proto. Needed so weGravatar A. Unique TensorFlower2016-08-22
| | | | | can use NodeDef in FunctionDef. Change: 130982373
* Update copyright for 3p/tf/python.Gravatar A. Unique TensorFlower2016-06-02
| | | | Change: 123900456
* Raise proper tensorflow exceptions in a few more places:Gravatar A. Unique TensorFlower2016-05-03
| | | | | | | | - Add a context manager to deal with C apis that want a status object passed as an extra argument. - Use the context manager in session.py and session.i - Update tests. Change: 121430994
* Restrict the use of OUT_OF_RANGE to what it was intended to.Gravatar A. Unique TensorFlower2016-04-11
| | | | | | | | | | | | Clarify that OUT_OF_RANGE is raised only when reaching the end of input for interable contents. Change the few places where we incorrectly raised OUT_OF_RANGE to raise ILLEGAL_ARGUMENT instead. This will make code that catches the OUT_OF_RANGE exception more robust as it won't get confused by spurious uses of the exception class. Change: 119560848
* TensorFlow: For errors that are returned without NodeDefs or OpsGravatar Vijay Vasudevan2016-03-09
| | | | | | associated with them, make sure we return the correct underlying error code when available. Change: 116719327
* Make the contrib.layers, contrib.util, and python_io packages only exposeGravatar A. Unique TensorFlower2016-03-03
| | | | | | | | | | | | | | | | | | | documented symbols. These names are removed: tf.contrib.layers.initializers tf.contrib.layers.layers tf.contrib.layers.loss_ops tf.contrib.layers.python tf.contrib.layers.regularizers tf.contrib.layers.summaries tf.errors.OpError tf.errors.error_codes_pb2 tf.errors.traceback tf.errors.warnings tf.python_io.compat tf.python_io.pywrap_tensorflow Change: 116190055
* TensorFlow: Improve performance of AlexnetGravatar Manjunath Kudlur2015-11-20
| | | | | | | | | | | | | | | | | | | | | | Changes: * error message that refers to removed `DefaultSession` method. * -Wnull-conversion warnings * the "_start_time" attr for recvs when the flag "--brain_enable_scheduling_for_recvs" is set. * typo in tutorial data download progress message. * a typo ("however their installing"=>"however installing"). * typo, rename "TensorFlow Mechanics" to "How To" to be consistent with the website. * a typo ("subtact"=>"subtract"). * protobuf examples in comments in tensorflow::Example.proto. * formula formatting in MNIST beginner tutorial * negative fraction-of-queue-full stats * protobuf inclusion path so that Android demo will build under Blaze. * small typo (moderatly > moderately) * Session.run() to check that tensor arguments come from the session's graph. * another six import * seq2seq typo in bazel command Base CL: 108349164
* TensorFlow: upstream changes from the afternoon.Gravatar Vijay Vasudevan2015-11-11
| | | | | | | | | | | | | | | | | | | | | | | | | | Changes: - futurize --stage2 changes for Python 3 compatibility by @girving. - Small updates to documentation by @vrv, schuster and others - Account for failure of std::thread::hardware_concurrency by @ebrevdo. - More changes for backwards-compatibility tests by Josh - Updates to python op doc generation by Josh - Added support for using the best-fit allocator via ConfigProto by @vrv. - Rename LocalSession to DirectSession, since local was a bad name for it. - Enable tf.nn.moments() to work with tensors of unknown shape by @mrry. GITHUB_ISSUE: 139 - Changes for Android build by Andrew. Base CL: 107645181
* TensorFlow: Upstream changes to git.Gravatar Manjunath Kudlur2015-11-08
| | | | | | | | Changes: - Documentation updates. - Relax numpy requirement to 1.9.2 Base CL: 107349632
* TensorFlow: Upstream latest changes to Git.Gravatar Manjunath Kudlur2015-11-06
| | | | | | | | | Changes: - Updates to installation instructions. - Updates to documentation. - Minor modifications and tests for word2vec. Base CL: 107284192
* TensorFlow: Initial commit of TensorFlow library.Gravatar Manjunath Kudlur2015-11-06
TensorFlow is an open source software library for numerical computation using data flow graphs. Base CL: 107276108