aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/python/training/session_manager_test.py
Commit message (Collapse)AuthorAge
* Updating the V2 variables API.Gravatar Alexandre Passos2018-09-27
| | | | PiperOrigin-RevId: 214824023
* Move from deprecated self.test_session() to self.cached_session().Gravatar A. Unique TensorFlower2018-09-10
| | | | | | | | self.test_session() has been deprecated in 9962eb5e84b15e309410071b06c2ed2d6148ed44 as its name confuses readers of the test. Moving to cached_session() instead which is more explicit about: * the fact that the session may be reused. * the session is not closed even when doing a "with self.test_session()" statement. PiperOrigin-RevId: 212336352
* Split checkpoint management utility functions out of saver.pyGravatar Allen Lavoie2018-08-02
| | | | | | Pure refactor, in preparation for adding a higher level checkpoint management utility. This utility will also need to work with the Checkpoint proto, and globbing it on to saver.py seems dirty. PiperOrigin-RevId: 207179646
* Refactoring and bug-fixes for _build_initializer_expr.Gravatar A. Unique TensorFlower2018-01-04
| | | | | | | | | | | | | | | | | | | | - Rename _build_initializer_expr to _try_guard_against_uninitialized_dependencies so as to clarify what it does. - Avoid invoking the logic in _try_guard_against_uninitialized_dependencies for cyclic graphs. This currently results in infinite recursion which blows the stack. - Use memoization to reduce the number of redundant operations created by _try_guard_against_uninitialized_dependencies when it encounters initial values with diamond-shaped dependencies. - Refactoring: Remove unnecessary logic in _try_guard_against_uninitialized_dependencies for dealing with types other than Tensor or Operation. The dependency graph of a Variable's _initial_value should only ever comprise these two types. - Refactoring: Added some filtering logic to _try_guard_against_uninitialized_dependencies to avoid initial_values with cyclic dependencies - Refactoring: Moved the recursive traversal of initial_value`s dependencies into _safe_initial_value_from_tensor and _safe_initial_value_from_op. - Refactoring: Made it so _find_initialized_value_for_variable will return None when it can't find the initialized_value. Currently it returns a Tensor when it finds the initialized_value and an Operation when it can't. This makes the logic in the caller a bit more consistent and explicit. Future changes will address more of the shortcomings of _build_initializer_expr. PiperOrigin-RevId: 180876754
* Fixed initialization of variables: when a variable w is initialized with theGravatar Benoit Steiner2017-07-07
| | | | | | value of another variable v, make sure that the initializer of v is run first. PiperOrigin-RevId: 161226052
* Making sure an error message will be produced by session_manager when a ↵Gravatar A. Unique TensorFlower2017-05-02
| | | | | | | non-tensor object is passed in. Otherwise the 'name' property is missing. Change: 154868022
* Added specific checkpoint file argument to the session_manager.Gravatar Mustafa Ispir2016-12-20
| | | | Change: 142575145
* Remove hourglass imports from even more testsGravatar Justine Tunney2016-12-16
| | | | Change: 142318245
* Merge changes from github.Gravatar Andrew Harp2016-12-08
| | | | | | | | Additionally: - change single quotes to double quotes to make path rewriting easier - guard windows lib reference with PLATFORM_WINDOWS - fixed failing kmeans test Change: 141515942
* Replace usages initialize_all_variables -> global_variables_initializerGravatar Illia Polosukhin2016-11-03
| | | | Change: 138128703
* Redirecting gfile to file_io.Gravatar Rohan Jain2016-09-08
| | | | | Also, changed the return type of FileIO.readline(), FileIO.readlines(), list_directories() and walk() to be strings rather than bytes. Change: 132634441
* Automated rollback of change 130366039Gravatar A. Unique TensorFlower2016-08-19
| | | | Change: 130801349
* Fixes a conflict where error is raised when:Gravatar A. Unique TensorFlower2016-08-16
| | | | | | | 1. Model is not restored from checkpoint 2. No init_op, init_fn, local_init_op provided 3. ready_op passes regardless Change: 130366039
* Adds a ready_for_local_init_op to SessionManager and Supervisor.Gravatar A. Unique TensorFlower2016-08-13
| | | | | | | | | | | | | | | | | | | The ready_for_local_init_op checks if a model is ready to run local_init_op; ready_for_local_init_op is always checked before local_init_op is run. Failure to pass ready_for_local_init_op results in different behaviors: 1. In prepare_session, a RuntimeError is raised, since the model cannot be made ready. 2. In recover_session, the `initialized` flag is returned as False, to indicate that the checkpoint recovery failed to make the model ready to run local_init_op. (If recover_session was called from prepare_session, the initialization process defaults back to using init_op and init_fn, i.e., it creates a fresh session.) 3. In wait_for_session, only by passing ready_for_local_init_op (and also ready_op) is a session returned. Otherwise, failing ready_for_local_init_op causes wai_for_session to continue to wait for the model to be made into a ready state to run local_init_op. Change: 130189227
* Update copyright for 3p/tf/python.Gravatar A. Unique TensorFlower2016-06-02
| | | | Change: 123900456
* Added a new op report_uninitialized_variables() which returns a 1-D tensorGravatar Sherry Moore2016-05-03
| | | | | | | | | | | | | containing names of the uninitialized variables when run. Supervisor's ready_op is now implemented with report_uninitialized_variables(). If you write custom ready_op, please make sure 1. If the model is ready, it returns an empty tensor. 2. If the model is not ready, it returns a 1-D tensor containing reasons why the model is not ready. assert_variables_initialized() will be kept for 6 months for backward compatibility. Change: 121407132
* Make the init_op optional and add an optional init_fn.Gravatar A. Unique TensorFlower2016-04-18
| | | | Change: 120139351
* Added is_variable_initialized(variable) function.Gravatar Sherry Moore2016-04-07
| | | | Change: 119321281
* Fixing bug in wait_for_session in which we were waiting for N ms instead of ↵Gravatar A. Unique TensorFlower2016-04-05
| | | | | | N secs. Change: 119119175
* Bounding the amount of time the Supervisor can spend waiting for a session.Gravatar A. Unique TensorFlower2016-04-04
| | | | Change: 118968679
* Mark more tests as size = "small"Gravatar Geoffrey Irving2016-03-22
| | | | Change: 117825911
* Moved session_manager and supervisor to third_party.Gravatar Sherry Moore2016-03-14
Change: 117170777