Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
juobs
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Javier Ugarrio
juobs
Commits
642b1656
Commit
642b1656
authored
Aug 03, 2024
by
ale
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug apply_rw
parent
923832a2
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
6 deletions
+10
-6
src/juobs_tools.jl
src/juobs_tools.jl
+10
-6
No files found.
src/juobs_tools.jl
View file @
642b1656
...
...
@@ -4,20 +4,22 @@ function apply_rw(data::Array{Float64}, W::Matrix{Float64}, vcfg::Union{Nothing,
vcfg
=
collect
(
1
:
nc
)
end
rw1
=
W
[
1
,
1
:
nc
]
rw2
=
W
[
2
,
1
:
nc
]
if
fs
==
false
if
id
==
"A653"
rw1
=
W
[
1
,
1
:
nc
]
rw
=
rw1
data_r
=
data
.*
rw
[
vcfg
]
return
(
data_r
,
rw
)
else
rw1
=
W
[
1
,
1
:
nc
]
rw2
=
W
[
2
,
1
:
nc
]
rw
=
rw1
.*
rw2
data_r
=
data
.*
rw
[
vcfg
]
return
(
data_r
,
rw
)
end
else
rw1
=
W
[
1
,
1
:
nc
]
rw2
=
W
[
2
,
1
:
nc
]
rw_s
=
[
1.0
for
i
in
1
:
nc
]
rw_s
[
flag_s
[
id
]]
.=
-
1.0
rw
=
rw1
.*
rw2
.*
rw_s
...
...
@@ -32,20 +34,22 @@ function apply_rw(data::Vector{<:Array{Float64}}, W::Vector{Matrix{Float64}}, vc
vcfg
=
[
collect
(
1
:
nc
[
k
])
for
k
=
1
:
length
(
nc
)]
end
rw1
=
[
W
[
k
][
1
,
1
:
nc
[
k
]]
for
k
=
1
:
length
(
W
)]
rw2
=
[
W
[
k
][
2
,
1
:
nc
[
k
]]
for
k
=
1
:
length
(
W
)]
if
fs
==
false
if
id
==
"A653"
rw1
=
[
W
[
k
][
1
,
1
:
nc
[
k
]]
for
k
=
1
:
length
(
W
)]
rw
=
[
rw1
[
k
]
for
k
=
1
:
length
(
W
)]
data_r
=
[
data
[
k
]
.*
rw
[
k
][
vcfg
[
k
]]
for
k
=
1
:
length
(
data
)]
return
(
data_r
,
rw
)
else
rw1
=
[
W
[
k
][
1
,
1
:
nc
[
k
]]
for
k
=
1
:
length
(
W
)]
rw2
=
[
W
[
k
][
2
,
1
:
nc
[
k
]]
for
k
=
1
:
length
(
W
)]
rw
=
[
rw1
[
k
]
.*
rw2
[
k
]
for
k
=
1
:
length
(
W
)]
data_r
=
[
data
[
k
]
.*
rw
[
k
][
vcfg
[
k
]]
for
k
=
1
:
length
(
data
)]
return
(
data_r
,
rw
)
end
else
rw1
=
[
W
[
k
][
1
,
1
:
nc
[
k
]]
for
k
=
1
:
length
(
W
)]
rw2
=
[
W
[
k
][
2
,
1
:
nc
[
k
]]
for
k
=
1
:
length
(
W
)]
rw_s
=
[[
1.0
for
i
in
1
:
nc
[
k
]]
for
k
=
1
:
length
(
W
)]
if
id
==
"H105"
rw_s
[
1
][
flag_s
[
"H105r001"
]]
.=
-
1.0
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment