Saravanan666/pypi-org huggingface dataset:
Package: py_sonicvisualiser
py_sonicvisualiserpy_sonicvisualiser is a framework for manipulating environment files
to be used with sonic visualiser, and application for viewing and analysing the contents of music audio fileshttp://www.sonicvisualiser.org/This module supports the generation of sonic visualiser environment files (export) and their parsing (import), allowing to manipulate sonic visualiser datasets and python iterable structures.Feel free to contribute if you like this project!Usefull LinksLatest source files:https://github.com/DavidDoukhan/py_sonicvisualiserPackage:https://pypi.python.org/pypi/py_sonicvisualiserDocumentation:http://pythonhosted.org/py_sonicvisualiser
Package: pysonnet
📜 PysonnetA pure Python implementation of the Jsonnet language.Features:Pure Python Implementation: Fully written in Python, ensuring compatibility and ease of integration with Python projects.No External Dependencies: Operates independently without the need for any external libraries, simplifying installation and use.[!IMPORTANT]
Pysonnet is in the early stages of development.
While it supports all Jsonnet syntax, it lacks some standard library features, and users might encounter bugs.InstallationpipinstallpysonnetUsageEvaluate a jsonnet file and generate a JSON string:importpysonnetjson_string=pysonnet.evaluate_file("path/to/file.jsonnet",ext_vars={...})Load a string and generate a Python object:importpysonnetoutput=pysonnet.loads("""local Person(name='Alice') = {name: name,welcome: 'Hello ' + name + '!',};{person1: Person(),person2: Person('Bob'),}""")assertoutput=={"person1":{"name":"Alice","welcome":"Hello Alice!"},"person2":{"name":"Bob","welcome":"Hello Bob!"}}Evaluate file from command line:pysonnetpath/to/file.jsonnet
Package: pysony
<img src="https://travis-ci.org/Bloodevil/sony_camera_api.svg?branch=master"/>Pysony===============python sony camera apiInstall====using pip:pip install pysonyusing repo:git clone https://github.com/Bloodevil/sony_camera_api.gitpython setup.py installUsage====simple example:>>> api = pysony.SonyAPI()>>> api.getAvailableApiList()api_list====there api list that you can use.examples====liveview- can see the photo via liveviewtimer- take a picture every n secondsdump_camera_capabilities- show every supported api listpyLiveView- Released under the GPL v2 (or later) by Simon Wood (simon@mungewell.org)- Sample application to connect to camera, and start a video recording- with or without a GUI LiveView screen
Package: pysonyavr
These Python bindings are intended to interact with modern Sony speakers.NOTEThis library has only been tested with a Sony SRS-ZR7. It may not work
reliably with other Sony speakers. Feel free to open an issue if your are having
trouble with your device.Code samplefrompysonyavrimportSonyAvrs=SonyAvr('10.0.0.18')s.turn_on()# Switch to AUX inputs.set_input('audio in')s.raise_volume()s.mute()s.unmute()s.turn_off()
Package: pySonyBraviaPSK
Sony Bravia PSK Python PackageAboutsony_bravia_pskis a Python library for remote communication with Sony Bravia TVs 2014 and newer which support a Pre-Shared Key
(http://info.tvsideview.sony.net/en_ww/home_device.html#bravia)Thank youThe source of this is the great work of Antonio Parraga onhttps://github.com/aparraga/braviarc. That version is being used to
add the PSK functionality.Home AssistantThis version is being developed for use in Home Assistant.
Package: py-sony-bravia-remote
py-sony-bravia-remoteis a Python 3 library for interfacing remotely with Sony Bravia TV’s. It utilizes a undocumented HTTP
API that the TV exposes. This allows you to control things like changing the volume, channel or turn the TV on and off.This API is the exact same API that the “Sony Remote” app uses to control the TV.InstallationFor inclusion in another project, install throughpip:pipinstallpy-sony-bravia-remoteExample usagefromsonybraviaremoteimportTV,TVConfig# called the very first time you attempt to connect to your# tv... the tv will display a pincode that you need to enter# after the first connection attempt, you'll never have to do this againdefon_auth():returninput('Pincode: ')# ip address of your tv... the device name is the name under which# your program will be registered... note that if you change the device# name, you have to re-authconfig=TVConfig('192.168.0.23','my device name')tv=TV(config,on_auth)tv.is_on()# true/falsetv.wake_up()tv.power_off()tv.netflix()tv.home()tv.enter()tv.confirm()tv.pause()tv.play()tv.confirm()tv.mute()tv.volume_up()tv.volume_down()
Package: py-soocial
IntroductionThis package provides a python wrapper to theSoocial developer API.Soocialis a web
service that facilitates contact management by syncing across mutliple devices.Basic UsageImport Soocial and provide it with your Soocial email and password:>>> from soocial import Soocial
>>> myemail = 'me@foo.com'
>>> mypassword '***'
>>> soo = Soocial(myemail, mypassword)You have the following API available:def __contains__(id): does the contact with ididexist?def __iter__(): for contact in soo: # do stuff with contactdef __len__(): no_of_contacts = len(soo)def __nonzero__(): if soo: # do stuffdef __getitem__(id): mycontact = soo[id]def __setitem__(id, postdata): soo[id] = {…} # n.b. rather limited atmdef __delitem__(id): del soo[id]def add(postdata): soo.add({…}) # ltddef get_all_vcards(parse=True): get all contacts as a list of vcardsdef get_vcard(id, parse=True): get contact as vcarddef get_phones(id): get list of contact’s telephone numbersdef get_emails(id): get list of contacts’s emailsdef get_urls(id): get list of contacts’s urlsdef get_addresses(id): get list of contacts’s addressesdef get_organisations(id): get list of contacts’s organisationsdef get_user(): get small set of user datadef get_connection_phones(): get phone number of user’s connectionsExample UsageSeesoocial.client.Soocial.__doc__.TestsTo run the tests create an empty soocial account, temporarily hack your email
and password into .client.Soocial’s doc string and run:$ python setup.py nosetests --with-doctestThen perhaps remove your email and password from the doc string ;)Notesthe API doesn’t supportHEADrequests, which would be handy for checking
existence without incurring extra request size overhead ofGETthe/contact*REST seems the wrong way round: usingPOSTfor add andPUTfor editparameter names don’t correspond to returned XML element names (i.e.:first_namebecomesgiven-namewrite access to the elements contained by a contact (email, url, phone, etc.)
seems not to be working as documented; in fact, it would be nice to have some
documentation on the right URLs and the right parameters
Package: pysoplot
PysoplotPysoplotis a Python library that provides basic functions and routines for geochronology. It implements some of the core functionality of the popular (and now defunct) Isoplot/Ex. software, but also includes new algorithms and routines. Pysoplot is intended to be used by geochronologists to build custom scripts and data processing routines in order to meet individual requirements.Pysoplot includes functions for:regressing 2-D data using the model 1, 2 and 3 algorithms popularised by Isoplot/Ex.regressing 2-D data using the robust spine algorithm of Powell et al. (2020) and a new "robust model 2" algorithmcomputing weighted averages using algorithms based on classical and robust statisticscomputing classical isochron and U-Pb concordia-intercept agesplotting isochron diagramscomputing disequilibrium U-Pb agesplotting equilibrium and disequilibriam concordia curves, age ellipses, and uncertainty envelopescomputing age uncertainties using Monte Carlo methodsFull code documentation is coming soon.InstallationRun the following to install:pipinstallpysoplotExample usageimportpysoplotaspp# get Tera-Wasserburg test datasetdp=pp.data.LA0708# transform data point errors from 2 sigma to 1 sigma absolutedp=pp.transform.dp_errors(dp,'abs2s')# regress datafit=pp.regression.robust_fit(*dp,plot=True,diagram='tw')pp.misc.print_result(fit,'Regression results')fit['fig'].show()# compute Tera-Wasserburg concordia-intercept ageresult=pp.upb.concint_age(fit,method='Powell')print(f"age:{result['age']:.2f}+/-{result['age_95pm']:.2f}")AcknowledgementsAcknowledgement of all third-party algorithms implemented in Pysoplot with links to publications will be added here soon...LicensePysoplot is distributed under the MIT license.ContactTimothy Pollard
Package: pysor
Pysor is a Python library for the simulation of various sensors. It is designed to be used with an MQTT broker of your choice, providing an easy and flexible way to simulate sensor data for IoT applications.InstallationPysor is available on PyPi. You can install it via pip:pipinstallpysorQuickstartHere's a quick example showing how to simulate a temperature sensor using Pysor:fromsensor_simulationimportMqttClient,SensorManagerfromsensor_simulation.sensorsimportTemperatureSensorif__name__=='__main__':mqtt_client=MqttClient('your.broker.org')temperature_sensor=TemperatureSensor(mqtt_client,'sensor/temperature')sensor_manager=SensorManager()sensor_manager.add_sensor(temperature_sensor)try:sensor_manager.run()exceptKeyboardInterrupt:sensor_manager.stop_all()Available SensorsPysor comes with a variety of pre-built sensor simulations:TemperatureSensorHumiditySensorLightIntensitySensorWaterLevelSensorPhSensorAll sensors have parameters to set the mqtt client, the topic and the interval at which the sensor should publish messages.Example of parameters for HumiditySensorclassHumiditySensor(BaseSensor):"""Humidity sensor class.Min and max humidity values are in percentage."""def__init__(self,mqtt_client:MqttClient,topic:str,interval:float=120.0,min_humidity:int=30,max_humidity:int=80,humidity_change:float=1.0,current_humidity:float=None)->None:...Custom SensorsExtend the BaseSensor class and implement the 'generate_data' method. This method should return the data to be published.classMyCustomSensor(BaseSensor):defgenerate_data(self)->Any:# Your custom data generation logic here...SensorManagerThe SensorManager class is used to run the sensors. It has a method to add sensors and a method to run the sensors.sensor_manager=SensorManager()sensor_manager.add_sensor(temperature_sensor)sensor_manager.add_sensor(humidity_sensor)sensor_manager.add_sensor(water_level_sensor)sensor_manager.add_sensor(light_intensity_sensor)try:sensor_manager.run()exceptKeyboardInterrupt:sensor_manager.stop_all()MqttClientThe MqttClient class is used to publish messages to the broker. It uses the Paho MQTT library to communicate with the broker.mqtt_client=MqttClient('your.broker.org')LicensePysor is licensed under the MIT License. See the LICENSE file for more details
Package: pysort
PySortA Powerful Python package that performs 15 different types of stable and unstable Sorting algorithms on List Data Structure. This package will be more beneficial for competitive programmers and developers. Based on your requirement choose your sort algorithm.USAGE# importing Libraryfromsorting_techniquesimportpysort# Creating the Sort ObjectsortObj=pysort.Sorting()BUBBLE SORTmyList=[1,3,2,7,4,89,56,99,111,23,6445,566]# Genearting the Sort ResultsortResult=sortObj.bubbleSort(myList)# The SortResult contains the Sorted Listprint(sortResult)Insertion Sort# Performing Insertion SortsortResult=sortObj.insertionSort(myList)# The SortResult contains the Sorted Listprint(sortResult)Selection Sort# Performing Insertion SortsortResult=sortObj.selectionSort(myList)# The SortResult contains the Sorted Listprint(sortResult)Shell Sort# Performing Insertion SortsortResult=sortObj.shellSort(myList)# The SortResult contains the Sorted Listprint(sortResult)Pigeon Hole Sort# Performing Insertion SortsortResult=sortObj.pigeonHoleSort(myList)# The SortResult contains the Sorted Listprint(sortResult)Heap Sort# Performing Insertion SortsortResult=sortObj.heapSort(myList)# The SortResult contains the Sorted Listprint(sortResult)Gnome Sort# Performing Insertion SortsortResult=sortObj.heapSort(myList)# The SortResult contains the Sorted Listprint(sortResult)Heap Sort# Performing Insertion SortsortResult=sortObj.heapSort(myList)# The SortResult contains the Sorted Listprint(sortResult)Pancake Sort# Performing Insertion SortsortResult=sortObj.pancakeSort(myList)# The SortResult contains the Sorted Listprint(sortResult)Bogo Sort# Performing Insertion SortsortResult=sortObj.bogoSort(myList)# The SortResult contains the Sorted Listprint(sortResult)Merge Sort# Performing Insertion SortsortResult=sortObj.mergeSort(myList)# The SortResult contains the Sorted Listprint(sortResult)Quick Sort# Performing Insertion SortsortResult=sortObj.heapSort(myList)# The SortResult contains the Sorted Listprint(sortResult)Brick Sort# Performing Insertion SortsortResult=sortObj.brickSort(myList)# The SortResult contains the Sorted Listprint(sortResult)Radix Sort# Performing Insertion SortsortResult=sortObj.radixSort(myList)# The SortResult contains the Sorted Listprint(sortResult)Stooage Sort# Performing Insertion SortsortResult=sortObj.heapSort(myList,initialIndexValue,lengthOfList-1)# The SortResult contains the Sorted Listprint(sortResult)DependenciesPython v3.x is Required.
Package: pysortcsv
Python OOP+ วิธีสร้าง Library เป็นของตัวเอง+ อัพโหลด Package ไปยัง
PyPI.orgโปรแกรมนี้ลุงใช้สำหรับสอนการเขียนโปรแกรมแบบ OOP
สามารถดูตัวอย่างคลิปวิดีโอที่สอนได้ใน:https://youtu.be/1egtTXUJ3-4วิธีติดตั้งเปิด CMD / Terminalpipinstalloopschoolวิธีใช้งานแพ็คเพจนี้เปิด IDLE ขึ้นมาแล้วพิมพ์…fromoopschoolimportStudent,Tesla,SpecialStudent,Teacherallstudent=[]teacher1=Teacher('Ada Lovelace')teacher2=Teacher('Bill Gates')print(teacher1.students)# Day 1print('-----Day 1----')st1=Student('Albert','Einstein')allstudent.append(st1)#สมัครเสร็จเก็บไว้ในลิสต์นักเรียนทันทีteacher2.AddStudent(st1)print(st1.fullname)# Day 2print('-----Day 2----')st2=Student('Steve','Jobs')allstudent.append(st2)teacher2.AddStudent(st2)print(st2.fullname)# Day 3print('-----Day 3----')foriinrange(3):st1.Coding()st2.Coding()st1.ShowEXP()st2.ShowEXP()# Day 4print('-----Day 4----')stp1=SpecialStudent('Thomas','Edison','Hitler')allstudent.append(stp1)teacher1.AddStudent(stp1)print(stp1.fullname)print('คุณครูครับ ขอคะแนนฟรีสัก 20 คะแนนได้ไหม')stp1.exp=20# แก้ไขค่าในคลาสได้stp1.Coding()stp1.ShowEXP()# Day 5print('-----Day 5----')print('นักเรียนกลับบ้านยังไงจ๊ะ?')print(allstudent)forstinallstudent:print('ผม:{}กลับบ้านด้วย{}ครับ'.format(st.name,st.vehicle))ifisinstance(st,SpecialStudent):st.vehicle.SelfDriving(st)# Day 6print('-----Day 6----')teacher1.CheckStudent()teacher2.CheckStudent()print('รวมพลังของนักเรียน 2 คน ',st1+st2)พัฒนาโดย: ลุงวิศวกร สอนคำนวณ FB:https://www.facebook.com/UncleEngineerYouTube:https://www.youtube.com/UncleEngineer
Package: pysortfolder
pysortfolderSort folders and files by size and display it in folder tree format.UsagefrompysortfolderimportPySortFolderPySortFolder(path='PATH/TO/ROOT/FOLDER')sf.make_tree(reverse=False)# support reverse=Truesf.print_tree()# data, size: 82# ├── subfolder3, size: 0# │   └── subsubfolder2, size: 0# │       └── subsubsubfolder1, size: 0# │           ├── subsubsubsubfolder1, size: 0# │           └── subsubsubfolder1_text1.txt, size: 0# ├── subfolder2, size: 17# │   └── subfolder2_text1.txt, size: 17# ├── subfolder1, size: 54# │   ├── subsubfolder1, size: 20# │   │   └── subsubfolder1_text1.txt, size: 20# │   ├── subfolder1_text1.txt, size: 17# │   └── subfolder1_text2.txt, size: 17# └── root_text1.txt, size: 11frompysortfolderimportdir_sizeprint(dir_size(path='PATH/TO/ROOT/FOLDER'))# print the size of the root# 82
Package: pysortlib
Python Sorting LibraryLibrary of sorting algorithms with precise implementation and documentation.AlgorithmsBubble sortCounting sortCycle sortHeap sortInsert sortMerge sortPancake sortQuick sortRadix sortSelection sortShell sortSleep sortInstallpipinstallpysortlibUsagefrompysortlibimportinsert_sortarray=[3,5,2,1,7,4,6]insert_sort(array)# set a breakpoint and explore \o/print(array)DevelopmentVirtual environmentpipinstall--userpoetry
poetryconfigvirtualenvs.in-projecttruepoetyshell
poetryinstallDependenciespoetryupdatePre-commitpre-commitclean
pre-commitinstall--hook-typepre-commitCoding standardsperfectionismblack- code formattingruff- static code analysismypy- static type checkingpytest- unit tests
Package: pysos
pySOS: Simple Objects Storagepersistant dictionaries and lists for pythonThis is ideal for lists or dictionaries which either need persistence,
are too big to fit in memory or both.There are existing alternatives likeshelve, which are very good too.
There main difference withpysosis that:only the index is kept in memory, not the values (so you can hold more data than what would fit in memory)it provides both persistent dictsandlistsobjects must be json "dumpable" (no cyclic references, etc.)it's fast (much faster thanshelveon windows, but slightly slower than nativedbmson linux)it's unbuffered by design: when the function returns, you are sure it has been written on diskit's safe: even if the machine crashes in the middle of a big write, data will not be corruptedit is platform independent, unlikeshelvewhich relies on an underlyingdbmimplementation, which may vary from system to systemthe data is stored in a plain text formatUsagepip install pysosDictionaries:import pysos
db = pysos.Dict('somefile')
db['hello'] = 'persistence!'Lists:import pysos
db = pysos.List('somefile')
db.append('it is now saved in the file')PerformanceJust to give a ballpark figure, there is a mini benchmark included intest_benchmark.py.
Here are the results on my laptop:Writes: 28521 / second
Reads: 188502 / secondThe test is just writing 100k small key/values, and reading them all too.
It's just meant to give a rough idea.It writes every time you set a value, but only the key/value pair.
So the cost of adding an item stays constant.
On the other hand, lots of updates / deletes / re-inserts would lead to data fragmentation in the file.
This might deteriorate performance in the long run.F.A.Q.Is it thread safe?No. It's not thread safe.
In practice, synchronization mechanisms are typically desired on a higher level anyway.Why not make it async writes?In the original version, there was a switch to choose between sync and async mode.
However, it turned out to have only a relatively small impact on overall performance.
Less than 25% on the hardware/OS/data I tested if I remember right.
Since the benefits seem rather low, I removed the flag and the associated code altogether,
in order to ensure safety by default.
IMHO, it's preferable to loose a few microseconds rather than data upon a crash.Why not use memory mapped files?I experimented with that too. In my experience, with the hardware/OS/data I tested,
it turned out to ...suck. Using memory mapped files lead to inconsistent and unpredictible performance,
often much slower than direct file access.
Package: pySOT
pySOT: Python Surrogate Optimization ToolboxThe Python Surrogate Optimization Toolbox (pySOT) is an asynchronous parallel
optimization toolbox for computationally expensive global optimization problems.
pySOT is built on top of the Plumbing for Optimization with Asynchronous Parallelism (POAP),
which is an event-driven framework for building and combining asynchronous optimization
strategies. POAP has support for both threads and MPI.pySOT implements many popular surrogate optimization algorithms such as the
Stochastic RBF (SRBF) and DYCORS methods by Regis and Shoemaker, and the SOP
method by Krityakierne et. al. We also support Expected Improvement (EI) and
Lower Confidence Bounds (LCB), which are popular in Bayesian optimization. All
optimization algorithms can be used in serial, synchronous parallel, and
asynchronous parallel and we support both continuous and integer variables.The toolbox is hosted on GitHub:https://github.com/dme65/pySOTDocumentation:http://pysot.readthedocs.io/InstallationInstallation instructions are available at:http://pysot.readthedocs.io/en/latest/quickstart.htmlExamplesSeveral pySOT examples and notebooks can be found at:https://github.com/dme65/pySOT/tree/master/exampleshttps://github.com/dme65/pySOT/tree/master/notebooksCiting UsIf you use pySOT, please cite the following paper:David Eriksson, David Bindel, Christine A. Shoemaker. pySOT and POAP: An event-driven asynchronous framework for surrogate optimization. arXiv preprint arXiv:1908.00420, 2019@article{eriksson2019pysot,
  title={pySOT and POAP: An event-driven asynchronous framework for surrogate optimization},
  author={Eriksson, David and Bindel, David and Shoemaker, Christine A},
  journal={arXiv preprint arXiv:1908.00420},
  year={2019}
}FAQQ: Can I use pySOT with MPI?A: Yes. You need to install mpi4py in order to use the MPIController in POAP.Q: I used pySOT for my research and want to cite itA: Please cite ourpreprintwhich is currently under review!Q: Is there support for Python 2?A: Python 2 support was removed in version 0.2.0Q: I can’t find the MARS interpolantA: You need to install py-earth in order to use MARS. More information is
available here:https://github.com/scikit-learn-contrib/py-earth
Package: pysotsog
pysotsogpython Library for Scholars to achieve "Standing on the shoulders of giants - with direct access to the clouds"Introductionpysotsog is a python library for scholars to help navigate the conceptual knowledge graph consisting ofauthorsorganizationspapersscientific eventsscientific event seriesDocs and TutorialsWikiDemosotsog Demo at https://sotsog.bitplan.comExample searchUCLA
TimBerners-Lee
WeNeedaMagnaCartafortheInternet
WikidataWorkshop2022VNC2019Proceedingsofthe35thInternationalWorkshoponDescriptionLogics(DL2022)COVID-19
Package: pysound
PySoundA Python library for creating digital sound and music.PySound uses numpy arrays to store and process sound.Features:Oscillators - sine, saw, square, wave table and noiseEnvelopes - ramp, attack-decay, generic envelopeEffects - echoMixers - add, multiplySequencers - join sounds, basic sound sequencerOutput - WAV fileGraph - plot sound wavesTutorialReference
Package: pysoundings
pysoundingspysoundingsis just a simple little module designed to pull atmospheric sounding data from theUniversity of Wyoming, College of Engineering, Department of Atmospheric Science's website. All you need is the station number and the date and this module will return apandas.DataFramecontaining the sounding data. You may still want to go to the website to determine what stations are available, but there are data from a lot of stations in the United States.InstallationThe package is available onPyPi:$pipinstallpysoundings
Package: pysourcebin
FUNCTIONS:get_key(url) -> gets the key to the sourcebin out of the link(must be a valid link)get_url(key) -> takes in the key to a sourcebin and turns it into a sourbin urlcreate(name, code, title=”None”, description=”None”) -> creates a sourcbin with the inputted coderead_key(key) -> returns the contents of the sourbin with that keyread_url(url) -> same as read_key but you can put in a sourbin url