問題
早期版本的 Imatest 出現了一個問題,一些原本運作正常的常用模組和工具現在會卡死。如果您的機器也出現了這種情況,請嘗試以下解決方案。
解決方案
要解決此問題,需要更新 libcudart.dylib 版本的程式碼簽章。雖然聽起來很複雜,但只需一條終端機命令即可完成。要執行此命令,您需要知道 MATLAB Runtime 自帶的 libcudart.dylib 的檔案路徑。受影響的最新 Imatest 版本的 libcudart.dylib 檔案路徑如下表所示:
Imatest 版本 | 庫路徑 |
|---|---|
2021.1 | /Applications/MATLAB/MATLAB_Runtime/v99/bin/maci64/libcudart.10.2.dylib |
2020.2 | /Applications/MATLAB/MATLAB_Runtime/v98/bin/maci64/libcudart.10.1.dylib |
2020.1 | /Applications/MATLAB/MATLAB_Runtime/v97/bin/maci64/libcudart.10.1.dylib |
如果您的 Imatest 版本未在上表中列出,並且您遇到了該問題,請找到與您的 Imatest 版本一起附帶的 MATLAB Runtime 版本中libcudart.<major number>.<minor number>.dylib檔案的路徑。
知道檔案路徑後,請在安裝了 Imatest 的 Mac 上執行下列步驟:
Open a terminal window
Enter the following and then press `return`
sudo codesign --deep -fs - <library path>where
<library path>should be replaced with the library path from the table above. Please note the spaces surrounding the trailing-.
For example, for Imatest 2021.1, you would runsudo codesign --deep -fs - /Applications/MATLAB/MATLAB_Runtime/v99/bin/maci64/libcudart.10.2.dylib[Optional] Verify that the library was successfully code-signed by running the following
codesign --verbose --verify <library path>
If the code-signing operation was successful, you should see output similar tocodesign --verify --verbose /Applications/MATLAB/MATLAB_Runtime/v99/bin/maci64/libcudart.10.2.dylib /Applications/MATLAB/MATLAB_Runtime/v99/bin/maci64/libcudart.10.2.dylib: valid on disk /Applications/MATLAB/MATLAB_Runtime/v99/bin/maci64/libcudart.10.2.dylib: satisfies its Designated Requirement
Start Imatest as normal and attempt the operation that previously froze.
如果 libcudart.10.2.dylib 不存在 (2020.2)
有兩種方法可以解決這個問題:
如果您已安裝 Matlab v97 執行階段環境,則其中應該包含 v98 所需的相同檔案副本。將此檔案從 v97 執行時期環境目錄中的對應資料夾複製並貼上到 v98 執行階段環境目錄中的相同位置。
上面給出的 Imatest v2020.1 的檔案路徑應該是 v97 運行時檔案的路徑。
如果您沒有安裝 Matlab v97 執行環境,我們建議您重新安裝 Matlab v98 執行環境。全新安裝後應該會包含缺少的檔案。
**如果您按照這些說明操作後仍然遇到困難,請聯絡support@imatest.com 。