Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
loopy
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Andreas Klöckner
loopy
Commits
370035b5
Commit
370035b5
authored
2 years ago
by
Andreas Klöckner
Committed by
Andreas Klöckner
2 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Fix pylint failures for pylint 2.14
parent
1251f96e
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Pipeline
#309732
failed
2 years ago
Stage: test
Stage: deploy
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
.pylintrc-local.yml
+5
-1
5 additions, 1 deletion
.pylintrc-local.yml
loopy/auto_test.py
+1
-0
1 addition, 0 deletions
loopy/auto_test.py
loopy/kernel/tools.py
+9
-11
9 additions, 11 deletions
loopy/kernel/tools.py
with
15 additions
and
12 deletions
.pylintrc-local.yml
+
5
−
1
View file @
370035b5
...
...
@@ -13,4 +13,8 @@
-
maptlotlib.pyplot
-
arg
:
init-hook
val
:
sys.setrecursionlimit(5000)
val
:
import sys; sys.setrecursionlimit(5000)
-
arg
:
disable
val
:
-
E1102
This diff is collapsed.
Click to expand it.
loopy/auto_test.py
+
1
−
0
View file @
370035b5
...
...
@@ -307,6 +307,7 @@ def _default_check_result(result, ref_result):
linf_err
=
(
np
.
max
(
np
.
abs
(
ref_result
-
result
))
/
np
.
max
(
np
.
abs
(
ref_result
-
result
)))
# pylint: disable=bad-string-format-type
return
(
False
,
"
results do not match -- (rel) l_2 err: %g, l_inf err: %g
"
%
(
l2_err
,
linf_err
))
...
...
This diff is collapsed.
Click to expand it.
loopy/kernel/tools.py
+
9
−
11
View file @
370035b5
...
...
@@ -763,13 +763,14 @@ def get_auto_axis_iname_ranking_by_stride(kernel, insn):
continue
coeffs
=
CoefficientCollector
()(
iexpr_i
)
for
var
,
coeff
in
coeffs
.
items
():
if
(
isinstance
(
var
,
Variable
)
and
var
.
name
in
auto_axis_inames
):
# excludes '1', i.e. the constant
new_stride
=
coeff
*
stride
old_stride
=
iname_to_stride_expr
.
get
(
var
.
name
,
None
)
if
old_stride
is
None
or
new_stride
<
old_stride
:
iname_to_stride_expr
[
var
.
name
]
=
new_stride
# This is a nested if instead of 'and' for pylint's benefit.
if
isinstance
(
var
,
Variable
):
if
var
.
name
in
auto_axis_inames
:
# excludes '1', i.e. the constant
new_stride
=
coeff
*
stride
old_stride
=
iname_to_stride_expr
.
get
(
var
.
name
,
None
)
if
old_stride
is
None
or
new_stride
<
old_stride
:
iname_to_stride_expr
[
var
.
name
]
=
new_stride
# }}}
...
...
@@ -1807,10 +1808,7 @@ def get_subkernel_to_insn_id_map(kernel):
for
insn_id
in
sched_item_to_insn_id
(
sched_item
):
result
[
subkernel
].
add
(
insn_id
)
for
subkernel
in
result
:
result
[
subkernel
]
=
frozenset
(
result
[
subkernel
])
return
result
return
{
name
:
frozenset
(
insn_ids
)
for
name
,
insn_ids
in
result
.
items
()}
# }}}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment