Virtual fitting(feat. Template-Free Try-On Image Synthesis via Semantic-Guided Optimization)

dobby
14 min readJun 17, 2021

이 논문 선정. 최근에 나왔고 CP-vton보다 성능이 좋다고하며, IEEE member? 들이 썻다고한다. member가 멀뜻하는건지 모르겠지만, 신뢰성 있어보여 읽는다.

의식의 흐름대로 쓴거라, 보기어려울것이다. 그리고 이미지 처음이라 체계적으로 정리를 못한다는점은 감안하고 봐주시기바랍니다 ㅠ

요약: TF-TIS 가 “옷의 디테일”과 좋은 합성을 위한 “포즈”를 생성한다. 그리고 problem들을 모두 subproblem으로 나누어서 딥러닝으로 각각 해결하고 통합한다.

Intro

성능 저하 원인 → the quality of the results significantly decreases when an occlusion (e.g., the user’s arm is in front of the chest, obscuring the garment in the source image) or a dramatic pose change (e.g., the limbs are from wide-opened to crossed) occurs.

Framework

신기한게 적합한 pose를 알아서 제공? 유저가 input으로 넣은 사진의 pose에 따라 옷을 합성하는게아니다. → input(사람) → suitable pose(reference 사람포즈, 옷모델이 입고있던 pose)를 recommend/

근데 쇼핑몰별로 마네킹같은 reference pose가 없는곳도 많다, 그럼 옷별로 clustering해서 pose 빈도 나오는것도 본다 → 새로운 옷의 경우는 적합한 포즈를 찾기 어려움.

→ 따라서, 이를 해결하기 위해 이논문에서는 첫 module(cloth2pose)를 만듬. 옷 별로 적합한 포즈를 render. (음 신기하넹)

====> pose transfer 데이터들 학습시킨거랑 뭐가 달라질까?

→ 논문에서 pose transfer 언급한다. → 논문에서는 TF-TIS라는 모듈로 pose transfer까지 포함해서 성능을 높인다. 하지만, pose transfer로 인해 data augmentation한거는 학습시키지 않는거같음..?

와 대박 Cross modal learning !.

Multimodal 처럼 audio나 image text를 같이 학습시키면 성능이 좋아진다. eg. (face and speech). 따라서 여기에서는 we used a similar concept to learn the correlation between clothes and human poses to synthesize the image of the virtual try-on with a suitable pose for the user from the corresponding clothing. → 나중에 어떻게했는지 자세히보도록하자.

Dataset:
TF-TIS를 위해 multiple pose for each person 데이터셋(10,895개)을 모았다.

11283 개 Deepfashion 데이터에서도 (one clothing and two human images) 모음.

training: 9590 , test: 1693

Conclusion

TF-TIS는 clothes와 pose의 연관성을 캐치해서 better pose를 합성한다 for better try-on.

추가로, global and local discriminators in clothing refinement network를 제안함으로써, TF-TIS는 이미지의 일관성, 옷의 detail을 살려준다.

→ 어떻게? 이따 method 보자 ㅎㅎ.

단점이나 그런거 discussion에 있을까?

음… 나와잇지는않다. 다른논문들은 자기 실패들 써두긴햇는데 없네..

Method.

우선 training overview를 보자.

Method A) Stage I. cloth2pose
여기에서 pose를 제안한다는데 학습을 어떻게 한거지..?
automatically generate 한다고한다. → how train?
in-shop clothes and mannequin photos on the online shopping site for training.
regression to single point는 힘드니깐, keypoint position 을 pose map으로 바꾼다고한다.( → noise 발생) 수식은 아래와 같다.

이렇게 하면 실제로 2D에서는 어떻게 보일지 궁금하다. → 다읽고 알아보자.

cloth2pose는 VGG-19를 사용해서 clothes의 feature를 추출한다. → 내가 이미지 처음인데, 왜 Unet, VGG 이런걸 많이 쓰는걸까? 그냥 제안된 모델들이다. randomforest, kmeans clustering 처럼.

