Saravanan666/pypi-org huggingface dataset:
Package: pyplatform-database
Pyplatform-database package provides read and write functions for Microsoft SQL database.Installationpipinstallpyplatform-databaseAuthentication and environment variablesRefer tomain pagefor documentation on authenticationExploring the modulesfrompyplatform.databaseimport*show_me()Usagereading from SQL table, default database provided in credential filefrompyplatform.databaseimport*query="""SELECT * FROM dbo.fact_sample_superstore"""df=az_to_df(query)df.head()writing pandas dataframe to sql table with non default settingfrompyplatform.databaseimport*# df #TODO create dataframe as sourcetable_name='dbo.fact_sample_superstore'engine=azure_sql_engine(database='testDB')#changing database onlydf_to_azure_sql(df,table_name,engine=engine)
Package: pyplatform-datalake
Pyplatform-datalake package provides functions for Google Cloud Storage and Microsoft Storage services.Installationpipinstallpyplatform-datalakeAuthentication and environment variablesRefer tomain pagefor documentation on authenticationExploring the modulesfrompyplatform.datalakeimport*show_me()Usageuploading in-memory data to Google Cloud Storageimportpyplatform.datalakeasdlkfromioimportBytesIO# df #TODO create dataframe as sourcein_mem_file=BytesIO()df.to_excel(in_mem_file,index=False)in_mem_file.seek(0)dlk.gcs_upload_blob(in_mem_file,bucket_id='bucket',blobname='test.xlsx')downloading and loading trained forecasting model from Google Cloud Storageimportpyplatform.datalakeasdlkfromioimportBytesIOimportpicklegcs_uri='gs://bucket/folder_name/model_name'model_name="fbprophet_forecast_daily"dlk.gcs_download_blob(gcs_uri,filepath=model_name)withopen(model_name,"rb")asmodel:my_model=pickle.load(model)
Package: pyplatform-datawarehouse
Pyplatform-datawarehouse package provides functions for querying, writing and managing data in Google BiqQuery.Installationpipinstallpyplatform-datawarehouseAuthentication and environment variablesRefer tomain pagefor documentation on authenticationExploring the modulesfrompyplatform.datawarehouseimport*show_me()Usagequerying BigQuery tableimportpyplatform.datawarehouseasdwsql="""SELECT Order_ID, Order_Date, Ship_Date, Ship_Mode, Customer_ID, Customer_Name, SegmentFROM `project_id.dataset.sample_superstore` """df=dw.bq_to_df(sql)df.head()# select statemet is enclosed in the stored proceduresql="""CALL `project_id.dataset.spoc_sample_superstore`();"""df=dw.bq_to_df(sql)df.head()writing dataframe to BigQuery tableimportpyplatform.datawarehouseasdw# df #TODO create dataframe as sourcetable_id='project_id.dataset.sample_superstore'job=dw.df_to_bq(df,table_id)print(dw.bq_get_job_info(job))
Package: pyplatform-reporting
Pyplatform-reporting package provides function for managing  hyper datasources on Tableau server.Installationpipinstallpyplatform-reportingAuthentication and environment variablesRefer tomain pagefor documentation on authenticationExploring the modulesfrompyplatform.reportingimport*show_me()Usagelisting Tableau server datasources and reading hyper datasource into pandas dataframefrompyplatform.reportingimport*print(tableau_server_list_resources())datasource_name='sample superstore'hyper_filepath=tableau_server_download_hyper(datasource_name)df=hyper_to_df(hyper_filepath)uploading pandas dataframe as hyper datasource on Tableau serverfrompyplatform.reportingimport*# df #TODO create dataframe as sourcehyper_filepath=df_to_hyper(df,filepath='Sample superstore.hyper')datasource_name=tableau_server_upload_hyper(hyper_filepath)
Package: pyplatform-udf
Pyplatform is a data analytics platform architeture built around Google BigQuery in a hybrid cloud environment.the platorm:provides fast, scalable and reliable SQL database solutionabstracts away the infrastuture by builiding data pipelines with serverless compute solutions in python runtime environmentssimplifies development environment by using jupyter lab as the main toolInstallationpipinstallpyplatformSetting up development environmentgit clone https://github.com/mhadi813/pyplatform
cd pyplatform
conda env create -f pyplatform_dev.ymlEnvironment variablesimportosos.environ['GOOGLE_APPLICATION_CREDENTIALS']='path/to/default_service_account.json'os.environ['DATASET']='default_bigquery_dataset_name'os.environ['STORAGE_BUCKET']='default_storage_bucket_id'Usagecommon data pipeline architectures:-Http sources-On-prem servers-Bigquery integration with Azure Logic Apps-Event driven ETL process-Streaming pipelinesExploring modulesimportpyplatformaspyppyp.show_me()
Package: pyplatypus
PyPlatypusInstalationTo installpyplatypususe command:pip install pyplatypusSee documentation at:GitHub Pages.DevelopmentTo build and deploy your updated docs, use:mkodcs buildWhich will create site/ directory in the project folder. Then type in:mkdocs gh-deployto automatically push the docs to GitHub Pages.To build the package locally just move to its main directory run:pip install --use-feature=in-tree-build .Then it may be imported as any other package installed with the use of pip.If you wish to create the source distribution (in the .egg format):python setup.py sdistTo build a wheel run:python setup.py bdist_wheel --universalImportant!
Before uploading the source distribution to PyPI test it using the TestPyPI using:twine upload --repository-url https://test.pypi.org/legacy/ source/package.tar.gzTo upload all the distributions from a certain folder, for instance if you created
wheels aside from the archive source distribution, use this line:twine upload --repository-url https://test.pypi.org/legacy/ folder/*Then try installing from TestPyPI:pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple pyplatypusOnly after testing it there should you proceed with the release:twine upload dist/*And then install your package!pip install pyplatypusNote!
Pip dependencies will be installed during the package build but there is one conda dependency that
needs to be installed by hand if you are planning to play around with the GPU.conda install -c conda-forge tensorflow==2.9.1We are working on creating the deployment script for this :)
Package: pyplay
Aboutpyplayis a command line tool that invokes the interactive Python
shell, but starts it up with tab completion turned on, common paths
added tosys.path, common modules preloaded and optionally some
startup python commands run.It is configurable, both at a system-wide level and a per project
(directory) level.InstallationInstall from sources:sudo python setup.py installUsageTo start apyplayshell, just enter a command like this:pyplay                  # Start Python and handy modules
pyplay --none           # No extras
pyplay -re yaml         # All except re, then add yaml
pyplay --none yaml      # Nothing except yaml
pyplay xyz test_foo     # import xyz and test_fooConfigurationIf you usepyplaya lot and always want to preload the same modules,
you can set up your own custom configuration in a file called~/.pyplay/config.yamlor./pyplay/config.yamllike this:# Is readline & tab completion on?
readline: true

# Added to the front of sys.path.
pythonpath:
- .
- lib
- tests

# Modules to import by default.
modules:
- os
- sys
- yaml

# Commands to run by default
- from yaml import *If you explicitly supply thePYPLAY_CONFIG_DIRenvironment variable,
that directory will be used to find theconfig.yamlfile. If you setPYPLAY_CONFIG_DIRto an empty string, no config file will be read,
even if the one of them exists.Also,PYPLAY_CONFIG_DIR,~/.pyplay/and./pyplay/will be
added to the front ofsys.pathif they exist, so you can put modules
that you want to play with in those directories.Command Line Options--noneClear the list of modules to importmoduleAdd a module to the import list-moduleRemove a module from the import listSample RunHere is what a session looks like on startup:$ pyplay foo bar
Python 2.6.2 (r262:71600, Apr 16 2009, 09:17:39)
[GCC 4.0.1 (Apple Computer, Inc. build 5250)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
*** Welcome to PyPlay version 0.3 -- Type h() for help.
*** PyPlay tab completion enabled
>>> import os
>>> import sys
>>> import re
>>> import foo
>>> import bar
>>>PyPlay CommandsPyplay adds some extra shell commands. The current commands are:h()Show the PyPlay help screen.y(object)Print a YAML dump of any object. (Requires theyamlmodule)From the AuthorThe interactive Python shell is a great tool for learning Python,
because Python has such great introspection. The only things that bugged
me about it are 1) I am always needing to set it up a certain way every
time I use it, B) and that it doesn’t have tab completion on by default.pyplaytakes care of these issues nicely.pyplayis my first (but definitely not last) Python module. I hope
you find it useful. Please email me if you have any problems or
suggestions.Kind regards, Ingy dot NetTo DoIn a future release, you might see:Logging of shell commandsSave readline history between sessionsMore PyPlay special commands
Package: pyplayground-ralfeus
pyplaygroundModule to create simple games using pygame. Aimed for kids who want learning Python in a fun wayUsageimport pyplayground
class Actor1(pyplayground.Actor):
  # here you override pyplayground.Actor methods you want to use
