Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Opus
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
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
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Xiph.Org
Opus
Commits
b50ddccf
Verified
Commit
b50ddccf
authored
1 year ago
by
Jean-Marc Valin
Browse files
Options
Downloads
Patches
Plain Diff
Fixes weights parsing with DISABLE_DEBUG_FLOAT
It's the name that's NULL when an array isn't found
parent
8cc769ea
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Pipeline
#4006
passed
1 year ago
Stage: build
Stage: test
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
dnn/parse_lpcnet_weights.c
+3
-3
3 additions, 3 deletions
dnn/parse_lpcnet_weights.c
with
3 additions
and
3 deletions
dnn/parse_lpcnet_weights.c
+
3
−
3
View file @
b50ddccf
...
...
@@ -84,14 +84,14 @@ static const void *find_array_entry(const WeightArray *arrays, const char *name)
static
const
void
*
find_array_check
(
const
WeightArray
*
arrays
,
const
char
*
name
,
int
size
)
{
const
WeightArray
*
a
=
find_array_entry
(
arrays
,
name
);
if
(
a
&&
a
->
size
==
size
)
return
a
->
data
;
if
(
a
->
name
&&
a
->
size
==
size
)
return
a
->
data
;
else
return
NULL
;
}
static
const
void
*
opt_array_check
(
const
WeightArray
*
arrays
,
const
char
*
name
,
int
size
,
int
*
error
)
{
const
WeightArray
*
a
=
find_array_entry
(
arrays
,
name
);
*
error
=
(
a
!=
NULL
&&
a
->
size
!=
size
);
if
(
a
&&
a
->
size
==
size
)
return
a
->
data
;
*
error
=
(
a
->
name
!=
NULL
&&
a
->
size
!=
size
);
if
(
a
->
name
&&
a
->
size
==
size
)
return
a
->
data
;
else
return
NULL
;
}
...
...
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