SwarmFACE

SwarmFACE#

%load_ext watermark
%watermark -i -v -p SwarmFACE,viresclient,numpy,pandas,matplotlib
Python implementation: CPython
Python version       : 3.11.6
IPython version      : 8.18.0

SwarmFACE  : 0.3.0
viresclient: 0.15.0
numpy      : 1.26.0
pandas     : 2.1.3
matplotlib : 3.8.2

Package authors: Adrian Blagau, Joachim Vogt

Resources#

Python package: SwarmFACE
Code
Documentation

Blagau A and Vogt J (2023) SwarmFACE: A Python package for field-aligned currents exploration with Swarm. Front. Astron. Space Sci. 9:1077845. doi: 10.3389/fspas.2022.1077845

Example usage#

For more examples, see ablagau/SwarmFACE

Here we demonstrate the simplest algorithm, the single-satellite FAC method, using SwarmFACE.j1sat.j1sat

from SwarmFACE.j1sat import j1sat

The package is currently awaiting updates to make it work here.

Example usage:

# Settings
dtime_beg = '2014-05-04T17:48:00'
dtime_end = '2014-05-04T17:54:00'
sat = ['C']
res = 'LR'
N3d=[0.2276, 0.6924, 0.6847]
tincl = ['2014-05-04 17:49:50', '2014-05-04 17:52:44']

# Fetch data and apply algorithm using above settings
j_df, input_df, param = j1sat(
    dtime_beg, dtime_end, sat, res=res,
    N3d=N3d, tincl=tincl
)

The inputs are stored within input_df, and the newly calculated FAC current in j_df with some extra metadata in param.

# Settings
dtime_beg = "2014-05-04T17:48:00"
dtime_end = "2014-05-04T17:54:00"
sat = ["C"]
res = "LR"
N3d = [0.2276, 0.6924, 0.6847]
tincl = ["2014-05-04 17:49:50", "2014-05-04 17:52:44"]

# Fetch data and apply algorithm using above settings
j_df, input_df, param = j1sat(dtime_beg, dtime_end, sat, res=res, N3d=N3d, tincl=tincl)
Used Swarm MAG L1b and magnetic model files:  ['CHAOS-8.1_static.shc', 'SW_OPER_MAGC_LR_1B_20140504T000000_20140504T235959_0701_MDR_MAG_LR', 'SW_OPER_MCO_SHA_2X_19970101T000000_20260206T235959_0805', 'SW_OPER_MMA_CHAOS__20140101T000000_20141231T233000_0704']
Used FAC file:  SW_OPER_FACCTMS_2F_20140504T000000_20140504T235959_0401
../_images/c6d15d9ca8d83d01f461a35038d93cfdf0d52bdb902166d9489804d813dfb044.png