Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
dwuggh
surfcode-rs
Commits
7b5ea960
Unverified
Commit
7b5ea960
authored
Jul 30, 2021
by
dwuggh
Browse files
add pure measurement error channel
parent
cdb12ebe
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/main.rs
View file @
7b5ea960
...
...
@@ -77,7 +77,16 @@ fn main() {
.parse
::
<
usize
>
()
.unwrap
();
let
(
m_correct
,
m_error
)
=
load_channel_coeffs_from_file
(
matches
.value_of
(
"channel"
)
.unwrap
());
let
channel
=
matches
.value_of
(
"channel"
)
.unwrap
();
let
(
m_correct
,
m_error
)
=
if
let
Ok
(
pm
)
=
channel
.parse
::
<
f64
>
()
{
let
mut
m_correct
=
vec!
[
0.
;
256
];
m_correct
[
0
]
=
1.
-
pm
;
let
mut
m_error
=
vec!
[
0.
;
256
];
m_error
[
0
]
=
pm
;
(
m_correct
,
m_error
)
}
else
{
load_channel_coeffs_from_file
(
channel
)
};
// let pm = 0.02;
// let mut m_correct = vec![0.; 256];
...
...
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