본문 바로가기

▶ 자연과학/▷ Python

【Python】 자연어 처리 및 LLM 유용 함수 모음 자연어 처리 및 LLM 유용 함수 모음  추천글 : 【Python】 파이썬 유용 함수 모음, 【알고리즘】 21강. NLP와 LLM 1. 자연어 처리 유용 함수 [본문]2. Llama2 응용 [본문]a. ollama.ai : Llama3, Phi-3, Mistral, Gemma, etcb. GroqChat : Mixtral, Llama3, Gemma 1. 자연어 처리 유용 함수 [목차]⑴ 주어진 문장을 자동으로 영어로 번역하는 함수 ! pip install --upgrade googletrans httpx httpcore deep_translatordef to_english (sentence): from deep_translator import GoogleTranslat..
【Python】 파이썬 앱 라이브러리 파이썬 앱 라이브러리(Python app library) 추천글 : 【컴퓨터과학】 컴퓨터과학 목차, 【Python】 파이썬 목차 1. 정사면체의 3차원 뷰어 [본문] 2. 파이썬 시각화를 위한 Bokeh 설치하기 [본문] 3. 파이썬으로 html 형식의 글을 자동 생성하는 것 (automatic PDF report) [본문] 4. 메타 Segment-Anything Model (SAM) + 공간전사체 분석 (IAMSAM) [본문] 5. 유기화합물 3차원 분자식[본문] 📃 파이썬 프로젝트 만들기: app.py ▶ 파이썬 코드를 이용한 앱 제작 과정 1. 정사면체의 3차원 뷰어 [목차] import dash from dash import html, dcc from dash.dependencies import..
【Python】 MinIO 유용 함수 모음 MinIO 유용 함수 모음 추천글 : 【Python】 파이썬 목차 1. MinIO [본문] 2. 파이썬 유용 함수 모음 [본문] 3. 터미널 유용 커멘드 모음 [본문] 1. MinIO [목차] ⑴ AWS S3-compatible object storage system ⑵ Synology NAS의 상위 버전 ① 이유 1. 한 번 업로드 하면 삭제가 불가능하도록 셋팅할 수 있음 ② 이유 2. 보안 수준이 더 높음 ⑶ 사용법 ① 1단계. 여기에서 MinIO Client 설치 : Linux Intel인 경우 다음과 같음 curl https://dl.min.io/client/mc/release/linux-amd64/mc \ --create-dirs \ -o $HOME/minio-binaries/mc chmod +..
【Python】 파이썬 주요 트러블슈팅 [61-80] 파이썬 주요 트러블슈팅 [61-80] 추천글 : 【Python】 파이썬 목차 61. ImportError: libGL.so.1: cannot open shared object file: No such file or directory ⑴ (package) 문제 상황 : import cv2를 할 때 문제가 발생함 ⑵ (package) 해결방법 1. Ubuntu/Debian sudo apt-get update sudo apt-get install -y libgl1-mesa-glx pip uninstall opencv-python pip install opencv-python ⑶ (package) 해결방법 2. CentOS/Fedora sudo yum update sudo yum install -y mesa-l..
【Python】 파이썬 프로젝트 만들기: app.py 파이썬 프로젝트 만들기: app.py 추천글 : 【Python】 파이썬 목차 1. 프로젝트 구성 [본문] 2. 프로젝트 실행 [본문] a. 파이썬 앱 라이브러리 1. 프로젝트 구성 (예시) [목차] ⑴ 개요 : 다음 열거되어 있는 여러 구성 중 README.md를 제외하고는 파일명이 꼭 지켜질 필요는 없으나 관용적으로 사용됨 ⑵ README.md ① 깃허브 repository를 설명해주는 마크다운 문서 : 마크다운이므로 html 코드를 삽입할 수도 있음 ② 내용 형식은 자유이며 설치 방법, 사용 방법은 꼭 써주어야 함 ⑶ .py, .yml, .xml : 디렉토리 안에 있지 않은 파일들 ① .py : 파이썬 스크립트 파일 ② .yml : 깃허브 홈페이지를 만들 때 가장 코어 역할을 하는 _config.ym..
【Python】 파이썬에서 tensorflow 환경 조성 및 Jupyter 사용법 파이썬에서 tensorflow 환경 조성 및 Jupyter 사용법 추천글 : 【Python】 파이썬 목차 1. 개요 [본문] 2. Anaconda 설치 [본문] 3. Anaconda Prompt (anaconda3) [본문] 4. Jupyter 설치 [본문] 5. 아나콘다 환경 공유하기 [본문] 1. 개요 [목차] ⑴ Tensorflow, Keras 등은 파이썬에서 인공신경망을 구현하기 위해 만들어짐 ⑵ 2017년부터 R에서 실행 가능한 버전이 출시됨 ⑶ 맥북은 터미널을 제공하므로 자연스럽게 설치돼 있음 2. Anaconda 설치 [목차] ⑴ Windows 기준 ① 1단계. 설치 웹사이트 Anaconda | Individual Edition Anaconda's open-source Individual E..
【Python】 파이썬 주요 트러블슈팅 [41-60] 파이썬 주요 트러블슈팅 [41-60] 추천글 : 【Python】 파이썬 목차 41. ImportError: cannot import name 'mnist.data_utils' ⑴ (grammar) 문제 상황 from mnist.data_utils import load_data ... MNIST_data = h5py.File("mnist/MNISTdata.hdf5", 'r') ⑵ (grammar) 해결책 1. MNIST 데이터를 다운받은 뒤 다음과 같이 코드를 실행 MNIST_data = h5py.File("./MNISTdata.hdf5", 'r') X_train = np.float32(MNIST_data['x_train'][:]) y_train = np.int32(np.array(MNIST_data['y..
【Python】 파이썬 주요 트러블슈팅 [21-40] 파이썬 주요 트러블슈팅 [21-40] 추천글 : 【Python】 파이썬 목차 21. rpy2.rinterface_lib.embedded.RRuntimeError: Error in library(ggplot2) : there is no package called 'ggplot2' ⑴ (package) 해결책 : R로 접속한 뒤 install.packages('ggplot2') 22. ERROR: pip's dependecy resolver does not currently take into account all the packages that are installed. This behavior is the source of the following dependency conflicts. stlearn 0...