提交 99014933 authored 作者: Frederic's avatar Frederic

Better name. Otherwise, we don't know if this is a None instance or Theano obj

上级 3757de67
...@@ -66,10 +66,9 @@ class NoneTypeT(Generic): ...@@ -66,10 +66,9 @@ class NoneTypeT(Generic):
else: else:
raise TypeError('Expected None!') raise TypeError('Expected None!')
def __str__(self): none_type_t = NoneTypeT()
return "None"
# This is a variable instance. It can be used only once per fgraph. # This is a variable instance. It can be used only once per fgraph.
# So use NoneConst.clone() before using it in a Theano graph. # So use NoneConst.clone() before using it in a Theano graph.
# Use NoneConst.equal(x) to check if two variable are NoneConst. # Use NoneConst.equal(x) to check if two variable are NoneConst.
NoneConst = Constant(NoneTypeT(), None, name='None') NoneConst = Constant(NoneTypeT(), None, name='NoneConst')
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论