Saravanan666/pypi-org huggingface dataset:
Package: circuitpython-unicornhathd
IntroductionCircuitPython framebuf based driver for Pimoroni’s Unicorn HAT HD.
This driver supports theadafruit_framebuf interfacevia composition instead of inheritance.DependenciesThis driver depends on:Adafruit CircuitPythonAdafruit framebufPlease ensure all dependencies are available on the CircuitPython filesystem.
This is easily achieved by downloadingthe Adafruit library and driver bundleor individual libraries can be installed usingcircup.Installing from PyPINoteThis library is not available on PyPI yet. Install documentation is included
as a standard element. Stay tuned for PyPI availability!On supported GNU/Linux systems like the Raspberry Pi, you can install the driver locallyfrom
PyPI.
To install for current user:pip3installcircuitpython-unicornhathdTo install system-wide (this may be required in some cases):sudopip3installcircuitpython-unicornhathdTo install in a virtual environment in your current project:mkdirproject-name&&cdproject-namepython3-mvenv.envsource.env/bin/activatepip3installcircuitpython-unicornhathdInstalling to a Connected CircuitPython Device with CircupMake sure that you havecircupinstalled in your Python environment.
Install it with the following command if necessary:pip3installcircupWithcircupinstalled and your CircuitPython device connected use the
following command to install:circupinstallunicornhathdOr the following command to update an existing version:circupupdateUsage ExampleimportboardimportdigitaliofromunicornhathdimportUnicornHATHD# TODO: Change this pin to match your wiringchip_select_pin=digitalio.DigitalInOut(board.D0)chip_select_pin.direction=digitalio.Direction.OUTPUTchip_select_pin.value=Truedisplay=UnicornHATHD(board.SPI(),chip_select_pin)# Turn on all of the blue LEDsdisplay.fill(127)display.show()ContributingContributions are welcome! Please read ourCode of Conductbefore contributing to help this project stay welcoming.DocumentationFor information on building library documentation, please check outthis guide.
Package: circuitpython-uplot
Framework to display different graphical plots in displayio.
Take a look in theexamplessection in RTD to see the galleryFor detailed view of the library please refer to theQuick start guideBelow a picture of a real live application. for more information visit the projectpage. Thanks to @CasainhoDependenciesThis library depends on:Adafruit CircuitPythonThis library is resource consuming, may or may not with some CircuitPython supported devices.
Tinker it as you wish in order to work.Please ensure all dependencies are available on the CircuitPython filesystem.
This is easily achieved by downloadingthe Adafruit library and driver bundleor individual libraries can be installed usingcircup.Installing from PyPIOn supported GNU/Linux systems like the Raspberry Pi, you can install the driver locallyfrom
PyPI.
To install for current user:pip3installcircuitpython-uplotTo install system-wide (this may be required in some cases):sudopip3installcircuitpython-uplotTo install in a virtual environment in your current project:mkdirproject-name&&cdproject-namepython3-mvenv.venvsource.env/bin/activatepip3installcircuitpython-uplotInstalling to a Connected CircuitPython Device with CircupMake sure that you havecircupinstalled in your Python environment.
Install it with the following command if necessary:pip3installcircupWithcircupinstalled and your CircuitPython device connected use the
following command to install:circupinstallcircuitpython_uplotOr the following command to update an existing version:circupupdateUsage ExampleTo learn how to use the library please refer to the examples folder or theQuick start guideDocumentationAPI documentation for this library can be found onRead the Docs.ContributingContributions are welcome!
Package: circuitpython-uschedule
IntroductionReduced version of the schedule library for CircuitPythonThis library is a reduced version of the Pythonschedule
library. Credit toDan Bader
(dbader)for
this excellent library.DependenciesThis driver depends on:Adafruit CircuitPythonAdafruit CircuitPython DatetimePlease ensure all dependencies are available on the CircuitPython filesystem.
This is easily achieved by downloadingthe Adafruit library and driver bundleor individual libraries can be installed usingcircup.Installing from PyPI
=====================On supported GNU/Linux systems like the Raspberry Pi, you can install the driver locallyfrom
PyPI.
To install for current user:pip3installadafruit-circuitpython-uscheduleTo install system-wide (this may be required in some cases):sudopip3installadafruit-circuitpython-uscheduleTo install in a virtual environment in your current project:mkdirproject-name&&cdproject-namepython3-mvenv.envsource.env/bin/activatepip3installadafruit-circuitpython-uscheduleUsage Exampleimporttimeimportuscheduleasscheduledefgreet():print("Hello, world!")""" Note: pass the function name, like greet, not greet():"""schedule.every(10).seconds.do(greet)whileTrue:schedule.run_pending()time.sleep(1)ContributingContributions are welcome! Please read ourCode of Conductbefore contributing to help this project stay welcoming.DocumentationRead themodule documentation.
Package: circuitpython-waveshare-lcd1602
IntroductionDrive for Waveshare’s I2C character display LCD1602DependenciesThis driver depends on:Adafruit CircuitPythonBus DevicePlease ensure all dependencies are available on the CircuitPython filesystem.
This is easily achieved by downloadingthe Adafruit library and driver bundleor individual libraries can be installed usingcircup.Installing from PyPIOn supported GNU/Linux systems like the Raspberry Pi, you can install the driver locallyfrom
PyPI.
To install for current user:pip3installcircuitpython-waveshare-lcd1602To install system-wide (this may be required in some cases):sudopip3installcircuitpython-waveshare-lcd1602To install in a virtual environment in your current project:mkdirproject-name&&cdproject-namepython3-mvenv.envsource.env/bin/activatepip3installcircuitpython-waveshare-lcd1602Installing to a Connected CircuitPython Device with CircupMake sure that you havecircupinstalled in your Python environment.
Install it with the following command if necessary:pip3installcircupWithcircupinstalled and your CircuitPython device connected use the
following command to install:circupinstallwaveshare_lcd1602Or the following command to update an existing version:circupupdateUsage ExampleDocumentationAPI documentation for this library can be found onRead the Docs.For information on building library documentation, please check outthis guide.ContributingContributions are welcome! Please read ourCode of Conductbefore contributing to help this project stay welcoming.
Package: circuitpython-wiichuck
IntroductionCircuitPython driver for Nintento WiiMote I2C Accessory DevicesDependenciesThis driver depends on:Adafruit CircuitPythonBus DevicePlease ensure all dependencies are available on the CircuitPython filesystem.
This is easily achieved by downloadingthe Adafruit library and driver bundle.Usage Exampleimporttimeimportboardfromwiichuck.nunchukimportNunchuknc=Nunchuk(board.I2C())whileTrue:x,y=nc.joystickax,ay,az=nc.accelerationprint("joystick ={},{}".format(x,y))print("accceleration ax={}, ay={}, az={}".format(ax,ay,az))buttons=nc.buttonsifbuttons.C:print("button C")ifbuttons.Z:print("button Z")time.sleep(0.5)ContributingContributions are welcome! Please read ourCode of Conductbefore contributing to help this project stay welcoming.DocumentationFor information on building library documentation, please check outthis guide.
Package: circuitree
CircuiTreeGenetic circuit design using Monte Carlo tree searchInstallationFrom a package repositoryTo install usingpip:pip install circuitreeFrom the GitHub repositoryTo install and usecircuitreefrom the GitHub source code, first clone the repo into a directory.git clone https://github.com/pranav-bhamidipati/circuitree.git[ dir_name]Then, you can build the environment using the command-line toolpoetry. Instructions for installation can befound here.From the main project directory, runpoetry installto install a virtual environment withcircuitreeinstalled. The easiest way to use this environment is to run it interactively withpoetry shell. Alternatively, you can run a command in the virtual environment withpoetry run <command>. For instance, to launch a Jupyter notebook withcircuitreepre-loaded, runpoetry run jupyter notebook.UsageSee thequick-start demo.
Package: circuitroomba
IntroductionCircuitRoomba is a CircuitPython library for interfacing with Roomba Open Interface devices.DependenciesThis driver depends on:Adafruit CircuitPythonPlease ensure all dependencies are available on the CircuitPython filesystem.
This is easily achieved by downloadingthe Adafruit library and driver bundle.Installing from PyPI for blinka boardspipinstallcircuitroombaTo install in a virtual environment in your current project:mkdirproject-name&&cdproject-namepython3-mvenv.envsource.env/bin/activatepipinstallcircuitroombaFor CircuitPython  boards that don’t supportblinkacopy/circuitroombafrom/srcto/libon the CircuitPython board.makeinstallhas been setup as a helper, but you may need
to update the/Volumepath for your system and board name.makeinstallUsage Exampleimportboardimportdigitalioimporttimefromcircuitroomba.series6importroomba__repo__="https://github.com/AlexanderHagerman/circuitroomba.git"# initialize roombabot=roomba.Commands(board.TX,board.RX,digitalio.DigitalInOut(board.A1))# wake roomba from sleep modebot.wake_up()# CircuitPython loopwhileTrue:# send commandsbot.start()bot.safe()bot.clean()time.sleep(2)bot.power()bot.stop()breakMore examples are available in/examples.ContributingContributions are welcome! Please read ourCode of Conductbefore contributing to help this project stay welcoming.Sphinx documentationSphinx is used to build the documentation based on rST files and comments in the code. First,
install dependencies (feel free to reuse the virtual environment from above):python3-mvenv.envsource.env/bin/activatepipinstallSphinxsphinx-rtd-themeNow, once you have the virtual environment activated:cddocssphinx-build-E-W-bhtml._build/htmlThis will output the documentation todocs/_build/html. Open theindex.htmlin your browser to
view them. It will also (due to -W) error out on any warning like Travis will. This is a good way to
locally verify it will pass.Images
Package: circuitsascode
Circuits as CodeThis is a collection of pre-built circuits written as scripts inSKiDL.DescriptionSKiDLlets you create electronic circuits by writing Python scripts instead of using a schematic editor.
Thecircuitsascodeauxiliary Python package gives you a library of ready-made electronic circuits that serves several purposes:It provides a set of lower-level modules that you can integrate within your own designs.It shows you examples of how to write SKiDL code.Free software: MIT licenseDocumentation:http://devbisme.github.io/circuitsascodeUser Forum:https://github.com/xesscorp/skidl/discussionsInstallationYou can install this circuit library usingpip:pipinstallcircuitsascodeUsageJust import the library to use a circuit module:# Import the function that creates a VGA display interface.fromcircuitsascode.displays.vgaimportvga# Create color and sync signals to connect to the VGA interface.red,grn,blu=Bus(5),Bus(4),Bus(3)hsync,vsync,gnd=Net(),Net(),Net()# Create a VGA interface circuit customized for the widths# of the RGB buses.vga1=vga(rgb=(len(red),len(grn),len(blu)))# Connect the signals to the VGA interface circuit.vga1.red+=redvga1.grn+=grnvga1.blu+=bluvga1.hsync+=hsyncvga1.vsync+=vsyncvga1.gnd+=gndChangelogVersion 0.0.1Initial release.
Package: circuits-bricks
Overviewcircuits-bricks is a collection of general purpose components
for thecircuits framework. Read thePackage Documentationfor details.The source is maintained atgithub. Please use theissue trackerthere to report any issues.Requirementscircuits-bricks has no dependencies beyond thePython Standard Libraryand thecircuits frameworkin the 2.0.1 version.InstallationThe simplest and recommended way to install circuits-bricks is with
easy_install:> easy_install circuits-bricksAlternatively, you may download the source package from thecircuits-bricks Page on PyPIor fromgithub, extract it
and install using:> python setup.py installLicensecircuits-bricks is licensed under theMIT License.
Package: circuitsim
CircuitSimAn interafce to perform simulations of gate-level HDL designs from python.InstallationCircuitSim requires Python3.6 or greater
The easiest way to install is via PyPi:pipinstallcircuitsimFinally, to install in-place with the source, use:cd<installlocation>
gitclonehttps://github.com/circuitgraph/circuitsim.gitcdcircuitsim
pipinstall-e.