Refinement architecture: first block → keypoint information을 생산.
P1 = τ1(F), where τ1 refers to the first convolutional block.
five 7x7 kernel, two 1x1 kernel, ReLU → keypoint tensor.
커널? → 아 filter를 kernel 이라고도 함.

근데 이걸한다고 왜 refinement가 되는거지…?
“The convolutional block takes the concatenation of F and the prediction from the previous block as input to predict the refined keypoint tensor” 뭔소리여..

— 읽다가 다시오자.

기존 model이 입던 P(model)의 keypoint와 cloth2pose에서 estimation P를 L2 loss를 사용함. 그리고 sparsity constraint를 두어 candidate를 줄인다.

sparsity constraint: “only using the L2 loss is likely to generate many responses in various locations for one joint.” 라서 쓴다고한다. 제약을걸어버려서 가능한 해를 줄인다. 근데 왜 저렇게 제약을 거는거지? 기존에 저렇게 많이쓴건가…? 아님 resnet같은거라서 효과가있는건가..? 일단 넘어가고 이따 다시 돌아오자.

Method B) Pose-Guided Parsing Translator

“the goal of the pose guided parsing translator is to translate the source body semantic segmentation Ms to the target body semantic segmentation Mt according to the target pose P”

처음에 PGN(?, pretrained on the Crowd Instance-level Human Parsing dataset// left-hand, top clothes, … 그냥 segmentation 해준다.)을사용.

총20가지 categories (left hand, top clothes …)에 대한 것을 정확히 Map 하기 위해서 , one hot encoding을 사용한다!!! WoW

따라서 20-channel tensor를 구성한다. 각 채널은 categories를 나타내는 binary mask이다!

오우.. 신기하네 정확히 mapping을 하기 위해서 one-hot encoding을 한다라.. 딥러닝에서는 숫자별로 가까우면 영향이있으니, ㅎㅎ 뭐 당연한건가..?

“Due to the unnecessity of the clothing channel of Ms, we replace it with the original in-shop clothing mask Mc . This replacement facilitates offering the in-shop clothing shape to realize the virtual try-on service.” → 뭔말?

Pix2pix: 이미지 변환 모델, GAN의 모델의 일종. https://taeoh-kim.github.io/blog/image2image/
two downsampling layers
nine residual blocks?
two upsampling layers
highway connection. : 이건머징?

G: Generator / D: Discriminator

그냥 Conditional GAN loss 형식인데 수식관련해서 자세한건 모델실제 돌려보고, 뜯어볼때 살펴보자.

Method C)Segmentation Region Coloring

Rendering color. Proposed된 pose segmentation에 coloring을 하여, 옷을 입히는 형식을 취함. coloring같은경우는 복잡하지 않을 수 도있으니, 성능이 좋을것같다. 이는 어려운 문제를 한번에 풀려는 것보다, sub-problem들로 여러개를 만들어서 진행했기 때문에, 문제들을 쉽게 풀 수 있는 것이라 생각한다.

architecture: UNet (CGAN) with highway connections, six residual blocks. , Generator — Loss function: L1 norm (pixelwise multiplication)
Discriminator — binary classification 이므로 (real or fake), cross-entropy loss를 사용(보통 머신러닝이나 그런곳에서도 통상적으로 cross-entropy 를 사용한다. 왜일까? 실제 loss에 범주갯수를 집어넣어서 편하기도하다.. 이론적으로 증명은 아직 잘 모르겠다.)

ㅋㅋㅋ 재밋네

각 residual block는 two convolutional layers and ReLU were stacked.
highway connection → vanishing gradient(기울기 손실)을 avoid 한다고한다. 뭐 이전 데이터를 계속 학습시켜주니깐 그러겠지뭐

Background information은 filtering해준다. → 코드로 어떻게 짜는거지..?
target ground truth의 background도 제거.

위의그림 Ct, I’s, Mg 를 input으로 집어넣는다.

Method D) Salient Region Refinement.

한국어로 두드러지는 영역을 정제?한다? ㅋㅋ

두드러지는 영역이 무엇을가리키는걸까? → 중요한 영역이네, 얼굴 디테일, 몸의 형태, 옷의 디테일 등.

