16#ifndef popops_ElementWise_hpp
17#define popops_ElementWise_hpp
19#include <poplar/Graph.hpp>
20#include <poplar/OptionFlags.hpp>
21#include <poplar/Program.hpp>
162 const std::vector<poplar::Tensor> &ts,
173 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(op, t, options));
175 map(graph, expr::UnaryOp(op, expr::_1), {t}, prog, {di}, options);
176 di.addOutput(output);
185 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(op, a, b, options));
186 auto output =
map(graph, expr::BinaryOp(op, expr::_1, expr::_2), {a, b}, prog,
188 di.addOutput(output);
198 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(op, a, b, c, options));
199 auto output =
map(graph, expr::TernaryOp(op, expr::_1, expr::_2, expr::_3),
200 {a, b, c}, prog, {di}, options);
201 di.addOutput(output);
211 const std::vector<poplar::Tensor> &ts,
220 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(op, t, options));
222 mapInPlace(graph, expr::UnaryOp(op, expr::_1), {t}, prog, {di}, options);
230 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(op, a, b, options));
232 mapInPlace(graph, expr::BinaryOp(op, expr::_1, expr::_2), {a, b}, prog, {di},
241 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(op, a, b, c, options));
243 mapInPlace(graph, expr::TernaryOp(op, expr::_1, expr::_2, expr::_3),
244 {a, b, c}, prog, {di}, options);
253 const std::vector<poplar::Tensor> &ts,
263 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(op, in, out, options));
265 mapWithOutput(graph, expr::UnaryOp(op, expr::_1), {in}, out, prog, {di},
275 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(op, a, b, out, options));
277 mapWithOutput(graph, expr::BinaryOp(op, expr::_1, expr::_2), {a, b}, out,
278 prog, {di}, options);
287 poputil::PoplibsOpDebugInfo di(debugContext,
288 DI_ARGS(op, a, b, c, out, options));
290 mapWithOutput(graph, expr::TernaryOp(op, expr::_1, expr::_2, expr::_3),
291 {a, b, c}, out, prog, {di}, options);
315 const std::vector<poplar::Tensor> &ts,
339 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
341 auto output =
map(graph, expr::UnaryOpType::ABSOLUTE, A, prog, {di}, options);
342 di.addOutput(output);
352 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
354 mapInPlace(graph, expr::UnaryOpType::ABSOLUTE, A, prog, {di}, options);
364 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
366 mapWithOutput(graph, expr::UnaryOpType::ABSOLUTE, A, out, prog, {di},
387 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
389 auto output =
map(graph, expr::UnaryOpType::ASIN, A, prog, {di}, options);
390 di.addOutput(output);
400 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
402 mapInPlace(graph, expr::UnaryOpType::ASIN, A, prog, {di}, options);
412 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
414 mapWithOutput(graph, expr::UnaryOpType::ASIN, A, out, prog, {di}, options);
433 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
436 map(graph, expr::UnaryOpType::BITWISE_NOT, A, prog, {di}, options);
437 di.addOutput(output);
447 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
449 mapInPlace(graph, expr::UnaryOpType::BITWISE_NOT, A, prog, {di}, options);
459 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
461 mapWithOutput(graph, expr::UnaryOpType::BITWISE_NOT, A, out, prog, {di},
481 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
483 auto output =
map(graph, expr::UnaryOpType::CBRT, A, prog, {di}, options);
484 di.addOutput(output);
494 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
496 mapInPlace(graph, expr::UnaryOpType::CBRT, A, prog, {di}, options);
506 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
508 mapWithOutput(graph, expr::UnaryOpType::CBRT, A, out, prog, {di}, options);
528 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
530 auto output =
map(graph, expr::UnaryOpType::GELU_ERF, A, prog, {di}, options);
531 di.addOutput(output);
541 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
543 mapInPlace(graph, expr::UnaryOpType::GELU_ERF, A, prog, {di}, options);
553 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
555 mapWithOutput(graph, expr::UnaryOpType::GELU_ERF, A, out, prog, {di},
575 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
577 auto output =
map(graph, expr::UnaryOpType::CEIL, A, prog, {di}, options);
578 di.addOutput(output);
588 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
590 mapInPlace(graph, expr::UnaryOpType::CEIL, A, prog, {di}, options);
600 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
602 mapWithOutput(graph, expr::UnaryOpType::CEIL, A, out, prog, {di}, options);
624 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
626 auto output =
map(graph, expr::UnaryOpType::COUNT_LEADING_ZEROS, A, prog,
628 di.addOutput(output);
639 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
641 mapInPlace(graph, expr::UnaryOpType::COUNT_LEADING_ZEROS, A, prog, {di},
653 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
655 mapWithOutput(graph, expr::UnaryOpType::COUNT_LEADING_ZEROS, A, out, prog,
675 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
676 auto output =
map(graph, expr::UnaryOpType::COS, A, prog, {di}, options);
677 di.addOutput(output);
687 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
688 mapInPlace(graph, expr::UnaryOpType::COS, A, prog, {di}, options);
698 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
699 mapWithOutput(graph, expr::UnaryOpType::COS, A, out, prog, {di}, options);
718 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
719 auto output =
map(graph, expr::UnaryOpType::ERF, A, prog, {di}, options);
720 di.addOutput(output);
730 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
731 mapInPlace(graph, expr::UnaryOpType::ERF, A, prog, {di}, options);
741 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
742 mapWithOutput(graph, expr::UnaryOpType::ERF, A, out, prog, {di}, options);
761 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
762 auto output =
map(graph, expr::UnaryOpType::EXPONENT, A, prog, {di}, options);
763 di.addOutput(output);
773 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
774 mapInPlace(graph, expr::UnaryOpType::EXPONENT, A, prog, {di}, options);
784 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
785 mapWithOutput(graph, expr::UnaryOpType::EXPONENT, A, out, prog, {di},
805 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
807 map(graph, expr::UnaryOpType::EXPONENT_MINUS_ONE, A, prog, {di}, options);
808 di.addOutput(output);
818 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
819 mapInPlace(graph, expr::UnaryOpType::EXPONENT_MINUS_ONE, A, prog, {di},
830 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
831 mapWithOutput(graph, expr::UnaryOpType::EXPONENT_MINUS_ONE, A, out, prog,
851 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
852 auto output =
map(graph, expr::UnaryOpType::FLOOR, A, prog, {di}, options);
853 di.addOutput(output);
863 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
864 mapInPlace(graph, expr::UnaryOpType::FLOOR, A, prog, {di}, options);
874 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
875 mapWithOutput(graph, expr::UnaryOpType::FLOOR, A, out, prog, {di}, options);
894 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
895 auto output =
map(graph, expr::UnaryOpType::INVERSE, A, prog, {di}, options);
896 di.addOutput(output);
906 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
907 mapInPlace(graph, expr::UnaryOpType::INVERSE, A, prog, {di}, options);
917 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
918 mapWithOutput(graph, expr::UnaryOpType::INVERSE, A, out, prog, {di}, options);
937 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
940 map(graph, expr::UnaryOpType::LOGARITHM, A, prog, {di}, options);
941 di.addOutput(output);
951 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
953 mapInPlace(graph, expr::UnaryOpType::LOGARITHM, A, prog, {di}, options);
963 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
965 mapWithOutput(graph, expr::UnaryOpType::LOGARITHM, A, out, prog, {di},
985 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
988 map(graph, expr::UnaryOpType::LOGARITHM_ONE_PLUS, A, prog, {di}, options);
989 di.addOutput(output);
999 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1001 mapInPlace(graph, expr::UnaryOpType::LOGARITHM_ONE_PLUS, A, prog, {di},
1012 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
1014 mapWithOutput(graph, expr::UnaryOpType::LOGARITHM_ONE_PLUS, A, out, prog,
1034 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1037 map(graph, expr::UnaryOpType::LOGICAL_NOT, A, prog, {di}, options);
1038 di.addOutput(output);
1048 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1050 mapInPlace(graph, expr::UnaryOpType::LOGICAL_NOT, A, prog, {di}, options);
1060 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
1062 mapWithOutput(graph, expr::UnaryOpType::LOGICAL_NOT, A, out, prog, {di},
1082 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1084 auto output =
map(graph, expr::UnaryOpType::NEGATE, A, prog, {di}, options);
1085 di.addOutput(output);
1095 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1097 mapInPlace(graph, expr::UnaryOpType::NEGATE, A, prog, {di}, options);
1107 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
1109 mapWithOutput(graph, expr::UnaryOpType::NEGATE, A, out, prog, {di}, options);
1128 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1130 auto output =
map(graph, expr::UnaryOpType::POPCOUNT, A, prog, {di}, options);
1131 di.addOutput(output);
1141 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1143 mapInPlace(graph, expr::UnaryOpType::POPCOUNT, A, prog, {di}, options);
1153 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
1155 mapWithOutput(graph, expr::UnaryOpType::POPCOUNT, A, out, prog, {di},
1176 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1178 auto output =
map(graph, expr::UnaryOpType::SIGNUM, A, prog, {di}, options);
1179 di.addOutput(output);
1189 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1191 mapInPlace(graph, expr::UnaryOpType::SIGNUM, A, prog, {di}, options);
1201 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
1203 mapWithOutput(graph, expr::UnaryOpType::SIGNUM, A, out, prog, {di}, options);
1222 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1224 auto output =
map(graph, expr::UnaryOpType::SIN, A, prog, {di}, options);
1225 di.addOutput(output);
1235 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1237 mapInPlace(graph, expr::UnaryOpType::SIN, A, prog, {di}, options);
1247 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
1249 mapWithOutput(graph, expr::UnaryOpType::SIN, A, out, prog, {di}, options);
1268 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1270 auto output =
map(graph, expr::UnaryOpType::TAN, A, prog, {di}, options);
1271 di.addOutput(output);
1281 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1283 mapInPlace(graph, expr::UnaryOpType::TAN, A, prog, {di}, options);
1293 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
1295 mapWithOutput(graph, expr::UnaryOpType::TAN, A, out, prog, {di}, options);
1314 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1316 auto output =
map(graph, expr::UnaryOpType::TANH, A, prog, {di}, options);
1317 di.addOutput(output);
1327 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1329 mapInPlace(graph, expr::UnaryOpType::TANH, A, prog, {di}, options);
1339 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
1341 mapWithOutput(graph, expr::UnaryOpType::TANH, A, out, prog, {di}, options);
1360 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1362 auto output =
map(graph, expr::UnaryOpType::ROUND, A, prog, {di}, options);
1363 di.addOutput(output);
1373 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1375 mapInPlace(graph, expr::UnaryOpType::ROUND, A, prog, {di}, options);
1385 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
1387 mapWithOutput(graph, expr::UnaryOpType::ROUND, A, out, prog, {di}, options);
1406 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1408 auto output =
map(graph, expr::UnaryOpType::SQRT, A, prog, {di}, options);
1409 di.addOutput(output);
1419 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1421 mapInPlace(graph, expr::UnaryOpType::SQRT, A, prog, {di}, options);
1431 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
1433 mapWithOutput(graph, expr::UnaryOpType::SQRT, A, out, prog, {di}, options);
1452 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1454 auto output =
map(graph, expr::UnaryOpType::SQUARE, A, prog, {di}, options);
1455 di.addOutput(output);
1465 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1467 mapInPlace(graph, expr::UnaryOpType::SQUARE, A, prog, {di}, options);
1477 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
1479 mapWithOutput(graph, expr::UnaryOpType::SQUARE, A, out, prog, {di}, options);
1498 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1500 auto output =
map(graph, expr::UnaryOpType::SIGMOID, A, prog, {di}, options);
1501 di.addOutput(output);
1511 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1513 mapInPlace(graph, expr::UnaryOpType::SIGMOID, A, prog, {di}, options);
1523 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
1525 mapWithOutput(graph, expr::UnaryOpType::SIGMOID, A, out, prog, {di}, options);
1544 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1546 auto output =
map(graph, expr::UnaryOpType::RSQRT, A, prog, {di}, options);
1547 di.addOutput(output);
1557 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1559 mapInPlace(graph, expr::UnaryOpType::RSQRT, A, prog, {di}, options);
1569 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
1571 mapWithOutput(graph, expr::UnaryOpType::RSQRT, A, out, prog, {di}, options);
1590 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, options));
1593 map(graph, expr::UnaryOpType::IS_FINITE, A, prog, {di}, options);
1594 di.addOutput(output);
1605 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, out, options));
1606 mapWithOutput(graph, expr::UnaryOpType::IS_FINITE, A, out, prog, {di},
1621template <
typename constType>
1624 throw std::runtime_error(
"Type mismatch between Binary op Tensor "
1629template <>
inline void checkTypes<float>(
poplar::Type elementType,
float) {
1631 throw std::runtime_error(
"Type mismatch between Binary op Tensor "
1637template <>
inline void checkTypes<double>(
poplar::Type elementType,
double) {
1639 throw std::runtime_error(
"Type mismatch between Binary op Tensor "
1669 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
1671 auto output =
map(graph, expr::BinaryOpType::ADD, A, B, prog, {di}, options);
1672 di.addOutput(output);
1676template <
typename constType>
1681 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
1687 map(graph, expr::BinaryOpType::ADD, A, BTensor, prog, {di}, options);
1688 di.addOutput(output);
1692template <
typename constType>
1698 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
1704 map(graph, expr::BinaryOpType::ADD, ATensor, B, prog, {di}, options);
1705 di.addOutput(output);
1718 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
1720 mapInPlace(graph, expr::BinaryOpType::ADD, A, B, prog, {di}, options);
1723template <
typename constType>
1728 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
1733 mapInPlace(graph, expr::BinaryOpType::ADD, A, BTensor, prog, {di}, options);
1746 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
1748 mapWithOutput(graph, expr::BinaryOpType::ADD, A, B, out, prog, {di}, options);
1751template <
typename constType>
1757 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
1762 mapWithOutput(graph, expr::BinaryOpType::ADD, A, BTensor, out, prog, {di},
1766template <
typename constType>
1772 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
1777 mapWithOutput(graph, expr::BinaryOpType::ADD, ATensor, B, out, prog, {di},
1804 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
1807 map(graph, expr::BinaryOpType::ATAN2, A, B, prog, {di}, options);
1808 di.addOutput(output);
1812template <
typename constType>
1817 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
1823 map(graph, expr::BinaryOpType::ATAN2, A, BTensor, prog, {di}, options);
1824 di.addOutput(output);
1828template <
typename constType>
1834 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
1840 map(graph, expr::BinaryOpType::ATAN2, ATensor, B, prog, {di}, options);
1841 di.addOutput(output);
1855 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
1857 mapInPlace(graph, expr::BinaryOpType::ATAN2, A, B, prog, {di}, options);
1860template <
typename constType>
1865 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
1870 mapInPlace(graph, expr::BinaryOpType::ATAN2, A, BTensor, prog, {di}, options);
1883 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
1885 mapWithOutput(graph, expr::BinaryOpType::ATAN2, A, B, out, prog, {di},
1889template <
typename constType>
1895 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
1900 mapWithOutput(graph, expr::BinaryOpType::ATAN2, A, BTensor, out, prog, {di},
1904template <
typename constType>
1910 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
1915 mapWithOutput(graph, expr::BinaryOpType::ATAN2, ATensor, B, out, prog, {di},
1941 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
1944 map(graph, expr::BinaryOpType::BITWISE_AND, A, B, prog, {di}, options);
1945 di.addOutput(output);
1949template <
typename constType>
1955 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
1960 auto output =
map(graph, expr::BinaryOpType::BITWISE_AND, A, BTensor, prog,
1962 di.addOutput(output);
1965template <
typename constType>
1971 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
1976 auto output =
map(graph, expr::BinaryOpType::BITWISE_AND, ATensor, B, prog,
1978 di.addOutput(output);
1992 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
1994 mapInPlace(graph, expr::BinaryOpType::BITWISE_AND, A, B, prog, {di}, options);
1997template <
typename constType>
2003 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2008 mapInPlace(graph, expr::BinaryOpType::BITWISE_AND, A, BTensor, prog, {di},
2023 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2025 mapWithOutput(graph, expr::BinaryOpType::BITWISE_AND, A, B, out, prog, {di},
2029template <
typename constType>
2035 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2040 mapWithOutput(graph, expr::BinaryOpType::BITWISE_AND, A, BTensor, out, prog,
2043template <
typename constType>
2050 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2055 mapWithOutput(graph, expr::BinaryOpType::BITWISE_AND, ATensor, B, out, prog,
2082 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2085 map(graph, expr::BinaryOpType::BITWISE_OR, A, B, prog, {di}, options);
2086 di.addOutput(output);
2090template <
typename constType>
2096 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2101 auto output =
map(graph, expr::BinaryOpType::BITWISE_OR, A, BTensor, prog,
2103 di.addOutput(output);
2107template <
typename constType>
2113 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2118 auto output =
map(graph, expr::BinaryOpType::BITWISE_OR, ATensor, B, prog,
2120 di.addOutput(output);
2134 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2136 mapInPlace(graph, expr::BinaryOpType::BITWISE_OR, A, B, prog, {di}, options);
2139template <
typename constType>
2144 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2149 mapInPlace(graph, expr::BinaryOpType::BITWISE_OR, A, BTensor, prog, {di},
2164 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2166 mapWithOutput(graph, expr::BinaryOpType::BITWISE_OR, A, B, out, prog, {di},
2170template <
typename constType>
2176 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2181 mapWithOutput(graph, expr::BinaryOpType::BITWISE_OR, A, BTensor, out, prog,
2185template <
typename constType>
2192 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2197 mapWithOutput(graph, expr::BinaryOpType::BITWISE_OR, ATensor, B, out, prog,
2224 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2227 map(graph, expr::BinaryOpType::BITWISE_XOR, A, B, prog, {di}, options);
2228 di.addOutput(output);
2232template <
typename constType>
2238 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2243 auto output =
map(graph, expr::BinaryOpType::BITWISE_XOR, A, BTensor, prog,
2245 di.addOutput(output);
2249template <
typename constType>
2255 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2260 auto output =
map(graph, expr::BinaryOpType::BITWISE_XOR, ATensor, B, prog,
2262 di.addOutput(output);
2276 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2278 mapInPlace(graph, expr::BinaryOpType::BITWISE_XOR, A, B, prog, {di}, options);
2281template <
typename constType>
2287 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2292 mapInPlace(graph, expr::BinaryOpType::BITWISE_XOR, A, BTensor, prog, {di},
2307 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2309 mapWithOutput(graph, expr::BinaryOpType::BITWISE_XOR, A, B, out, prog, {di},
2313template <
typename constType>
2319 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2324 mapWithOutput(graph, expr::BinaryOpType::BITWISE_XOR, A, BTensor, out, prog,
2328template <
typename constType>
2335 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2340 mapWithOutput(graph, expr::BinaryOpType::BITWISE_XOR, ATensor, B, out, prog,
2367 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2370 map(graph, expr::BinaryOpType::BITWISE_XNOR, A, B, prog, {di}, options);
2371 di.addOutput(output);
2375template <
typename constType>
2381 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2386 auto output =
map(graph, expr::BinaryOpType::BITWISE_XNOR, A, BTensor, prog,
2388 di.addOutput(output);
2392template <
typename constType>
2398 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2403 auto output =
map(graph, expr::BinaryOpType::BITWISE_XNOR, ATensor, B, prog,
2405 di.addOutput(output);
2420 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2422 mapInPlace(graph, expr::BinaryOpType::BITWISE_XNOR, A, B, prog, {di},
2426template <
typename constType>
2432 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2437 mapInPlace(graph, expr::BinaryOpType::BITWISE_XNOR, A, BTensor, prog, {di},
2452 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2454 mapWithOutput(graph, expr::BinaryOpType::BITWISE_XNOR, A, B, out, prog, {di},
2458template <
typename constType>
2464 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2469 mapWithOutput(graph, expr::BinaryOpType::BITWISE_XNOR, A, BTensor, out, prog,
2473template <
typename constType>
2480 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2485 mapWithOutput(graph, expr::BinaryOpType::BITWISE_XNOR, ATensor, B, out, prog,
2512 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2515 map(graph, expr::BinaryOpType::DIVIDE, A, B, prog, {di}, options);
2516 di.addOutput(output);
2520template <
typename constType>
2525 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2531 map(graph, expr::BinaryOpType::DIVIDE, A, BTensor, prog, {di}, options);
2532 di.addOutput(output);
2536template <
typename constType>
2542 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2548 map(graph, expr::BinaryOpType::DIVIDE, ATensor, B, prog, {di}, options);
2549 di.addOutput(output);
2562 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2564 mapInPlace(graph, expr::BinaryOpType::DIVIDE, A, B, prog, {di}, options);
2567template <
typename constType>
2572 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2577 mapInPlace(graph, expr::BinaryOpType::DIVIDE, A, BTensor, prog, {di},
2591 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2593 mapWithOutput(graph, expr::BinaryOpType::DIVIDE, A, B, out, prog, {di},
2597template <
typename constType>
2603 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2608 mapWithOutput(graph, expr::BinaryOpType::DIVIDE, A, BTensor, out, prog, {di},
2612template <
typename constType>
2618 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2623 mapWithOutput(graph, expr::BinaryOpType::DIVIDE, ATensor, B, out, prog, {di},
2649 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2652 map(graph, expr::BinaryOpType::EQUAL, A, B, prog, {di}, options);
2653 di.addOutput(output);
2657template <
typename constType>
2662 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2668 map(graph, expr::BinaryOpType::EQUAL, A, BTensor, prog, {di}, options);
2669 di.addOutput(output);
2673template <
typename constType>
2679 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2685 map(graph, expr::BinaryOpType::EQUAL, ATensor, B, prog, {di}, options);
2686 di.addOutput(output);
2699 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2701 mapInPlace(graph, expr::BinaryOpType::EQUAL, A, B, prog, {di}, options);
2704template <
typename constType>
2709 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2714 mapInPlace(graph, expr::BinaryOpType::EQUAL, A, BTensor, prog, {di}, options);
2727 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2729 mapWithOutput(graph, expr::BinaryOpType::EQUAL, A, B, out, prog, {di},
2733template <
typename constType>
2739 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2744 mapWithOutput(graph, expr::BinaryOpType::EQUAL, A, BTensor, out, prog, {di},
2748template <
typename constType>
2754 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2759 mapWithOutput(graph, expr::BinaryOpType::EQUAL, ATensor, B, out, prog, {di},
2786 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2788 auto output =
map(graph, expr::BinaryOpType::GREATER_THAN_EQUAL, A, B, prog,
2790 di.addOutput(output);
2794template <
typename constType>
2799 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2804 auto output =
map(graph, expr::BinaryOpType::GREATER_THAN_EQUAL, A, BTensor,
2805 prog, {di}, options);
2806 di.addOutput(output);
2810template <
typename constType>
2816 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2821 auto output =
map(graph, expr::BinaryOpType::GREATER_THAN_EQUAL, ATensor, B,
2822 prog, {di}, options);
2823 di.addOutput(output);
2837 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2839 mapInPlace(graph, expr::BinaryOpType::GREATER_THAN_EQUAL, A, B, prog, {di},
2843template <
typename constType>
2848 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2853 mapInPlace(graph, expr::BinaryOpType::GREATER_THAN_EQUAL, A, BTensor, prog,
2867 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2869 mapWithOutput(graph, expr::BinaryOpType::GREATER_THAN_EQUAL, A, B, out, prog,
2873template <
typename constType>
2879 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2884 mapWithOutput(graph, expr::BinaryOpType::GREATER_THAN_EQUAL, A, BTensor, out,
2885 prog, {di}, options);
2888template <
typename constType>
2894 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
2899 mapWithOutput(graph, expr::BinaryOpType::GREATER_THAN_EQUAL, ATensor, B, out,
2900 prog, {di}, options);
2926 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2929 map(graph, expr::BinaryOpType::GREATER_THAN, A, B, prog, {di}, options);
2930 di.addOutput(output);
2934template <
typename constType>
2939 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2944 auto output =
map(graph, expr::BinaryOpType::GREATER_THAN, A, BTensor, prog,
2946 di.addOutput(output);
2950template <
typename constType>
2956 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2961 auto output =
map(graph, expr::BinaryOpType::GREATER_THAN, ATensor, B, prog,
2963 di.addOutput(output);
2976 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2978 mapInPlace(graph, expr::BinaryOpType::GREATER_THAN, A, B, prog, {di},
2982template <
typename constType>
2987 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
2992 mapInPlace(graph, expr::BinaryOpType::GREATER_THAN, A, BTensor, prog, {di},
3006 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3008 mapWithOutput(graph, expr::BinaryOpType::GREATER_THAN, A, B, out, prog, {di},
3012template <
typename constType>
3018 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3023 mapWithOutput(graph, expr::BinaryOpType::GREATER_THAN, A, BTensor, out, prog,
3027template <
typename constType>
3033 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3038 mapWithOutput(graph, expr::BinaryOpType::GREATER_THAN, ATensor, B, out, prog,
3065 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3067 auto output =
map(graph, expr::BinaryOpType::INV_STD_DEV_TO_VARIANCE, A, B,
3068 prog, {di}, options);
3069 di.addOutput(output);
3073template <
typename constType>
3079 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3084 auto output =
map(graph, expr::BinaryOpType::INV_STD_DEV_TO_VARIANCE, A,
3085 BTensor, prog, {di}, options);
3086 di.addOutput(output);
3090template <
typename constType>
3096 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3101 auto output =
map(graph, expr::BinaryOpType::INV_STD_DEV_TO_VARIANCE, ATensor,
3102 B, prog, {di}, options);
3103 di.addOutput(output);
3118 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3120 mapInPlace(graph, expr::BinaryOpType::INV_STD_DEV_TO_VARIANCE, A, B, prog,
3124template <
typename constType>
3130 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3135 mapInPlace(graph, expr::BinaryOpType::INV_STD_DEV_TO_VARIANCE, A, BTensor,
3136 prog, {di}, options);
3149 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3151 mapWithOutput(graph, expr::BinaryOpType::INV_STD_DEV_TO_VARIANCE, A, B, out,
3152 prog, {di}, options);
3155template <
typename constType>
3162 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3167 mapWithOutput(graph, expr::BinaryOpType::INV_STD_DEV_TO_VARIANCE, A, BTensor,
3168 out, prog, {di}, options);
3171template <
typename constType>
3177 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3182 mapWithOutput(graph, expr::BinaryOpType::INV_STD_DEV_TO_VARIANCE, ATensor, B,
3183 out, prog, {di}, options);
3209 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3211 auto output =
map(graph, expr::BinaryOpType::LESS_THAN_EQUAL, A, B, prog,
3213 di.addOutput(output);
3217template <
typename constType>
3222 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3227 auto output =
map(graph, expr::BinaryOpType::LESS_THAN_EQUAL, A, BTensor,
3228 prog, {di}, options);
3229 di.addOutput(output);
3233template <
typename constType>
3239 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3244 auto output =
map(graph, expr::BinaryOpType::LESS_THAN_EQUAL, ATensor, B,
3245 prog, {di}, options);
3246 di.addOutput(output);
3260 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3262 mapInPlace(graph, expr::BinaryOpType::LESS_THAN_EQUAL, A, B, prog, {di},
3266template <
typename constType>
3271 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3276 mapInPlace(graph, expr::BinaryOpType::LESS_THAN_EQUAL, A, BTensor, prog, {di},
3290 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3292 mapWithOutput(graph, expr::BinaryOpType::LESS_THAN_EQUAL, A, B, out, prog,
3296template <
typename constType>
3302 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3307 mapWithOutput(graph, expr::BinaryOpType::LESS_THAN_EQUAL, A, BTensor, out,
3308 prog, {di}, options);
3311template <
typename constType>
3317 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3322 mapWithOutput(graph, expr::BinaryOpType::LESS_THAN_EQUAL, ATensor, B, out,
3323 prog, {di}, options);
3349 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3352 map(graph, expr::BinaryOpType::LOGICAL_AND, A, B, prog, {di}, options);
3353 di.addOutput(output);
3357template <
typename constType>
3363 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3368 auto output =
map(graph, expr::BinaryOpType::LOGICAL_AND, A, BTensor, prog,
3370 di.addOutput(output);
3374template <
typename constType>
3380 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3385 auto output =
map(graph, expr::BinaryOpType::LOGICAL_AND, ATensor, B, prog,
3387 di.addOutput(output);
3401 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3403 mapInPlace(graph, expr::BinaryOpType::LOGICAL_AND, A, B, prog, {di}, options);
3406template <
typename constType>
3412 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3417 mapInPlace(graph, expr::BinaryOpType::LOGICAL_AND, A, BTensor, prog, {di},
3432 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3434 mapWithOutput(graph, expr::BinaryOpType::LOGICAL_AND, A, B, out, prog, {di},
3438template <
typename constType>
3444 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3449 mapWithOutput(graph, expr::BinaryOpType::LOGICAL_AND, A, BTensor, out, prog,
3453template <
typename constType>
3460 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3465 mapWithOutput(graph, expr::BinaryOpType::LOGICAL_AND, ATensor, B, out, prog,
3492 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3495 map(graph, expr::BinaryOpType::LOGICAL_OR, A, B, prog, {di}, options);
3496 di.addOutput(output);
3500template <
typename constType>
3506 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3511 auto output =
map(graph, expr::BinaryOpType::LOGICAL_OR, A, BTensor, prog,
3513 di.addOutput(output);
3517template <
typename constType>
3523 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3528 auto output =
map(graph, expr::BinaryOpType::LOGICAL_OR, ATensor, B, prog,
3530 di.addOutput(output);
3544 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3546 mapInPlace(graph, expr::BinaryOpType::LOGICAL_OR, A, B, prog, {di}, options);
3549template <
typename constType>
3554 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3559 mapInPlace(graph, expr::BinaryOpType::LOGICAL_OR, A, BTensor, prog, {di},
3574 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3576 mapWithOutput(graph, expr::BinaryOpType::LOGICAL_OR, A, B, out, prog, {di},
3580template <
typename constType>
3586 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3591 mapWithOutput(graph, expr::BinaryOpType::LOGICAL_OR, A, BTensor, out, prog,
3595template <
typename constType>
3602 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3607 mapWithOutput(graph, expr::BinaryOpType::LOGICAL_OR, ATensor, B, out, prog,
3634 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3637 map(graph, expr::BinaryOpType::LESS_THAN, A, B, prog, {di}, options);
3638 di.addOutput(output);
3642template <
typename constType>
3647 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3652 auto output =
map(graph, expr::BinaryOpType::LESS_THAN, A, BTensor, prog,
3654 di.addOutput(output);
3658template <
typename constType>
3664 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3669 auto output =
map(graph, expr::BinaryOpType::LESS_THAN, ATensor, B, prog,
3671 di.addOutput(output);
3684 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3686 mapInPlace(graph, expr::BinaryOpType::LESS_THAN, A, B, prog, {di}, options);
3689template <
typename constType>
3694 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3699 mapInPlace(graph, expr::BinaryOpType::LESS_THAN, A, BTensor, prog, {di},
3713 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3715 mapWithOutput(graph, expr::BinaryOpType::LESS_THAN, A, B, out, prog, {di},
3719template <
typename constType>
3725 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3730 mapWithOutput(graph, expr::BinaryOpType::LESS_THAN, A, BTensor, out, prog,
3734template <
typename constType>
3740 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3745 mapWithOutput(graph, expr::BinaryOpType::LESS_THAN, ATensor, B, out, prog,
3772 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3775 map(graph, expr::BinaryOpType::MAXIMUM, A, B, prog, {di}, options);
3776 di.addOutput(output);
3780template <
typename constType>
3785 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3791 map(graph, expr::BinaryOpType::MAXIMUM, A, BTensor, prog, {di}, options);
3792 di.addOutput(output);
3796template <
typename constType>
3802 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3808 map(graph, expr::BinaryOpType::MAXIMUM, ATensor, B, prog, {di}, options);
3809 di.addOutput(output);
3822 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3824 mapInPlace(graph, expr::BinaryOpType::MAXIMUM, A, B, prog, {di}, options);
3827template <
typename constType>
3832 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3837 mapInPlace(graph, expr::BinaryOpType::MAXIMUM, A, BTensor, prog, {di},
3851 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3853 mapWithOutput(graph, expr::BinaryOpType::MAXIMUM, A, B, out, prog, {di},
3857template <
typename constType>
3863 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3868 mapWithOutput(graph, expr::BinaryOpType::MAXIMUM, A, BTensor, out, prog, {di},
3872template <
typename constType>
3878 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3883 mapWithOutput(graph, expr::BinaryOpType::MAXIMUM, ATensor, B, out, prog, {di},
3910 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3913 map(graph, expr::BinaryOpType::MINIMUM, A, B, prog, {di}, options);
3914 di.addOutput(output);
3918template <
typename constType>
3923 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3929 map(graph, expr::BinaryOpType::MINIMUM, A, BTensor, prog, {di}, options);
3930 di.addOutput(output);
3934template <
typename constType>
3940 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3946 map(graph, expr::BinaryOpType::MINIMUM, ATensor, B, prog, {di}, options);
3947 di.addOutput(output);
3960 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3962 mapInPlace(graph, expr::BinaryOpType::MINIMUM, A, B, prog, {di}, options);
3965template <
typename constType>
3970 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
3975 mapInPlace(graph, expr::BinaryOpType::MINIMUM, A, BTensor, prog, {di},
3989 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
3991 mapWithOutput(graph, expr::BinaryOpType::MINIMUM, A, B, out, prog, {di},
3995template <
typename constType>
4001 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4006 mapWithOutput(graph, expr::BinaryOpType::MINIMUM, A, BTensor, out, prog, {di},
4010template <
typename constType>
4011inline void minWithOutoput(
poplar::Graph &graph,
const constType A,
4016 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4021 mapWithOutput(graph, expr::BinaryOpType::MINIMUM, ATensor, B, out, prog, {di},
4047 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4050 map(graph, expr::BinaryOpType::MULTIPLY, A, B, prog, {di}, options);
4051 di.addOutput(output);
4055template <
typename constType>
4060 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4066 map(graph, expr::BinaryOpType::MULTIPLY, A, BTensor, prog, {di}, options);
4067 di.addOutput(output);
4071template <
typename constType>
4077 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4083 map(graph, expr::BinaryOpType::MULTIPLY, ATensor, B, prog, {di}, options);
4084 di.addOutput(output);
4097 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4099 mapInPlace(graph, expr::BinaryOpType::MULTIPLY, A, B, prog, {di}, options);
4102template <
typename constType>
4107 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4112 mapInPlace(graph, expr::BinaryOpType::MULTIPLY, A, BTensor, prog, {di},
4126 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4128 mapWithOutput(graph, expr::BinaryOpType::MULTIPLY, A, B, out, prog, {di},
4132template <
typename constType>
4138 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4143 mapWithOutput(graph, expr::BinaryOpType::MULTIPLY, A, BTensor, out, prog,
4147template <
typename constType>
4153 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4158 mapWithOutput(graph, expr::BinaryOpType::MULTIPLY, ATensor, B, out, prog,
4185 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4188 map(graph, expr::BinaryOpType::NOT_EQUAL, A, B, prog, {di}, options);
4189 di.addOutput(output);
4193template <
typename constType>
4198 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4203 auto output =
map(graph, expr::BinaryOpType::NOT_EQUAL, A, BTensor, prog,
4205 di.addOutput(output);
4209template <
typename constType>
4215 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4220 auto output =
map(graph, expr::BinaryOpType::NOT_EQUAL, ATensor, B, prog,
4222 di.addOutput(output);
4235 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4237 mapInPlace(graph, expr::BinaryOpType::NOT_EQUAL, A, B, prog, {di}, options);
4240template <
typename constType>
4245 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4250 mapInPlace(graph, expr::BinaryOpType::NOT_EQUAL, A, BTensor, prog, {di},
4264 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4266 mapWithOutput(graph, expr::BinaryOpType::NOT_EQUAL, A, B, out, prog, {di},
4270template <
typename constType>
4276 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4281 mapWithOutput(graph, expr::BinaryOpType::NOT_EQUAL, A, BTensor, out, prog,
4285template <
typename constType>
4291 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4296 mapWithOutput(graph, expr::BinaryOpType::NOT_EQUAL, ATensor, B, out, prog,
4322 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4325 map(graph, expr::BinaryOpType::POWER, A, B, prog, {di}, options);
4326 di.addOutput(output);
4330template <
typename constType>
4335 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4341 map(graph, expr::BinaryOpType::POWER, A, BTensor, prog, {di}, options);
4342 di.addOutput(output);
4346template <
typename constType>
4352 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4358 map(graph, expr::BinaryOpType::POWER, ATensor, B, prog, {di}, options);
4359 di.addOutput(output);
4372 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4374 mapInPlace(graph, expr::BinaryOpType::POWER, A, B, prog, {di}, options);
4377template <
typename constType>
4382 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4387 mapInPlace(graph, expr::BinaryOpType::POWER, A, BTensor, prog, {di}, options);
4400 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4402 mapWithOutput(graph, expr::BinaryOpType::POWER, A, B, out, prog, {di},
4406template <
typename constType>
4412 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4417 mapWithOutput(graph, expr::BinaryOpType::POWER, A, BTensor, out, prog, {di},
4421template <
typename constType>
4427 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4432 mapWithOutput(graph, expr::BinaryOpType::POWER, ATensor, B, out, prog, {di},
4458 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4461 map(graph, expr::BinaryOpType::REMAINDER, A, B, prog, {di}, options);
4462 di.addOutput(output);
4466template <
typename constType>
4471 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4476 auto output =
map(graph, expr::BinaryOpType::REMAINDER, A, BTensor, prog,
4478 di.addOutput(output);
4482template <
typename constType>
4488 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4493 auto output =
map(graph, expr::BinaryOpType::REMAINDER, ATensor, B, prog,
4495 di.addOutput(output);
4508 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4510 mapInPlace(graph, expr::BinaryOpType::REMAINDER, A, B, prog, {di}, options);
4513template <
typename constType>
4518 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4523 mapInPlace(graph, expr::BinaryOpType::REMAINDER, A, BTensor, prog, {di},
4537 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4539 mapWithOutput(graph, expr::BinaryOpType::REMAINDER, A, B, out, prog, {di},
4543template <
typename constType>
4549 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4554 mapWithOutput(graph, expr::BinaryOpType::REMAINDER, A, BTensor, out, prog,
4558template <
typename constType>
4564 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4569 mapWithOutput(graph, expr::BinaryOpType::REMAINDER, ATensor, B, out, prog,
4595 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4598 map(graph, expr::BinaryOpType::SHIFT_LEFT, A, B, prog, {di}, options);
4599 di.addOutput(output);
4603template <
typename constType>
4609 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4614 auto output =
map(graph, expr::BinaryOpType::SHIFT_LEFT, A, BTensor, prog,
4616 di.addOutput(output);
4620template <
typename constType>
4626 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4631 auto output =
map(graph, expr::BinaryOpType::SHIFT_LEFT, ATensor, B, prog,
4633 di.addOutput(output);
4647 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4649 mapInPlace(graph, expr::BinaryOpType::SHIFT_LEFT, A, B, prog, {di}, options);
4652template <
typename constType>
4657 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4662 mapInPlace(graph, expr::BinaryOpType::SHIFT_LEFT, A, BTensor, prog, {di},
4677 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4679 mapWithOutput(graph, expr::BinaryOpType::SHIFT_LEFT, A, B, out, prog, {di},
4683template <
typename constType>
4689 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4694 mapWithOutput(graph, expr::BinaryOpType::SHIFT_LEFT, A, BTensor, out, prog,
4698template <
typename constType>
4705 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4710 mapWithOutput(graph, expr::BinaryOpType::SHIFT_LEFT, ATensor, B, out, prog,
4737 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4740 map(graph, expr::BinaryOpType::SHIFT_RIGHT, A, B, prog, {di}, options);
4741 di.addOutput(output);
4745template <
typename constType>
4751 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4756 auto output =
map(graph, expr::BinaryOpType::SHIFT_RIGHT, A, BTensor, prog,
4758 di.addOutput(output);
4762template <
typename constType>
4768 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4773 auto output =
map(graph, expr::BinaryOpType::SHIFT_RIGHT, ATensor, B, prog,
4775 di.addOutput(output);
4789 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4791 mapInPlace(graph, expr::BinaryOpType::SHIFT_RIGHT, A, B, prog, {di}, options);
4794template <
typename constType>
4800 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4805 mapInPlace(graph, expr::BinaryOpType::SHIFT_RIGHT, A, BTensor, prog, {di},
4820 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4822 mapWithOutput(graph, expr::BinaryOpType::SHIFT_RIGHT, A, B, out, prog, {di},
4826template <
typename constType>
4832 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4837 mapWithOutput(graph, expr::BinaryOpType::SHIFT_RIGHT, A, BTensor, out, prog,
4842template <
typename constType>
4849 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4854 mapWithOutput(graph, expr::BinaryOpType::SHIFT_RIGHT, ATensor, B, out, prog,
4881 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4883 auto output =
map(graph, expr::BinaryOpType::SHIFT_RIGHT_SIGN_EXTEND, A, B,
4884 prog, {di}, options);
4885 di.addOutput(output);
4889template <
typename constType>
4895 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4900 auto output =
map(graph, expr::BinaryOpType::SHIFT_RIGHT_SIGN_EXTEND, A,
4901 BTensor, prog, {di}, options);
4902 di.addOutput(output);
4906template <
typename constType>
4912 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4917 auto output =
map(graph, expr::BinaryOpType::SHIFT_RIGHT_SIGN_EXTEND, ATensor,
4918 B, prog, {di}, options);
4919 di.addOutput(output);
4934 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4936 mapInPlace(graph, expr::BinaryOpType::SHIFT_RIGHT_SIGN_EXTEND, A, B, prog,
4940template <
typename constType>
4946 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
4951 mapInPlace(graph, expr::BinaryOpType::SHIFT_RIGHT_SIGN_EXTEND, A, BTensor,
4952 prog, {di}, options);
4965 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4967 mapWithOutput(graph, expr::BinaryOpType::SHIFT_RIGHT_SIGN_EXTEND, A, B, out,
4968 prog, {di}, options);
4971template <
typename constType>
4978 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4983 mapWithOutput(graph, expr::BinaryOpType::SHIFT_RIGHT_SIGN_EXTEND, A, BTensor,
4984 out, prog, {di}, options);
4987template <
typename constType>
4993 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
4998 mapWithOutput(graph, expr::BinaryOpType::SHIFT_RIGHT_SIGN_EXTEND, ATensor, B,
4999 out, prog, {di}, options);
5024 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
5027 map(graph, expr::BinaryOpType::SUBTRACT, A, B, prog, {di}, options);
5028 di.addOutput(output);
5032template <
typename constType>
5037 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
5043 map(graph, expr::BinaryOpType::SUBTRACT, A, BTensor, prog, {di}, options);
5044 di.addOutput(output);
5048template <
typename constType>
5054 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
5060 map(graph, expr::BinaryOpType::SUBTRACT, ATensor, B, prog, {di}, options);
5061 di.addOutput(output);
5074 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
5076 mapInPlace(graph, expr::BinaryOpType::SUBTRACT, A, B, prog, {di}, options);
5079template <
typename constType>
5084 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
5089 mapInPlace(graph, expr::BinaryOpType::SUBTRACT, A, BTensor, prog, {di},
5103 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
5105 mapWithOutput(graph, expr::BinaryOpType::SUBTRACT, A, B, out, prog, {di},
5109template <
typename constType>
5115 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
5120 mapWithOutput(graph, expr::BinaryOpType::SUBTRACT, A, BTensor, out, prog,
5124template <
typename constType>
5130 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
5135 mapWithOutput(graph, expr::BinaryOpType::SUBTRACT, ATensor, B, out, prog,
5161 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
5163 auto output =
map(graph, expr::BinaryOpType::VARIANCE_TO_INV_STD_DEV, A, B,
5164 prog, {di}, options);
5165 di.addOutput(output);
5169template <
typename constType>
5175 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
5180 auto output =
map(graph, expr::BinaryOpType::VARIANCE_TO_INV_STD_DEV, A,
5181 BTensor, prog, {di}, options);
5182 di.addOutput(output);
5186template <
typename constType>
5192 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
5197 auto output =
map(graph, expr::BinaryOpType::VARIANCE_TO_INV_STD_DEV, ATensor,
5198 B, prog, {di}, options);
5199 di.addOutput(output);
5214 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
5216 mapInPlace(graph, expr::BinaryOpType::VARIANCE_TO_INV_STD_DEV, A, B, prog,
5220template <
typename constType>
5226 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, options));
5231 mapInPlace(graph, expr::BinaryOpType::VARIANCE_TO_INV_STD_DEV, A, BTensor,
5232 prog, {di}, options);
5245 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
5247 mapWithOutput(graph, expr::BinaryOpType::VARIANCE_TO_INV_STD_DEV, A, B, out,
5248 prog, {di}, options);
5251template <
typename constType>
5258 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
5263 mapWithOutput(graph, expr::BinaryOpType::VARIANCE_TO_INV_STD_DEV, A, BTensor,
5264 out, prog, {di}, options);
5267template <
typename constType>
5273 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, out, options));
5278 mapWithOutput(graph, expr::BinaryOpType::VARIANCE_TO_INV_STD_DEV, ATensor, B,
5279 out, prog, {di}, options);
5310 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, C, options));
5312 map(graph, expr::TernaryOpType::SELECT, A, B, C, prog, {di}, options);
5313 di.addOutput(output);
5324 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, C, options));
5325 mapInPlace(graph, expr::TernaryOpType::SELECT, A, B, C, prog, {di}, options);
5336 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, C, out, options));
5337 mapWithOutput(graph, expr::TernaryOpType::SELECT, A, B, C, out, prog, {di},
5366 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, C, options));
5369 map(graph, expr::TernaryOpType::CLAMP, A, B, C, prog, {di}, options);
5370 di.addOutput(output);
5381 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, C, options));
5383 mapInPlace(graph, expr::TernaryOpType::CLAMP, A, B, C, prog, {di}, options);
5394 poputil::PoplibsOpDebugInfo di(debugContext, DI_ARGS(A, B, C, out, options));
5396 mapWithOutput(graph, expr::TernaryOpType::CLAMP, A, B, C, out, prog, {di},
Poplibs generic debug info structure.
TernaryOpType
Enumeration defining operators used by Expr for building expressions.
Definition: ExprOp.hpp:16
Expressions with elements of tensors.
DebugContext gathers the common external parameters of the context of an operation.
Definition: DebugContext.hpp:221
This class represents a graph program to be executed on the IPU.
Definition: Graph.hpp:52
Tensor addConstant(const Type &type, const Tensor &metadata, ArrayRef< std::size_t > shape, ArrayRef< T > values, const DebugContext &debugContext={"<const>"})
Add a constant to the graph with a type that may require metadata.
Definition: Graph.hpp:427
void setTileMapping(VertexRef v, unsigned tileNum)
Map a vertex to a specific tile on the device.
A set of option/value string flags to be used in various APIs.
Definition: OptionFlags.hpp:24
ProfileValue represents a read-only JSON-like tree of values that are used to store the output of the...
Definition: ProfileValue.hpp:39
A target representation.
Definition: Target.hpp:69
A reference to a subset of tensor elements.
Definition: Tensor.hpp:38
Type elementType() const
Get the element type information for this tensor.
Class representing device data types.
Definition: Type.hpp:42
Program that executes a sequence of programs.
Definition: Program.hpp:77
Type to represent element expressions.
Definition: Expr.hpp:36
Type FLOAT
Device type: float
Type HALF
Device type: half
Common functions, such as elementwise and reductions.
Definition: AllTrue.hpp:15
void rsqrtWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of rsqrt() to the given output tensor.
Definition: ElementWise.hpp:1564
poplar::Tensor signum(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the signum of each element in A.
Definition: ElementWise.hpp:1172
void geluErfInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of geluErf().
Definition: ElementWise.hpp:537
void bitwiseOrWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of bitwiseOr() to the given output tensor.
Definition: ElementWise.hpp:2158
poplar::Tensor add(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Add each element in A to the corresponding element in B.
Definition: ElementWise.hpp:1664
void remInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of rem().
Definition: ElementWise.hpp:4504
void tanInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of tan().
Definition: ElementWise.hpp:1277
void selectInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &C, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of select().
Definition: ElementWise.hpp:5319
void sinInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of sin().
Definition: ElementWise.hpp:1231
poplar::Tensor max(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the maximum of each element in A with the corresponding element in B.
Definition: ElementWise.hpp:3767
void addInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of add().
Definition: ElementWise.hpp:1714
void mapInPlace(poplar::Graph &graph, const expr::Expr &expr, const std::vector< poplar::Tensor > &ts, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensors with the result of map().
void erfInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of erf().
Definition: ElementWise.hpp:726
poplar::Tensor neg(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the negation of each element in A.
Definition: ElementWise.hpp:1078
void logicalNotWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of logicalNot() to the given output tensor.
Definition: ElementWise.hpp:1055
void shiftLeftWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of shiftLeft() to the given output tensor.
Definition: ElementWise.hpp:4671
void atan2InPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of atan2().
Definition: ElementWise.hpp:1850
void roundInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of round().
Definition: ElementWise.hpp:1369
void signumInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of signum().
Definition: ElementWise.hpp:1185
poplar::Tensor div(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Divide each element in A by the corresponding element in B.
Definition: ElementWise.hpp:2507
void rsqrtInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of rsqrt().
Definition: ElementWise.hpp:1553
void sigmoidInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of sigmoid().
Definition: ElementWise.hpp:1507
void bitwiseXorWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of bitwiseXor() to the given output tensor.
Definition: ElementWise.hpp:2301
void cosInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of cos().
Definition: ElementWise.hpp:683
void tanWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of tan() to the given output tensor.
Definition: ElementWise.hpp:1288
void maxInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of max().
Definition: ElementWise.hpp:3818
poplar::Tensor square(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the square for each element in A.
Definition: ElementWise.hpp:1448
void log1pWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of log1p() to the given output tensor.
Definition: ElementWise.hpp:1007
poplar::Tensor exp(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the exponential of each element in A.
Definition: ElementWise.hpp:757
void invWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of inv() to the given output tensor.
Definition: ElementWise.hpp:912
void shiftRightSignExtendInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of shiftRightSignExtend().
Definition: ElementWise.hpp:4929
void bitwiseNotWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of bitwiseNot() to the given output tensor.
Definition: ElementWise.hpp:454
void invStdDevToVarianceWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of invStdDevToVariance() to the given output tensor.
Definition: ElementWise.hpp:3144
void minWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of min() to the given output tensor.
Definition: ElementWise.hpp:3984
void bitwiseXorInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of bitwiseXor().
Definition: ElementWise.hpp:2271
poplar::Tensor bitwiseXnor(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the bitwise XNOR of each element in A with the corresponding element in B.
Definition: ElementWise.hpp:2362
void roundWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of round() to the given output tensor.
Definition: ElementWise.hpp:1380
void geluErfWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of geluErf() to the given output tensor.
Definition: ElementWise.hpp:548
void varianceToInvStdDevWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of varianceToInvStdDev() to the given output tensor.
Definition: ElementWise.hpp:5240
poplar::Tensor logicalNot(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the logical NOT of each element in A.
Definition: ElementWise.hpp:1030
void logWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of log() to the given output tensor.
Definition: ElementWise.hpp:958
void subInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of sub().
Definition: ElementWise.hpp:5070
void bitwiseNotInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of bitwiseNot().
Definition: ElementWise.hpp:443
void countLeadingZerosInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of countLeadingZeros().
Definition: ElementWise.hpp:635
poplar::Tensor sigmoid(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the sigmoid (logistic) function for each element in A.
Definition: ElementWise.hpp:1494
void shiftRightSignExtendWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of shiftRightSignExtend() to the given output tensor.
Definition: ElementWise.hpp:4960
void logInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of log().
Definition: ElementWise.hpp:947
poplar::Tensor inv(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the inverse of each element in A.
Definition: ElementWise.hpp:890
poplar::Tensor neq(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Check if each element in A is not equal to the corresponding element in B.
Definition: ElementWise.hpp:4180
void erfWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of erf() to the given output tensor.
Definition: ElementWise.hpp:736
void countLeadingZerosWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of countLeadingZeros() to the given output tensor.
Definition: ElementWise.hpp:648
void tanhWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of tanh() to the given output tensor.
Definition: ElementWise.hpp:1334
void ceilWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of ceil() to the given output tensor.
Definition: ElementWise.hpp:595
void squareWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of square() to the given output tensor.
Definition: ElementWise.hpp:1472
void gteqInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of gteq().
Definition: ElementWise.hpp:2832
poplar::Tensor floor(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the floor of each element in A.
Definition: ElementWise.hpp:847
poplar::Tensor log(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the log base-e of each element in A.
Definition: ElementWise.hpp:933
poplar::Tensor popcount(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the number of 1 bits in each element of A.
Definition: ElementWise.hpp:1124
void cbrtInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of cbrt().
Definition: ElementWise.hpp:490
void floorInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of floor().
Definition: ElementWise.hpp:859
void expm1InPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of expm1().
Definition: ElementWise.hpp:814
void minInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of min().
Definition: ElementWise.hpp:3956
void shiftLeftInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of shiftLeft().
Definition: ElementWise.hpp:4642
poplar::Tensor min(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the minimum of each element in A with the corresponding element in B.
Definition: ElementWise.hpp:3905
void asinInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of asin().
Definition: ElementWise.hpp:396
poplar::Tensor bitwiseAnd(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the bitwise AND of each element in A with the corresponding element in B.
Definition: ElementWise.hpp:1936
poplar::Tensor asin(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the arc-sine of each element in A.
Definition: ElementWise.hpp:383
poplar::Tensor countLeadingZeros(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the number of binary leading zeros of each element in A.
Definition: ElementWise.hpp:620
void expInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of exp().
Definition: ElementWise.hpp:769
poplar::Tensor shiftLeft(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Shift the elements of A left by the corresponding elements of B.
Definition: ElementWise.hpp:4590
void maxWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of max() to the given output tensor.
Definition: ElementWise.hpp:3846
void neqWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of neq() to the given output tensor.
Definition: ElementWise.hpp:4259
void log1pInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of log1p().
Definition: ElementWise.hpp:995
void sqrtWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of sqrt() to the given output tensor.
Definition: ElementWise.hpp:1426
poplar::Tensor sub(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Subtract the elements of B from A and return the result in a new tensor.
Definition: ElementWise.hpp:5019
void floorWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of floor() to the given output tensor.
Definition: ElementWise.hpp:869
void logicalNotInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of logicalNot().
Definition: ElementWise.hpp:1044
void invStdDevToVarianceInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of invStdDevToVariance().
Definition: ElementWise.hpp:3113
void powWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of pow() to the given output tensor.
Definition: ElementWise.hpp:4395
poplar::Tensor ceil(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the ceiling of each element in A.
Definition: ElementWise.hpp:571
void cosWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of cos() to the given output tensor.
Definition: ElementWise.hpp:693
void selectWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &C, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of select() to the given output tensor.
Definition: ElementWise.hpp:5330
poplar::Tensor abs(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the absolute value of each element in A.
Definition: ElementWise.hpp:335
void shiftRightInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of shiftRight().
Definition: ElementWise.hpp:4784
poplar::Tensor log1p(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the log base-e of each element in A plus one.
Definition: ElementWise.hpp:981
poplar::Tensor pow(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute each element in A to the power of the corresponding element in B.
Definition: ElementWise.hpp:4317
poplar::Tensor sin(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the sine of each element in A.
Definition: ElementWise.hpp:1218
poplar::Tensor shiftRightSignExtend(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Shift the elements of A right with sign extension by the corresponding elements of B.
Definition: ElementWise.hpp:4877
poplar::Tensor isFinite(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Check if each element in A is finite.
Definition: ElementWise.hpp:1586
void eqInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of eq().
Definition: ElementWise.hpp:2695
poplar::Tensor geluErf(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute (1 + erf(A/sqrt(2))) * A / 2 where all the operations are element-wise, and erf is the error ...
Definition: ElementWise.hpp:524
void gteqWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of gteq() to the given output tensor.
Definition: ElementWise.hpp:2862
poplar::Tensor shiftRight(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Shift the elements of A right by the corresponding elements of B.
Definition: ElementWise.hpp:4732
void popcountInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of popcount().
Definition: ElementWise.hpp:1137
poplar::Tensor gteq(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Check if each element in A is greater than or equal to the corresponding element in B.
Definition: ElementWise.hpp:2781
void neqInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of neq().
Definition: ElementWise.hpp:4231
void powInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of pow().
Definition: ElementWise.hpp:4368
void logicalOrWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of logicalOr() to the given output tensor.
Definition: ElementWise.hpp:3568
void isFiniteWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of isFinite() to the given output tensor.
Definition: ElementWise.hpp:1600
poplar::Tensor lteq(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Check if each element in A is less than or equal to the corresponding element in B.
Definition: ElementWise.hpp:3204
void sqrtInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of sqrt().
Definition: ElementWise.hpp:1415
void clampWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &C, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of clamp() to the given output tensor.
Definition: ElementWise.hpp:5388
void ltInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of lt().
Definition: ElementWise.hpp:3680
poplar::Tensor round(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Round each element in A.
Definition: ElementWise.hpp:1356
poplar::Tensor gt(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Check if each element in A is greater than the corresponding element in B.
Definition: ElementWise.hpp:2921
poplar::Tensor clamp(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &C, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Populate the returned tensor with elements from A but clamp them such that each element is greater th...
Definition: ElementWise.hpp:5361
poplar::Tensor tan(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the tangent of each element in A.
Definition: ElementWise.hpp:1264
void lteqInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of lteq().
Definition: ElementWise.hpp:3255
void bitwiseXnorWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of bitwiseXnor() to the given output tensor.
Definition: ElementWise.hpp:2446
poplar::Tensor logicalOr(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the logical OR (||) of each element in A with the corresponding element in B.
Definition: ElementWise.hpp:3487
void addWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of add() to the given output tensor.
Definition: ElementWise.hpp:1741
poplar::Tensor lt(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Check if each element in A is less than the corresponding element in B.
Definition: ElementWise.hpp:3629
poplar::Tensor cbrt(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the cube-root for each element in A.
Definition: ElementWise.hpp:477
void absInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of abs().
Definition: ElementWise.hpp:348
void mapWithOutput(poplar::Graph &graph, const expr::Expr &expr, const std::vector< poplar::Tensor > &ts, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of map() to the given output tensor.
void absWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of abs() to the given output tensor.
Definition: ElementWise.hpp:359
void bitwiseOrInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of bitwiseOr().
Definition: ElementWise.hpp:2129
void eqWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of eq() to the given output tensor.
Definition: ElementWise.hpp:2722
void expWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of exp() to the given output tensor.
Definition: ElementWise.hpp:779
void tanhInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of tanh().
Definition: ElementWise.hpp:1323
void shiftRightWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of shiftRight() to the given output tensor.
Definition: ElementWise.hpp:4814
poplar::Tensor rem(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the remainder of each element in A divided by the corresponding element in B.
Definition: ElementWise.hpp:4453
void outputGeneratedCodelet(const poplar::Target &target, const expr::Expr &expr, const std::vector< poplar::Tensor > &ts, const poplar::OptionFlags &options, std::ostream &os)
Writes the generated codelet for the given expr and ts to os.
void expm1WithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of expm1() to the given output tensor.
Definition: ElementWise.hpp:825
poplar::Tensor eq(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Check if each element in A is equal to the corresponding element in B.
Definition: ElementWise.hpp:2644
poplar::Tensor rsqrt(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the reciprocal square root for each element in A.
Definition: ElementWise.hpp:1540
void checkTypes(poplar::Type elementType, constType)
Check that the host compile-time type constType is compatible with the run-time IPU type elementType.
Definition: ElementWise.hpp:1622
void subWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of sub() to the given output tensor.
Definition: ElementWise.hpp:5098
void logicalAndInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of logicalAnd().
Definition: ElementWise.hpp:3396
void signumWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of signum() to the given output tensor.
Definition: ElementWise.hpp:1196
poplar::Tensor logicalAnd(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the logical AND (&&) of each element in A with the corresponding element in B.
Definition: ElementWise.hpp:3344
void gtWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of gt() to the given output tensor.
Definition: ElementWise.hpp:3001
void cbrtWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of cbrt() to the given output tensor.
Definition: ElementWise.hpp:501
poplar::Tensor atan2(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the two argument arctangent of each element in A with the corresponding element in B.
Definition: ElementWise.hpp:1799
poplar::Tensor bitwiseOr(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the bitwise OR of each element in A with the corresponding element in B.
Definition: ElementWise.hpp:2077
void ltWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of lt() to the given output tensor.
Definition: ElementWise.hpp:3708
void mulWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of mul() to the given output tensor.
Definition: ElementWise.hpp:4121
void logicalOrInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of logicalOr().
Definition: ElementWise.hpp:3539
poplar::Tensor varianceToInvStdDev(poplar::Graph &graph, const poplar::Tensor &src, const poplar::Tensor &epsilon, poplar::program::Sequence &prog, const poplar::Type dstType=poplar::HALF, const poplar::DebugContext &debugContext={})
Convert variance to inverse standard deviation.
void invInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of inv().
Definition: ElementWise.hpp:902
void mulInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of mul().
Definition: ElementWise.hpp:4093
poplar::Tensor bitwiseNot(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the bitwise NOT operation for each element in A.
Definition: ElementWise.hpp:429
poplar::Tensor invStdDevToVariance(poplar::Graph &graph, const poplar::Tensor &src, const poplar::Tensor &epsilon, poplar::program::Sequence &prog, const poplar::Type dstType=poplar::FLOAT, const poplar::DebugContext &debugContext={})
Convert inverse standard deviation to variance.
poplar::Tensor erf(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the error function of each element in A.
Definition: ElementWise.hpp:714
void divInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of div().
Definition: ElementWise.hpp:2558
void sinWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of sin() to the given output tensor.
Definition: ElementWise.hpp:1242
void asinWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of asin() to the given output tensor.
Definition: ElementWise.hpp:407
void logicalAndWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of logicalAnd() to the given output tensor.
Definition: ElementWise.hpp:3426
void negInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of neg().
Definition: ElementWise.hpp:1091
poplar::Tensor select(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &C, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Populate the returned tensor with elements from A or B depending on the corresponding element of C.
Definition: ElementWise.hpp:5305
void bitwiseXnorInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of bitwiseXnor().
Definition: ElementWise.hpp:2415
void remWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of rem() to the given output tensor.
Definition: ElementWise.hpp:4532
void clampInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &C, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of clamp().
Definition: ElementWise.hpp:5376
void sigmoidWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of sigmoid() to the given output tensor.
Definition: ElementWise.hpp:1518
void bitwiseAndInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of bitwiseAnd().
Definition: ElementWise.hpp:1987
poplar::Tensor bitwiseXor(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the bitwise XOR of each element in A with the corresponding element in B.
Definition: ElementWise.hpp:2219
poplar::Tensor mul(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Multiply each element in A by the corresponding element in B.
Definition: ElementWise.hpp:4042
void negWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of neg() to the given output tensor.
Definition: ElementWise.hpp:1102
poplar::Tensor cos(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the cosine of each element in A.
Definition: ElementWise.hpp:671
poplar::Tensor sqrt(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the square-root for each element in A.
Definition: ElementWise.hpp:1402
void divWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of div() to the given output tensor.
Definition: ElementWise.hpp:2586
void lteqWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of lteq() to the given output tensor.
Definition: ElementWise.hpp:3285
void bitwiseAndWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of bitwiseAnd() to the given output tensor.
Definition: ElementWise.hpp:2017
poplar::Tensor tanh(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the hyperbolic tangent of each element in A.
Definition: ElementWise.hpp:1310
void ceilInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of ceil().
Definition: ElementWise.hpp:584
poplar::Tensor map(poplar::Graph &graph, const expr::Expr &expr, const std::vector< poplar::Tensor > &ts, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Map an expression across tensors.
void gtInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of gt().
Definition: ElementWise.hpp:2972
void atan2WithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of atan2() to the given output tensor.
Definition: ElementWise.hpp:1878
void varianceToInvStdDevInPlace(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &B, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of varianceToInvStdDev().
Definition: ElementWise.hpp:5209
void popcountWithOutput(poplar::Graph &graph, const poplar::Tensor &A, const poplar::Tensor &out, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Write the result of popcount() to the given output tensor.
Definition: ElementWise.hpp:1148
poplar::Tensor expm1(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Compute the exponential of each element in A minus one.
Definition: ElementWise.hpp:801
void squareInPlace(poplar::Graph &graph, const poplar::Tensor &A, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={}, const poplar::OptionFlags &options={})
Update the input tensor with the result of square().
Definition: ElementWise.hpp:1461
General utility functions for building graphs.
Definition: GfloatExprUtil.hpp:23
Template structure to relate a host type to a device type.
Definition: Type.hpp:192