0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

指定の元素種を含む POSCAR ファイルパスのリ ストの取得(ログ)

Last updated at Posted at 2024-01-09

目標

ここでは,POSCARファイルが存在するパスのリストを用いて,特定の元素種を含むPOSCARファイルパスのリストを取得する.
例として,元素種C, Oを含むPOSCARファイルパスのリストを取得したいときは,以下のようにPythonスクリプトの第1引数以降に,その元素種を半角英字で引き渡す.尚,複数の元素種を指定する場合には,半角スペース1文字で区切って入力する.

実行手順ログ

ここでは,元素種P,Hを含むPOSCARファイルパス一覧を取得する.

pwd
/mnt/ssd_elecom_c2c_960gb/scripts/get_some_speceis_existed_poscar_path_list

ls -CF
C_O_existed_poscar_file_path_list.npy*    N_H_existed_poscar_folder_path_list.npy*       get_some_speceis_existed_poscar_path_list.py.sh*
C_O_existed_poscar_folder_path_list.npy*  get_poscar_existed_path_list.py*               poscar_existed_file_path_list.npy*
N_H_existed_poscar_file_path_list.npy*    get_some_speceis_existed_poscar_path_list.py*  poscar_existed_folder_path_list.npy*
time python3 get_some_speceis_existed_poscar_path_list.py P H

len(poscar_abs_path_list_loaded): 308325
100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████| 308325/308325 [12:26<00:00, 413.25it/s]
len(P_H_existed_poscar_file_path_list): 39122
P_H_existed-poscar file, and folder path list were saved as .npy!!!

real 12m36.668s
user 4m10.564s
sys 9m20.628s

ls -CF
C_O_existed_poscar_file_path_list.npy*    P_H_existed_poscar_file_path_list.npy*         get_some_speceis_existed_poscar_path_list.py.sh*
C_O_existed_poscar_folder_path_list.npy*  P_H_existed_poscar_folder_path_list.npy*       poscar_existed_file_path_list.npy*
N_H_existed_poscar_file_path_list.npy*    get_poscar_existed_path_list.py*               poscar_existed_folder_path_list.npy*
N_H_existed_poscar_folder_path_list.npy*  get_some_speceis_existed_poscar_path_list.py*
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?