🤍 전 강의 25% 할인 중 🤍

2024년 상반기를 돌아보고 하반기에도 함께 성장해요!
인프런이 준비한 25% 할인 받으러 가기 >>

  • 카테고리

    질문 & 답변
  • 세부 분야

    컴퓨터 비전

  • 해결 여부

    미해결

keras-retinanet 라쿤학습 시 오류

20.11.13 13:23 작성 조회수 75

0

아래 구문으로 레티나넷 학습 평가를 출력할 때  

AttributeError: 'tuple' object has no attribute 'items'

오류가 나옵니다. 해결방법이 궁금합니다.

사용os은 window 10입니다.

====================================================================================

# print evaluation

total_instances = []

precisions = []

for label, (average_precision, num_annotations) in average_precisions.items():

    print('{:.0f} instances of class'.format(num_annotations),

          generator.label_to_name(label), 'with average precision: {:.4f}'.format(average_precision))

    total_instances.append(num_annotations)

    precisions.append(average_precision)

if sum(total_instances) == 0:

    print('No test instances found.')

print('Inference time for {:.0f} images: {:.4f}'.format(generator.size(), inference_time))

print('mAP using the weighted average of precisions among classes: {:.4f}'.format(sum([a * b for a, b in zip(total_instances, precisions)]) / sum(total_instances)))

print('mAP: {:.4f}'.format(sum(precisions) / sum(x > 0 for x in total_instances)))

======================================================================================

답변 1

답변을 작성해보세요.

0

안녕하십니까,

전체 오류 메시지를 올려주시겠습니까?

감사합니다.

채널톡 아이콘