Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
aidge_core
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
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
Cyril Moineau
aidge_core
Commits
50a8f938
Commit
50a8f938
authored
1 year ago
by
Maxence Naud
Browse files
Options
Downloads
Patches
Plain Diff
[Fix] do not use initializer_list to initialize array anymore in operators factories
parent
365bb132
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
include/aidge/operator/Conv.hpp
+1
-1
1 addition, 1 deletion
include/aidge/operator/Conv.hpp
include/aidge/operator/FC.hpp
+2
-2
2 additions, 2 deletions
include/aidge/operator/FC.hpp
include/aidge/operator/MatMul.hpp
+1
-1
1 addition, 1 deletion
include/aidge/operator/MatMul.hpp
with
4 additions
and
4 deletions
include/aidge/operator/Conv.hpp
+
1
−
1
View file @
50a8f938
...
...
@@ -196,7 +196,7 @@ inline std::shared_ptr<Node> Conv(DimSize_t in_channels,
auto
conv
=
std
::
make_shared
<
Node
>
(
std
::
make_shared
<
Conv_Op
<
static_cast
<
DimIdx_t
>
(
DIM
)
>>
(
in_channels
,
out_channels
,
kernel_dims
,
stride_dims
,
padding_dims
,
dilation_dims
),
name
);
// addProducer(conv, 1, append(append(kernel_dims, in_channels), out_channels), "w");
addProducer
(
conv
,
1
,
append
(
out_channels
,
append
(
in_channels
,
kernel_dims
)),
"w"
);
addProducer
(
conv
,
2
,
{
out_channels
},
"b"
);
addProducer
(
conv
,
2
,
std
::
array
<
DimSize_t
,
1
>
(
{
out_channels
}
)
,
"b"
);
return
conv
;
}
...
...
This diff is collapsed.
Click to expand it.
include/aidge/operator/FC.hpp
+
2
−
2
View file @
50a8f938
...
...
@@ -163,8 +163,8 @@ public:
inline
std
::
shared_ptr
<
Node
>
FC
(
DimSize_t
out_channels
,
bool
noBias
=
false
,
const
std
::
string
&
name
=
""
)
{
// FIXME: properly handle default w&b initialization in every cases
auto
fc
=
std
::
make_shared
<
Node
>
(
std
::
make_shared
<
FC_Op
>
(
out_channels
,
noBias
),
name
);
addProducer
(
fc
,
1
,
{
out_channels
,
1
},
"w"
);
addProducer
(
fc
,
2
,
{
(
noBias
?
0
:
out_channels
)
},
"b"
);
// already sets bias dims
addProducer
(
fc
,
1
,
std
::
array
<
DimSize_t
,
2
>
(
{
out_channels
,
1
}
)
,
"w"
);
addProducer
(
fc
,
2
,
(
noBias
?
std
::
array
<
DimSize_t
,
1
>
({
0
})
:
std
::
array
<
DimSize_t
,
1
>
({
out_channels
}
))
,
"b"
);
// already sets bias dims
return
fc
;
}
}
// namespace Aidge
...
...
This diff is collapsed.
Click to expand it.
include/aidge/operator/MatMul.hpp
+
1
−
1
View file @
50a8f938
...
...
@@ -153,7 +153,7 @@ public:
inline
std
::
shared_ptr
<
Node
>
MatMul
(
DimSize_t
out_channels
,
const
std
::
string
&
name
=
""
)
{
// FIXME: properly handle default w initialization in every cases
auto
matmul
=
std
::
make_shared
<
Node
>
(
std
::
make_shared
<
MatMul_Op
>
(
out_channels
),
name
);
addProducer
(
matmul
,
1
,
{
out_channels
,
1
},
"w"
);
addProducer
(
matmul
,
1
,
std
::
array
<
DimSize_t
,
2
>
(
{
out_channels
,
1
}
)
,
"w"
);
return
matmul
;
}
}
// namespace Aidge
...
...
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