Lines Matching refs:embeddings
1094 std::vector<float> embeddings; in TEST_F() local
1097 EXPECT_TRUE(embedder.EmbedTokensPerMessage(tokens, &embeddings, in TEST_F()
1101 EXPECT_EQ(embeddings.size(), 3); in TEST_F()
1102 EXPECT_THAT(embeddings[0], in TEST_F()
1105 EXPECT_THAT(embeddings[1], in TEST_F()
1108 EXPECT_THAT(embeddings[2], in TEST_F()
1118 std::vector<float> embeddings; in TEST_F() local
1121 EXPECT_TRUE(embedder.EmbedTokensPerMessage(tokens, &embeddings, in TEST_F()
1125 EXPECT_EQ(embeddings.size(), 5); in TEST_F()
1126 EXPECT_THAT(embeddings[0], in TEST_F()
1129 EXPECT_THAT(embeddings[1], in TEST_F()
1132 EXPECT_THAT(embeddings[2], in TEST_F()
1135 EXPECT_THAT(embeddings[3], testing::FloatEq(options_->padding_token_id)); in TEST_F()
1136 EXPECT_THAT(embeddings[4], testing::FloatEq(options_->padding_token_id)); in TEST_F()
1144 std::vector<float> embeddings; in TEST_F() local
1147 EXPECT_TRUE(embedder.EmbedTokensPerMessage(tokens, &embeddings, in TEST_F()
1151 EXPECT_EQ(embeddings.size(), 2); in TEST_F()
1152 EXPECT_THAT(embeddings[0], in TEST_F()
1155 EXPECT_THAT(embeddings[1], in TEST_F()
1165 std::vector<float> embeddings; in TEST_F() local
1168 EXPECT_TRUE(embedder.EmbedTokensPerMessage(tokens, &embeddings, in TEST_F()
1172 EXPECT_THAT(embeddings[0], in TEST_F()
1175 EXPECT_THAT(embeddings[1], in TEST_F()
1178 EXPECT_THAT(embeddings[2], in TEST_F()
1181 EXPECT_THAT(embeddings[3], in TEST_F()
1184 EXPECT_THAT(embeddings[4], in TEST_F()
1187 EXPECT_THAT(embeddings[5], testing::FloatEq(options_->padding_token_id)); in TEST_F()
1194 std::vector<float> embeddings; in TEST_F() local
1198 embedder.EmbedAndFlattenTokens(tokens, &embeddings, &total_token_count)); in TEST_F()
1201 EXPECT_EQ(embeddings.size(), 5); in TEST_F()
1202 EXPECT_THAT(embeddings[0], testing::FloatEq(options_->start_token_id)); in TEST_F()
1203 EXPECT_THAT(embeddings[1], in TEST_F()
1206 EXPECT_THAT(embeddings[2], in TEST_F()
1209 EXPECT_THAT(embeddings[3], in TEST_F()
1212 EXPECT_THAT(embeddings[4], testing::FloatEq(options_->end_token_id)); in TEST_F()
1220 std::vector<float> embeddings; in TEST_F() local
1224 embedder.EmbedAndFlattenTokens(tokens, &embeddings, &total_token_count)); in TEST_F()
1227 EXPECT_EQ(embeddings.size(), 7); in TEST_F()
1228 EXPECT_THAT(embeddings[0], testing::FloatEq(options_->start_token_id)); in TEST_F()
1229 EXPECT_THAT(embeddings[1], in TEST_F()
1232 EXPECT_THAT(embeddings[2], in TEST_F()
1235 EXPECT_THAT(embeddings[3], in TEST_F()
1238 EXPECT_THAT(embeddings[4], testing::FloatEq(options_->end_token_id)); in TEST_F()
1239 EXPECT_THAT(embeddings[5], testing::FloatEq(options_->padding_token_id)); in TEST_F()
1240 EXPECT_THAT(embeddings[6], testing::FloatEq(options_->padding_token_id)); in TEST_F()
1248 std::vector<float> embeddings; in TEST_F() local
1252 embedder.EmbedAndFlattenTokens(tokens, &embeddings, &total_token_count)); in TEST_F()
1255 EXPECT_EQ(embeddings.size(), 3); in TEST_F()
1256 EXPECT_THAT(embeddings[0], in TEST_F()
1259 EXPECT_THAT(embeddings[1], in TEST_F()
1262 EXPECT_THAT(embeddings[2], testing::FloatEq(options_->end_token_id)); in TEST_F()
1270 std::vector<float> embeddings; in TEST_F() local
1274 embedder.EmbedAndFlattenTokens(tokens, &embeddings, &total_token_count)); in TEST_F()
1277 EXPECT_EQ(embeddings.size(), 9); in TEST_F()
1278 EXPECT_THAT(embeddings[0], testing::FloatEq(options_->start_token_id)); in TEST_F()
1279 EXPECT_THAT(embeddings[1], in TEST_F()
1282 EXPECT_THAT(embeddings[2], in TEST_F()
1285 EXPECT_THAT(embeddings[3], in TEST_F()
1288 EXPECT_THAT(embeddings[4], testing::FloatEq(options_->end_token_id)); in TEST_F()
1289 EXPECT_THAT(embeddings[5], testing::FloatEq(options_->start_token_id)); in TEST_F()
1290 EXPECT_THAT(embeddings[6], in TEST_F()
1293 EXPECT_THAT(embeddings[7], in TEST_F()
1296 EXPECT_THAT(embeddings[8], testing::FloatEq(options_->end_token_id)); in TEST_F()
1306 std::vector<float> embeddings; in TEST_F() local
1310 embedder.EmbedAndFlattenTokens(tokens, &embeddings, &total_token_count)); in TEST_F()
1313 EXPECT_EQ(embeddings.size(), 7); in TEST_F()
1314 EXPECT_THAT(embeddings[0], in TEST_F()
1317 EXPECT_THAT(embeddings[1], testing::FloatEq(options_->end_token_id)); in TEST_F()
1318 EXPECT_THAT(embeddings[2], testing::FloatEq(options_->start_token_id)); in TEST_F()
1319 EXPECT_THAT(embeddings[3], in TEST_F()
1322 EXPECT_THAT(embeddings[4], in TEST_F()
1325 EXPECT_THAT(embeddings[5], in TEST_F()
1328 EXPECT_THAT(embeddings[6], testing::FloatEq(options_->end_token_id)); in TEST_F()