"use strict";(self.webpackChunkrspress_doc_template=self.webpackChunkrspress_doc_template||[]).push([["8824"],{32241:function(e,n,r){r.r(n);var s=r(85893),a=r(50065);function i(e){let n=Object.assign({h1:"h1",a:"a",pre:"pre",code:"code",span:"span",p:"p"},(0,a.ah)(),e.components);return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsxs)(n.h1,{id:"rgb2gray",children:[(0,s.jsx)(n.a,{className:"header-anchor","aria-hidden":"true",href:"#rgb2gray",children:"#"}),"rgb2gray"]}),"\n",(0,s.jsx)(n.pre,{className:"code",children:(0,s.jsx)(n.pre,{className:"shiki css-variables has-line-number",style:{backgroundColor:"var(--shiki-color-background)"},tabIndex:"0",children:(0,s.jsxs)(n.code,{className:"language-python",meta:"",children:[(0,s.jsxs)(n.span,{className:"line line-number",children:[(0,s.jsx)(n.span,{style:{color:"var(--shiki-color-text)"},children:"horizon_plugin_pytorch"}),(0,s.jsx)(n.span,{style:{color:"var(--shiki-token-punctuation)"},children:"."}),(0,s.jsx)(n.span,{style:{color:"var(--shiki-token-function)"},children:"rgb2gray "}),(0,s.jsx)(n.span,{style:{color:"var(--shiki-token-punctuation)"},children:"("}),(0,s.jsx)(n.span,{style:{color:"var(--shiki-token-function)"},children:"input"}),(0,s.jsx)(n.span,{style:{color:"var(--shiki-token-punctuation)"},children:": Tensor)"})]}),"\n"]})})}),"\n",(0,s.jsx)(n.p,{children:"Convert color space."}),"\n",(0,s.jsx)(n.p,{children:"Convert images from RGB format to gray"}),"\n",(0,s.jsx)(n.p,{children:"Parameters: input (Tensor) \u2013 input image in RGB format of shape [N, 3, H, W], ranging 0 to 255"}),"\n",(0,s.jsx)(n.p,{children:"Returns: gray image of shape [N, 1, H, W], ranging 0 to 255"}),"\n",(0,s.jsx)(n.p,{children:"Return type: Tensor"})]})}function o(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{wrapper:n}=Object.assign({},(0,a.ah)(),e.components);return n?(0,s.jsx)(n,Object.assign({},e,{children:(0,s.jsx)(i,e)})):i(e)}n.default=o,o.__RSPRESS_PAGE_META={},o.__RSPRESS_PAGE_META["latest%2Fzh%2Fguide%2Fplugin%2Fplugin_api_reference%2Fhorizon_operator%2Fhorizon_plugin_pytorch_rgb2gray.md"]={toc:[],title:"rgb2gray",frontmatter:{}}}}]);