semvec/pypi-packages huggingface dataset:
ovspy 0.1.0b2
Open vSwitch Mnipulation Library
License: MIT

# ovspy
Open vSwitch Library written in Python  

[ovspy · PyPI](https://pypi.org/project/ovspy/)

## Supported Operation
- Bridge
  - Get(name, uuid, port)
  - Add
  - Delete
- Port
  - Get(name, uuid, vlan)
  - Add(with VLAN)
  - Delete

## install
```
pip install ovspy
```

## Getting Started

### Configure Open vSwitch Manager
This library manipulate Open vSwitch by access OVSDB  
You need to configure OVSDB manager port to manipulate OVSDB from ovspy via TCP.
```
sudo ovs-vsctl set-manager ptcp:5678
```

### Bridge
```
import ovspy.client

ovs = ovspy.client.OvsClient(5678)

#Get exist all bridges
#This function return list of OvsBridge instance
for br in ovs.get_bridges():
    print(br.get_name())

#Find bridge by bridge name
#This function return OvsBridge instance
#If specified bridge is not found, the function return None
bridge = ovs.find_bridge("br0")
print(bridge.get_name())


#Add bridge
#If specified bridge is already exist, This function raise ovspy.ovs_error.Duplicate
ovs.add_bridge("br1")

#Delete bridge
#If specified bridge is not exist, This function raise ovspy.ovs_error.NotFound
ovs.del_bridge("br1")
```

### Port
```
import ovspy.client

ovs = ovspy.client.OvsClient(5678)

#Get Bridge instance
bridge = ovs.find_bridge("br0")

#Get all ports which is associate to birgde
for p in bridge.get_ports():
    print("%s:(%s)" % (p.get_name(), p.get_vlan_info()))

#Find port by name
port =  bridge.find_port("p0")
print(port.get_name())

#Add port(Access port)
bridge.add_port("p1", 10)

#Add port(Trunk port)
bridge.add_port("p2")
bridge.add_port("p3", [])

#Add port(Trunk port with restrict vlan)
bridge.add_port("p4", [10, 20])

#Delete port
bridge.del_port("p3")

```

### Errors
ovspy has following class as custom exception
- `ovspy.ovs_error.OvspyError`
  - Super class of custom exceptions
- `ovspy.ovs_error.Duplicate`
  - The error is raise when user operation cause duplicate status(e.g. Case of try to create port with same name as existing port)
- `ovspy.ovs_error.NotFound`
  - The error is raise when user specified resource is not exist. (e.g. Case of try to delete port but the port is not existing)
- `ovspy.ovs_error.TransactionError`
  - The error is raise when failed to transaction with OVSDB. (e.g. Timeout for connection)
- `ovspy.ovs_error.Unsupported`
  - The error is raise when user try to unsupported operation with ovspy.
mgenerator 0.1.2
Generate a sympy matrix fast
License: MIT

# matrix-generator

[![PyPI version](https://badge.fury.io/py/mgenerator.svg)](https://badge.fury.io/py/mgenerator)

This is a python program that helps you to make a sympy matrix easily. This module uses [sympy](https://www.sympy.org/en/index.html), python library for simbolic mathmatics. 

By using this generator, you can create a new sympy matrix with only entering the dimension size and elements.

## Dependencies

The following dependencies are required

- [sympy](https://www.sympy.org/en/index.html)

## Download

 ``` bash
  $ pip install mgenerator
  ```

## Example
```python
    from mgenerator import *

    foo = new() # makes new sympy Matrix object. You will enter elements
    foo = new(1,2) # makes new sympy Matrix with 1 raw and 2 column

    ef(foo) # makes foo as Echelon form
    rf(foo) # makes foo as Reduced Echelon form

    num = 3
    ran(num) #finds image num elements vector range

    #used in finding eigenvalues
    char(foo, 3) #makes characteristic polynomial equation, and finds soluton with 3*3 matrix

    orthon(foo) #makes orthogonal basis matrix

    vec(2,1) #makes the vector (2,1)
```

## Instructions

1. `new( )`:

- When you make a mistake, just enter 'Enter'. **It will make new matrix**
- You can use any type of componenent(int,float,string), even a fraction like 1/2

2. `ran( )`:

- First you have to find echelon form of linear combination's agmented coefficient matrix
- Put coefficients of the range. Ex) If the range is ax-by-cz = 0 -> enter a,-b,-c

3. `char( )`:

- Put a Matrix and number of the matrix dimension ( if 2 by 2 matrix, enter 2 )
clod 0.10.0
Create and recursively fill a temporary directory
License: MIT
Keywords: testing,modules

�� - clod: CLass mODule! Give your module the power of an object - ��
=========================================================================

_Give your module the power of an object, with ``clod`` (and save a
little typing too)._

Ever wanted to call a module directly, or index it?
Or just sick of seeing ``from foo import foo`` in your examples?

``clod`` is a tiny library that solves both these issues in one line of code,
by extending a module with the methods and members of a Python object.

This is extremely handy for modules that primarily do one thing.

EXAMPLE: Make a module callable

.. code-block:: python

    # In your_module.py
    import clod

    A_CONSTANT = 23

    @clod
    def a_function(*args, **kwargs):
        print('a function!')
        return args, kwargs


    # Test at the command line
    >>> import your_module

    >>> your_module(2, 3, a=5)
    a function!
    (2, 3), {'a': 5}

    >>> assert your_module.A_CONSTANT == 23

EXAMPLE: Make a module look like an object

.. code-block:: python

    # In your_module.py
    import clod

    A_CONSTANT = 23

    clod(list(), __name__)

    # Test at the command line
    >>> import your_module

    >>> assert your_module == []

    >>> assert your_module.A_CONSTANT == 23

    >>> your_module.extend(range(3))

    >>> print(your_module)
    [0, 1, 2]

API
---

``clod.clod(extension=None, name=None, properties=None, omit=None)``
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

(`clod.py, 96-177 <https://github.com/rec/clod/blob/master/clod.py#L96-L177>`_)

Extend the system module at ``name`` with any Python object.

The original module is replaced in ``sys.modules`` by a proxy class
which delegates attributes, first to the extension, and then to the
original module.

``clod`` can also be used as a decorator, both with and without
parameters.

ARGUMENTS
  extension
    The object whose methods and properties extend the namespace.
    This includes magic methods like __call__ and __getitem__.

  name
    The name of this symbol in ``sys.modules``.  If this is ``None``
    then ``clod`` will use ``extension.__module__``.

    If the ``name`` argument is given, it should almost certainly be
    ``__name__``.

  properties
    There is little need to use this argument.

    Properties in this list are copied directly from the module into the
    custom class - they do not get overridden by the extension.

    If ``properties`` is None, it defaults to ``clod.MODULE_PROPERTIES``
    which seems to work well a lot of the time

  omit
    There is little need to use this argument.

    A list of methods _not_ to delegate from the proxy to the extension.

(automatically generated by `doks <https://github.com/rec/doks/>`_ on 2020-07-18T15:46:33.018839)