Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F27036497
Decimation.cpp
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Authored By
Unknown
Size
1 KB
Referenced Files
None
Subscribers
None
Decimation.cpp
View Options
//===-- app/executionpolicies/Decimation.cpp -----------------*- C++ -*-===//
//
// The RoSA Framework
//
// Distributed under the terms and conditions of the Boost Software License 1.0.
// See accompanying file LICENSE.
//
// If you did not receive a copy of the license file, see
// http://www.boost.org/LICENSE_1_0.txt.
//
//===----------------------------------------------------------------------===//
///
/// \file app/executionpolicies/Decimation.cpp
///
/// \author David Juhasz (david.juhasz@tuwien.ac.at)
///
/// \date 2019-2020
///
/// \brief Implementation for app/executionpolicies/Decimation.h.
///
//===----------------------------------------------------------------------===//
#include
"Decimation.h"
#include
<algorithm>
namespace
rosa
{
namespace
app
{
Decimation
::
Decimation
(
const
size_t
D
)
:
Rate
(
std
::
max
<
size_t
>
(
D
,
1
)),
Cycle
(
0
)
{}
bool
Decimation
::
canHandle
(
const
AgentHandle
,
const
AppSystem
&
)
const
noexcept
{
return
true
;
}
bool
Decimation
::
shouldProcess
(
const
std
::
vector
<
bool
>
&
)
noexcept
{
return
(
Cycle
++
%
Rate
)
==
0
;
}
std
::
string
Decimation
::
dump
(
void
)
const
noexcept
{
return
"Decimation with rate "
+
std
::
to_string
(
Rate
);
}
}
// End namespace app
}
// End namespace rosa
File Metadata
Details
Attached
Mime Type
text/x-c++
Expires
Tue, Oct 27, 8:00 PM (1 d, 20 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
407906
Default Alt Text
Decimation.cpp (1 KB)
Attached To
Mode
R20 SoC_Rosa_repo
Attached
Detach File
Event Timeline