見出し画像

PyGPlates使ってみた(1)

地球のプレート運動を復元するソフトウェア「GPlates」が Python で動かせるようになっていました.サイトの緯度経度を数値で入力できるようになったのが個人的にはメリットかなと思います.
公式ページはあるのですが,ダウンロードページを探すのさえ大変だったのでまとめておきます.

準備

(1) PyGPlates のダウンロード

GPlates のページから,Download pyGPlates を選択します.

別のダウンロードページに飛ばされるので,Pythonのバージョン,Win/Macを確認して適切なバージョンをダウンロードします(氏名・メールアドレス・使用目的の入力が必要でした).ダウンロードしたファイルは展開しておきます.

(2) Rotation Model のダウンロード

EarthByte にあるGPlatesのページから,最新のデータセットのダウンロードページに飛びます.

GPlates-compatible data files から,EarthByte Global Rotation Model をダウンロードし,zip ファイルを展開します.

テスト

PyGPlates がインポートできるかを確認します.
プログラムを動かすフォルダに,先ほど展開した pygplates のフォルダと ローテーションファイルのフォルダを移動させます.pygplates は,外のフォルダ(pygplates_0.36.0_py38_win64)から中のpygplatesというファイルを出しておきます.

フォルダの構成

test.ipynb というノートブックを作成し,とりあえず以下を打ってみます.

import pygplates

すると以下のような RuntimeError が出たのですが,もう一度同じセルを実行すると(なぜか)今度は上手くいきました.

実行時のエラー表示.同じセルをもう一度実行すると解消される

色々試してみましょう

print(pygplates.__version__) # 出力:0.36.0

point = pygplates.PointOnSphere(35, 135)
latitude, longitude = point.to_lat_lon()
print(latitude, longitude) # 出力:35.0 135.0

# ローテーションモデルの読み込み
rotation_model = pygplates.RotationModel('Rotations\\Muller2019-Young2019-Cao2020_CombinedRotations.rot')

次回はもう少し遊んでみようと思います.

引用

GPlates のページには以下を引用するように書かれています.

GPlates Citation:
Müller, R. D., Cannon, J., Qin, X., Watson, R. J., Gurnis, M., Williams, S., et al. 2018. GPlates: Building a virtual Earth through deep time. Geochemistry, Geophysics, Geosystems, 19. doi:10.1029/2018GC007584.
PyGPlates, PlateTectonicTools, GPlately Citation:
Mather, B. R., Müller, R. D., Zahirovic, S., Cannon, J., Chin, M., Ilano, L., et al. Deep time spatio-temporal data analysis using pyGPlates with PlateTectonicTools and GPlately. Geoscience Data Journal, https://doi.org/10.1002/gdj3.185

https://www.gplates.org/

また,ローテーションファイルを使う際には,以下を引用するよう書かれています.

Müller, RD, Zahirovic, S, Williams, SE, Cannon, J, Seton, M, Bower, DJ, Tetley, MG, Heine, C, Le Breton, E, Liu, S, Russell, SHJ, Yang, T, Leonard, J & Gurnis, M 2019, 'A global plate model including lithospheric deformation along major rifts and orogens since the Triassic', Tectonics, vol. 38, no. Fifty Years of Plate Tectonics: Then, Now, and Beyond.
Cao, X, Zahirovic, S, Li, S, Suo, Y, Wang, P, Liu, J & Muller, RD 2020, 'A deforming plate tectonic model of the South China Block since the Jurassic', Gondwana Research.
Young, A, Flament, N, Maloney, K, Williams, S, Matthews, K, Zahirovic, S & Müller, RD 2018, 'Global kinematics of tectonic plates and subduction zones since the late Paleozoic Era', Geoscience Frontiers.
Torsvik, TH, Steinberger, B, Shephard, GE, Doubrovine, PV, Gaina, C, Domeier, M, Conrad, CP & Sager, WW 2019, 'Pacific‐Panthalassic reconstructions: Overview, errata and the way forward', Geochemistry, Geophysics, Geosystems, vol. 20, no. 7, pp. 3659-89.

Rotations/README.txt

この記事が気に入ったらサポートをしてみませんか?