e2f9a04f406c8f8d75708669074511479e9cb6a5,t3f/riemannian.py,,already_projected_scalar_products_matrix,#Any#Any#,521

Before Change


  actual_first_ranks = np.array(first_static_ranks.as_list())[1:-1]
  actual_first_ranks = actual_first_ranks[~np.isnan(actual_first_ranks)]
  actual_second_ranks = np.array(second_static_ranks.as_list())[1:-1]
  actual_second_ranks = actual_second_ranks[~np.isnan(actual_second_ranks)]
  if any(actual_first_ranks % 2 != 0) or any(actual_second_ranks % 2 != 0):
    raise ValueError("The TT-ranks of the arguments are not dividable by 2, it "
                     "seems like the arguments are not projections.\n"
                     "Consider using scalar_products_matrix which doesn\" "

After Change


  Returns:
    tf.tensor with the scalar product matrix.
  
  if not hasattr(projected_tt_vectors_1, "projection_on") or \
      not hasattr(projected_tt_vectors_2, "projection_on"):
    raise ValueError("Both arguments should be projections on the tangent "
                     "space of some other TT-object. All projection* functions "
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: Bihaqo/t3f
Commit Name: e2f9a04f406c8f8d75708669074511479e9cb6a5
Time: 2017-04-13
Author: novikov@bayesgroup.ru
File Name: t3f/riemannian.py
Class Name:
Method Name: already_projected_scalar_products_matrix


Project Name: bethgelab/foolbox
Commit Name: d032ee03dcb302a5c71919ad43434eb327522de3
Time: 2018-07-08
Author: git@jonasrauber.de
File Name: foolbox/models/base.py
Class Name: Model
Method Name: _process_input


Project Name: NervanaSystems/coach
Commit Name: a7206ed7029a06954a490de603fd26dffe9f9270
Time: 2018-02-26
Author: 30383381+itaicaspi-intel@users.noreply.github.com
File Name: environments/gym_environment_wrapper.py
Class Name: GymEnvironmentWrapper
Method Name: _preprocess_state