네트워크는 2개다.

  1. FacialGAN — 얼굴
  2. ClothingGAN — 옷

왜이건 따로안하고한번에하지? —> 연결되어잇으니깐~~~~~

residual output을 뽑아낸다고한다. residual 잔여..? 잘모르겠네.. 유튜브에 검색해서 찾아서 공부해보자. 아래는 Resnet논문을 리뷰한것이다.

레이어를 마구잡이로 depth 깊게쌓으면 성능이 좋아지거나 overfitting이 될 것같지만, 사실상은 아니다.

위 동영상에서 layer 수가 높은 것이 오히려 trainning error가 더 높다. 마찬가지로 test도. 이는 overfitting 문제라기보단 다른 문제일 것이다. 이 논문에서는 이를 잘 설명한다.

skip connection.

perceptual loss를 사용.

이미지 변환을할때 문제가 생긴다. per-pixel loss with a perceptual loss가 높은 성능을 보인다고 말함. 어떻게 생겨먹은 함수일까?

perceptual loss = feature reconstruction loss + style reconstruction loss

특정 pixel별로 어떤 특징들의 loss를 따로따로구분지어서 학습되게끔한거같다.

아 용어 약어들이 너무많아서 읽기가 불편하다…. 그래도 공부차원이니깐 ㅠㅠ참고보자..

ClothingGAN: 대부분의 VITON은 미리 뒤틀린 옷을 이미지에 직접 융합하여 자세한 옷 정보를 보존합니다. → 이러한것이 문제점으로 발생을해서 ClothingGAN을 만들었다. → 무슨문제점? → 옷이 뒤틀리거나 정확히 warped 되지 않은 옷 때문에 더 안좋게 된다.

→ 해결 → 자기네들의 이전 논문 FashionOn에서 해결함. → 조금더 손 보았다고는 하는데, FashionOn 을 읽어보지 않아서 정확히 구분하기는 어려운거같다.

다른것들도 막 그냥 어떤 module썻고 그에 맞는 loss 썻고 그정도다. 수식이 약어가 너무많아서 skip하도록한다. 꼼꼼히보면 어렵진않게 볼 수 있다.

Experiments

Dataset)

11283개 썻고 9590은 train, 1693은 test로 사용.

Implement details)

kernel 어떻게 썻고 그런거임.

Qualitative Results)

현재 sota인 VTNCAP이랑 비교, 그리고 GFLA라는 pose transfer를 이용하여 CP-vton(GFLA + CP-VTON)이랑 비교함.

이러한 위의 모든 방법론은 arbitrary pose와 try-on할때 모두 성공적으로 됐다. 하지만, VTNCAP, GFLA+CP-VTON은 몇가지 artifacts가 존재했다.

어떤 artifacts 인거지? → 안나오네,, 반면에 FashionOn(TF-TIS)는 some details와 local consistency를 잃는다고 나온다.

근데 qualitative result는 수치적으로는 표현하는 기법이 없나? 수치가 안나오넹..

Quantitative Result)

이건 수치적으로 나온다.

SSIM: Structural Similarity Index Metric

IS: Inception Score

Conclusion)

걍우리것이 짱이다.

나의 의견)

기존의 VITON 논문에서 발견되는 문제점들을 sub-problem으로 분리해서 각각 수행해버려서 나중엔 합쳐버린다. 이러한 부분에있어서 내가 CP-vton을 읽고 부족한부분을 해결한 느낌이다. ㅋㅋㅋ

다만, 이 TF-TIS는 자기네들이 실패한부분을 자세히 적어두지는않았다. 그림에 나와있는 것들은 전무 거의 민무늬라서 잘 나온것만 넣은거 같기도함;; 그리고 상용화를 만약 하게되면 사용자들이 input으로 넣은 포즈를 합성하고 싶을텐데.. 그게 아니라 recommend 되버리니깐 의문점이 많이 들긴한다.

→ pose가 제일 문제다.

왜 이러한 problem이 있을때 이러한 network를 사용했으며,~ 이러한 loss function을 사용했는지 더 자세히 공부.

→ 또 설치해서 돌릴 수 있는 지도 확인해보자. → 아직 코드없음;

--

--