Inordertoperformsimulations,youmusthaveatleastoneoftheavailablesimulatorsinstalled.Using the simulatorSimulation can be performed using theCircuitSimulatorclass.This allows the simulation to be compiled once and then quieried multiple times without having to recompile.TheCircuitSimulatoraccepts circuits in the form ofcircuitgraphCircuitobjects.Vectors are accepted and returned as dictionaries mapping input/output names to logical values (TrueorFalse).Available simulatorsCurrently,iverilog,verilator, and VCS are supported. In order to use a given simulator, it must be in yourPATH.Usage ExampleimportrandomimportshutilimportcircuitgraphascgfromcircuitsimimportCircuitSimulatordefmain():# Exercise 3 random inputs patterns 5 times.num_trials=5num_vectors=3c=cg.from_lib("c17")simulator=CircuitSimulator(c)forsim_numinrange(num_trials):vectors=[]for_inrange(num_vectors):vectors.append({i:random.choice([True,False])foriinc.inputs()})sim_results=simulator.simulate(vectors)print(f"Simulation{sim_num}")print(f"inputs:{vectors}")print(f"outputs:{sim_results}")if__name__=="__main__":main()ContributingIf you want to develop an improvement for this library, please consider the information below.Tests are run using the builtin unittest framework. Some basic linting is performed using flake8.pipinstsallflake8
maketestDocumentation is built using pdoc3.pipinstallpdoc3
makedocCode should be formatted usingblack.Pre-commitis used to automatically run black on commit.pipinstallblackpre-commit
pre-commitinstallPre-commit also runs a few other hooks, including a docstring formatter and linter. Docs follow thenumpydocumentation convention.
Package: circuits-minpor
Overviewcircuits-minpor provides a minimal portal component based on the
thecircuits framework. Read thePackage Documentationfor details.The source is maintained atgithub. Please use theissue trackerthere to report any issues.Requirementscircuits-minpor depends on thePython Standard Library,
thecircuits frameworkin the 2.0.1 version,
the general purposecircuits_brickscomponents, theTenjintemplate engine and therbtranslationslibrary. Both circuits bricks and the
resource bundle translations library are small libraries
that have been developed in parallel with the portal
component. They have been singled out because they have
proven to be useful independent of this portal component.InstallationThe simplest and recommended way to install circuits-minpor is with
easy_install:> easy_install circuits-minporAlternatively, you may download the source package from thecircuits-minpor Page on PyPIor fromgithub, extract it
and install using:> python setup.py installLicensecircuits-minpor is licensed under theGPL License.
Package: circuits-py
Circuits-pyA python package for creating logic circuits.seeexamplesfromcircuits_pyimportStateclassDLatch():def__init__(self,Q,QI):self.Q=Qself.QI=QIdefd_latch(self,Clock,D):self.Q=State(D).NOT().AND(Clock).NOR(self.QI).stateself.QI=State(D).AND(Clock).NOR(self.Q).statel=DLatch(1,0)whileTrue:l.d_latch(1,0)fromcircuits_pyimportState,logic,divide,combinedefaddCircuit(a,b,carry):a=State(a)# A State object represents current up to the next logic gate.divide(a.XOR(b),# when an circuit path divideslambdae:e.XOR(carry),lambdae:a.AND(carry).OR(a.AND(b).state))addCircuit(1,1,0)Designusing plain functions to create circuits make it harder to understand and write:out=AND(0,AND(0,XOR(input,0)))# gates are nested#     <----<----<----<----<-----#     the circuit flows in the opposite direction of the codeinstead:State(1).XOR(0).AND(0).AND(0)#     ----->---->---->---->#     the circuit flows in the direction of the codeStateA State object represents path of electrical current up to the next logical gate, a state can be initialized either 0 or 1.a=State(0)b=State(1)supported logic functions: AND, OR, XOR, NOT, NOR, NAND, XNOR and BUFFERwhen a logic gate is invoked a new State() object is returned initialized output of that gateState(1).XOR(0).AND(1)# returns State(1)the output state can be accessed by get_output()print(State(1).XOR(0).AND(1).get_output())# prints 1Custom Logicuse the combine() function to use custom logic,fromcircuits_pyimportcombine,logic_gate@logic_gatedefcustom_logic(A,B):if((A)and(notB)):returnTrueelse:returnFalse# combine() takes two or more paths and combines it to a logic functioncombine(State(1).AND(1),State(0).AND(0),Logic=custom_logic# pass the logic function)combine()combine two or more paths to a logic gateexample:@logic_gatedefOR(A,B):returnAorBcombine(State(b).NOT().AND(a),# sourceState(a).NOT().AND(b),# sourceLogic=OR# Logic function)def combine(*sources, Logic=None)*sourcesState() objects,Logica logic function which takes *source parameters and returns abooloutput (the function should use the @logic_gate decorator)
Package: circuit-webhook
circuit-webhookcircuit-webhook is a python client library for Unify Circuit api Incoming Webhooks on Python 3.6 and above.Installation$ pip install circuit-webhookUsagefromcircuit_webhookimportCircuitcircuit=Circuit(url='https://eu.yourcircuit.com/rest/v2/webhooks/incoming/XXX')circuit.post(text="Hello, world.")Getting startedFor help getting started with Incoming Webhooks, view onlinedocumentation.ContributingFork itCreate your feature branch (git checkout -b my-new-feature)Commit your changes (git commit -am 'Add some feature')Push to the branch (git push origin my-new-feature)Create new Pull Request
Package: circularAlgos
A package including many functions for circular distributions:r_vonmises() - This function is used for generating random numbers for a von Mises circular distributionq_vonmises() - This function is used used to calculate the quantiles for the given probabilities for a von Mises distributionp_vonmises() - This function is  used to calculate the CDF value at the given points for a von Mises distributiond_vonmises() - This function is for calculating the PDF at the given points for a von Mises circular distributionangles_VMF_mix() - This function is used to fit angular data in radians using the expectation maximization algorithm formaximum likelihood estimatation of the parameters of the different mixturesvmf_clust() - This function is used to:fit the given data using the expectation maximization algorithm for
maximum likelihood estimatation of the parameters of the differnt mixturesPerform probabilistic clustering using the mixtures obtained above
Package: circular-buffer
Efficient circular buffer implementation in Python with optional Numba JIT compilationUsageimportcircular_bufferbuffer_of_int_type=circular_buffer.for_instances_like(123)buf=buffer_of_int_type(size=10,autoexpand=True)foriinrange(12):buf.push_back(i)assertbuf.pop_front()==0assertbuf.front()==1assertbuf.back()==11Remember to installnumbaJIT compiler package to get a small extra speedup.numbacan be
automatically installed if you install this package viapip install circular-buffer[numba].
Package: circularcoordinates
Circular-CoordinatesCircular coordinates from persistent cohomologyCircular-Coordinates is an all in one class that facilitates creating and plotting circular coordinates from persistent cohomology functions hidden in your dataset.Featurestakes input data in the form of numpy array or pandas dataframeutilizes the ripser library for fast persistent cohomology barcode calculationProvides multiple ways of plotting and visualizing the output.SetupYou can install the library directly from github(will be published on Pypi soon). You will need PyQt5 before installing(only for visualizing plots in ide will be optional in future).pip install PyQt5
pip install git+https://github.com/appliedtopology/circular-coordinatesExample usageCircular coordinates can be calculated and visualized with only a few lines of code. The circular coordinates are outputted mapped between [0,1]. When visualising the coordinates are denoted by colors on the color wheel (with its values mapped to [0,1]). Thus forming a loop stretching from 0 to 1.import pandas as pd
import circularcoordinates