pyplayground.Game().init((width, height)).run(Actor1())widthandheightare size of game window.runmethod arguments  are the list of instances of the Actor descendants instances.Any comments, proposals, requests are welcome
Package: pyplayht
pyplayhtPython wrapper for PlayHT APIhttps://docs.play.ht/reference/api-getting-startedInstallationpipinstallpyplayhtEnvironmental VariablesGet your keys fromhttps://play.ht/app/api-accessNameValuePLAY_HT_USER_IDaccount user idPLAY_HT_API_KEYaccount secret keySample CodefrompathlibimportPathfrompyplayht.classesimportClient# create new clientclient=Client()# create new conversion jobjob=client.new_conversion_job(text="Hello, World!",voice="en-US-JennyNeural",)# check job statusjob=client.get_coversion_job_status(job.get("transcriptionId"))# download audio from jobdata=client.download_file(job.get('audioUrl'))# do something with audio bytespath=Path("demo.mp3")path.write_bytes(data)Developer InstructionsRun the dev setup scripts insidescriptsdirectory├──scripts
│├──setup-dev.bat# windows│└──setup-dev.sh# linuxInstall thepyplayhtpackage as editablehttps://setuptools.pypa.io/en/latest/userguide/development_mode.htmlpipinstall-e.When making a commit, use the commandcz commitorcz cYou may also use the regulargit commitcommand but make sure to follow theConventional Commitsspecificationhttps://www.conventionalcommits.org/en/v1.0.0/
Package: pyplayingcards
pyplayingcardsRepository for the pyplayingcards module on PyPi.This module allows you to create and modify playing card objects in Python. With only the standard library modules random and functools as dependencies, the pyplayingcards module is an easy-to-use, well documented way of adding playing cards to your code.As this is a simple project, the documentation is within the code itself. Feel free to fork, clone, copy and use any of the code in the module. For more information, see the LICENSE file on the GitHub page.I learnt a lot of good coding practices from this project, and I hope it will help you have an easier time doing whatever card thing you're doing. Enjoy!Installation:pip install pyplayingcardsHow to use, basics:There are three classes in the pyplayingcards module:PlayingCardPlayingCardsDeckAll three of these classes are relatively simple to use.
The PlayingCard class defines a simple class for normal playing cards.The PlayingCards class defines either a randomly generated list of PlayingCard objects or a user-defined list of PlayingCard objects, with various other features.A Deck is inherits from the PlayingCards class, but with the default values of a normal deck of cards and other methods.For an actual understanding of the inner-workings of the pyplayingcards module, it is recommended that you look at the source code on the GitHub page, as it has more documentation than actual code.Happy coding!The GitHub page I keep talking about:https://github.com/DaJodhi/pyplayingcards
Package: pyplayscheduler
pyplayschedulerHandles play schedules with byes - minimizes duplicate partners and opponentsUsagefrom pyplayscheduler import Scheduler

