Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
psaap3-weno
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
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
psaap3-weno
Merge requests
!30
Suggested style fixes for data fixtures
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Suggested style fixes for data fixtures
fix-mr-29
into
data-fixtures
Overview
4
Commits
5
Pipelines
3
Changes
1
All threads resolved!
Hide all comments
Merged
Andreas Klöckner
requested to merge
fix-mr-29
into
data-fixtures
5 years ago
Overview
4
Commits
5
Pipelines
3
Changes
1
All threads resolved!
Hide all comments
Expand
0
0
Merge request reports
Viewing commit
266f95dc
Prev
Next
Show latest version
1 file
+
4
−
4
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
266f95dc
Flake8 fixes
· 266f95dc
Andreas Klöckner
authored
5 years ago
data_for_test.py
+
4
−
4
Options
@@ -55,21 +55,21 @@ class FluxDataSingle:
def
swap_array
(
self
,
arr
,
d
):
p
=
self
.
permutation
(
d
)
arr
[
p
]
=
arr
[[
1
,
2
,
3
]]
arr
[
p
]
=
arr
[[
1
,
2
,
3
]]
return
arr
def
swap_array_rows
(
self
,
arr
,
d
):
p
=
self
.
permutation
(
d
)
arr
[
p
,:]
=
arr
[[
1
,
2
,
3
],:]
arr
[
p
,
:]
=
arr
[[
1
,
2
,
3
],
:]
return
arr
def
swap_array_cols
(
self
,
arr
,
d
):
p
=
self
.
permutation
(
d
)
arr
[:,
p
]
=
arr
[:,[
1
,
2
,
3
]]
arr
[:,
p
]
=
arr
[:,
[
1
,
2
,
3
]]
return
arr
def
permutation
(
self
,
d
):
return
[(
d
-
1
+
i
)
%
3
+
1
for
i
in
range
(
3
)]
return
[(
d
-
1
+
i
)
%
3
+
1
for
i
in
range
(
3
)]
# }}}
Loading