การจัดการเวอร์ชันข้อมูลด้วย DVC เบื้องต้น
Ravi Bhadauria
Machine Learning Engineer
$ dvc push <target>$ dvc pull <target>
$ dvc push data.csv
$ dvc push
$ dvc fetch
-r$ dvc push -r aws_remote data.csv
dvc pull
ฟังก์ชัน: ดาวน์โหลดข้อมูลจาก remote มายัง DVC workspace
กรณีใช้งาน: ชุดข้อมูลขนาดใหญ่หรือ model artifacts
dvc push
ฟังก์ชัน: อัปโหลดข้อมูลไปยัง remote storage
กรณีใช้งาน: แชร์หรือจัดเก็บ data artifacts
git pull
ฟังก์ชัน: ดึง/รวมข้อมูลจาก remote Git repo
กรณีใช้งาน: ซิงค์ branch ในเครื่องกับ remote
git push
ฟังก์ชัน: อัปโหลดการเปลี่ยนแปลงในเครื่องไปยัง remote
กรณีใช้งาน: แชร์การเปลี่ยนแปลงไปยัง Git remote
.dvc ถูก track โดย Git ไม่ใช่ DVC
ใช้ประโยชน์นี้เพื่อ checkout ไฟล์ข้อมูลเวอร์ชันที่ต้องการ
Checkout ไฟล์ .dvc
$ git checkout <commit_hash|tag|branch>
.dvc$ dvc checkout <target>
$ dvc add <target>
.dvc ที่เปลี่ยนแปลงไปยัง Git$ git add <target>.dvc
$ git commit <target>.dvc \
-m "Dataset updates"
$ git push origin main
$ dvc push
การจัดการเวอร์ชันข้อมูลด้วย DVC เบื้องต้น