当前位置:网站首页>numpy.logical_and()
numpy.logical_and()
2022-06-24 09:40:00 【Wanderer001】
参考 numpy.logical_and() - 云+社区 - 腾讯云
numpy.
logical_and
(x1, x2, /, out=None, *, where=True, casting='same_kind', order='K', dtype=None, subok=True[, signature, extobj]) = <ufunc 'logical_and'>
Compute the truth value of x1 AND x2 element-wise.
Parameters: | x1, x2 : array_like Input arrays. If out : ndarray, None, or tuple of ndarray and None, optional A location into which the result is stored. If provided, it must have a shape that the inputs broadcast to. If not provided or None, a freshly-allocated array is returned. A tuple (possible only as a keyword argument) must have length equal to the number of outputs. where : array_like, optional This condition is broadcast over the input. At locations where the condition is True, the out array will be set to the ufunc result. Elsewhere, the out array will retain its original value. Note that if an uninitialized out array is created via the default **kwargs For other keyword-only arguments, see the ufunc docs. |
---|---|
Returns: | y : ndarray or bool Boolean result of the logical OR operation applied to the elements of x1 and x2; the shape is determined by broadcasting. This is a scalar if both x1 and x2 are scalars. |
See also
logical_or, logical_not, logical_xor, bitwise_and
Examples
>>> np.logical_and(True, False)
False
>>> np.logical_and([True, False], [False, False])
array([False, False])
>>> x = np.arange(5)
>>> np.logical_and(x>1, x<4)
array([False, False, True, True, False])
边栏推荐
- Network of test and development - Common Service Protocols
- 416-二叉树(前中后序遍历—迭代法)
- 保健品一物一码防窜货营销软件开发
- SQL Sever关于like操作符(包括字段数据自动填充空格问题)
- canvas无限扫描js特效代码
- Basic operations on binary tree
- Go language development environment setup +goland configuration under the latest Windows
- 413-二叉树基础
- 十大证券公司哪个佣金最低,最安全可靠?有知道的吗
- canvas 绘制图片
猜你喜欢
canvas掉落的小球重力js特效动画
Geogebra instance clock
p5.js实现的炫酷交互式动画js特效
如何提高网络基础设施排障效率,告别数据断档?
Yolov6: the fast and accurate target detection framework is open source
上升的气泡canvas破碎动画js特效
Practical analysis: implementation principle of APP scanning code landing (app+ detailed logic on the web side) with source code
LeetCode: 240. Search 2D matrix II
How to solve multi-channel customer communication problems in independent stations? This cross-border e-commerce plug-in must be known!
Getting user information for applet learning (getuserprofile and getUserInfo)
随机推荐
CVPR 2022 Oral | 英伟达提出自适应token的高效视觉Transformer网络A-ViT,不重要的token可以提前停止计算
PHP encapsulates a file upload class (supports single file and multiple file uploads)
SVG+js拖拽滑块圆形进度条
Observer mode
411 stack and queue (20. valid parentheses, 1047. delete all adjacent duplicates in the string, 150. inverse Polish expression evaluation, 239. sliding window maximum, 347. the first k high-frequency
[input method] so far, there are so many Chinese character input methods!
2021-08-17
Prct-1400: failed to execute getcrshome resolution
读取csv(tsv)文件出错
Cicflowmeter source code analysis and modification to meet requirements
How does home office manage the data center network infrastructure?
Error reading CSV (TSV) file
411-栈和队列(20. 有效的括号、1047. 删除字符串中的所有相邻重复项、150. 逆波兰表达式求值、239. 滑动窗口最大值、347. 前 K 个高频元素)
PostgreSQL DBA快速入门-通过源码编译安装
Tutorial (5.0) 08 Fortinet security architecture integration and fortixdr * fortiedr * Fortinet network security expert NSE 5
Groovy obtains Jenkins credentials through withcredentials
Operator details
Jcim | AI based protein structure prediction in drug discovery: impacts and challenges
大中型企业如何构建自己的监控体系
Programming questions (continuously updated)