Skip to content
Snippets Groups Projects

New operator Round

Merged Noam Zerah requested to merge noamzerah/aidge_core:feat_operator_round into dev
2 unresolved threads
5 files
+ 153
0
Compare changes
  • Side-by-side
  • Inline
Files
5
+ 64
0
/********************************************************************************
* Copyright (c) 2023 CEA-List
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License 2.0 which is available at
* http://www.eclipse.org/legal/epl-2.0.
*
* SPDX-License-Identifier: EPL-2.0
*
********************************************************************************/
#ifndef AIDGE_CORE_OPERATOR_ROUND_H_
#define AIDGE_CORE_OPERATOR_ROUND_H_
#include <memory>
#include <vector>
#include <string>
#include "aidge/graph/Node.hpp"
#include "aidge/operator/OperatorTensor.hpp"
#include "aidge/utils/StaticAttributes.hpp"
#include "aidge/utils/Registrar.hpp"
#include "aidge/utils/Types.h"
namespace Aidge {
class Round_Op : public OperatorTensor,
public Registrable<Round_Op,
std::string,
std::function<std::shared_ptr<OperatorImpl>(const Round_Op&)>> {
public:
static const std::string Type;
Round_Op() : OperatorTensor(Type, {InputCategory::Data}, 1) {}
/**
* @brief Copy-constructor. Copy the operator attributes and its output tensor(s), but not its input tensors (the new operator has no input associated).
* @param op Operator to copy.
*/
Round_Op(const Round_Op& op);
/**
* @brief Clone the operator using its copy-constructor.
* @see Operator::Round_Op
*/
std::shared_ptr<Operator> clone() const override;
void setBackend(const std::string& name, DeviceIdx_t device = 0) override final;
std::set<std::string> getAvailableBackends() const override;
static const std::vector<std::string> getInputsName(){
return {"data_input"};
}
static const std::vector<std::string> getOutputsName(){
return {"data_output"};
}
};
std::shared_ptr<Node> Round(const std::string& name = "");
}
#endif /* AIDGE_CORE_OPERATOR_ROUND_H_ */
Loading