fix an issue that block-h param is not applied properly
This commit is contained in:
parent
85c45e32c0
commit
0f8134edf5
1
.gitignore
vendored
1
.gitignore
vendored
@ -1 +1,2 @@
|
|||||||
/build/
|
/build/
|
||||||
|
/exp/
|
||||||
|
@ -56,7 +56,7 @@ std::vector<std::vector<int32_t>> indices;
|
|||||||
|
|
||||||
static void Embed(int32_t t, Frame& dst, const Frame& base) {
|
static void Embed(int32_t t, Frame& dst, const Frame& base) {
|
||||||
const auto bw = args::get(param::bw);
|
const auto bw = args::get(param::bw);
|
||||||
const auto bh = args::get(param::bw);
|
const auto bh = args::get(param::bh);
|
||||||
const auto hbw = bw/2;
|
const auto hbw = bw/2;
|
||||||
const auto hbh = bh/2;
|
const auto hbh = bh/2;
|
||||||
|
|
||||||
@ -92,7 +92,7 @@ static void Embed(int32_t t, Frame& dst, const Frame& base) {
|
|||||||
|
|
||||||
static void Exec() {
|
static void Exec() {
|
||||||
const auto bw = args::get(param::bw);
|
const auto bw = args::get(param::bw);
|
||||||
const auto bh = args::get(param::bw);
|
const auto bh = args::get(param::bh);
|
||||||
const auto ut = args::get(param::utime);
|
const auto ut = args::get(param::utime);
|
||||||
Enforce(bw > 0 && bh > 0, "block size must be greater than 0");
|
Enforce(bw > 0 && bh > 0, "block size must be greater than 0");
|
||||||
Enforce(ut > 0, "utime must be greater than 0");
|
Enforce(ut > 0, "utime must be greater than 0");
|
||||||
|
@ -131,7 +131,7 @@ static Vec EachBlock(const Frame& cf, const Frame& pf, int32_t bx, int32_t by) {
|
|||||||
|
|
||||||
static void EachFrame(int32_t t, const Frame& cf, const Frame& pf) {
|
static void EachFrame(int32_t t, const Frame& cf, const Frame& pf) {
|
||||||
const auto bw = args::get(param::bw);
|
const auto bw = args::get(param::bw);
|
||||||
const auto bh = args::get(param::bw);
|
const auto bh = args::get(param::bh);
|
||||||
const auto ut = args::get(param::utime);
|
const auto ut = args::get(param::utime);
|
||||||
|
|
||||||
Enforce(cf.w == pf.w && cf.h == pf.h, "variable frame size is not allowed");
|
Enforce(cf.w == pf.w && cf.h == pf.h, "variable frame size is not allowed");
|
||||||
@ -185,7 +185,7 @@ static void EachFrame(int32_t t, const Frame& cf, const Frame& pf) {
|
|||||||
|
|
||||||
static void Exec() {
|
static void Exec() {
|
||||||
const auto bw = args::get(param::bw);
|
const auto bw = args::get(param::bw);
|
||||||
const auto bh = args::get(param::bw);
|
const auto bh = args::get(param::bh);
|
||||||
const auto ut = args::get(param::utime);
|
const auto ut = args::get(param::utime);
|
||||||
Enforce(bw > 0 && bh > 0, "block size must be greater than 0");
|
Enforce(bw > 0 && bh > 0, "block size must be greater than 0");
|
||||||
Enforce(ut > 0, "utime must be greater than 0");
|
Enforce(ut > 0, "utime must be greater than 0");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user