df = pd.read_csv('malaria.csv')
features = df[['Weight', 'Glucose', 'Accuri', 'RBC']]

prime=11
circ=circularcoordinates.circular_coordinate(prime)
vertex_values=circ.fit_transform(features)
circ.plot_pca(features,vertex_values)If we already have the ripser output dictionary we can directly compute the circular coordinates without recomputing the dictionary.ripser_output=circ.rips
vertex_values=circ.circular_coordinate(ripser_output)We can also plot the persistant homology barcodescirc.plot_barcode(circ.rips['dgms'][1])Circular coordinates can also be plottted against external data to see what patterns emerge.circ.plot_eps(df['Day Post Infection'],vertex_values)LicenseMIT
Package: circular-queue
Circular QueueA pythonic implementation of the beloved data structureCircular Queue is an object that can be used whenever you need to connect the head of an iterable to its tail.
It can be easily connected to a database in order to persist your queue rotation.Installationpip install circular-queueHow to useAfter cloning the repo, you can import theCircularQueueclass to your project:fromcircular_queueimportCircularQueueYou can instantiate theCircularQueueobject passing aqueuean apointeras arguments:mylist=['Banana','Star Fruit','Apple','Orange','Avocado']pointer='Apple'myqueue=CircularQueue(mylist,pointer)Now you have two methods at your disposal:get_next_elementandget_previous_element:myqueue.get_next_element()>>>'Orange'myqueue.get_next_element()>>>'Avocado'myqueue.get_next_element()>>>'Banana'myqueue.get_previous_element()>>>'Avocado'If you need to get a batch of elements you can use the get_batch method like so:mylist=['Banana','Star Fruit','Apple','Orange','Avocado']pointer='Banana'batch_size=3myqueue=CircularQueue(mylist,pointer)myqueue.get_batch(batch_size)>>>['Star Fruit','Apple','Orange']You can also get batch elements in queue rotating to the left:myqueue.get_batch(batch_size,rotation='left')>>>['Orange','Apple','Star Fruit']
Package: circulartape
circulartapeIt's a node-oriented circular linked list implementation.Source:phab.tris.fyi.Examplefrom circulartape import Tape

one = Tape("one")  # one.to_list() == ["one"]
two = one.insert("two")  # one.to_list() == ["one", "two"]
three = two.insert("three")  # one.to_list() == ["one", "two", "three"]

two.remove()  # one.to_list() == ["one", "three"]

# You can build a long list and seek through it n nodes at a time:
one = Tape(1)
current = one
for i in range(2, 100):
    current = current.insert(i)

one.seek(30).data  # => 31

# Use negative values to seek backwards.