Added support for NChannelImage pattern and ExtendToNChannel patterngene...