Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
P
pytensor
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
testgroup
pytensor
Commits
151da532
提交
151da532
authored
12月 06, 2022
作者:
Brandon T. Willard
提交者:
Thomas Wiecki
12月 10, 2022
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Update pre-commit
上级
a30f815f
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
7 行增加
和
6 行删除
+7
-6
.pre-commit-config.yaml
.pre-commit-config.yaml
+3
-2
op.py
pytensor/scan/op.py
+4
-4
没有找到文件。
.pre-commit-config.yaml
浏览文件 @
151da532
...
...
@@ -7,7 +7,7 @@ exclude: |
)$
repos
:
-
repo
:
https://github.com/pre-commit/pre-commit-hooks
rev
:
v4.
3
.0
rev
:
v4.
4
.0
hooks
:
-
id
:
debug-statements
exclude
:
|
...
...
@@ -25,9 +25,10 @@ repos:
-
id
:
black
language_version
:
python3
-
repo
:
https://github.com/pycqa/flake8
rev
:
5.0.4
rev
:
6.0.0
hooks
:
-
id
:
flake8
language_version
:
python39
-
repo
:
https://github.com/pycqa/isort
rev
:
5.10.1
hooks
:
...
...
pytensor/scan/op.py
浏览文件 @
151da532
...
...
@@ -54,6 +54,7 @@ from typing import Callable, List, Optional, Union
import
numpy
as
np
import
pytensor
import
pytensor.link.utils
as
link_utils
from
pytensor
import
tensor
as
at
from
pytensor.compile.builders
import
construct_nominal_fgraph
,
infer_shape
from
pytensor.compile.function.pfunc
import
pfunc
...
...
@@ -75,7 +76,6 @@ from pytensor.graph.replace import clone_replace
from
pytensor.graph.utils
import
InconsistencyError
,
MissingInputError
from
pytensor.link.c.basic
import
CLinker
from
pytensor.link.c.exceptions
import
MissingGXX
from
pytensor.link.utils
import
raise_with_op
from
pytensor.printing
import
op_debug_information
from
pytensor.scan.utils
import
ScanProfileStats
,
Validator
,
forced_replace
,
safe_new
from
pytensor.tensor.basic
import
as_tensor_variable
...
...
@@ -1627,7 +1627,7 @@ class Scan(Op, ScanMethodsMixin, HasInnerGraph):
if
hasattr
(
self
.
fn
.
vm
,
"position_of_error"
)
and
hasattr
(
self
.
fn
.
vm
,
"thunks"
):
raise_with_op
(
link_utils
.
raise_with_op
(
self
.
fn
.
maker
.
fgraph
,
self
.
fn
.
vm
.
nodes
[
self
.
fn
.
vm
.
position_of_error
],
self
.
fn
.
vm
.
thunks
[
self
.
fn
.
vm
.
position_of_error
],
...
...
@@ -1930,7 +1930,7 @@ class Scan(Op, ScanMethodsMixin, HasInnerGraph):
# done by raise_with_op is not implemented in C.
if
hasattr
(
vm
,
"thunks"
):
# For the CVM
raise_with_op
(
link_utils
.
raise_with_op
(
self
.
fn
.
maker
.
fgraph
,
vm
.
nodes
[
vm
.
position_of_error
],
vm
.
thunks
[
vm
.
position_of_error
],
...
...
@@ -1940,7 +1940,7 @@ class Scan(Op, ScanMethodsMixin, HasInnerGraph):
# We don't have access from python to all the
# temps values So for now, we just don't print
# the extra shapes/strides info
raise_with_op
(
link_utils
.
raise_with_op
(
self
.
fn
.
maker
.
fgraph
,
vm
.
nodes
[
vm
.
position_of_error
]
)
else
:
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论