Skip to content

Commit 21da18b

Browse files
committed
timeout-minutes: 1
1 parent f064bdc commit 21da18b

File tree

2 files changed

+15
-15
lines changed

2 files changed

+15
-15
lines changed

.github/workflows/causal_lm_cpp.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -703,11 +703,11 @@ jobs:
703703
&& brew install coreutils scons
704704
- run: OpenVINO_DIR=./ov/runtime/cmake/ cmake -DCMAKE_BUILD_TYPE=Release -B ./build/ ./
705705
- run: LD_LIBRARY_PATH=${{ github.workspace }}/ov/runtime/3rdparty/tbb/lib/:$LD_LIBRARY_PATH cmake --build ./build/ --config Release --target visual_language_chat -j
706-
- name: Download and convert MiniCPM-V-2_6
707-
run: |
706+
timeout-minutes: 1
707+
- run: OpenVINO_DIR=./ov/runtime/cmake/ python -m pip install --upgrade-strategy eager ./thirdparty/openvino_tokenizers/[transformers] -r ./samples/requirements.txt --pre --extra-index-url https://storage.openvinotoolkit.org/simple/wheels/nightly
708+
- run: >
708709
source ./ov/setupvars.sh
709-
python -m pip install --upgrade-strategy eager ./thirdparty/openvino_tokenizers/[transformers] -r ./samples/requirements.txt --pre --extra-index-url https://storage.openvinotoolkit.org/simple/wheels/nightly
710-
python ./samples/cpp/visual_language_chat/export_MiniCPM-V-2_6.py ./miniCPM-V-2_6/
710+
&& python ./samples/cpp/visual_language_chat/export_MiniCPM-V-2_6.py ./miniCPM-V-2_6/
711711
- run: wget https://github.com/openvinotoolkit/openvino_notebooks/assets/29454499/d5fbbd1a-d484-415c-88cb-9986625b7b11
712712
- run: >
713713
LD_LIBRARY_PATH=${{ github.workspace }}/ov/runtime/3rdparty/tbb/lib/:$LD_LIBRARY_PATH

samples/cpp/visual_language_chat/visual_language_chat.cpp

+11-11
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ bool print_subword(std::string&& subword) {
99
return !(std::cout << subword << std::flush);
1010
}
1111

12-
int main(int argc, char* argv[]) {
12+
int main(int argc, char* argv[]) try {
1313
if (3 != argc) {
1414
throw std::runtime_error(std::string{"Usage "} + argv[0] + " <MODEL_DIR> <IMAGE_FILE>");
1515
}
@@ -42,14 +42,14 @@ int main(int argc, char* argv[]) {
4242
"question:\n";
4343
}
4444
pipe.finish_chat();
45-
// } catch (const std::exception& error) {
46-
// try {
47-
// std::cerr << error.what() << '\n';
48-
// } catch (const std::ios_base::failure&) {}
49-
// return EXIT_FAILURE;
50-
// } catch (...) {
51-
// try {
52-
// std::cerr << "Non-exception object thrown\n";
53-
// } catch (const std::ios_base::failure&) {}
54-
// return EXIT_FAILURE;
45+
} catch (const std::exception& error) {
46+
try {
47+
std::cerr << error.what() << '\n';
48+
} catch (const std::ios_base::failure&) {}
49+
return EXIT_FAILURE;
50+
} catch (...) {
51+
try {
52+
std::cerr << "Non-exception object thrown\n";
53+
} catch (const std::ios_base::failure&) {}
54+
return EXIT_FAILURE;
5555
}

0 commit comments

Comments
 (0)