|
|
@@ -1254,7 +1254,7 @@ struct test_count_equal : public test_case {
|
|
|
ggml_tensor * b = ggml_new_tensor(ctx, type, 4, ne.data());
|
|
|
ggml_set_name(b, "b");
|
|
|
|
|
|
- ggml_tensor * b_argmax = ggml_argmax(ctx, a);
|
|
|
+ ggml_tensor * b_argmax = ggml_argmax(ctx, b);
|
|
|
ggml_set_name(b_argmax, "b_argmax");
|
|
|
|
|
|
ggml_tensor * out = ggml_count_equal(ctx, a_argmax, b_argmax);
|
|
|
@@ -1511,6 +1511,7 @@ struct test_cont : public test_case {
|
|
|
};
|
|
|
|
|
|
// GGML_OP_ADD
|
|
|
+// GGML_OP_SUB
|
|
|
// GGML_OP_MUL
|
|
|
// GGML_OP_DIV
|
|
|
struct test_bin_bcast : public test_case {
|
|
|
@@ -3860,7 +3861,8 @@ static std::vector<std::unique_ptr<test_case>> make_test_cases_eval() {
|
|
|
test_cases.emplace_back(new test_conv_transpose_1d({3,2,1,1}, {3,1,2,1}, 1, 0, 1));
|
|
|
test_cases.emplace_back(new test_conv_transpose_1d({2,1,1,1}, {3,1,1,1}, 1, 0, 1));
|
|
|
|
|
|
- test_cases.emplace_back(new test_count_equal());
|
|
|
+ test_cases.emplace_back(new test_count_equal(GGML_TYPE_F32, {4, 500, 1, 1}));
|
|
|
+ test_cases.emplace_back(new test_count_equal(GGML_TYPE_F32, {4, 5000, 1, 1}));
|
|
|
|
|
|
test_cases.emplace_back(new test_argmax(GGML_TYPE_F32, {32, 1, 1, 1}));
|
|
|
test_cases.emplace_back(new test_argmax(GGML_TYPE_F32, {100, 10, 1, 1}));
|
|
|
@@ -3885,8 +3887,6 @@ static std::vector<std::unique_ptr<test_case>> make_test_cases_eval() {
|
|
|
test_cases.emplace_back(new test_repeat_back(GGML_TYPE_F32, {8, 6, 4, 2}, {1, 2, 1, 1}, view));
|
|
|
test_cases.emplace_back(new test_repeat_back(GGML_TYPE_F32, {8, 6, 4, 2}, {1, 1, 2, 1}, view));
|
|
|
test_cases.emplace_back(new test_repeat_back(GGML_TYPE_F32, {8, 6, 4, 2}, {1, 1, 1, 2}, view));
|
|
|
- test_cases.emplace_back(new test_repeat_back(GGML_TYPE_I32, {8, 6, 4, 2}, {2, 1, 1, 1}, view));
|
|
|
- test_cases.emplace_back(new test_repeat_back(GGML_TYPE_I16, {8, 6, 4, 2}, {1, 1, 1, 2}, view));
|
|
|
}
|
|
|
|
|
|
test_cases.emplace_back(new test_dup(GGML_TYPE_F32));
|
|
|
@@ -3938,7 +3938,7 @@ static std::vector<std::unique_ptr<test_case>> make_test_cases_eval() {
|
|
|
test_cases.emplace_back(new test_cont(GGML_TYPE_BF16, {2, 3, 5 ,7}));
|
|
|
|
|
|
auto add_test_bin_bcast = [&](ggml_type type, std::array<int64_t, 4> ne, std::array<int, 4> nr) {
|
|
|
- for (auto op : {ggml_add, ggml_mul, ggml_div}) {
|
|
|
+ for (auto op : {ggml_add, ggml_sub, ggml_mul, ggml_div}) {
|
|
|
test_cases.emplace_back(new test_bin_bcast(op, type, ne, nr));
|
|
|
}
|
|
|
};
|