- Today
- Total
목록Development/Python (5)
hye-log

1. Window Powershell 에서 아래 명령어를 입력하여 Poetry 설치 (Invoke-WebRequest -Uri https://install.python-poetry.org -UseBasicParsing).Content | py - 2. 시스템 환경 변수 편집에서 Path 추가 3. poetry 명령어를 입력했을 때 올바르게 작동하는지 확인 poetry --version ※ 참고 : https://python-poetry.org/docs/#installing-with-the-official-installer Introduction | Documentation | Poetry - Python dependency management and packaging made easy If you ins..

⚠️ 에러 상황 ✅ 해결 방법 1) 아래 코드를 실행했을 때 GLIBCXX_3.4.26이 존재하지 않음 strings /usr/lib/x86_64-linux-gnu/libstdc++.so.6 | grep GLIBCX 2) GLIBCXX_3.4.26을 다운로드 받기 위해서 gcc-8을 다운로드 받음 sudo apt update sudo apt install wget gcc-8 unzip libssl1.0.0 software-properties-common sudo add-apt-repository ppa:ubuntu-toolchain-r/test sudo apt update sudo apt-get install --only-upgrade libstdc++6 3) 다시 1) 코드를 실행하면 GLIBCXX_3..
✅ requirements.txt 로 패키지 내보내기 pip freeze > requirements.txt ✅ requirements.txt 로 패키지 설치하기 pip install -r requirements.txt

⚠️ 에러 상황 ✅ 해결 방법 image를 불러올 때 np.array로 불러오기 np.array(Image.open(image_path)) resnet 모델을 사용하여 transform을 적용한 경우 아래와 같이 reutrn if self.transform: image = self.transform(image=image) return image['image']

⚠️ 에러 상황 ✅ 해결 방법 0) typing_extensions가 설치되지 않았다면 설치하기 pip install typing-extensions 1) typing-extensions가 설치되었지만 최신 버전이 아닌 경우 official 홈페이지를 참고해서 버전 업데이트 pip install typing-extensions==4.4.0 https://pypi.org/project/typing-extensions/ typing-extensions Backported and Experimental Type Hints for Python 3.7+ pypi.org 참고) 현재 설치된 패키지의 버전 확인 pip list