Easily dump python objects to files, and then load them back.


License
Other
Install
pip install vlermv==0.2

Documentation

Vlermv

Vlermv makes it easy to save Python objects to files with meaningful identifiers.

Interface

You should concern yourself primarily with these two elements.

vlermv.Vlermv
Class that helps you use the filesystem like a dictionary.
vlermv.cache
Decorator that helps you use vlermv.Vlermv for caching the output of a function.

Basic usage

Install from PyPI.

pip install vlermv

Then call it like this.

from vlermv import Vlermv
like_a_dictionary = Vlermv('a-directory')

Now you can mostly pretend that like_a_dictionary is a dictionary, except that it will persist across Python sessions.

Cache decorator

Decorate the function with @vlermv.cache() to cache its results.

@vlermv.cache()
def is_prime(number):
    for n in range(2, number):
        if number % n == 0:
            return False
    return True

Documentation

Read the full documentation for more information.

License

Copyright 2014, 2015 Vlermv contributors. Here are the contributors.

  • Thomas Levine
  • Aaron Schumacher

Vlermv is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with Vlermv. If not, see http://www.gnu.org/licenses/.