自動駕駛用的 AI depth SGDepth 環境安全裝可參考YOLOv7 的安裝步驟

https://github.com/ifnspaml/SGDepth

本篇著重在datasets 的配置.

須要使用到2個資料庫

A. Kitti. 可以參考 [Windows python] Depth Kitti dataset 下載

B. cityscapes. 到官網下載   https://www.cityscapes-dataset.com , 但須要註冊. 註冊有e-mail 須求, 須學術的

" This Cityscapes Dataset is made freely available to academic and non-academic entities for non-commercial purposes such as academic research, teaching, scientific publications, or personal experimentation. Permission is granted to use the data given that you agree to our license terms. "

C. 資料目錄:

image

C.1  還要從官網的 "Prerequisites and Requirements" 章節 download split 相關的檔案, 並解壓到對的目錄

 

D. 都準備好之後, 改部分的source code

如果出現 : "OMP: Error #15: Initializing libiomp5md.dll,..."

import os
os.environ["KMP_DUPLICATE_LIB_OK"]="TRUE"

以上是因為版本不對. 都這樣湊合的使用. 在適當的地方加上這二行. 請自行依照第一行的方法, 將python 3.8 改成 3.6. 也許會成功. 因自己沒有試過. 如果成功告知一下.

 

 

image

E. python train.py --model-name zhou_full --depth-training-loaders "kitti_zhou_train" --train-batches-per-epoch 7293 --masking-enable --masking-from-epoch 15 --masking-linear-increase

F. test. download weight file from "Our models"

python inference.py --model-path bin\sgd_only_model.pth --inference-resize-height 192 --inference-resize-width 640 --image-path image --output-path out

"image" 目錄中放 *.jpg , "out" 目錄則為 output 放的地方

 

arrow
arrow

    cianfen 發表在 痞客邦 留言(0) 人氣()