make the logic consistent with shape_inference.cc
make the logic consistent with shape_inference.cc

DavidNorman/tensorflow,tensorflow/tensorflow,Intel-tensorflow/tensorflow,renyi533/tensorflow,chemelnucfin/tensorflow,gunan/tensorflow,xzturn/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,gautam1858/tensorflow,adit-chandra/tensorflow,annarev/tensorflow,Intel-Corporation/tensorflow,cxxgtxy/tensorflow,sarvex/tensorflow,chemelnucfin/tensorflow,DavidNorman/tensorflow,Intel-tensorflow/tensorflow,karllessard/tensorflow,annarev/tensorflow,adit-chandra/tensorflow,annarev/tensorflow,arborh/tensorflow,karllessard/tensorflow,aldian/tensorflow,karllessard/tensorflow,freedomtan/tensorflow,alsrgv/tensorflow,chemelnucfin/tensorflow,tensorflow/tensorflow-pywrap_saved_model,arborh/tensorflow,renyi533/tensorflow,alsrgv/tensorflow,tensorflow/tensorflow,gunan/tensorflow,tensorflow/tensorflow,gautam1858/tensorflow,Intel-tensorflow/tensorflow,yongtang/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,gunan/tensorflow,tensorflow/tensorflow,alsrgv/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,aam-at/tensorflow,chemelnucfin/tensorflow,renyi533/tensorflow,DavidNorman/tensorflow,Intel-tensorflow/tensorflow,annarev/tensorflow,gautam1858/tensorflow,paolodedios/tensorflow,xzturn/tensorflow,petewarden/tensorflow,DavidNorman/tensorflow,karllessard/tensorflow,frreiss/tensorflow-fred,gautam1858/tensorflow,tensorflow/tensorflow-pywrap_saved_model,frreiss/tensorflow-fred,tensorflow/tensorflow-pywrap_tf_optimizer,Intel-tensorflow/tensorflow,tensorflow/tensorflow-pywrap_saved_model,xzturn/tensorflow,gunan/tensorflow,alsrgv/tensorflow,DavidNorman/tensorflow,jhseu/tensorflow,tensorflow/tensorflow-pywrap_saved_model,Intel-tensorflow/tensorflow,paolodedios/tensorflow,aam-at/tensorflow,adit-chandra/tensorflow,frreiss/tensorflow-fred,xzturn/tensorflow,gautam1858/tensorflow,karllessard/tensorflow,paolodedios/tensorflow,aldian/tensorflow,sarvex/tensorflow,ppwwyyxx/tensorflow,frreiss/tensorflow-fred,gautam1858/tensorflow,sarvex/tensorflow,jhseu/tensorflow,arborh/tensorflow,xzturn/tensorflow,jhseu/tensorflow,DavidNorman/tensorflow,tensorflow/tensorflow,jhseu/tensorflow,xzturn/tensorflow,renyi533/tensorflow,ppwwyyxx/tensorflow,petewarden/tensorflow,Intel-Corporation/tensorflow,freedomtan/tensorflow,aam-at/tensorflow,sarvex/tensorflow,freedomtan/tensorflow,frreiss/tensorflow-fred,yongtang/tensorflow,yongtang/tensorflow,jhseu/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,aldian/tensorflow,davidzchen/tensorflow,Intel-Corporation/tensorflow,petewarden/tensorflow,adit-chandra/tensorflow,adit-chandra/tensorflow,DavidNorman/tensorflow,ppwwyyxx/tensorflow,chemelnucfin/tensorflow,davidzchen/tensorflow,cxxgtxy/tensorflow,tensorflow/tensorflow,gunan/tensorflow,gautam1858/tensorflow,freedomtan/tensorflow,freedomtan/tensorflow,ppwwyyxx/tensorflow,yongtang/tensorflow,frreiss/tensorflow-fred,tensorflow/tensorflow-experimental_link_static_libraries_once,aldian/tensorflow,gautam1858/tensorflow,petewarden/tensorflow,jhseu/tensorflow,xzturn/tensorflow,xzturn/tensorflow,ppwwyyxx/tensorflow,petewarden/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,tensorflow/tensorflow-pywrap_saved_model,jhseu/tensorflow,arborh/tensorflow,annarev/tensorflow,tensorflow/tensorflow,karllessard/tensorflow,Intel-Corporation/tensorflow,freedomtan/tensorflow,yongtang/tensorflow,aam-at/tensorflow,chemelnucfin/tensorflow,ppwwyyxx/tensorflow,tensorflow/tensorflow-pywrap_saved_model,tensorflow/tensorflow,gunan/tensorflow,ppwwyyxx/tensorflow,jhseu/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,gunan/tensorflow,renyi533/tensorflow,davidzchen/tensorflow,aldian/tensorflow,DavidNorman/tensorflow,davidzchen/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,davidzchen/tensorflow,freedomtan/tensorflow,annarev/tensorflow,adit-chandra/tensorflow,adit-chandra/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,DavidNorman/tensorflow,renyi533/tensorflow,annarev/tensorflow,gunan/tensorflow,petewarden/tensorflow,Intel-tensorflow/tensorflow,adit-chandra/tensorflow,Intel-tensorflow/tensorflow,sarvex/tensorflow,DavidNorman/tensorflow,petewarden/tensorflow,ppwwyyxx/tensorflow,sarvex/tensorflow,davidzchen/tensorflow,ppwwyyxx/tensorflow,Intel-Corporation/tensorflow,paolodedios/tensorflow,renyi533/tensorflow,yongtang/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,paolodedios/tensorflow,yongtang/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,paolodedios/tensorflow,alsrgv/tensorflow,ppwwyyxx/tensorflow,frreiss/tensorflow-fred,renyi533/tensorflow,alsrgv/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,petewarden/tensorflow,Intel-tensorflow/tensorflow,freedomtan/tensorflow,arborh/tensorflow,xzturn/tensorflow,arborh/tensorflow,renyi533/tensorflow,arborh/tensorflow,gunan/tensorflow,petewarden/tensorflow,tensorflow/tensorflow-pywrap_saved_model,tensorflow/tensorflow,aam-at/tensorflow,petewarden/tensorflow,adit-chandra/tensorflow,frreiss/tensorflow-fred,yongtang/tensorflow,xzturn/tensorflow,aam-at/tensorflow,xzturn/tensorflow,alsrgv/tensorflow,tensorflow/tensorflow,Intel-Corporation/tensorflow,karllessard/tensorflow,aldian/tensorflow,DavidNorman/tensorflow,cxxgtxy/tensorflow,alsrgv/tensorflow,paolodedios/tensorflow,jhseu/tensorflow,aam-at/tensorflow,jhseu/tensorflow,alsrgv/tensorflow,davidzchen/tensorflow,yongtang/tensorflow,chemelnucfin/tensorflow,aam-at/tensorflow,Intel-tensorflow/tensorflow,cxxgtxy/tensorflow,Intel-tensorflow/tensorflow,tensorflow/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,freedomtan/tensorflow,cxxgtxy/tensorflow,karllessard/tensorflow,aldian/tensorflow,freedomtan/tensorflow,gautam1858/tensorflow,aam-at/tensorflow,karllessard/tensorflow,davidzchen/tensorflow,arborh/tensorflow,aam-at/tensorflow,chemelnucfin/tensorflow,petewarden/tensorflow,davidzchen/tensorflow,frreiss/tensorflow-fred,alsrgv/tensorflow,chemelnucfin/tensorflow,frreiss/tensorflow-fred,tensorflow/tensorflow-pywrap_tf_optimizer,adit-chandra/tensorflow,adit-chandra/tensorflow,davidzchen/tensorflow,petewarden/tensorflow,gunan/tensorflow,cxxgtxy/tensorflow,arborh/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,freedomtan/tensorflow,ppwwyyxx/tensorflow,paolodedios/tensorflow,alsrgv/tensorflow,gautam1858/tensorflow,aldian/tensorflow,annarev/tensorflow,karllessard/tensorflow,karllessard/tensorflow,arborh/tensorflow,davidzchen/tensorflow,arborh/tensorflow,tensorflow/tensorflow-pywrap_saved_model,DavidNorman/tensorflow,paolodedios/tensorflow,aam-at/tensorflow,renyi533/tensorflow,ppwwyyxx/tensorflow,chemelnucfin/tensorflow,gunan/tensorflow,annarev/tensorflow,cxxgtxy/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,Intel-Corporation/tensorflow,renyi533/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,yongtang/tensorflow,freedomtan/tensorflow,chemelnucfin/tensorflow,Intel-Corporation/tensorflow,frreiss/tensorflow-fred,yongtang/tensorflow,paolodedios/tensorflow,chemelnucfin/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,sarvex/tensorflow,jhseu/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,tensorflow/tensorflow-experimental_link_static_libraries_once,renyi533/tensorflow,tensorflow/tensorflow-pywrap_saved_model,xzturn/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,gautam1858/tensorflow,jhseu/tensorflow,davidzchen/tensorflow,annarev/tensorflow,aam-at/tensorflow,alsrgv/tensorflow,gunan/tensorflow,frreiss/tensorflow-fred,sarvex/tensorflow,tensorflow/tensorflow-pywrap_saved_model,tensorflow/tensorflow-pywrap_saved_model,cxxgtxy/tensorflow,arborh/tensorflow,annarev/tensorflow,gautam1858/tensorflow,paolodedios/tensorflow,adit-chandra/tensorflow