abdelaziz-mahdy / pytorch_lite

flutter package to help run pytorch lite models classification and YoloV5 and YoloV8.
MIT License
58 stars 25 forks source link

issue in last version #44

Closed maheralzoubi97 closed 1 year ago

maheralzoubi97 commented 1 year ago

What went wrong: Execution failed for task ':pytorch_lite:configureCMakeDebug[arm64-v8a]'.

[CXX1405] error when building with cmake using /Users/maher/.pub-cache/hosted/pub.dev/pytorch_lite-4.0.0/android/CMakeLists.txt: Build command failed. Error while executing process /Users/maher/Library/Android/sdk/cmake/3.18.1/bin/cmake with arguments {-H/Users/maher/.pub-cache/hosted/pub.dev/pytorch_lite-4.0.0/android -DCMAKE_SYSTEM_NAME=Android -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DCMAKE_SYSTEM_VERSION=24 -DANDROID_PLATFORM=android-24 -DANDROID_ABI=arm64-v8a -DCMAKE_ANDROID_ARCH_ABI=arm64-v8a -DANDROID_NDK=/Users/maher/Library/Android/sdk/ndk/21.4.7075529 -DCMAKE_ANDROID_NDK=/Users/maher/Library/Android/sdk/ndk/21.4.7075529 -DCMAKE_TOOLCHAIN_FILE=/Users/maher/Library/Android/sdk/ndk/21.4.7075529/build/cmake/android.toolchain.cmake -DCMAKE_MAKE_PROGRAM=/Users/maher/Library/Android/sdk/cmake/3.18.1/bin/ninja -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/Users/maher/Downloads/pytorch_lite-master/example/build/pytorch_lite/intermediates/cxx/Debug/493q5310/obj/arm64-v8a -DCMAKE_RUNTIME_OUTPUT_DIRECTORY=/Users/maher/Downloads/pytorch_lite-master/example/build/pytorch_lite/intermediates/cxx/Debug/493q5310/obj/arm64-v8a -DCMAKE_BUILD_TYPE=Debug -B/Users/maher/.pub-cache/hosted/pub.dev/pytorch_lite-4.0.0/android/.cxx/Debug/493q5310/arm64-v8a -GNinja} -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Check for working C compiler: /Users/maher/Library/Android/sdk/ndk/21.4.7075529/toolchains/llvm/prebuilt/darwin-x86_64/bin/clang - skipped -- Detecting C compile features -- Detecting C compile features - done -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Check for working CXX compiler: /Users/maher/Library/Android/sdk/ndk/21.4.7075529/toolchains/llvm/prebuilt/darwin-x86_64/bin/clang++ - skipped -- Detecting CXX compile features -- Detecting CXX compile features - done -- Hash matches - no need to download. -- MD5 hash verification successful. Calculated MD5: 05491f47535dc6623c823bfcd0e89c75, Expected MD5: 05491f47535dc6623c823bfcd0e89c75 -- Downloaded archive... -- Extracted archive... -- Hash matches - no need to download. -- MD5 hash verification successful. Calculated MD5: a9b147c0a5cfdaf1673a55fc4d9a82e9, Expected MD5: a9b147c0a5cfdaf1673a55fc4d9a82e9 -- Downloaded archive... -- Extracted archive... -- Found OpenCV: /Users/maher/.pub-cache/hosted/pub.dev/pytorch_lite-4.0.0/android/opencv/opencv-mobile-4.6.0-android (found version "4.6.0") -- Configuring incomplete, errors occurred! See also "/Users/maher/.pub-cache/hosted/pub.dev/pytorch_lite-4.0.0/android/.cxx/Debug/493q5310/arm64-v8a/CMakeFiles/CMakeOutput.log".

CMake Error at CMakeLists.txt:128 (message): File /Users/maher/.pub-cache/hosted/pub.dev/pytorch_lite-4.0.0/android/libtorch-android-13.1/libtorch-android-13.1/jni/arm64-v8a/libpytorch_jni.so does not exist. Call Stack (most recent call first): CMakeLists.txt:143 (check_file_exists)

abdelaziz-mahdy commented 1 year ago

Flutter clean should fix it , also try on the dev one most of these bugs can be avoided by going back to native code

abdelaziz-mahdy commented 1 year ago

most probably fixed in 4.2.0