Giter VIP home page Giter VIP logo

splipy's Introduction

Splipy

This repository contains the Splipy packages. Splipy is a pure python library for the creation, evaluation and manipulation of B-spline and NURBS geometries. It supports n-variate splines of any dimension, but emphasis is made on the use of curves, surfaces and volumes. The library is designed primarily for analysis use, and therefore allows fine-grained control over many aspects which is not possible to achieve with conventional CAD tools.

Installation

The library is packaged on splipy and can be installed through pip by simply running

pip install splipy

Resources

Development and building from source

Dependencies

Required

This library requires numpy and scipy. For building, cython is also required. E.g. on Ubuntu:

pip install numpy
pip install scipy
pip install cython

Optional

To use image processing tools, you need OpenCV

pip install python-opencv

To generate the documentation you will need Sphinx:

pip install sphinx

And to run the tests you can use your favourite test runner, for example pytest:

pip install pytest pytest-benchmark pytest-cov

Installing

To install, use:

python setup.py build_ext --inplace
python setup.py install

To generate a package, use:

python setup.py sdist --dist-dir .

Documentation

To generate the documentation, run in the doc folder:

make html

To push generated docs online on the gh-pages branch, run the helper script:

python push_documentation.py [remote]

where remote is the name of the remote to push to. If not given, it will be asked.

Tests

To run the tests, you can use your favourite test runner. For example, with pytest:

PYTHONPATH=. py.test --benchmark-skip

To get a report of test coverage, run:

PYTHONPATH=. py.test --benchmark-skip --cov=splipy --cov-report term-missing

Code analysis

You can use pylint3 to perform static code analysis on the module. This can help identify bugs and give suggestions for improvements.

To install, use:

pip3 install pylint

To perform the code analysis, use:

pylint -d C --rcfile=pylint.cfg splipy/

Releasing

To make a new release, it is recommended to install bumpversion. To make a new release, run:

bumpversion <type>

where type is one of patch, minor or major. This will up the version number, create a commit and a tag. To push this to github, use:

git push --tags

After that, Travis CI should automatically build and deploy the packages to PyPi. It would be helpful to monitor the Travis build so that errors can be fixed quickly. See the list of builds.

splipy's People

Contributors

akva2 avatar vikingscientist avatar thebb avatar timovanopstal avatar luzpaz avatar zetison avatar darikg avatar yukoba avatar

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.