Size: 2276
Comment:
|
← Revision 6 as of 2025-01-30 11:05:17 ⇥
Size: 4641
Comment:
|
Deletions are marked like this. | Additions are marked like this. |
Line 3: | Line 3: |
An open source package management system and environment management system | An open source package management system and environment management system<<BR>> |
Line 7: | Line 7: |
== Installation == | Please install conda on your PC referring to the IGWN webpage.<<BR>> [[https://computing.docs.ligo.org/conda/usage/#local]] |
Line 9: | Line 10: |
Download the installer from [[https://www.anaconda.com/distribution/|official site]] or from wget | == IGWN "Local usage"の和訳 (2023-01-11) == このセクションはローカルマシン、つまりラップトップやデスクトップワークステーションで conda を使うユーザ向けに書かれています。 |
Line 11: | Line 13: |
{{{ pem@PEM:~$ wget https://repo.anaconda.com/archive/Anaconda3-2019.07-Linux-x86_64.sh ... pem@PEM:~$ bash Anaconda3-2019.07-Linux-x86_64.sh |
1. condaのインストール まず、conda自体のインストールです。Mambaforgeからcondaをインストールすることをお勧めします。[[https://github.com/conda-forge/miniforge#mambaforge]] 1. コマンドラインでインストーラーをダウンロードする。 {{{ $ curl -L -O https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-x86_64.sh }}} 2. インストーラーを実行する。 {{{ $ bash Mambaforge-Linux-x86_64.sh |
Line 16: | Line 23: |
Welcome to Anaconda3 2019.07 | Welcome to Mambaforge 22.9.0-2 |
Line 21: | Line 28: |
>>> }}} press ENTER {{{ =================================== Anaconda End User License Agreement =================================== |
>>> (enterキーを押す) |
Line 29: | Line 30: |
Copyright 2015, Anaconda, Inc. ... |
(中略) |
Line 33: | Line 33: |
[no] >>> Please answer 'yes' or 'no':' }}} 'yes' {{{ Anaconda3 will now be installed into this location: /home/pem/anaconda3 |
[no] >>> (yesと回答する) |
Line 41: | Line 35: |
- Press ENTER to confirm the location - Press CTRL-C to abort the installation - Or specify a different location below |
(中略) |
Line 45: | Line 37: |
[/home/pem/anaconda3] >>> }}} press ENTER {{{ PREFIX=/home/pem/anaconda3 Unpacking payload ... Collecting package metadata (current_repodata.json): done Solving environment: done |
Do you wish the installer to initialize Mambaforge by running conda init? [yes|no] [no] >>> (yesと回答する) |
Line 54: | Line 41: |
# All requested packages already installed. | (中略) |
Line 56: | Line 43: |
installation finished. WARNING: You currently have a PYTHONPATH environment variable set. This may cause unexpected behavior when running the Python interpreter in Anaconda3. For best results, please verify that your PYTHONPATH only points to directories of packages that are compatible with the Python interpreter in Anaconda3: /home/pem/anaconda3 Do you wish the installer to initialize Anaconda3 by running conda init? [yes|no] [no] >>> }}} 'yes' {{{ ... Thank you for installing Anaconda3! |
==> For changes to take effect, close and re-open your current shell. <== |
Line 72: | Line 45: |
=========================================================================== | If you'd prefer that conda's base environment not be activated on startup, set the auto_activate_base parameter to false: |
Line 74: | Line 48: |
Anaconda and JetBrains are working together to bring you Anaconda-powered environments tightly integrated in the PyCharm IDE. |
conda config --set auto_activate_base false |
Line 77: | Line 50: |
PyCharm for Anaconda is available at: https://www.anaconda.com/pycharm |
Thank you for installing Mambaforge! }}} 2. condaの設定を確認する 正しくインストールされていたら、新しいターミナルウィンドウを開いた後 condaが正しく動作することを確認できるはずです。(出力結果は人や時によって変わります) {{{ $ conda info active environment : None shell level : 0 user config file : /home/ユーザー名//.condarc populated config files : /home/ユーザー名//mambaforge/.condarc conda version : 22.9.0 conda-build version : not installed python version : 3.10.6.final.0 virtual packages : __cuda=11.7=0 __linux=5.10.102.1=0 __glibc=2.31=0 __unix=0=0 __archspec=1=x86_64 base environment : /home/ユーザー名//mambaforge (writable) conda av data dir : /home/ユーザー名//mambaforge/etc/conda conda av metadata url : None channel URLs : https://conda.anaconda.org/conda-forge/linux-64 https://conda.anaconda.org/conda-forge/noarch package cache : /home/ユーザー名//mambaforge/pkgs /home/ユーザー名//.conda/pkgs envs directories : /home/ユーザー名//mambaforge/envs /home/ユーザー名//.conda/envs platform : linux-64 user-agent : conda/22.9.0 requests/2.28.1 CPython/3.10.6 Linux/5.10.102.1-microsoft-standard-WSL2 debian/11 glibc/2.31 UID:GID : 1000:1000 netrc file : None offline mode : False }}} * conda-forgeチャンネルが設定されていることを確認する IGWN ソフトウェアは conda-forge パッケージチャンネルにのみアップロードされます。上記の conda info の出力に conda-forge への参照がない場合は、以下のように conda-forge チャンネルを手動で設定する必要があります。 {{{ $ conda config --add channels conda-forge $ conda config --set channel_priority strict }}} == condaの削除 == * 環境一覧を表示 {{{ $ conda info -e # conda environments: # base * /home/ユーザー名/anaconda3 igwn-py39-20220317 /home/ユーザー名/anaconda3/envs/igwn-py39-20220317 |
Line 81: | Line 109: |
reload bashrc {{{ pem@PEM:~$ source ~/.bashrc (base) pem@PEM:~$ }}} |
* いらない環境を削除 {{{ $ conda remove --name ENV_NAME --all }}} * 不要になったパッケージやキャッシュを削除 {{{ $ conda clean --all }}} * conda自身を削除 {{{ $ conda install anaconda-clean $ anaconda-clean --yes $ rm -r /home/ユーザー名/anaconda3 }}} 最後にPATHの設定を戻しておくために.bash_profileからAnacondaのパスを消しておく |
Conda (Anaconda / Miniconda)
An open source package management system and environment management system
Please install conda on your PC referring to the IGWN webpage.
https://computing.docs.ligo.org/conda/usage/#local
IGWN "Local usage"の和訳 (2023-01-11)
このセクションはローカルマシン、つまりラップトップやデスクトップワークステーションで conda を使うユーザ向けに書かれています。
1. condaのインストール
まず、conda自体のインストールです。Mambaforgeからcondaをインストールすることをお勧めします。https://github.com/conda-forge/miniforge#mambaforge
- コマンドラインでインストーラーをダウンロードする。
$ curl -L -O https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-x86_64.sh
- インストーラーを実行する。
$ bash Mambaforge-Linux-x86_64.sh Welcome to Mambaforge 22.9.0-2 In order to continue the installation process, please review the license agreement. Please, press ENTER to continue >>> (enterキーを押す) (中略) Do you accept the license terms? [yes|no] [no] >>> (yesと回答する) (中略) Do you wish the installer to initialize Mambaforge by running conda init? [yes|no] [no] >>> (yesと回答する) (中略) ==> For changes to take effect, close and re-open your current shell. <== If you'd prefer that conda's base environment not be activated on startup, set the auto_activate_base parameter to false: conda config --set auto_activate_base false Thank you for installing Mambaforge!
- コマンドラインでインストーラーをダウンロードする。
2. condaの設定を確認する
- 正しくインストールされていたら、新しいターミナルウィンドウを開いた後 condaが正しく動作することを確認できるはずです。(出力結果は人や時によって変わります)
$ conda info active environment : None shell level : 0 user config file : /home/ユーザー名//.condarc populated config files : /home/ユーザー名//mambaforge/.condarc conda version : 22.9.0 conda-build version : not installed python version : 3.10.6.final.0 virtual packages : __cuda=11.7=0 __linux=5.10.102.1=0 __glibc=2.31=0 __unix=0=0 __archspec=1=x86_64 base environment : /home/ユーザー名//mambaforge (writable) conda av data dir : /home/ユーザー名//mambaforge/etc/conda conda av metadata url : None channel URLs : https://conda.anaconda.org/conda-forge/linux-64 https://conda.anaconda.org/conda-forge/noarch package cache : /home/ユーザー名//mambaforge/pkgs /home/ユーザー名//.conda/pkgs envs directories : /home/ユーザー名//mambaforge/envs /home/ユーザー名//.conda/envs platform : linux-64 user-agent : conda/22.9.0 requests/2.28.1 CPython/3.10.6 Linux/5.10.102.1-microsoft-standard-WSL2 debian/11 glibc/2.31 UID:GID : 1000:1000 netrc file : None offline mode : False
- conda-forgeチャンネルが設定されていることを確認する
- IGWN ソフトウェアは conda-forge パッケージチャンネルにのみアップロードされます。上記の conda info の出力に conda-forge への参照がない場合は、以下のように conda-forge チャンネルを手動で設定する必要があります。
$ conda config --add channels conda-forge $ conda config --set channel_priority strict
- IGWN ソフトウェアは conda-forge パッケージチャンネルにのみアップロードされます。上記の conda info の出力に conda-forge への参照がない場合は、以下のように conda-forge チャンネルを手動で設定する必要があります。
condaの削除
- 環境一覧を表示
$ conda info -e # conda environments: # base * /home/ユーザー名/anaconda3 igwn-py39-20220317 /home/ユーザー名/anaconda3/envs/igwn-py39-20220317
- いらない環境を削除
$ conda remove --name ENV_NAME --all
- 不要になったパッケージやキャッシュを削除
$ conda clean --all
- conda自身を削除
$ conda install anaconda-clean $ anaconda-clean --yes $ rm -r /home/ユーザー名/anaconda3
最後にPATHの設定を戻しておくために.bash_profileからAnacondaのパスを消しておく