amazon-science / patchcore-inspection

Apache License 2.0
779 stars 154 forks source link

training patchcore #39

Closed tuandat-github closed 2 years ago

tuandat-github commented 2 years ago

datapath=/path_to_mvtec_folder/mvtec datasets=('bottle' 'cable' 'capsule' 'carpet' 'grid' 'hazelnut' 'leather' 'metal_nut' 'pill' 'screw' 'tile' 'toothbrush' 'transistor' 'wood' 'zipper') dataset_flags=($(for dataset in "${datasets[@]}"; do echo '-d '$dataset; done))

python bin/run_patchcore.py --gpu 0 --seed 0 --save_patchcore_model \ --log_group IM224_WR50_L2-3_P01_D1024-1024_PS-3_AN-1_S0 --log_online --log_project MVTecAD_Results results \ patch_core -b wideresnet50 -le layer2 -le layer3 --faiss_on_gpu \ --pretrain_embed_dimension 1024 --target_embed_dimension 1024 --anomaly_scorer_num_nn 1 --patchsize 3 \ sampler -p 0.1 approx_greedy_coreset dataset --resize 256 --imagesize 224 "${dataset_flags[@]}" mvtec $datapath

i run this on my pc but 3 lines are always error image I don't know what happens. Please helps me.

tuandat-github commented 2 years ago

How can i write datapath=/path_to_mvtec_folder/mvtec datasets=('bottle' 'cable' 'capsule' 'carpet' 'grid' 'hazelnut' 'leather' 'metal_nut' 'pill' 'screw' 'tile' 'toothbrush' 'transistor' 'wood' 'zipper') dataset_flags=($(for dataset in "${datasets[@]}"; do echo '-d '$dataset; done)) in terminal?