player_names = ['Joe', 'Tom', 'Steve', 'Bill', 'Sharon', 'Jill', 'Betty', 'Birdie', 'Sheila']
s = Scheduler(player_names=player_names, n_courts=2, n_rounds=5)
s.optimize_schedule()
Package: pyplazmix
PyPlazmix - A python wrapper for PlazmixAPIInstallingPython 3.9 or higher is requiredFor windowspipinstallpyplazmixFor Linux/macOSpython3-mpipinstallpyplazmixExamplesClientfrompyplazmiximportApiClientclient=ApiClient("TOKEN HERE")Get useruser=client.get_user(nickname="nickname")# or uuid="uuid" or _id=idprint(user)
Package: pypledge
defpledge(promises:Optional[Iterable[str]]=None,execpromises:Optional[Iterable[str]]=None)->None:...ThrowsOSErrorif the platform does not supportpledge(2)or
if the pledge fails.ExampleThe following will restrict the current process to only thestdioandttypromises, and then attempt to violate that restriction:importpypledgepypledge.pledge(['stdio','tty'])f=open('foo.txt')On OpenBSD 5.9, this will terminate with SIGABRT because therpathpromise was required.On other platforms, this will throw OSError.
Package: pyplelogger
pypleloggerSimple logger written in python mostly for command line interface tools.InstallpipinstallpypleloggerUsageSimple usageThis is the atomic usage. Import this and print it out.frompypleloggerimportLoggerlog=Logger(__name__).build()log.info("hogehoge")INFO2018-11-2623:11:15,109test.py:maininline4:hogehogeThe default log level isINFOand you have to pass unique name for each handler.Change default logger levelYou can change logger level entire the project.importloggingfrompypleloggerimportLoggerLogger.set_default_log_level(logging.WARNING)log=Logger(__name__).build()log.info("hogehoge")#=> Nothing is pritted outAnd once you set teh default log level, it is valid in entire project.The logger levels are defined inlogginglibrary.levelnumberCRITICAL50ERROR40WARNING30INFO20DEBUG10NOTSET0Let's say you have ascript1.pyandscript2.py.If you change defaul log level inscript1.pylike this,importloggingfrompypleloggerimportLoggerLogger.set_default_log_level(logging.WARNING)it is valid inscript2.pytoo.importloggingfrompypleloggerimportLoggerlog=Logger(__name__).build()log.info("hogehoge")#=> Nothing is pritted outChange logger levelThis is similier to changing default log level but this method changes log level for one logger.Futhermore, the method to change default log level is a class method but, this method is a instance method, so it will only effect the instance.importloggingfrompypleloggerimportLoggerlog=Logger(__name__).set_log_level(logging.WARNING).build()log.info("hogehoge")#=> Nothing is pritted outChange default formatYou can change default format of every instance of Logger by this method. Pass string object describing logging format.format='%(levelname)s%(asctime)s%(message)s'Logger.set_default_format(format)log=Logger(__name__).build()log.info("hogehoge")This will print out this logs.INFO2018-11-2818:11:15,109hogehogeChange formatSpecify format in string. The default format is'%(levelname)s %(asctime)s %(module)s.py:%(funcName)s in line %(lineno)d: %(message)s'.frompypleloggerimportLoggerlog_before=Logger(__name__).build()log_after=Logger(__name__+"after").set_format('%(levelname)s%(message)s').build()log_before.info("before")log_after.info("after")Here is the output.INFO2018-11-2623:11:15,109test.py:maininline4:before
INFOafterWith ArgparseThis has good integration withargparse, a library for creating cli tool.Verbose flagThis is just a simple example of the verbose flag.importargparseparser=argparse.ArgumentParser()parser.add_argument('--verbose','-v',action='count')args=parser.parse_args()Now you can get number ofvflags like-v: 1-vvv: 3You can convert to log level by UsingIncrementalLoggerLevelIntEnum Class.# 1 is debug levelcount=1log_level=IncrementalLoggerLevel.convert_logger_level(1)log=Logger().set_log_level(log_level)log.DEBUG("hoge")Then you will see#=> 
DEBUG 2018-11-26 23:11:15,109 test.py:main in line 3: hogeThe default level of logging isINFOin current version.levelnumbercountCRITICAL50-ERROR40-WARNING30-INFO200DEBUG101NOTSET02To contributeWe welcome for your contribution.Fork this projectRunjustto install dependencies.Give us a pull requestMemberKeisukeYamashita: Maintainer and creater
Package: py-plesk-domains
py-plesk-domainsA python script to get some basic data about domains from a server with plesk panel.
Except from the data that plesk's api returns (id, domain, created datetime, type, status), the script also returns the domain's current ip, certificate expiration and issuer.InstallationIt's recommended to use Python 3.7 or newer.pip install git+https://github.com/takisrs/py-plesk-domains.gitDockerAlternatively, you may quick run it through docker...By cloning this repo and using the provided docker-dompose.yml file:ex.docker-compose run --rm py-plesk-domains server-hostname.com -u admin -o ./ -pOr by pulling and running the image that has been uploaded in the docker hub:ex.docker container run -it --rm -v ${PWD}:/app takisrs/py-plesk-domains server-hostname.com -u admin -o ./ -pInstructionspanos@panos-linux:~$ py-plesk-domains -h
usage: py-plesk-domains [-h] -u USERNAME -p [PASSWORD] [-s {name,created,type,status,ip,expiry_date,issuer}] [-f {plain,simple,github,grid,fancy_grid,pipe,orgtbl,jira,presto,pretty,psql,rst,mediawiki,moinmoin,youtrack,html,latex,latex_raw,latex_booktabs,textile}]
                        [-o CSVPATH]
                        host

