Skip to main content
This is a pre-production deployment of Warehouse. Changes made here affect the production instance of PyPI (pypi.python.org).
Help us improve Python packaging - Donate today!

A sparse vector in pure python, based on numpy.

Project Description

A sparse vector is a 1D numerical list where most (say, more than 95% of) values will be 0 (or some other default) and for reasons of memory efficiency you don’t wish to store these. (cf. Sparse array)

This implementation has a similar interface to Python’s 1D numpy.ndarray but stores the values and indices in linked lists to preserve memory.

sparse_vector is for numerical data only, if you want any type of data, have a look at sparse_list, the parent library, a dictionary-of-keys implementation of a sparse list in python.

If you need 2D matrices, have a look at scipy.sparse, they also have a linked lists implementation, lil_matrix.

Installation

Available on the cheeseshop.

Installation is simply:

$ pip install sparse_vector

Usage

See the unit-tests!

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Ensure the tests pass for all Pythons in .travis.yml <https://github.com/johnsyweb/python_sparse_vector/blob/master/.travis.yml>__
  5. Push to the branch (git push origin my-new-feature)
  6. Create new Pull Request

Thanks

Release History

Release History

This version
History Node

0.4

History Node

0.3

History Node

0.2

History Node

0.1

Download Files

Download Files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
sparse_vector-0.4.tar.gz (4.6 kB) Copy SHA256 Checksum SHA256 Source May 18, 2016

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting