Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Opus
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Xiph.Org
Opus
Commits
dfd4175a
Unverified
Commit
dfd4175a
authored
10 months ago
by
Jan Buethe
Browse files
Options
Downloads
Patches
Plain Diff
updates in download_model.sh (more verbose now)
parent
9faf6f07
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
dnn/download_model.sh
+6
-7
6 additions, 7 deletions
dnn/download_model.sh
with
6 additions
and
7 deletions
dnn/download_model.sh
+
6
−
7
View file @
dfd4175a
...
...
@@ -8,22 +8,21 @@ if [ ! -f $model ]; then
wget https://media.xiph.org/opus/models/
$model
fi
SHA256
=
$(
command
-v
sha256sum
)
if
[
"
$?
"
!=
"0"
]
if
command
-v
sha256sum
then
echo
"Could not find sha256 sum. Skipping verification. Please verify manually that sha256 hash of
${
model
}
matches
${
1
}
."
else
echo
"Validating checksum"
checksum
=
$1
checksum
=
"
$1
"
checksum2
=
$(
sha256sum
$model
|
awk
'{print $1}'
)
if
[
"
$checksum
"
!=
"
$checksum2
"
]
then
echo
"checksums don't match, aborting"
echo
"Aborting due to mismatching checksums. This could be caused by a corrupted download of
$model
."
echo
"Consider deleting local copy of
$model
and running this script again."
exit
1
else
echo
"checksums match"
fi
else
echo
"Could not find sha256 sum; skipping verification. Please verify manually that sha256 hash of
${
model
}
matches
${
1
}
."
fi
...
...
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