Saravanan666/pypi-org huggingface dataset:
Package: python-vectors
UsageTo import everything:import vectorsTo import only 2D and 3D points:from vectors import Vector2, Vector3, SlopeCreate a 2D Vector:v = Vector2(x, y)Create a 3D vector:v = Vector3(x, y, z)Create a slope instance:m = Slope(rise, run)Get point information:_.xor_.yor_.zGet all points/rise and run as a tuple:_.tuple()Get all points/rise and run as an array list:_.list()Get all points/rise and run as a dictionary:_.dict()Get rise over run from slope object as a string formated asrise/run:_.string()Add two points:vectors.add(<v1>, <v2>)_.add(v)Subtract two points:vectors.subtract(<v1>, <v2>)_.subtract(v)Multiply two points:vectors.multiply(<v1>, <v2>)_.multiply(v)Divide two points:vectors.divide(<v1>, <v2>)_.divide(v)Simplify slope rise and run:_.simplify()Generate a 2D vector matrix:vectors.generate_2d_matrix(<Vector2>, <Vector2>)Generate a 3D vector matrix:vectors.generate_3d_matrix(<Vector3>, <Vector3>)Usage Notes:vectors.find_slope(<Vector2>, <Vector2>)returns a Slope classvectors.generate_2d_square_matrix(<Vector2>, <Vector2>)increments by one. This means your given Vector2 objects should only contain ints, no double or floats.You can add, subtract, multiply, and divide aVector2and aVector3(and vice versa). The output will be converted to a Vector3, using0 <operator> <second_param>.zas the z valueIMPORTANT: Remember when dividing, you cannot divide by zero.0 / 2is valid, however2 / 0is not. If your second parameter has a 0, you WILL get an errorUpdates11/18/2020 - 1.2.3Changedvectors.generate_square_matrix(<Vector2>, <Vector2>)tovectors.generate_2d_matrix(<Vector2>, <Vector2>Addedvectors.generate_3d_matrix(<Vector3>, <Vector3>)11/18/2020 - 1.2.1Added inline math functionsAdded square matrix generation withvectors.generate_square_matrix(<Vector2>, <Vector2>)AddedSlopeclassAddedvectors.find_slope(<Vector2>, <Vector2>),_.simplify(), and_.string()functions11/18/2020 - 1.1.2Updated README.md11/18/2020 - 1.1.0Added add, subtract, multiply, and dividing of Vector2 and Vector311/18/2020 - 1.0.0FixedVector3.tuple()showing as(x, y, x)instead of(x, y, z)11/17/2020 - 0.0.1Package publishedOther InformationSee my other projects athttps://fosterreichert.com
Package: python-veralite
Installation[sudo]pipinstallpython-veraliteUsageModuleYou can import the module asveralite.importveraliteip='192.168.1.89'user='admin'password='password'vera_api=veralate.Veralite(ip,user,password)vera_api.update_devices()Command lineusage:veralite[-h][--confFILE]--ipIP-uUSER-pPASSWORD{light,motion,switch}...CommandlineinterfacetoVeralite™SmartHomeControllerpositionalarguments:{light,motion,switch}commandhelplightlightcommandsmotionmotionsensorcommandsswitchswitchcommandsoptionalarguments:-h,--helpshowthishelpmessageandexit--confFILEconfigfile(default~/.config/veralite/config)--ipIPtheipforveralitesystem-uUSER,--userUSERusernameforveralite-pPASSWORD,--passwordPASSWORDpasswordforveraliteexamples:veralite--ip192.168.1.22-uveraadmin-padminpasswordswitchmodify--id22--onveralite--ip192.168.1.22-uveraadmin-padminpasswordlightlistveralite--ip192.168.1.22-uveraadmin-padminpasswordmotionmodify--id10--armA configuration file can also be specified to prevent ip/user/password repitition.[DEFAULT]ip=192.168.1.55user=theuserpassword=mypassword
Package: pythonversion
Usage#!/usr/bin/env pythonimportpythonversionpythonversion.PyVersionCheck(min="2.7.5",max="2.7.6")print"foo"python-VPython2.7.10test.pyThesupportedPythonversionforthisscriptisfrom2.7.5to2.7.6#!/usr/bin/env pythonimportpythonversionpythonversion.PyVersionCheck(min="2.7.5")print"foo"python-VPython2.7.10test.pyfoo
Package: python_version
## Python VersionThis package provides a basic python version checking utility.
It will check for a range of python versions and either report
an error or exit depending on the parameters provided.## Example` $ python Python 3.5.1+ (default, Mar 30 2016, 22:46:26) [GCC 5.3.1 20160330] on linux Type "help", "copyright", "credits" or "license" for more information. >>> import python_version >>> >>> try: ...python_version.check(min=(3,0, 0),max=(4,0, 0)) ... except Exception as e: ...     print(repr(e)) ... else: ...print("Allgood!")... All good! >>> try: ...python_version.check(min=(3,6, 0),max=(4,0, 0)) ... except Exception as e: ...     print(repr(e)) ... else: ...print("Allgood!")...VersionConflict('requirespython version >= 3.6.0 but the running python version is3.5.1+',)>>> try: ...python_version.check(min=(2,7, 0),max=(2,7, 999)) ... except Exception as e: ...     print(repr(e)) ... else: ...print("Allgood!")...VersionConflict('requirespython version <= 2.7.999 but the running python version is3.5.1+',)>>> try: ...python_version.check(min=(2,7, 0),max=(2,7, 999), exit_on_error=True) ... except Exception as e: ...     print(repr(e)) ... else: ...print("Allgood!")... requires python version <= 2.7.999 but the running python version is 3.5.1+ $ `
Package: python-versioned
Versioning is a user-friendly interface to a very common way of
versioning files, which creates a snapshot on every save, using
hardlinks, withlatest.extalways referring to the latest version
and other versions named according to when they were created.You can use it on the command line or from Python.Status:unstable.Usage:versioned (init | update) <dest> [options]
versioned rm <dest> [options]
versioned ls <dest> [options]
versioned <dest> [<src>] [options]Options:-s --max-size <size>        Prune old snapshots to keep the directory under a certain size.
-n --max-snapshots <n>      Prune snapshots beyond the latest <n>.
-d --max-days <days>        Prune snapshots older than <days>.
-r --range <range>...       List snapshots in a range. Get the latest snapshot using `head`,
                            a range of older snapshots using `-5 -2`, snapshots that are
                            between a certain age using `-9d -4d` and snapshots from a
                            certain year, month or day using `2014`, `2014-05` and so on.
-k --keep                   When adding a file from <src> to the versioned directory,
                            also keep the file in its original location.Arguments: The path to either the versioned directory or the file you
wish to start versioning. The path to the file that should beWhen initializing a versioned directory, you should refer to it with the
desired extension of the files that it will contain at the end.example.txtwill result in a versioned directory calledexamplebeing created, and all the files therein will have the.txtextension. From then on, you can refer to your versioned directory with
or without extension tacked on.
Package: python-video
pyvideoA lightweight module for simple handling of video frames and audio.first of allspecifics:writen and owned by: Shahaf Frank-Shapirall the rights are saved for: Shahaf Frank-Shapirprogramming languages: python 3.9.12 (100%)before we startdescription:visit the docs to learn more about this project and how to develop with it.dependencies:opening:
For this is a complex program, which uses a lot of modules, there are required dependencies needed
in order to run the program. keep in mined the program was writen in python 3.9, so any python version lower
than 3.9 might not work properly.install app dependencies by writing the "-r" option to install the requirements
writen in a file, and write the following line in the project directory:pip install -r requirements.txtrun a testrun from windows command line (inside the project directory)run with python by writing to the command line in the project directory:python test.py
Package: python-video-thumbnail
Python Video ThumbnailPython package for capturing frames from video.
Written as replacement ofhttps://github.com/radek-senfeld/ffvideopackage,
and to help with transition of Python 2.7 projects that relay on FFVideo, to Python 3.FeaturesSupports file paths and urlsSupports image resizingUsagefrom python_video_thumbnail import VideoFrames

vf = VideoFrames(
        source="https://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4",
        frame_numbers=[6000],
        img_options={"width": 128},
        format=".png"
)

captured_frames = vf.capture()

with open("captured_frame.png", "wb") as f:
        f.write(captured_frames[0].getvalue())CreditsThis package was created withCookiecutterand theaudreyr/cookiecutter-pypackageproject template.History0.1.0 (2021-10-02)First release on PyPI.
Package: python-vitrageclient
Python bindings to the Vitrage APIThis is a client library for Vitrage built to interface with the Vitrage API
. It
provides a Python API (thevitrageclientmodule) and a command-line tool
(vitrage).Contents:Ubuntu InstallBuilding and PackagingReferencesUbuntu InstallAt the moment only manual install is availableManual Install Steps:cd to your python-vitrageclient reposudo pip install -r requirements.txtpython setup.py installBuilding and PackagingInstall the tool dependenciessudo apt-get install python-pip python-virtualenvIn the python-vitrageclient source directoryvirtualenv --no-site-packages .venv

source ./.venv/bin/activate

pip install wheel

python setup.py bdist_wheel

pip install $(ls -1rt dist/*.whl | tail -1) --upgradeReferencesDetailed documentation for the CLI seeCLI Spec
Package: python-vivid
VividSupport Tools for Machine Learning Vividly 🚀DocumentsUsageThe concept of vivid iseasy to use. Only make instance and run fit, vivid save model metrics and weights (like feature_imporance, pr/auc curve, training time, ...) .importpandasaspdfromsklearn.datasetsimportload_bostonfromvivid.backends.experimentsimportLocalExperimentBackendfromvivid.estimators.boostingimportXGBRegressorBlockX,y=load_boston(return_X_y=True)train_df=pd.DataFrame(X)# create model and experimentxgb=XGBRegressorBlock('xgb')experiment=LocalExperimentBackend('./outputs/simple')# run modelsfromvivid.runnerimportcreate_runnerrunner=create_runner(blocks=xgb,experiment=experiment)runner.fit(train_df,y)runner.predict(train_df)VIVID makes it easy to describe model/feature relationships. For example, you can easily describe stacking, which can be quite complicated if you create it normally.Installpipinstallpython-vividSample CodeIn/vivid/samples, Some sample script codes exist.DeveloperRequirementsdockerdocker-composecreate docker-image from docker-compose filedocker-composebuild
docker-composeup-d
dockerexec-itvivid-testbashTestusepytestfor test tool (seegitlab-ci.yml).pytesttests
Package: python-vkontakte
Python library to access vkontakte social network api.InstallationVia pip:pipinstallpython-vkontakteApiimportpyvkontakteapi=pyvkontakte.VkontakteApi()api.call('users.get',user_ids=1)# [{'last_name': 'Дуров', 'id': 1, 'first_name': 'Павел'}]or calling method via class attribute:api.users_get(user_ids=1)# [{'last_name': 'Дуров', 'id': 1, 'first_name': 'Павел'}]Are both the same. In a second form, it is a method name where dots replaced with underscores -wall.getByIdwill bewall_getByIdand so on.If you want to call some private api, which require access token, just create a api class with it:pyvkontakte.VkontakteApi('access token')Using different api version:pyvkontakte.VkontakteApi(v='5.50')If some error occures after api request (response json containserrorinsead ofresponsekey),pyvkontakte.VkontakteApiErrorwill be raised.
Special attributejsonwill be avaible on exception object, additionally exception str representation will contain error description and error code.AuthorizationFor obtaining access token, you can usepyvkontakte.authmethod.pyvkontakte.auth(login,password,client_id,scope)which will return dict with keys access_token, expires_in, user_id. If login or password is invalid,pyvkontakte.InvalidCredentialswill be raised.
If some parsing error occurs,pyvkontakte.ParsingErrorwill be raised.
Bothpyvkontakte.InvalidCredentialsandpyvkontakte.ParsingErrorare subclasses ofpyvkontakte.VkontakteAuthError.There is also a loggerpyvkontakte(pyvkontakte.authandpyvkontakte.api) enabled.pyvkontakte.apilogs an INFO every request made with request params, and DEBUG with json of responseHistory1.1.2 (2016-05-13)Fixed setup.py requires option (changed to install_requires)1.1.1 (2016-04-27)Some refactoring for easier VkontakteApi extending1.1.0 (2016-04-21)Fixed auth issue1.0.0 (2016-04-16)First PyPi release0.1.0 (2016-04-16)Initial release
Package: python-vlc
This module provides ctypes-based bindings (seehttp://wiki.videolan.org/PythonBinding) for the native libvlc
API (seehttp://wiki.videolan.org/LibVLC) of the VLC video
player. Note that it relies on an already present install of VLC.It has been automatically generated from the include files of
vlc 3.0.20, using generator 1.23.
Package: python-vlc-http
python-vlc-httpPip module for sending http requests to a VLC ServerInstallationpip install python-vlc-httpHow to usefrompython_vlc_httpimportHttpVLCvlc_client=HttpVLC('host','username','password')fullscreen_status=vlc_client.is_fullscreen()if(fullscreen_status):print('VLC is running on fullscreen!')NOTE:Host follows the format ofhttp://thisissomeaddrress.com:[PORTNUMBER HERE] else it will raise an exception!Methodsalbum()Get the album playing, if none it returns Noneapi_version()Return API Version of VLC Serverartist()Get the artist playing, if none it returns Noneaspect_ratio()Return Aspect Ratio of media playingaudio_delay()Return Aspect Ratio of media playingclear_queue()Clear media in queuefilename()Get the filenameis_fullscreen()Return if VLC is in fullscreenis_looped()Return if VLC is set on loopis_on_repeat()Return if playback is set on repeatis_random()Return if shuffle is on or offmedia_artist()Return Current Artist playingmedia_length()Return the length of the media in secondsmedia_time()Return how long the media file isnext_track()Play next media in queueposition()Return the position of the playbackprevious_track()Play previous media in queuerate()Return the rateset_volume(volume)Set volume level, range 0..1.shuffle()Set shuffle modestate()Return the state of the media filestop()Send stop command.subtitle_delay()Return the set delay for subtitlestitle()Get the title playing, if none it returns Nonetoggle_fullscreen()Toggle Fullscreentrack_number()Get the track_number playing, if none it returns Nonevolume()Return the volume of the media playingplay()Start playing media playbackpause()Pause playbackplay_playlist_itemArguments:id -> The id of the playlist item you want to playStart playing a specific item from a playlistdelete_playlist_itemDelete a specific item from a playlistArguments:id -> The id of the playlist item you want to deletesub_delaySelect the subtitle delay for a video.Arguments:val -> The delay for the subtitlesvideo_trackSelect the video track for a particular media file.Arguments:val -> ID from the streamsubtitle_trackSelect the subtitle track for a video.Arguments:val -> ID from the streamset_rateSet the rate for a current media file.Arguments:val -> the value of what ratee it should be
Package: python-vncorenlp
python-vncorenlpA Python wrapper forVnCoreNLPusing PyjniusTable Of ContentsPrerequisitesInstallationExamplePrerequisitesJava 1.8+ (JREorJDK)InstallationYou can install this package from PyPI usingpip:$ pip install python-vncorenlpExample#!/usr/bin/python# -*- coding: utf-8 -*-frompython_vncorenlpimportinstall,Pipelineinstall('-Xmx2g')defmain():pipeline=Pipeline()pipeline.load_model()print(pipeline.annotate_doc('Tôi là chàng sinh viên Bách Khoa'))print(pipeline.annotate_docs(['Tôi là chàng sinh viên Bách Khoa','Tôi học Toán tin ứng dụng']))if__name__=='__main__':main()The parameter-Xmx2gmeans that the VM can allocate a maximum of 2 GB for the Heap Space. If you want to use all module, set heap space to-Xmx4g
Package: python-voi
pyvoi: Variation of Information in numpy/torchCalculate the Variation of Information for two clusteringsReferences:
Meila, Marina (2003). Comparing Clusterings by the Variation of Information. Learning Theory and Kernel Machines: 173–187Installationpip install python-voiUsageBy default, pyvoi uses torch to compute the variation of information.To get VI values onlyimport pyvoi
labels1=[0,1,1,2,4]
labels2=[0,2,3,4,4]
vi,vi_split,vi_merge=pyvoi.VI(labels1,labels2)
print(vi,vi_split,vi_merge)
# total vi, split vi, merge vi
# tensor(0.5545) tensor(0.2773) tensor(0.2773)To get VI componentsimport pyvoi
labels1=[0,1,1,2,4]
labels2=[0,2,3,4,4]
vi,vi_split,vi_merge,splitters,mergers=pyvoi.VI(labels1,labels2,return_split_merge=True)
print(vi,vi_split,vi_merge)
# (same as above) total vi, split vi, merge vi
# tensor(0.5545) tensor(0.2773) tensor(0.2773)

print(splitters)
# vi contribution, label in label2
#tensor([[0.2773, 4.0000],
#    [0.0000, 3.0000],
#    [0.0000, 2.0000],
#    [0.0000, 0.0000]])

print(mergers)
# vi contribution, label in label1
#tensor([[0.2773, 1.0000],
#    [0.0000, 4.0000],
#    [0.0000, 2.0000],
#    [0.0000, 0.0000]])Using cudaimport pyvoi
labels1=[0,1,1,2,4]
labels2=[0,2,3,4,4]
vi,vi_split,vi_merge=pyvoi.VI(labels1,labels2,device="cuda")
print(vi,vi_split,vi_merge)
#tensor(0.5545, device='cuda:0') tensor(0.2773, device='cuda:0') tensor(0.2773, device='cuda:0')Using numpyimport numpy as np
import pyvoi
labels1=np.array([0,1,1,2,4])
labels2=np.array([0,2,3,4,4])
vi,vi_split,vi_merge=pyvoi.VI(labels1,labels2,torch=False)
print(vi,vi_split,vi_merge)
#0.5545177444479561 0.27725887222397794 0.27725887222397816Contact and Bug ReportsCore Francisco Park:cfpark00@gmail.com
Package: python-vote-core
python-vote-core implements various electoral methods, providing the results
calculated off a provided set of ballots and options.Project page:http://github.com/bradbeattie/python-vote-coreIssue tracker:http://github.com/bradbeattie/python-vote-core/issuesExample usage:http://vote.cognitivesandbox.com,http://modernballots.comMethods implementedSingle Winner MethodsPlurality (aka first-past-the-post or fptp)Instant-Runoff Voting (aka IRV)Schulze Method (aka Beatpath)Multiple Winner MethodsPlurality at large (aka block voting)Single Transferable Vote (aka STV)Schulze STVOrdering MethodsSchulze Proportional RepresentationSchulze Nonproportional RepresentationBasic UsageSchulze method example:print SchulzeMethod([
  { "count":3, "ballot":[["A"], ["C"], ["D"], ["B"]] },
  { "count":9, "ballot":[["B"], ["A"], ["C"], ["D"]] },
  { "count":8, "ballot":[["C"], ["D"], ["A"], ["B"]] },
  { "count":5, "ballot":[["D"], ["A"], ["B"], ["C"]] },
  { "count":5, "ballot":[["D"], ["B"], ["C"], ["A"]] }
], ballot_notation = "grouping").as_dict()20110509.1
—Fixing PyPi release20110509.0
—Initial PyPi releaseLicenseCopyright (C) 2009, Brad BeattieThis program is free software: you can redistribute it and/or modify
it under the terms of the GNU 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 this program.  If not, seehttp://www.gnu.org/licenses.
Package: python-vote-full
python-vote-core implements various electoral methods, providing the results
calculated off a provided set of ballots and options.Project page:http://github.com/bradbeattie/python-vote-coreIssue tracker:http://github.com/bradbeattie/python-vote-core/issuesExample usage:http://modernballots.comMethods implementedSingle Winner MethodsPlurality (aka first-past-the-post or fptp)Instant-Runoff Voting (aka IRV)Schulze Method (aka Beatpath)Multiple Winner MethodsPlurality at large (aka block voting)Single Transferable Vote (aka STV)Schulze STVOrdering MethodsSchulze Proportional RepresentationSchulze Nonproportional RepresentationBasic UsageSchulze method example:>>> from pyvotecore.schulze_method import SchulzeMethod
>>> ballots = [
...   { "count":3, "ballot":[["A"], ["C"], ["D"], ["B"]] },
...   { "count":9, "ballot":[["B"], ["A"], ["C"], ["D"]] },
...   { "count":8, "ballot":[["C"], ["D"], ["A"], ["B"]] },
...   { "count":5, "ballot":[["D"], ["A"], ["B"], ["C"]] },
...   { "count":5, "ballot":[["D"], ["B"], ["C"], ["A"]] }
... ]
>>> SchulzeMethod(ballots, ballot_notation = "grouping").as_dict()
{'actions': [{'edges': {('A', 'B')}},
  {'edges': {('A', 'C')}},
  {'nodes': {'A'}},
  {'edges': {('B', 'C')}},
  {'nodes': {'B', 'D'}}],
 'candidates': {'A', 'B', 'C', 'D'},
 'pairs': {('A', 'B'): 16,
  ('A', 'C'): 17,
  ('A', 'D'): 12,
  ('B', 'A'): 14,
  ('B', 'C'): 19,
  ('B', 'D'): 9,
  ('C', 'A'): 13,
  ('C', 'B'): 11,
  ('C', 'D'): 20,
  ('D', 'A'): 18,
  ('D', 'B'): 21,
  ('D', 'C'): 10},
 'strong_pairs': {('A', 'B'): 16,
  ('A', 'C'): 17,
  ('B', 'C'): 19,
  ('C', 'D'): 20,
  ('D', 'A'): 18,
  ('D', 'B'): 21},
 'winner': 'C'}20110509.1
—Fixing PyPi release20110509.0
—Initial PyPi releaseLicenseCopyright (C) 2009, Brad BeattieThis program is free software: you can redistribute it and/or modify
it under the terms of the GNU 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 this program.  If not, seehttp://www.gnu.org/licenses.
Package: python-vpic
# Python-vPicA simple wrapper around the vPic API.## To install:pip install python-vpic## To use:```from vpic import vpic# Single VIN lookupvehicle = vpic.lookup_vin('5FYD4FS147B031975')print('Make:', vehicle.make)print('Model:', vehicle.model)print('Year:', vehicle.model_year)# Bulk VIN lookupvehicles = vpic.lookup_vins([{'vin': '5FYD4FS147B031975', 'year': 2006}, {'vin': '4V4WDBPFSCN735320'}])# ...```
Package: pythonvrft
PythonVRFT Library - Version 0.0.5VRFT Adaptive Control Library written in Python. Aim of this library is to provide an implementation of the VRFT (Virtual Reference Feedback Tuning) algorithm.You can find the package also at the followinglinkAuthor: Alessio Russo (PhD Student at KTH -alesssior@kth.se)LicenseOur code is released under the GPLv3 license (refer to theLICENSEfile for details).RequirementsTo run the library you need atleast Python 3.5.Other dependencies:NumPy (1.19.5)SciPy (1.6.0)InstallationCheck the requirements, but the following command should install all the packages.
Run the following command from  root folder:pipinstall.ExamplesExamples are located in the examples/ folder. At the moment there are examples available.
Check example3 to see usage of instrumental variables.TestsTo execute tests run the following commandpython-munittestChangelog[V. 0.0.2][26.03.2017] Implement the basic VRFT algorithm (1 DOF. offline, linear controller, controller expressed as scalar product theta*f(z))[V. 0.0.3][05.01.2020] Code refactoring and conversion to Python 3; Removed support for Python Control library.[V. 0.0.5][08.01.2020] Add Instrumental Variables (IVs) Support[In Progress][07.01.2020-] Add Documentation and Latex formulas[TODO] Add MIMO Support[TODO] Generalize to other kind of controllers (e.g., neural nets)[TODO] Add Cython supportCitationsIf you find this code useful in your research, please, consider citing it:@misc{pythonvrft,
author       = {Alessio Russo},
title        = {Python VRFT Library},
year         = 2020,
doi          = {},
url          = {https://github.com/rssalessio/PythonVRFT}
}