for x in /data/cameron/LBM11/flattened_robotdirs/*real*/*; 
do 
    echo $x
    y=$(echo "$x" | sed 's/\//-/g')
    #z="${x/depth/rgb}"
    #echo $z
    outdir="/data/cameron/monocular_ests/tri_robotics_real_more/$y" 
    if [ -d $outdir ]; then
        echo "$outdir is a directory"
    else
        echo "need to do" $y
        CUDA_VISIBLE_DEVICES=2 python scripts/preprocess_imgdir.py -i $x -o $outdir
        CUDA_VISIBLE_DEVICES=2 python scripts/pkg_data.py -i $outdir
    fi
done
