Returns the default session for the current thread. The returned `Session` will be the innermost session on which a `Session` or `Session.as_default()` context has been entered. NOTE: The default session is a property of the current thread. If you create a new thread, and wish to use the d
()
| 5431 | |
| 5432 | @tf_export(v1=["get_default_session"]) |
| 5433 | def get_default_session(): |
| 5434 | """Returns the default session for the current thread. |
| 5435 | |
| 5436 | The returned `Session` will be the innermost session on which a |
| 5437 | `Session` or `Session.as_default()` context has been entered. |
| 5438 | |
| 5439 | NOTE: The default session is a property of the current thread. If you |
| 5440 | create a new thread, and wish to use the default session in that |
| 5441 | thread, you must explicitly add a `with sess.as_default():` in that |
| 5442 | thread's function. |
| 5443 | |
| 5444 | Returns: |
| 5445 | The default `Session` being used in the current thread. |
| 5446 | """ |
| 5447 | return _default_session_stack.get_default() |
| 5448 | |
| 5449 | |
| 5450 | def _eval_using_default_session(tensors, feed_dict, graph, session=None): |
no test coverage detected