pixi init learn_pixi
cd learn_pixi
pixi add python=3.9
pixi add rich // from conda-forge chanel
pixi add --pypi cowsay // from pip
pixi install
pixi run cowsay -t hello| from pypdf import PdfReader, PdfWriter | |
| import argparse | |
| import os | |
| import sys | |
| import logging | |
| # Configure basic logging for better user feedback | |
| logging.basicConfig(level=logging.INFO, format='%(levelname)s: %(message)s') | |
| def compress_pdf_lossless(input_path: str, output_path: str) -> None: |
| # https://micromamba-docker.readthedocs.io/en/latest/quick_start.html#running-commands-in-dockerfile-within-the-conda-environment | |
| FROM mambaorg/micromamba:1.5.1 | |
| # RUN mkdir /home/mambauser/eggnog | |
| COPY --chown=$MAMBA_USER:$MAMBA_USER environments.yml /tmp/env.yml | |
| # to activate the conda environment | |
| ARG MAMBA_DOCKERFILE_ACTIVATE=1 | |
| RUN micromamba install -y --file env.yml && \ | |
| micromamba clean --all --yes |
| # ref: https://beta.ruff.rs/docs/rules/ | |
| [tool.ruff] | |
| # defaults to 88 like black | |
| line-length = 100 | |
| # the python version to target, useful when considering code upgrades, defaults to "py310" | |
| target-version = "py310" | |
| # Linting file type |
| Name | entry_code | |
|---|---|---|
| Abagovomab | 3YK0326U7X | |
| Abelacimab | KX1N4TV7UY | |
| Abiprubart | No entry | |
| Abituzumab | 724QD330RD | |
| Abrilumab | Y9UQ37XT2T | |
| Acrixolimab | KHG83J8RMW | |
| Actoxumab | G3LU5LC5SX | |
| Adalimumab | FYS6T7F842 | |
| Adebrelimab | 1XBY50W1OX |
| import pandas as pd | |
| import matplotlib.pyplot as plt | |
| df = pd.read_csv("./data/230116_Tumor_regression.csv") | |
| # Group Mouse Day Tumor(mm2) | |
| # 0 G1 2210ES50_1 0 0.000000 | |
| # 1 G1 2210ES50_1 7 107.827200 | |
| # 2 G1 2210ES50_1 11 674.233875 | |
| # 3 G1 2210ES50_1 14 1573.768326 |
| import matplotlib.pyplot as plt | |
| import pands as pd | |
| df = pd.read_csv("./data/230119_df_Bernard_Thienpont.csv") | |
| # CellType Sample SampleType Values | |
| # 0 NK_T 1 Tumor 0.007453 | |
| # 1 NK_T 4 Tumor 0.018171 | |
| # 2 NK_T 5 Tumor 0.052632 | |
| # 3 NK_T 6 Normal 0.151292 |
| import warnings | |
| import matplotlib.pyplot as plt | |
| import pandas as pd | |
| import seaborn as sns | |
| from scipy import stats | |
| df = pd.read_csv("../input/tumor_growth.csv") | |
| df.head() |
NVIDIA ๊ทธ๋ํฝ ์นด๋(ํน์ GPU)์ ์ปดํจํฐ ์ด์ ์ฒด์ (OS) ๊ฐ์ ํต์ ์ ๊ด๋ฆฌํ๊ณ ์ ์ดํ๋ ์ํํธ์จ์ด๋ก NVIDIA GPU๋ฅผ ์ปดํจํฐ์์ ์ฌ๋ฐ๋ฅด๊ฒ ์ธ์ํ๊ณ ์ ์ด, ๋ฆฌ์์ค๋ฅผ ์ต์ ํํ๊ณ , ๊ทธ๋ํฝ ์์ ์ ์ฒ๋ฆฌํ๊ธฐ ์ํด GPU์ ๋ช ๋ น์ ์ ๋ฌํ๋ ์ญํ
CUDA๋ C/C++ ํ๋ก๊ทธ๋๋ฐ ์ธ์ด๋ฅผ ๊ธฐ๋ฐ์ผ๋ก ํ๋ฉฐ, GPU์์ ๋ณ๋ ฌ ์ฝ๋๋ฅผ ์์ฑํ๊ณ ์คํํ ์ ์๋ ํ๋ถํ ๋ผ์ด๋ธ๋ฌ๋ฆฌ์ ๋๊ตฌ๋ฅผ ์ ๊ณต, CUDA๋ GPU ์ปดํจํ ์์ ์ผ์ข ์ ์ปดํ์ผ๋ฌ ์ญํ ์ ์ํํ๋ค.
CUDA๋ 2๊ฐ์ API๋ฅผ ๊ฐ์ง๊ณ ์๋๋ฐ, ํ๋๋ runtime API์ด๊ณ ๋ค๋ฅธ ํ๋๋ driver API์ด๋ค. ๊ฐ API๊ฐ ๊ฐ์์ version์ ๊ฐ์ง๊ณ ์๋ค.
nvidia-smi๋ runtime API๋ก GPU ๋๋ผ์ด๋ฒ์ ์ํด ์ค์น๋๋ค. nvcc๋ CUDA toolkit์ ์ํด ์ค์น๋๋ค.