GithubHelp home page GithubHelp logo

benvial / scatpy Goto Github PK

View Code? Open in Web Editor NEW
0.0 2.0 2.0 603 KB

ScatPy is a Python package for interfacing to the popular scattering simulator DDSCAT. Forked from https://github.com/hohlraum/ScatPy

License: GNU General Public License v3.0

Python 100.00%

scatpy's Introduction

ScatPy -- A Python interface to DDSCAT

ScatPy is a Python package for interfacing to the popular scattering simulator DDSCAT. ScatPy provides a rich toolset to:

  • Create standard DDSCAT scattering targets based on physical (rather than dipole) dimensions
  • Construct and visualize complex custom scattering targets
  • Manage the job parameters found in the ddscat.par file
  • Organize iterative jobs requiring multiple targets or input parameters
  • Script job submission to cluster queue managers
  • Maintain profiles and defaults for deployment on platforms other than the local machine
  • Load, plot and manipulate DDSCAT output tables
  • Manage the output from multiple jobs through results collections
  • Work with and visualize nearfield results as multidimensional numpy arrays
  • Suitable for interactive or scripted use

Documentation

Complete documentation can be found at: http://pythonhosted.org/ScatPy

Download

The package can be downloaded for installation via easy_install at https://pypi.python.org/pypi/ScatPy

Example

    from ScatPy import *

    # Establish target geometry (in um)
    length = 0.100
    radius = 0.020
    target = targets.CYLNDRCAP(length, radius, d=0.005, material='Au_Palik.txt')

    # Create a job to be run in the subdirectory tmp/
    job = DDscat(folder = './tmp', target=target)

    # Change the range of calculated wavelengths and ambient index
    job.settings.wavelengths = ranges.How_Range(0.300, 0.600, 15)
    job.settings.NAMBIENT = 1.0

    # Run the job locally
    job.calculate()

    # Open the results qtable, plot Q_sca, and Q_abs, and add a legend
    ans = results.QTable(folder = './tmp')
    ax = ans.plot(['Q_sca', 'Q_abs'])
    ax.legend(loc=0)

scatpy's People

Watchers

James Cloos avatar Benjamin Vial avatar

Forkers

pjlohr jmcook1186

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.