Skip to content

Commit d3fc623

Browse files
committed
Fixed placeholder docstrings for logical operations
1 parent 47e61de commit d3fc623

File tree

1 file changed

+18
-21
lines changed

1 file changed

+18
-21
lines changed

dpctl/tensor/_elementwise_funcs.py

Lines changed: 18 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -573,16 +573,16 @@
573573

574574
# B16: ==== LOGICAL_AND (x1, x2)
575575
_logical_and_docstring_ = """
576-
multiply(x1, x2, out=None, order='K')
576+
logical_and(x1, x2, out=None, order='K')
577577
578-
Calculates the product for each element `x1_i` of the input array `x1`
578+
Computes the logical AND for each element `x1_i` of the input array `x1`
579579
with the respective element `x2_i` of the input array `x2`.
580580
581581
Args:
582582
x1 (usm_ndarray):
583-
First input array, expected to have numeric data type.
583+
First input array.
584584
x2 (usm_ndarray):
585-
Second input array, also expected to have numeric data type.
585+
Second input array.
586586
out ({None, usm_ndarray}, optional):
587587
Output array to populate.
588588
Array have the correct shape and the expected data type.
@@ -591,8 +591,7 @@
591591
Default: "K".
592592
Returns:
593593
usm_narray:
594-
An array containing the element-wise products. The data type of
595-
the returned array is determined by the Type Promotion Rules.
594+
An array containing the element-wise logical AND results.
596595
"""
597596
logical_and = BinaryElementwiseFunc(
598597
"logical_and",
@@ -604,10 +603,10 @@
604603
# U24: ==== LOGICAL_NOT (x)
605604
_logical_not_docstring = """
606605
log(x, out=None, order='K')
607-
Computes the natural logarithm element-wise.
606+
Computes the logical NOT for each element `x_i` of input array `x`.
608607
Args:
609608
x (usm_ndarray):
610-
Input array, expected to have numeric data type.
609+
Input array.
611610
out (usm_ndarray):
612611
Output array to populate. Array must have the correct
613612
shape and the expected data type.
@@ -616,7 +615,7 @@
616615
Default: "K".
617616
Return:
618617
usm_ndarray:
619-
An array containing the element-wise natural logarithm values.
618+
An array containing the element-wise logical NOT results.
620619
"""
621620

622621
logical_not = UnaryElementwiseFunc(
@@ -628,16 +627,16 @@
628627

629628
# B17: ==== LOGICAL_OR (x1, x2)
630629
_logical_or_docstring_ = """
631-
multiply(x1, x2, out=None, order='K')
630+
logical_or(x1, x2, out=None, order='K')
632631
633-
Calculates the product for each element `x1_i` of the input array `x1`
632+
Computes the logical OR for each element `x1_i` of the input array `x1`
634633
with the respective element `x2_i` of the input array `x2`.
635634
636635
Args:
637636
x1 (usm_ndarray):
638-
First input array, expected to have numeric data type.
637+
First input array.
639638
x2 (usm_ndarray):
640-
Second input array, also expected to have numeric data type.
639+
Second input array.
641640
out ({None, usm_ndarray}, optional):
642641
Output array to populate.
643642
Array have the correct shape and the expected data type.
@@ -646,8 +645,7 @@
646645
Default: "K".
647646
Returns:
648647
usm_narray:
649-
An array containing the element-wise products. The data type of
650-
the returned array is determined by the Type Promotion Rules.
648+
An array containing the element-wise logical OR results.
651649
"""
652650
logical_or = BinaryElementwiseFunc(
653651
"logical_or",
@@ -658,16 +656,16 @@
658656

659657
# B18: ==== LOGICAL_XOR (x1, x2)
660658
_logical_xor_docstring_ = """
661-
multiply(x1, x2, out=None, order='K')
659+
logical_xor(x1, x2, out=None, order='K')
662660
663-
Calculates the product for each element `x1_i` of the input array `x1`
661+
Computes the logical XOR for each element `x1_i` of the input array `x1`
664662
with the respective element `x2_i` of the input array `x2`.
665663
666664
Args:
667665
x1 (usm_ndarray):
668-
First input array, expected to have numeric data type.
666+
First input array.
669667
x2 (usm_ndarray):
670-
Second input array, also expected to have numeric data type.
668+
Second input array.
671669
out ({None, usm_ndarray}, optional):
672670
Output array to populate.
673671
Array have the correct shape and the expected data type.
@@ -676,8 +674,7 @@
676674
Default: "K".
677675
Returns:
678676
usm_narray:
679-
An array containing the element-wise products. The data type of
680-
the returned array is determined by the Type Promotion Rules.
677+
An array containing the element-wise logical XOR results.
681678
"""
682679
logical_xor = BinaryElementwiseFunc(
683680
"logical_xor",

0 commit comments

Comments
 (0)