提交 4721113b authored 作者: Razvan Pascanu's avatar Razvan Pascanu

removed useless step

at make_thunk we don't actually have access to the memory buffer to be able to do such things .. those have to be done at runtime
上级 93978136
...@@ -188,14 +188,8 @@ class ScanOp(PureOp): ...@@ -188,14 +188,8 @@ class ScanOp(PureOp):
node_output_storage = [storage_map[r] for r in node.outputs] node_output_storage = [storage_map[r] for r in node.outputs]
node_input_compute = [compute_map[r] for r in node.inputs] node_input_compute = [compute_map[r] for r in node.inputs]
node_output_compute = [compute_map[r] for r in node.outputs] node_output_compute = [compute_map[r] for r in node.outputs]
# 2. If the op is not inplace we need to copy over the initial values
if not self.inplace: # 2. Construct fake shared variables around every argument of scan
for membuf1, membuf2 in izip(
node_output_storage,
node_input_storage[1: 1 + len(node_output_storage)]):
membuf1[0][:] = membuf2[0]
# 3. Construct fake shared variables around every argument of scan
givens = {} givens = {}
base_inputs = self.inputs[:len(self.outputs)] base_inputs = self.inputs[:len(self.outputs)]
aux_inputs = self.inputs[len(self.outputs):] aux_inputs = self.inputs[len(self.outputs):]
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论