Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

Graduated cylindrical shell CME model in Python

License

NotificationsYou must be signed in to change notification settings

dinesh-hegde/gcs_python

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

56 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DOI

Python 3 implementation of the Graduated Cylindrical Shell model (GCS,Thernisien, 2011).Based on the existing IDL implementation inSolarSoft(cmecloud.pro,shellskeleton.pro).

The code ingcs/geometry.py provides the basic implementation of the GCS geometry, while the Qt-based GUI ingcs/gui.py usesSunPy and Matplotlib to plot the model on top of coronagraph images provided byHelioviewer.org.

A more detailed description of the GCS model, this Python implementation and its validation is given inthis excerpt frommy PhD thesis.

Screenshot

Note

This code is still in a quite early stage. It has been compared with the original IDL/SolarSoft version to verify the results, but only for a few case studies.Please be careful when using it and compare to IDL when in doubt.

If you find a bug, run into technical problems during the installation, or have suggestions for improvement, please create aGitHubissue. As I have since left the Heliophysics field and am no longer actively using the tool myself, I can't promise timely responses. But it is still preferrable compared to writing me an email in private, as other users can also help you.

If you have fixed a bug or implemented improvements, please feel free to open aPull Request!

If you use this code in a publication, please cite it usingthe DOI generated by Zenodo. I would also appreciate it if youdrop me an email and tell me what you used it for :)

How to install and run the GUI

Python 3.7 or later and Git are required for installation.

# install GCSpip3 install git+https://github.com/johan12345/gcs_python.git# run GCS GUI, providing a date/time and the spacecraft to usegcs_gui "2020-04-15 06:00" STA SOHO

Information on the available command line arguments for the GUI is given when you run the help option:

gcs_gui -h

Common issues

  • command not found: gcs_gui
    This sounds like the directory wherepip installs executables (on Linux this is typically~/.local/bin) is not on yourPATH.pip probably printed a warning about this when you were installing the package.
  • RuntimeError: You must have a version of OpenJPEG at least as high as 2.3.0 before you can read JPEG2000 images with glymur.
    Loading Helioviewer images with SunPy requires the OpenJPEG library to be available on yourPATH. You can install it through your system package manager (e.g.,apt install libopenjp2-7-dev), throughconda ormanually, as you prefer.

How to use the GCS geometry in your own plotting code

Simply install GCS (as seen above) and use

importgcs.geometry

to import the code from the GCS package. You can find some examples what you can do with it in the filessample.py andsample_sunpy.py.

Development setup

First, clone the git repository:

git@github.com:johan12345/gcs_python.git

It is recommended to use avirtual environment so that thePython packages you install as dependencies of GCS don't interfere with your globally installed packages.On some Linux distributions, the additionalpython3-venv package needs to be installed for this to work.

python3 -m venv env. env/bin/activate

Then, install the dependencies:

# install requirementspython3 -m pip install --upgrade pip setuptoolspip3 install -r requirements.txt

and test the GUI using

python -m gcs.gui"2020-04-15 06:00" STA SOHO

About

Graduated cylindrical shell CME model in Python

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python100.0%

[8]ページ先頭

©2009-2025 Movatter.jp