Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for CompareNumericalAndAutodiffGradients (0.27 sec)

  1. tensorflow/c/experimental/gradients/math_grad_test.cc

      // AddV2Registerer.
      status_ = registry_.Register("AddV2", AddRegisterer);
      ASSERT_EQ(errors::OK, status_.code()) << status_.message();
    
      ASSERT_NO_FATAL_FAILURE(CompareNumericalAndAutodiffGradients(
          AddModel, BuildGradModel(AddModel, registry_),
          immediate_execution_ctx_.get(), {x.get(), y.get()}, UseFunction()));
    }
    
    TEST_P(CppGradients, TestExpGrad) {
      AbstractTensorHandlePtr x;
    C++
    - Registered: Tue Mar 26 12:39:09 GMT 2024
    - Last Modified: Thu Apr 13 17:32:14 GMT 2023
    - 16.3K bytes
    - Viewed (0)
  2. tensorflow/c/experimental/gradients/nn_grad_test.cc

            immediate_execution_ctx_.get(), X_vals, X_dims, 2, &X_raw);
        ASSERT_EQ(errors::OK, status_.code()) << status_.message();
        X.reset(X_raw);
      }
    
      ASSERT_NO_FATAL_FAILURE(CompareNumericalAndAutodiffGradients(
          ReluModel, ReluGradModel, immediate_execution_ctx_.get(), {X.get()},
          UseFunction()));
    
      // Mathematically, Relu isn't differentiable at `0`. So `gradient_checker`
      // does not work with it.
    C++
    - Registered: Tue Mar 26 12:39:09 GMT 2024
    - Last Modified: Wed Feb 28 13:53:47 GMT 2024
    - 8.3K bytes
    - Viewed (0)
  3. tensorflow/c/experimental/gradients/grad_test_helper.h

    #include "tensorflow/c/eager/gradients.h"
    #include "tensorflow/c/eager/unified_api_testutil.h"
    
    namespace tensorflow {
    namespace gradients {
    namespace internal {
    
    void CompareNumericalAndAutodiffGradients(
        Model model, Model grad_model, AbstractContext* ctx,
        absl::Span<AbstractTensorHandle* const> inputs, bool use_function,
        double abs_error = 1e-2);
    
    C
    - Registered: Tue Mar 26 12:39:09 GMT 2024
    - Last Modified: Thu Jan 14 20:36:51 GMT 2021
    - 1.5K bytes
    - Viewed (0)
  4. tensorflow/c/experimental/gradients/grad_test_helper.cc

    #include "tensorflow/c/experimental/gradients/tape/tape_context.h"
    #include "tensorflow/core/platform/test.h"
    
    namespace tensorflow {
    namespace gradients {
    namespace internal {
    
    void CompareNumericalAndAutodiffGradients(
        Model model, Model grad_model, AbstractContext* ctx,
        absl::Span<AbstractTensorHandle* const> inputs, bool use_function,
        double abs_error) {
      auto num_inputs = inputs.size();
    C++
    - Registered: Tue Mar 26 12:39:09 GMT 2024
    - Last Modified: Wed Feb 28 13:53:47 GMT 2024
    - 5K bytes
    - Viewed (0)
Back to top