Home
last modified time | relevance | path

Searched full:floordiv (Results 1 – 25 of 264) sorted by relevance

1234567891011

/external/pytorch/test/
Dtest_dynamic_shapes.py46 FloorDiv,
233 operator.floordiv,
241 (op != operator.mod or op != operator.floordiv) and args[1][0] != 0
1463 # Note: we fully evaluate here since FloorDiv might not always do
1466 return shape_env.evaluate_expr(FloorDiv(x, y))
1494 # Tests how we simplify or evaluate FloorDiv without free variables
1497 exprs = (7 * FloorDiv(6, 2),)
1516 return FloorDiv(base, divisor)
1534 # In regular Python, x//x == 1.0 if x is a float, but FloorDiv
1705 dim_constraints.add(Ne(FloorDiv(s1, 2), 1))
[all …]
Dtest_sympy_utils.py17 from torch.utils._sympy.functions import FloorDiv, simple_floordiv_gcd
42 "truediv", "floordiv",
108 elif (fn in ["div", "truediv", "floordiv"]) and b == 0:
402 elif fn == "floordiv" and args[1] == 0:
454 Eq(FloorDiv(a, b), c),
456 Ne(FloorDiv(a, b), c),
572 # (Eq(FloorDiv(a, pos), integer), And(Ge(a, integer * pos), Lt(a, (integer + 1) * pos))),
573 … # (Eq(FloorDiv(a + 5, pos), integer), And(Ge(a, integer * pos), Lt(a, (integer + 1) * pos))),
574 # (Ne(FloorDiv(a, pos), integer), Or(Lt(a, integer * pos), Ge(a, (integer + 1) * pos))),
577 # 'FloorDiv' turns into 'And', which can't be simplified any further.
[all …]
/external/tensorflow/tensorflow/core/kernels/mlir_generated/
Dgpu_op_floor_div.cc24 GENERATE_AND_REGISTER_BINARY_JIT_GPU_KERNEL(FloorDiv, DT_INT8);
25 GENERATE_AND_REGISTER_BINARY_JIT_GPU_KERNEL(FloorDiv, DT_UINT32);
26 GENERATE_AND_REGISTER_BINARY_JIT_GPU_KERNEL(FloorDiv, DT_UINT64);
28 GENERATE_AND_REGISTER_BINARY_GPU_KERNEL(FloorDiv, DT_INT16);
29 GENERATE_AND_REGISTER_BINARY_GPU_KERNEL(FloorDiv, DT_INT64);
31 GENERATE_AND_REGISTER_BINARY_GPU_KERNEL(FloorDiv, DT_HALF);
32 GENERATE_AND_REGISTER_BINARY_GPU_KERNEL(FloorDiv, DT_FLOAT);
33 GENERATE_AND_REGISTER_BINARY_GPU_KERNEL(FloorDiv, DT_DOUBLE);
Dgpu_op_div.cc47 REGISTER_ALIASED_GPU_KERNEL(FloorDiv, Div, DT_UINT8, DT_UINT8);
48 REGISTER_ALIASED_GPU_KERNEL(FloorDiv, Div, DT_UINT16, DT_UINT16);
/external/pytorch/test/inductor/
Dtest_indexing.py22 FloorDiv,
57 # if there are negative terms in ModularIndexing base, we cannot replace it with FloorDiv
65 sizevars.simplify_with_ranges(FloorDiv(r3 + i2 + i1, 32), var_ranges),
66 FloorDiv(r3 + i2 + i1, 32),
74 self.assertEqual(FloorDiv(r3 * i0, r3), i0)
102 self.assertEqual(FloorDiv(i0 * 4, 2), i0 * 2)
112 expected = FloorDiv(ModularIndexing(i2, 1, 28), 7)
159 # works for ModularIndexing + FloorDiv
160 expr5 = 197 * FloorDiv(i0, 197) + ModularIndexing(i0, 1, 197)
172 expr6 = 197 * FloorDiv(i0, 197 * 3) + ModularIndexing(i0, 3, 197)
[all …]
/external/tensorflow/tensorflow/core/kernels/
Dcwise_op_floor_div.cc20 REGISTER8(BinaryOp, CPU, "FloorDiv", functor::safe_floor_div, uint8, uint16,
22 REGISTER4(BinaryOp, CPU, "FloorDiv", functor::floor_div_real, float,
27 REGISTER4(BinaryOp, GPU, "FloorDiv", functor::floor_div, uint8, uint16, int16,
29 REGISTER3(BinaryOp, GPU, "FloorDiv", functor::floor_div_real, float,
38 REGISTER_KERNEL_BUILDER(Name("FloorDiv")
46 REGISTER_KERNEL_BUILDER(Name("FloorDiv")
/external/pytorch/c10/util/
Dgeneric_math.h47 scalar_t floordiv; in div_floor_floating() local
49 floordiv = std::floor(div); in div_floor_floating()
50 if (div - floordiv > scalar_t(0.5)) { in div_floor_floating()
51 floordiv += scalar_t(1.0); in div_floor_floating()
54 floordiv = C10_COMPAT_COPYSIGN(scalar_t(0), a / b); in div_floor_floating()
56 return floordiv; in div_floor_floating()
/external/threetenbp/src/main/java/org/threeten/bp/jdk8/
DJdk8Methods.java294 * This returns {@code 0} for {@code floorDiv(0, 4)}.<br />
295 * This returns {@code -1} for {@code floorDiv(-1, 4)}.<br />
296 * This returns {@code -1} for {@code floorDiv(-2, 4)}.<br />
297 * This returns {@code -1} for {@code floorDiv(-3, 4)}.<br />
298 * This returns {@code -1} for {@code floorDiv(-4, 4)}.<br />
299 * This returns {@code -2} for {@code floorDiv(-5, 4)}.<br />
305 public static long floorDiv(long a, long b) { in floorDiv() method in Jdk8Methods
347 * This returns {@code 1} for {@code floorDiv(3, 3)}.<br />
348 * This returns {@code 0} for {@code floorDiv(2, 3)}.<br />
349 * This returns {@code 0} for {@code floorDiv(1, 3)}.<br />
[all …]
/external/pytorch/aten/src/ATen/native/cuda/
DBinaryDivFloorKernel.cu57 scalar_t floordiv; in div_floor_kernel_cuda()
59 floordiv = std::floor(div); in div_floor_kernel_cuda()
60 if (div - floordiv > scalar_t(0.5)) { in div_floor_kernel_cuda()
61 floordiv += scalar_t(1.0); in div_floor_kernel_cuda()
64 floordiv = c10::cuda::compat::copysign(scalar_t(0), a * inv_b); in div_floor_kernel_cuda()
66 return floordiv; in div_floor_kernel_cuda()
/external/tensorflow/tensorflow/core/ops/compat/ops_history_v2/
DFloorDiv.pbtxt2 name: "FloorDiv"
36 name: "FloorDiv"
71 name: "FloorDiv"
106 name: "FloorDiv"
/external/tensorflow/tensorflow/core/ops/compat/ops_history_v1/
DFloorDiv.pbtxt2 name: "FloorDiv"
36 name: "FloorDiv"
71 name: "FloorDiv"
/external/pytorch/torch/utils/_sympy/
Dinterp.py25 FloorDiv,
70 FloorDiv: "floordiv",
71 CleanDiv: "floordiv", # TODO: hmm?
89 # FloorDiv in a bigger cleanup
Dreference.py12 FloorDiv,
133 def floordiv(a, b): member in ReferenceAnalysis
134 return FloorDiv(a, b)
209 def floordiv(a, b): member in PythonReferenceAnalysis
Dsolve.py6 from torch.utils._sympy.functions import FloorDiv
39 # 'floordiv_inequality': flag to enable conversion of 'FloorDiv' into
132 # left-hand side is FloorDiv
142 and isinstance(e.lhs, FloorDiv)
/external/tensorflow/tensorflow/core/api_def/java_api/
Dapi_def_FloorDiv.pbtxt2 graph_op_name: "FloorDiv"
4 name: "math.FloorDiv"
/external/executorch/exir/passes/
Dexecutorch_prim_ops_registry.py43 executorch_prims_lib, "floordiv.Scalar(Scalar a, Scalar b) -> Scalar"
45 def floordiv(a: _SymScalar, b: _SymScalar) -> _SymScalar: function
120 operator.floordiv: ops.backend.executorch_prim.floordiv.Scalar,
/external/opencensus-java/api/src/main/java/io/opencensus/common/
DTimestamp.java86 long secs = floorDiv(epochMilli, MILLIS_PER_SECOND); in fromMillis()
186 long secs = TimeUtils.checkedAdd(epochSecond, floorDiv(nanoAdjustment, NANOS_PER_SECOND)); in ofEpochSecond()
192 private static long floorDiv(long x, long y) { in floorDiv() method in Timestamp
196 // Returns the floor modulus "x - (floorDiv(x, y) * y)"
198 return x - floorDiv(x, y) * y; in floorMod()
/external/tensorflow/tensorflow/core/api_def/base_api/
Dapi_def_FloorDiv.pbtxt2 graph_op_name: "FloorDiv"
5 *NOTE*: `FloorDiv` supports broadcasting. More about broadcasting
/external/pytorch/torch/_inductor/
Dsizevars.py23 from torch.utils._sympy.functions import FloorDiv, ModularIndexing
198 return FloorDiv(remove_zero_terms(base, divisor), divisor)
208 return FloorDiv(base, divisor)
221 if expr.has(FloorDiv):
223 FloorDiv(
727 Expand the FloorDiv to the entire expression so that the expression may
733 By expanding the FloorDiv to the entire expression, we get
770 elif isinstance(term, FloorDiv):
779 # can not handle multi FloorDiv yet
817 ModularIndexing(i0, 1, 32) + 32 * FloorDiv(i0, 32)
[all …]
/external/tensorflow/tensorflow/core/transforms/constant_folding/tests/
Dneutral_element.mlir57 // CHECK: FloorDiv{{.*}} name("floordiv")
58 …%FloorDiv, %ctl_47 = FloorDiv(%Placeholder, %Fill_28) name("floordiv") {T = f32} : (tensor<2x2xf32…
83 …ul, %Mul_31, %Mul_37, %Mul_39, %MulNoNan, %MulNoNan_42, %Div, %Div_45, %FloorDiv, %MatMul, %MatMul…
/external/angle/third_party/r8/
Dbackported_methods.txt54 java/lang/Math#floorDiv(II)I
55 java/lang/Math#floorDiv(JI)J
56 java/lang/Math#floorDiv(JJ)J
81 java/lang/StrictMath#floorDiv(II)I
82 java/lang/StrictMath#floorDiv(JI)J
83 java/lang/StrictMath#floorDiv(JJ)J
/external/tensorflow/tensorflow/python/kernel_tests/math_ops/
Ddivision_past_test.py63 floordiv = x // y
65 check(floordiv, tf_floordiv)
Ddivision_future_test.py60 floordiv = x // y
62 check(floordiv, tf_floordiv)
/external/pytorch/torch/fx/experimental/
Dvalidator.py177 # Python semantics for 'FloorDiv' states that before applying the floor
179 def floordiv(self, numerator: z3.ArithRef, denominator: z3.ArithRef) -> z3.ArithRef: member in _Z3Ops
199 # Python semantics for 'Mod' is defined as: p % q = p - floordiv(p, q) * q
202 return p - self.floordiv(p, q) * q
282 operator.floordiv: lift(ops.floordiv),
378 def floordiv(self, numerator: z3.ArithRef, denominator: z3.ArithRef) -> z3.ArithRef: member in SympyToZ3
379 return self._ops.floordiv(numerator, denominator)
382 return self._ops.floordiv(numerator, denominator)
/external/pytorch/torch/csrc/jit/frontend/
Dbuiltin_functions.cpp44 auto floordiv = at::jit::CodeTemplate( variable
46 def floordiv(self : Tensor, other : ${Rhs_Type}) -> Tensor:
164 loadSource(floordiv.format(env), "aten"); in loadBuiltinFunctions()

1234567891011