Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 8 of 8 for AttrSpec (0.52 sec)

  1. tensorflow/c/experimental/ops/gen/model/attr_spec.h

    // An attribute for an Op, such as an input/output type or for passing options.
    //
    // Essentially, this represents an OpDef::AttrDef and its context within the Op.
    class AttrSpec {
     public:
      AttrSpec() = default;
      AttrSpec(const AttrSpec& other) = default;
      static AttrSpec Create(const OpDef::AttrDef& attr_def);
    
      const string& name() const { return name_; }
      const string& description() const { return description_; }
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Jun 15 18:23:40 UTC 2021
    - 1.9K bytes
    - Viewed (0)
  2. tensorflow/c/experimental/ops/gen/model/attr_spec.cc

    #include "tensorflow/c/experimental/ops/gen/model/attr_spec.h"
    
    #include "tensorflow/core/lib/strings/str_util.h"
    
    namespace tensorflow {
    namespace generator {
    
    AttrSpec AttrSpec::Create(const OpDef::AttrDef& attr_def) {
      return AttrSpec(attr_def);
    }
    
    AttrSpec::AttrSpec(const OpDef::AttrDef& attr_def) {
      name_ = attr_def.name();
      description_ = attr_def.description();
      full_type_ = attr_def.type();
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Jun 15 18:23:40 UTC 2021
    - 1.4K bytes
    - Viewed (0)
  3. tensorflow/c/experimental/ops/gen/model/op_spec.h

      const std::vector<AttrSpec>& Attributes() const { return argument_attrs_; }
    
     private:
      explicit OpSpec(const OpDef& op_def, const ApiDef& api_def);
    
     private:
      string name_;
      string summary_;
      string description_;
      std::vector<ArgSpec> input_args_;
      std::vector<ArgSpec> output_args_;
      std::vector<AttrSpec> argument_attrs_;
      std::map<string, AttrSpec> type_attrs_;
    };
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Jun 15 18:23:40 UTC 2021
    - 2.1K bytes
    - Viewed (0)
  4. tensorflow/c/experimental/ops/gen/cpp/views/attr_view.h

    #include "tensorflow/c/experimental/ops/gen/model/attr_spec.h"
    #include "tensorflow/core/platform/types.h"
    
    namespace tensorflow {
    namespace generator {
    namespace cpp {
    
    class AttrView {
     public:
      explicit AttrView(AttrSpec attr) : attr_(attr) {}
    
      string VariableName() const;
      string VariableType() const;
      string AttrNameString() const;
      string VariableStrLen() const;
      string VariableSpanData() const;
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 17 17:54:34 UTC 2022
    - 1.5K bytes
    - Viewed (0)
  5. tensorflow/c/experimental/ops/gen/model/op_spec.cc

        ArgSpec arg = ArgSpec::CreateOutput(arg_def, output_args_.size());
        output_args_.push_back(arg);
      }
      // Parse the attributes.
      for (const OpDef::AttrDef& attr_def : op_def.attr()) {
        AttrSpec attr = AttrSpec::Create(attr_def);
        // Only non-inferred args are added as arguments.
        if (inferred_attrs.find(attr_def.name()) == inferred_attrs.end()) {
          argument_attrs_.push_back(attr);
        }
      }
    }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Jul 01 21:05:56 UTC 2021
    - 2.1K bytes
    - Viewed (0)
  6. tensorflow/c/experimental/ops/gen/cpp/views/op_argument_view.h

    #include "tensorflow/core/platform/types.h"
    
    namespace tensorflow {
    namespace generator {
    namespace cpp {
    
    class OpArgumentView {
     public:
      explicit OpArgumentView(ArgSpec arg);
      explicit OpArgumentView(AttrSpec attr);
      explicit OpArgumentView(string type, string var, string def = "");
    
      string Declaration() const;
      string Initializer() const;
      bool HasDefaultValue() const;
    
     private:
      string type_name_;
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Jul 01 21:05:56 UTC 2021
    - 1.5K bytes
    - Viewed (0)
  7. tensorflow/c/experimental/ops/gen/cpp/views/op_argument_view.cc

    OpArgumentView::OpArgumentView(ArgSpec arg)
        : type_name_(ArgTypeView(arg.arg_type()).TypeName()),
          variable_name_(ArgView(arg).VariableName()) {}
    
    OpArgumentView::OpArgumentView(AttrSpec attr)
        : type_name_(AttrView(attr).VariableType()),
          variable_name_(AttrView(attr).VariableName()),
          default_value_(AttrView(attr).DefaultValue()) {}
    
    }  // namespace cpp
    }  // namespace generator
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon Jun 03 07:02:00 UTC 2024
    - 2.1K bytes
    - Viewed (0)
  8. tensorflow/c/experimental/ops/gen/README.md

    the model and provides utilities for the language generators.
    
    The *View* and rendering classes map the language-independent Model classes
    (`OpSpec`, `ArgSpec`, `AttrSpec`, etc.) to language-specific `SourceCode`. The
    framework does not impose any design on the language-specific generators, but
    provides some utilities, and the C++ generator is a complete example.
    
    ### C++ Generator
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon Jun 21 18:51:25 UTC 2021
    - 5.7K bytes
    - Viewed (0)
Back to top