Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion chapter5/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ $ unzip -n chapter5/data/ml-10m.zip -d chapter5/data

### Poetry를 사용해서 환경 구축하기

python 버전은 python3.7.8을 사용합니다. python3.7.8 설치에는 [pyenv](https://github.com/pyenv/pyenv) 등의 버전 관리 도구를 사용하십시오. 또한, 여기에서는 [poetry](https://python-poetry.org/)를 패키지 관리 도구로 사용하므로 설치하기 바랍니다. 참골, MacOS Monterey에 `pyenv`와 `poetry`를 설치하는 순서를 설명합니다. Windows나 Linux의 경우에는 여러분이 사용하는 OS에 해다아는 명령어로 변경하거나, 도커를 사용한 환경 구축하기를 참조하기 바랍니다.
python 버전은 python3.7.8을 사용합니다. python3.7.8 설치에는 [pyenv](https://github.com/pyenv/pyenv) 등의 버전 관리 도구를 사용하십시오. 또한, 여기에서는 [poetry](https://python-poetry.org/)를 패키지 관리 도구로 사용하므로 설치하기 바랍니다. 참골, MacOS Monterey에 `pyenv`와 `poetry`를 설치하는 순서를 설명합니다. Windows나 Linux의 경우에는 여러분이 사용하는 OS에 해당하는 명령어로 변경하거나, 도커를 사용한 환경 구축하기를 참조하기 바랍니다.

#### python3.7.8 설치

Expand Down
2 changes: 1 addition & 1 deletion chapter5/util/metric_calculator.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ def _calc_recall_at_k(
self, true_user2items: Dict[int, List[int]], pred_user2items: Dict[int, List[int]], k: int
) -> float:
scores = []
# テストデータに存在する各ユーザーのrecall@kを計算
# 테스트 데이터에 존재하는 각 사용자의 recall@k를 계산한다
for user_id in true_user2items.keys():
r_at_k = self._recall_at_k(true_user2items[user_id], pred_user2items[user_id], k)
scores.append(r_at_k)
Expand Down