count_channelscount_channelsCountChannelsCountChannelscount_channels (算子名称)
名称
count_channelscount_channelsCountChannelsCountChannelscount_channels — Count channels of image.
参数签名
描述
该算子 count_channelscount_channelsCountChannelsCountChannelsCountChannelscount_channels counts the number of
channels of all input images.
运行信息
- Supports objects on compute devices.
- 多线程类型:可重入(与非独占操作符并行运行)。
- 多线程作用域:全局(可以从任何线程调用)。
- 未经并行化处理。
参数表
MultiChannelImageMultiChannelImageMultiChannelImageMultiChannelImagemultiChannelImagemulti_channel_image (input_object) (multichannel-)image(-array) → objectHImageHObjectHImageHobject (byte / direction / cyclic / int1 / int2 / uint2 / int4 / int8 / real / complex / vector_field)
One- or multi-channel image.
ChannelsChannelsChannelsChannelschannelschannels (output_control) integer(-array) → HTupleSequence[int]HTupleHtuple (integer) (int / long) (Hlong) (Hlong)
Number of channels.
例程 (C)
read_image(&Color,"patras");
count_channels(Color,&num_channels);
for (i=1; i<=num_channels; i++)
{
access_channel(Color,&Channel,i);
disp_image(Channel,WindowHandle);
clear_obj(Channel);
}
可能的后置算子
access_channelaccess_channelAccessChannelAccessChannelAccessChannelaccess_channel,
append_channelappend_channelAppendChannelAppendChannelAppendChannelappend_channel,
disp_imagedisp_imageDispImageDispImageDispImagedisp_image
参考其它
append_channelappend_channelAppendChannelAppendChannelAppendChannelappend_channel,
access_channelaccess_channelAccessChannelAccessChannelAccessChannelaccess_channel
模块
Foundation