Saravanan666/pypi-org huggingface dataset:
Package: pydgn
PyDGN: a research library for Deep Graph NetworksDocumentationThis is a Python library to easily experiment
withDeep Graph Networks(DGNs). It provides
automatic management of data splitting, loading and common experimental settings. It also handles both model
selection and risk assessment procedures, by trying many different configurations in parallel (CPU or GPU).Citing this workIf you used this library for your project, please consider citing us:@article{pydgn,
  author = {Errica, Federico and Bacciu, Davide and Micheli, Alessio},
  doi = {10.21105/joss.05713},
  journal = {Journal of Open Source Software},
  month = oct,
  number = {90},
  pages = {5713},
  title = {{PyDGN: a Python Library for Flexible and Reproducible Research on Deep Learning for Graphs}},
  url = {https://joss.theoj.org/papers/10.21105/joss.05713},
  volume = {8},
  year = {2023}
}Installation:Automated tests passing on Windows, Linux, and MacOS. Requires at least Python 3.8.
Simply runpip install pydgnQuickstart:Build dataset and data splitspydgn-dataset --config-file examples/DATA_CONFIGS/config_NCI1.ymlTrainpydgn-train  --config-file examples/MODEL_CONFIGS/config_SupToyDGN.ymlAnd we are up and running!To debug your code you can add--debugto the command above, but the "GUI" will be disabled.To stop the computation, useCTRL-Cto send aSIGINTsignal, and consider using the commandray stopto stop
all Ray processes.Warning:ray stopstopsallray processes you have launched, including those of other
experiments in progress, if any.Projects using PyDGNInfinite Contextual Graph Markov Model (ICML 2022)Graph Mixture Density Networks (ICML 2021)Contextual Graph Markov Model (ICML 2018, JMLR 2020)Extended Contextual Graph Markov Model (IJCNN 2021)Continual Learning Benchmark for Graphs (WWW Workshop 2021, spotlight)Data SplitsWe provide the data splits taken fromErrica Federico, Podda Marco, Bacciu Davide, Micheli Alessio:A Fair Comparison of Graph Neural Networks for Graph
Classification.8th International Conference on Learning
Representations (ICLR 2020).Codein theexamples/DATA_SPLITSfolder.License:PyDGN >= 1.0.0 isBSD 3-Clauselicensed, as written in theLICENSEfile.
Package: pydgq
Integrate first-order ODE systems  u’(t) = f(u, t).The main feature of this library is dG(q), i.e. the
time-discontinuous Galerkin method using a Lobatto basis
(a.k.a. hierarchical polynomial basis).dG(q) is a very accurate implicit method that often allows
using a rather large timestep. Due to its Galerkin nature,
it also allows inspecting the behavior of the solution
inside the timestep.Arbitrary q is supported, but often best results are
obtained for q=1 or q=2.Some classical integrators (RK2, RK3, RK4, IMR, BE)
are also provided for convenience.The focus is on arbitrary nonlinear problems; all implicit
methods are implemented using fixed-point (Banach/Picard)
iteration.
Package: pyDGSA
pyDGSApyDGSA is a Python implementation of distance-based generalized sensitivity analysis (DGSA) followingFenwick et al. (2014).InstallationUse the package managerpipto install pyDGSA.pipinstallpyDGSAUsagePlease see thetutorial_short.ipynbandtutorial_long.ipynbJupyter notebooks in thepyDGSA GitHub repositoryfor detailed usage examples.ContributingPull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.Please make sure to update tests as appropriate.LicenseGPL
Package: pydgutils
pydgutils (PYthon DownGrade UTILitieS)PrefaceThis library use for compatilbe purpose.It provided a simple method to preprocess sources to python2 syntax through 3to2 library (if using python2) and do nothing while using python3.So that you could write your project in python3 syntax and install on python2 without any changes, all jobs are done by 3to2 module which we depends on.UsageCopy the pydgutils_bootstrap.py (in pydgutils source package) to the same directory of your setup.py, then modify your setup.py like this:from pydgutils_bootstrap import use_pydgutils
use_pydgutils()

import pydgutils

# Convert source to v2.x if we are using python 2.x.
source_dir = pydgutils.process()

# Exclude the original source package, only accept the preprocessed package!
packages = find_packages(where=source_dir)

setup(
    ...
    package_dir = {"": source_dir},
    packages=packages,
    ...
    )

...Changes0.0.8 (2016-09-11)Ensure only modified files be parsed while process the second time0.0.7 (2016-08-26)Enabled fixers : collections, memoryview, printfunction, unittestFixed lib3to2 don’t write backAdded helper functions : process_packages, process_requirements
Package: pyDH
pyDHPure Python Implementation of Diffie-Hellman Key Exchange. Py2, Py3, PyPy compatible.ExampleTo use as a library:importpyDHd1=pyDH.DiffieHellman()d2=pyDH.DiffieHellman()d1_pubkey=d1.gen_public_key()d2_pubkey=d2.gen_public_key()d1_sharedkey=d1.gen_shared_key(d2_pubkey)d2_sharedkey=d2.gen_shared_key(d1_pubkey)d1_sharedkey==d2_sharedkeyBy default it uses the group 14 (2048 bit). To use another group (e.g., 15):d1=pyDH.DiffieHellman(15)#or pyDH.DiffieHellman(group=15)InstallationTo install pyDH, simply:$pipinstallpyDH
Package: pydhcp-ldap-schema
Helper class that can simplyfy most of the tasks when managing ISC-DHCP
configuration stored in a LDAP tree.Modifying existing configurationExample:import ldap
from pydhcp_ldap_schema import DHCPEntry

con = ldap.initialize('ldap://localhost')
con.bind_s('user', 'pass')

subNet = DHCPEntry.ldap_load(con, 'cn=192.168.1.0,cn=DHCP Config,dc=example,dc=com')
print subNet['dhcpNetMask']      # prints ['24']
subNet['dhcpNetMask'] = ['25']   # set new value

subNet.ldap_modify(con)          # automatic change detection and commit if nessesery

con.unbind_s()Creating new nodesAdd fresh configuration:import ldap
from pydhcp_ldap_schema import DHCPEntry

con = ldap.initialize('ldap://localhost')
con.bind_s('user', 'pass')

service = DHCPEntry(['top', 'dhcpService'], cn=['DHCP Config'])
service.ldap_add(con, 'cn=DHCP Config,dc=example,dc=com')       # create base entry

dhcpServer = DHCPEntry(['top', 'dhcpServer'], cn=['dhcp.local'])
dhcpServer['dhcpServiceDN'] = [service.dn]

service.subobjects.insert_entry(dhcpServer)   # DN will be calculated

dhcpServer.ldap_add(con)

# and most important subnet declaration

subnet = DHCPEntry(['top', 'dhcpSubnet'], cn=['192.168.1.0'])
subnet['dhcpNetMask'] = ['24']

service.subobjects.insert_entry(subnet)

subnet.ldap_add(con)

# Now you can start DHCPd server

con.unbind_s()
Package: pydhcplib
Pydhcplib is a python library to read/write and encode/decode dhcp
packet on network.Installation :On Debian, simply run “./setup.py install”. Python modules will be
installed in /usr/lib/python2.X/site-packages/pydhcplib/.If you want to install it on a different location, use the –prefix on
the setup.py command line like this :
./setup.py install –prefix=/rootpath/to/your/location/How to use pydhcplib :Look in the examples directory to learn how to use the modules.
man pydhcp
man pydhcplib
Package: pyDHE
pyDHE is a simple to use Diffie-Hellman implementation written in python, for
python. It makes using Diffie-Hellman a breeze so you can focus on the real
crypto.This library was created out of need, because none of the standard crypto
libraries provide DHE, and of the separate libraries out there, they were
all complicated, incomplete, or requireed manual installation from github.
This library is to change that. The goal is too provide a simple API that is
similar to the pyCrypto and pyCryptodome libraries. The goal is familiarity
and seamless blending with existing code.
Package: pyDHM
pyDHMAn open-source Python library to numerically recover the complex wavefield information of samples from Digital Holographic Microscopy (DHM) for a wide variety of experimental recording configurations. Among others, the library includes:Phase retrieval from image-plane and non-image-plane recordings.Numerical propagation of wavefields via three different propagators (Angular spectrum approach, Fresnel transform, and Fresnel-Bluestein transform).Phase compensation of the tilting angle in off-axis DHM (diffraction-limited and non-diffraction-limited recordings) via three different approaches.Phase-shifting methods for both in-line (3-step, 4-step, and 5-step), slightly off-axis acquisitions (quadrature phase-shifting), and two blind phase-shifting methods (No known phase-shifts).Phase recovery for systems working in telecentric and non-telecentric (compensation of the quadrature phase factor) regimes.InstallationYou can install pyDHM fromPyPI:pip install pyDHMpyDHM is supported on Python 3.7 and above.To use pyDHM, you must install opencv (cv2) and scipy in your enviroment.DocumentationThe pyDHM documentation page can be found inProject Documentation.How to useThree sample scripts are provided:The “example_numericalPropagation.py” script includes examples of the use of the three numerical propagators implemented in the library to digitally focus complex wavefields.The “examples_compensation.py” script includes examples of the use of the three compensation methods for telecentric off-axis DHM holograms and one example of the non-telecentric wavefield compensation.The “examples_phaseShitting.py” script includes examples of the use of two phase-shifting retrieval methods for slightly off-axis DHM holograms and three phase-shifting retrieval methods for in-line setups.More on the use of the pyDHM library can be found in the following academic papers:Castañeda R, Trujillo C, Doblas A (2022) pyDHM: A Python library for applications in digital holographic microscopy. PLoS ONE 17(10): e0275818.https://doi.org/10.1371/journal.pone.0275818R. Castaneda, C. Trujillo, and A. Doblas, "An Open-Source Python library for Digital Holographic Microscopy Imaging," in Imaging and Applied Optics Congress 2022 (3D, AOA, COSI, ISA, pcAOP), Technical Digest Series (Optica Publishing Group, 2022), paper JTh2A.1.https://opg.optica.org/abstract.cfm?URI=3D-2022-JTh2A.1About usThe library has been envisioned, designed, and implemented by the Optical Imaging Research laboratory (OIRL) from the University of Memphis and the Applied Optics research group from Universidad EAFIT. The main contributors to the library are:PhD candidate Raúl Castañeda-Quintero (University of Memphis)rcstdqnt@memphis.eduProfessor Dr. Ana Doblas (University of Memphis)adoblas@memphis.eduProfessor Dr. Carlos Trujillo (Universidad EAFIT)catrujilla@eafit.edu.co
Package: pyDHTMLParser
What is it?DHTMLParser is a lightweight HTML/XML parser created for one purpose - quick and easy
picking selected tags from DOM.It can be very useful when you are in need to write own “guerilla” API for some webpage, or a scrapper.If you want, you can also create HTML/XML documents more easily than by joining strings.DocumentationFull module documentation can be found here:http://pyDHTMLParser.rtfd.orgChangelog2.2.32020-04-12 Fix by #25 (thxhttps://github.com/fm4d).2.2.2Attempt to fix strange recursive inheritance problem.2.2.0Rewritten for compatibility with python3.2.1.0 - 2.1.8State parser fixed - it can now recover from invalid html like<invalid tag=something">.Rewritten to useStateEnumin parser for better readability.Garbage collector is now disabled during _raw_split().Fixed #16 - recovery after tags which don’t ends with>(</codefor example).Closed #17 - implementation of ignoring of<in usage asis smaller thansign.Restored support of multiline attributes..parseString()now doesn’t try to parse HTML element parameters.Implementedfirst()getter.License changed to MIT.Fixed #18: bug which in some cases caused invalid output.Added HTMLElement.__repr__().Added test_coverage.sh.Added extended test_equality() coverage.Formatting improvements.Improved constructor handling, which is now much more readable.Updated formatting of the setup.py.Added more tests.Fixed #22; bug in the SpecialDict.Fixed some nasty unicode problems.Fixed python 2 / 3 problem in docs/__init__.py.getVersion() -> get_version().2.0.10Added more tests of removeTags().run_tests.sh now gets arguments.Check for string in removeTags() changed to basestring from str.2.0.6 - 2.0.9Fixed behaviour of toString() and tagToString().SpecialDict is now derived from OrderedDict.Changed and added tests of .params attribute (OrderedDict is now used).Fixed bug in _repair_tags().Removed _repair_tags() - it wasn’t really necessary.Fixed nasty bug whichcouldcause invalid XML output.2.0.1 - 2.0.5Fixed bugs in.match().Fixed broken links in documentation.Fixed bugs in.isAlmostEqual()..find(); Fixed bug which prevented tag_name to be None.Added op.__eq__()to theSpecialDict.Added new method.containsParamSubset()toHTMLElement.2.0.0Rewritten, refactored, splitted to multiple files.Added unittest coverage of almost 100% of the code.Added better selector methods (.wfind(),.match)Added Sphinx documentation.Fixed a lot of bugs.
Package: pydi
# Simple Little Dependency Injection Container[![Build Status](https://secure.travis-ci.org/aventurella/pydi.png?branch=master)](http://travis-ci.org/aventurella/pydi)## Usage:```pythonfrom pydi import Containerclass DogService(object):def __init__(self, dep):self.dep = depdef action(self):self.dep.action()class FooService(object):def __init__(self, dep1, dep2):self.dep1 = dep1self.dep2 = dep2def action1(self):self.dep1.action()def action2(self):self.dep2.action()class Bar(object):def action(self):print('bar')class Baz(object):def __init__(self, option):self.option = optiondef action(self):print('baz!!!', self.option)class Lucy(object):def action(self):print("I'm a dog!")container = Container()# shared must be called last. It will reuse an instancecontainer.register(FooService).depends(Bar).depends(Baz, option="Hello World!").shared()# without shared, a new instance will be created each timecontainer.register(DogService).depends(Lucy)# could also container['FoOSeRViCE']()obj = container.FooService()obj.action1()obj.action2()print('+-------------+')# could also container['fooservice']()obj2 = container.FooService()obj2.action1()print('+-------------+')obj3 = container.FooService()obj3.action1()```
Package: py_di
# Py_DI - Python Container of Dependency Injection (IOC) implementation## Authors
- [Moises P. Sena](http://moisespsena.com)## Issues[Issues on GitHub](https://github.com/moisespsena/py_di/issues).## Installation### By pip:`bash sudo pip install py_di `### Manual:For default python executable:`bash git clonehttps://github.com/moisespsena/py_dipy_di cd py_di sudo python setup.py install `For another python executable:`bash sudo python3 setup.py install `## Example:See [tests](https://github.com/moisespsena/py_di/blob/master/tests/p/test_all.py) for more details.
Package: pydia
DIA is Microsoft’s Debug Interface Acccess API, for inspection
of PDB files. It’s exposed as a COM object, with no automation, hence
access through Python COM is not possible.pydia is a wrapper that exposes much of the DIA API as-is to Python.
For detailed information of the API, see the Microsoft documentation athttp://msdn.microsoft.com/en-us/library/x93ctkx8.aspxThis module assumes the VS 2005 version of the DIA API; some of the
attributes it exposes weren’t defined in VS 2003. To use the binary
modules, VS 2005 or newer needs to be installed on the system.See the included diademo.py for an example.
Package: pydia2
DIA packaged for use without COM registration usingcomtypes.InstallationWheels are available. Building from source requires the DIA SDK (Install the “Desktop development
with C++” workload of Visual Studio) and the “Debugging Tools for Windows” from the Windows SDK.pipinstallpydia2Exampleimportpydia2source=pydia2.CreateObject(pydia2.dia.DiaSource,interface=pydia2.dia.IDiaDataSource)source.loadDataFromPdb("example.pdb")session=source.openSession()# Query the session...LicenseMIT license.DIA (Debug Information Access) is distributed according to the Microsoft Visual Studio™ distributable
code license terms:https://visualstudio.microsoft.com/license-terms/mlt031819/symsrv.dll is distributed according to the Windows SDK “Distributable Code” license terms:https://docs.microsoft.com/en-us/legal/windows-sdk/redist.
Package: pydiablo
pydiablopydiablo is a Diablo 2 toolkit written in Python. The original goal was to calculate and simulate the time required to kill specific monsters using different builds and equipment. The library is still in early stages. It currently has an accurate monster stats parser and the beginnings of a weapon speed calculator.usagemonster statsimportsysimportpydiabloasd2# interesting monster_ids# unraveler5: wave2 minions# unraveler8/9: high exp dudes in WSK/throne# bloodlord5: death lords in WSK/throne# fallen5: wave1 minions# dkfig2, dkmag2: act5 doom knights and oblivion knights# venomlord: wave4# baalhighpriest: wave3# baalminion1: wave5monster_id='doomknight1'difficulty=d2.monster.HELL# write the area table (if we want to choose a specific area)d2.monster.Monster.levels.write_area_table(sys.stdout,monster_id,difficulty)# with no specific area chosen, it defaults to highest level availableMonsterType=d2.monster.MinionMonster.create_monster_type(monster_id,difficulty)print('========')print('Class name: '+MonsterType.__name__)print('Areas: '+str(MonsterType.mlvl_specific_area_names()))print('Monster: '+MonsterType.monster_name())print('mlvl: '+str(MonsterType.mlvl))print('hp range: '+str(MonsterType.base_hp()))print('exp: '+str(MonsterType.base_experience()))print('block chance: '+str(MonsterType.block_chance()))print('defense: '+str(MonsterType.base_defense()))print('cold effect: '+str(MonsterType.cold_effect()))print('drain effect: '+str(MonsterType.drain_effect()))print('fire resist: '+str(MonsterType.base_fire_resist()))print('cold resist: '+str(MonsterType.base_cold_resist()))print('lightning resist: '+str(MonsterType.base_lightning_resist()))print('poison resist: '+str(MonsterType.base_poison_resist()))print('damage resist: '+str(MonsterType.base_damage_resist()))print('magic resist: '+str(MonsterType.magic_resist()))monster=MonsterType(player_count=8,rand=False)print('==========')print('max_life: '+str(monster.max_life))print('experience: '+str(monster.experience()))weapon speedimportsysimportpydiabloasd2# write a few selected ias breakpoint tablesd2.char.write_bp_table(sys.stdout,d2.char.Amazon.strafe_duration,'BOW',100,0,10)d2.char.write_bp_table(sys.stdout,d2.char.WolfDruid.fury_duration,'STF',100,68,10,WIAS=90)d2.char.write_bp_table(sys.stdout,d2.char.Paladin.zeal_duration,'2HS',100,37,10,WIAS=0)d2.char.write_bp_table(sys.stdout,d2.char.Act2Merc.jab_duration,'HTH',100,0,-10)character data importThis feature is brand new, and there's not a lot of interesting stuff you can do with it yet.from slashdiablo or nokka's d2s parser (https://github.com/nokka/d2s)importpydiabloasd2char_name='netease'char=d2.char.chardata_from_slash(char_name)# if you want to import another d2s file parsed by nokka's d2s# char_json = ... # from d2s parser# char = create_from_json(char_json)#print some stuffprint(char.primary_weapon_stats)print(char.secondary_weapon_stats)print(char.off_weapon_stats)licenseSee the LICENSE file for license details on source files contained in pydiablo. The files in data and data2 are derivative of Diablo 2 game data; the license in the LICENSE file does not apply.
Package: pydiagrams
pydiagramspydiagrams is a tool to generate software diagrams by using Python as a DSL.
pydiagrams providers a framework for describing a software diagram as python code, and translating into it source code specific to a rendering program.It can generate the following types of diagrams:FlowchartsDatabase "View" diagrams / Data flow diagramsUML Component diagramsIntegration Architecture diagramsThese diagrams are can be generated via a choice of rendering programs:PlantUMLGraphvizyEd (as GraphML)BlockdiagMotivationDiagram generation languages (such as PlantUML, Graphviz, Blockdiag) provide general-purpose diagrams, but require the user to learn a specific syntax.
They each have certain strengths and weaknesses that sometimes require switching from one format to another.
pydiagrams instead provides a simple python-DSL that allows the user to write a single diagram that is can then be translated into the rendering program of choice.
Package: pydialect
Pydialect makes Python into a language platform, à la Racket. It provides the
plumbing that allows to create, in Python, dialects that compile into Python
at import time.An extension to the Python language doesn’t need to make it into the Python core,or even be desirable for inclusioninto the Python core, in order to be useful.Building on functions and syntactic macros, customization of the language itself
is one more tool for the programmer to extract patterns, at a higher level.
Hence, beside language experimentation, such extensions can be used as a
framework that allows shorter and/or more readable programs.Pydialect places language-creation power in the hands of its users, without the
need to go to extreme lengths to hack CPython itself or implement from scratch
a custom language that compiles to Python AST or bytecode.Pydialect is geared toward creating languages that extend Python and look
almost like Python, but extend or modify its syntax and/or semantics.
Hencedialects.That said, Pydialect itself is only a lightweight infrastructure hook that makes
it convenient to define and use dialects. To implement the actual semantics
for your dialect (which is where all the interesting things happen), you may
want to look at [MacroPy](https://github.com/azazel75/macropy). Examples can be
found in [unpythonic](https://github.com/Technologicat/unpythonic); see especially
the macros (comprising about one half ofunpythonic). On packaging a set of
semantics into a Pydialect definition, look at the example dialects included
in the Pydialect distribution.Example of a module using a dialect:from __lang__ import lispython

print("hello, my dialect is {}".format(__lang__))

c = cons(1, 2)
assert tuple(c) == (1, 2)
assert car(c) == 1
assert cdr(c) == 2
assert ll(1, 2, 3) == llist((1, 2, 3))

x = let[(a, 21) in 2*a]
assert x == 42

x = letseq[((a, 1),
            (a, 2*a),
            (a, 2*a)) in
           a]
assert x == 4

a = lambda x: cond[x < 0, "nope",
                   x % 2 == 0, "even",
                   "odd"]
assert a(-1) == "nope"
assert a(2) == "even"
assert a(3) == "odd"

def fact(n):
    def f(k, acc):
        if k == 1:
            return acc
        f(k - 1, k*acc)  # implicit return in tail position, like in Lisps
    f(n, acc=1)
assert fact(4) == 24
fact(5000)  # automatic TCO, no crash

square = lambda x: x**2
assert square(3) == 9
assert square.__name__ == "square"  # lambdas are auto-named
Package: pydialog
# pydialog__Command line dialogs made easy.__## InstallationFrom github:```git clone https://github.com/nicr9/pydialog.gitcd pydialogsudo python2.7 setup.py install```## ExamplesFirst things first, import `Dialog`:```from pydialog import Dialog```This is used to make a variety of different dialogs for collecting user input.For example, asking user for a string:```d = Dialog("What's your name?")d.input() # This blocks until user answersprint "Hello %s" % d.result```You can also ask the user to choose from a selection:```d = Dialog("Which do you prefer?")d.choose(['cake', 'chocolate'])print "I like %s too!" % d.result```Or maybe you just want the answer to a yes/no question?:```d = Dialog("Do you want to quit?")d.yesno()if d.result:quit()```Finally, you can also ask users for passwords. This is like the `Dialog.input()`method shown above but it doesn't display what the user is typing:```d = Dialog("Please enter your password")d.secret()sign_in(username, d.result)```## AuthorName: Nic Roland<br>Twitter: [@nicr9_](https://twitter.com/nicr9_)<br>email: nicroland9@gmail.com
Package: pydialogflow
PyDialogflow for HTTPS server© 2018 SiLeader.featuresPyAlexa (pyalexa-lambda) like syntaxsimple systemusageuse FlaskfromflaskimportFlask,request,jsonifyimportdialowapp=Flask(__name__)# Alexa like syntax@app.route("/dialogflow/endpoint",methods=["POST"])defdialogflow_endpoint():req=dialow.Request(request.json)ifrequest.type=="IntentRequest":res=dialow.Response()res.output_speech(text="Dialogflow Test")returnjsonify(res.response)LicenseApache License 2.0See LICENSEfor AlexaGitHub