# Taiwania 3 tips (2024)
## link to other Markdown
- [BIG SEVER tips (about basic Linux)](https://hackmd.io/@yaowenlee82/r1W1eLSnC)
- [How to use ORCHIDEE in off-line mode with IPSL LibIGCM (2023/02/13)(Yi-Ying Chen, RCEC)](https://hackmd.io/@yaowenlee82/ORCHIDEE0213)
- [How to use ORCHIDEE with libIGCM? (2023/02/20)(Yi-Ying Chen, RCEC)](https://hackmd.io/@yaowenlee82/ByxoQ5-Co)
## TWCC-III
- [Taiwania 3 manual](https://man.twcc.ai/@TWCC-III-manual/H1bEXeGcu) (Chinese version)
- [IDExpert](https://play.google.com/store/apps/details?id=com.changingtec.idexpert&hl=zh_TW) for 2FA
- host\:t3-c3.nchc.org.tw / port:22
## .bashrc settings (load module when login)
```
module load old-module
module load rcec/ufs-ext/bbc872c-intel19-ompi
module load libs/gdal/3.4.1
module load biology/Python/3.11.0
```
## ORCHIDEE settings
### clean<span/>.sh (change job name, remove the files we don't need)
`rm -rf /work/u2936446/IGCM_OUT/OL2/PROD/secsto/{Job name}`
### config<span/>.card (change job name/date range/output path/ restart rule...)
`JobName={Job name}`
```
DateBegin=1993-01-01
DateEnd=2017-12-31
```
`ARCHIVE=/work/{t3 account}/`
`[Restarts] OverRule=n`
### /PARAM/run.def (change region/PFT parameter)
```
#small region (Taipei)
LIMIT_WEST=121.00
LIMIT_EAST=122.00
LIMIT_SOUTH=24.5
LIMIT_NORTH=25.5
```
### /COMP/orchidee_ol.card (set BoundaryFiles)
```
#2km
[BoundaryFiles]
List=(/project/MST_AS3033/orchideeshare/METRO/WRF_2km/TCCIP_${year}.nc, forcing_file.nc)
```
### /COMP/sechiba.card (set BoundaryFiles)
```
#PFT maps
[InitialStateFiles]
List=(/project/MST_AS3033/orchideeshare/MAPS/MAPS/soils_param.nc, soils_param.nc), \
(/project/MST_AS3033/orchideeshare/MAPS/MAPS/cartepente2d_15min.nc, cartepente2d_15min.nc)
[BoundaryFiles]
List=(/project/MST_AS3033/orchideeshare/MAPS/MAPS/PFT_map_tw_5km_${year}.nc, PFTmap.nc)
```
### /COMP/stomate.card (set BoundaryFiles)
```
[BoundaryFiles]
List= ()
ListNonDel= (/project/MST_AS3033/orchideeshare/MAPS/MAPS/reftemp.nc, .)
```
### summit a job
>1. `rm Job file`
>2. `rm run.card`
>3. `./clean.sh`
>4. check your Job file settings
>5. sbatch Job file (start run)
## Ferret Installation in Taiwania 3
`module load miniconda3/24.1.2`
- create env & PyFerret (first time)
`conda create -n FERRET -c conda-forge pyferret ferret_datasets --yes`(注意ferret或numpy版本可能造成安裝失敗)
[pyferret issue with anaconda install, MacOS, Apple silicon #145](https://github.com/NOAA-PMEL/PyFerret/issues/145)
**`conda create --name FERRET_new --clone /home/u2936446/.conda/envs/FERRET`**
```
# /home/u2936446/ferret_env.yml
conda env create -f ferret_env.yml -n ferret_new
# 忽略錯誤
conda install pyferret ferret_datasets
```
- To start using PyFerret
`conda activate FERRET`
`ferret`
- leave this environment
`conda deactivate`
### Ferret tips
- use data
`use {filename}`
- show data
`sh da`
- Plot
`shade {var}[i=?, j=?, k=?]`/`plot {var}[i=?, j=?, k=?]`
e.g.
`plot LAI[i=@ave, j=@ave, k=24]`
- save
`frame /files=test1.gif`