본문 바로가기
AI/pose with style

CIHP-PGN

by wenect 2023. 2. 14.

CIHP-PGN : Crowd Instance-level Human Parsing via Part Grouping Network

 

저장경로를 datasets/silhouatte/으로 하며 파일에 _sil.png로 한다.

	###### gryscale silhouatte
    sil_dir = os.path.join(args.output, 'silhouette')
    if not os.path.exists(sil_dir):
        os.makedirs(sil_dir)
        
        
        # Iterate over training steps.
        ...
        
        
        ###### gryscale silhouatte
        gray = cv2.cvtColor(msk[0], cv2.COLOR_BGR2GRAY)       
        (thresh, blackAndWhiteImage) = cv2.threshold(gray, 1, 255, cv2.THRESH_BINARY)
        cv2.imwrite('{}/{}_sil.png'.format(sil_dir, img_id), blackAndWhiteImage)

 

source : datasets/images/bill.jpg
  output:output/cihp_edge_maps/bill.png
edge추출(사용x)
output:cihp_parsing_maps
사용x
output:output/silhouatte/bill_sil.png
실루엣 추출-detectron2에서 사용

 

inf_pgn.py
0.01MB

 

참고자료

https://github.com/Engineering-Course/CIHP_PGN

 

'AI > pose with style' 카테고리의 다른 글

YOLO V7 - installation  (0) 2023.02.16
Detection Human and garments  (0) 2023.02.15
Pose with Style - Test  (0) 2023.02.14
CIHP-PGN Multi-Person  (0) 2023.02.14
detectron2  (0) 2023.02.14

댓글