Giter VIP home page Giter VIP logo

pythia's People

Contributors

baagaard-usgs avatar tan2 avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pythia's Issues

Multlline values for .cfg files are not supported in conversion to Python 3

There are significant differences between the ConfigParser for Python 2.7 and Python 3.X. The handling of multiple values is one of them. The v3 ConfigParser first reads in the values and then resets them using _join_multiline_values(). This interferes with the proxy Section used in Pyre to set paths and track the location of settings. Currently, we overwrite this method in pyre.inventory.cfg.Parser and raise an exception if we encounter a value that is a list.

The way to resolve this is to reimplement _join_multiline_values() so that it handles the multiline values without messing up the registry that tracks the paths and location of where values were set.

Create unit tests for Pyre inventory.

Create unit tests for Pyre inventory.

See #5.

Inventory

  • bool
  • int
  • float
  • string
  • dimensional
  • list
  • InputFile
  • OutputFile
  • facility
  • array of facilities

Functionality

  • defaults
  • override defaults using command line arguments
  • override defaults using .cfg file
  • override defaults using pml file

Create unit tests for functionality used by PyLith

Before converting code to Python 3, we need unit tests for the functionality that we use, so that we can verify the conversion doesn't break anything.

Functionality that needs unit tests:

  • Journal
  • MPI
  • Pyre units
  • Pyre inventory
  • Pyre application
  • Pyre schedulers

Move all packages under a high-level pythia package

Python packaging continues to undergo significant changes. The "new" preferred mechanism (PEP 517) puts all packages into the destination directory. As a result, all pythia packages (pyre, journal, mpi, etc) are not listed under a pythia directory. This could result in naming conflicts, for example multiple mpi or journal packages.

Proposed change: Move all current packages under a top-level pythia directory so that they become submodules of the pythia package.

Cannot bind different component to facilityArray

The factory keyword is used to bind a default component to a facilityArray. Within a .cfg file or on the command line, we can assign an array of components, but we cannot assign a single component acting as the array.

Example

A materials array with a default factory creating an array with one facility.

Ok: Use the default

materials.homogeneous = materials.Elastic

Ok: Create array of two materials.

materials = [one, two]
materials.one = materials.Elastic
materials.two = materials.Plastic

Fails: Replace default factory with another factory.

materials = materials.ElasticPlastic

# This is interpreted as materials = [materials.ElasticPlastic]

Add support for SLURM batch schedulers.

Pyre currently has implementations for the LSF, PBS, and SGE batch schedulers. We should also have an implementation for the SLURM batch scheduler.

The schedulers are in the pyre/schedulers directory.

Improve error message for .cfg parsing

Having an inadvertent space at the beginning of a line in a .cfg file specifying a facility (not a property) generates a very vague, difficult to understand error message:

 >> {command line}::
 >> pyre.inventory(error)
 -- 'str' object has no attribute 'append'
pylithapp: configuration error(s)

This could be an error in generating the error message.

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.