Returns the domains from a server with plesk panel with some extra info for each domain (current domain's ip address, certificate expiration date, certificate issuer).

positional arguments:
  host                  server hostname or ip address

optional arguments:
  -h, --help            show this help message and exit
  -u USERNAME           Plesk administrator username
  -p [PASSWORD]         Plesk administrator password
  -s {name,created,type,status,ip,expiry_date,issuer}
                        Select a sorting option. Default: created
  -f {plain,simple,github,grid,fancy_grid,pipe,orgtbl,jira,presto,pretty,psql,rst,mediawiki,moinmoin,youtrack,html,latex,latex_raw,latex_booktabs,textile}
                        Select a formatting option for the table. Default: pretty
  -o CSVPATH            Optionally, Provide a path to export the data in a csv fileExample command:py-plesk-domains server-hostname.com -u admin -s expiry_date -f rst -o ~/domains/ -pDemo
Package: pypleski
pypleski 0.0.7 - under developmentPypleski (Pythonic Plesk Interface) is a collection of functions and classes that aim to ease the use of the Plesk XML API. The most important classes being PleskRequestPacket and PleskResponsePacket which are designed to represent the Request and Response Packets defined by Plesk.Bugfixes:Fixed the Filter bug in get and delete related functions
of the database and the customer moduleChanges:Merged PyPleskiApiClient with PleskApiClient.New Documentation is online:https://pypleski.codingcow.deRemoved the Managers entirelyRemoved the 'Meta' classes from all modules.PleskApiClientAdded ModulesWebhostingMailTODOCore Imporvements:Implement Logging in Api Client ClassesClean up Api Client ClassesReview all ModulesImprove the DocsPlanned Modules:resellerreseller_planwebspaceservice_planservice_plan_addonManagers module deprecated.The managers module was removed with version 0.0.5.Use the PleskApiClient Class's request method to retrieve in conjunction with the several plypleski modules functions.We moved away from building ManagerClasses and instead provide a functions based approachthis allows usage like this and makes managers obsoletepython
from pypleski.core import PleskApiClient
from pypleski.datbase import get_database

#create client object
client = PleskApiClient("localhost") 

#add your token or use set_credentials method
client.set_access_token("IamAValidTokenLOL") 

#make your request
datbase_info = client.request(get_database("webspace-name", "domain.name"))

#print out the response
print(database_info)Seehttps://pypleski.codingcow.deto read the docs.
Package: pypletics
# PYPLETICS PACKAGEWe created a package 'pypletics' running on Python in order to use smart functions for people analysis.For now, there is 3 functions:1. introduction(): it just introduces myself2. get_my_network(...): return an array with a plot network created from networkx package, its value and a dataframe with interlocutors and interactions.3. get_structured_df(...): return an array very useful in order to manage copy or multi-addressees for example*get_my_network(...)[0]:*![alt text](Readme_images/gmn_0.png)*get_my_network(...)[1].show():*![alt text](Readme_images/gmn_1.png)*get_my_network(...)[2]:*![alt text](Readme_images/gmn_2.png)*get_structured_df(...):*From:| Sender   | Addressee       || -------- | --------------- || Clément  | Florian-Jean    || Florian  | Jean            || Gaëtan   | Clément-Florian |To:| Sender   | Addressee || -------- | --------- || Clément  | Florian   || Clément  | Jean      || Florian  | Jean      || Gaëtan   | Clément   || Gaëtan   | Florian   |## ABOUT ME```pythondef introduce_myself():print(df.head(1))introduce_myself()```| Name                | Company           | Job             || ------------------- | ----------------- | --------------- || Clément Tailleur    | Octo Technology   | Data scientist  |
Package: py-plex-api
plex-apiAPI wrapper for interacting with a Plex ServerFree software: MIT licenseDocumentation:https://py-plex-api.readthedocs.io.FeaturesTODOCreditsThis package was created withCookiecutterand theaudreyr/cookiecutter-pypackageproject template.History0.1.0 (2021-06-27)First release on PyPI.
Package: pyplif-hippos
PyPLIF HIPPOS: A Molecular Interaction Fingerprinting Tool for Docking Results of AutoDock Vina and PLANTSIcons made byFreepikfromFlaticonis licensed by CC 3.0 BYWelcome to PyPLIF-HIPPOS's project page. PyPLIF-HIPPOS is an upgraded version ofPyPLIF(Python-based Protein-Ligand Interaction Fingerprinting), a tool for molecular docking post-analysis. It will translate the 3D coordinates of both ligand(s) (generated from docking simulation) and protein into a series ofinteraction bitstring(also known asInteraction Fingerprint) (see image below).HIPPOS(/ˌhipoʊz/) is a recursive acronym ofHIPPOS Is PyPLIF On Steroids. From this point forward, PyPLIF-HIPPOS is simplified to HIPPOS.Compared to PyPLIF, HIPPOS is not only faster and able to generate more customized interaction bitstring, but also supports bothPLANTS&Vina! More over, unlike its predecessor it is (far) more well-documented.Reprinted with permission from https://doi.org/10.1021/acs.jcim.0c00305. Copyright 2020 American Chemical Society.Illustration by Radifar et al (2013) fromBioinformation.netis licensed byCC 4.0 BYCiting HIPPOSIf you are using HIPPOS please cite this paper:Istyastono, E., Radifar, M., Yuniarti, N., Prasasty, V. and Mungkasi, S., 2020.
PyPLIF HIPPOS: A Molecular Interaction Fingerprinting Tool for Docking Results
of AutoDock Vina and PLANTS. Journal of Chemical Information and Modeling.https://doi.org/10.1021/acs.jcim.0c00305AcknowledgmentThis project has received funding from theIndonesian National Research and Innovation Agencyunder grant agreement No. 807.7/LL5/PG/2020. This project has been restructured based on theMOLSSI Computational Molecular Science Python Cookiecutterversion 1.3, and benefited greatly fromMOLSSI Python Package Development Best Practicesworkshop.© Copyright 2020, Muhammad Radifar & Enade Perdana Istyastono