[이미지 전처리]

1. 128*128 사진 두장을 먼저 A, B에 넣기

 trainning 용이면 A, B의 위치가 중요하나 TEST를 하려면 둘다 같은 사진이여도 무방함

2. path/to/data 에 train, test, val 중에 하나로 폴더를 만들어서 이미지 넣기

3.  명령어 작성

sudo python scripts/combine_A_and_B.py --fold_A path/to/data/A --fold_B path/to/data/B --fold_AB path/to/data

이렇게 하면 train, test, val로 합쳐진 이미지가 만들어짐

그렇게 되면 datasets에 폴더를 만들고 만들어진 train, test, val 폴더를 가지고 옮겨줘야함

 

[test 실행하기]

1. cd .. 으로 폴더에서 벗어나 홈으로 나오기

2. 왜인지... 모르겠으나 매번 이작업을 해줘야 함...

luarocks install cutorch

source ~/.bashrc
source ~/.profile

이 두줄로 소스를 다시 공유함

3. 다시 cd ~/pix2pix로 들어가서

env DATA_ROOT=./datasets/wheel name=wheel_generation which_direction=BtoA th train.lua

env DATA_ROOT=./datasets/wheel name=wheel_generation which_direction=BtoA phase=test th test.lua

변경해줘야하는 부분

 

+ Recent posts