From commits-return-11185-archive-asf-public=cust-asf.ponee.io@tvm.apache.org Sun Apr 12 07:45:50 2020 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [207.244.88.153]) by mx-eu-01.ponee.io (Postfix) with SMTP id 40D2E180608 for ; Sun, 12 Apr 2020 09:45:50 +0200 (CEST) Received: (qmail 45957 invoked by uid 500); 12 Apr 2020 07:45:49 -0000 Mailing-List: contact commits-help@tvm.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@tvm.apache.org Delivered-To: mailing list commits@tvm.apache.org Received: (qmail 45947 invoked by uid 99); 12 Apr 2020 07:45:49 -0000 Received: from ec2-52-202-80-70.compute-1.amazonaws.com (HELO gitbox.apache.org) (52.202.80.70) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 12 Apr 2020 07:45:49 +0000 From: GitBox To: commits@tvm.apache.org Subject: [GitHub] [incubator-tvm] jwfromm commented on a change in pull request #5284: [Topi] Tensorcore support for Conv3D Message-ID: <158667754914.1068.7812936671813650476.gitbox@gitbox.apache.org> References: In-Reply-To: Date: Sun, 12 Apr 2020 07:45:49 -0000 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit jwfromm commented on a change in pull request #5284: [Topi] Tensorcore support for Conv3D URL: https://github.com/apache/incubator-tvm/pull/5284#discussion_r407161101 ########## File path: python/tvm/relay/op/nn/_nn.py ########## @@ -139,13 +139,17 @@ def convert_conv2d(attrs, inputs, tinfos, desired_layout): # pylint: disable=import-outside-toplevel from tvm import relay data, weight = inputs - assert desired_layout == 'NCHW', \ - "Currently only transformation to NCHW layout is supported." + new_attrs = dict(attrs) if desired_layout == 'NCHW': - new_attrs = dict(attrs) new_attrs['data_layout'] = desired_layout new_attrs['kernel_layout'] = 'OIHW' return relay.nn.conv2d(data, weight, **new_attrs) + elif desired_layout == 'NHWC': + new_attrs['data_layout'] = desired_layout + new_attrs['kernel_layout'] = 'HWIO' Review comment: Good point, I added a depthwise check here. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: users@infra.apache.org With regards, Apache Git Services