Saravanan666/pypi-org huggingface dataset:
Package: greece-utils
greece-utilsA set of common but yet useful generic toolsExamples:Convert SQL database table to CSV fileImplement recursive mapping of all foreign key tables (join of all related tables)>>> from utils.toolset import SqlCsv
>>> my_object = SqlCsv(engine, session)
>>> my_object.to_csv("my_table_name", "path/to/file.csv", map_foreign_key_tables=True)Find files in directoryfrom utils.sys import find_fileLook for file extension in current directory>>> find_file(".py")Look for file name(s) in specific directory>>> find_file("filename", "/path/to/valid/directory")Look for multiple file names/extension in current directory>>> list(set([item for item in find_file(ext) for ext in ["filename", ".py"]]))LogPrint standard output error to log file>>> from utils.sys import StreamToLogger
>>> import logging
>>> log = StreamToLogger(logging.getLogger('STDERR'), name=log_name, log_level=logging.ERROR)
>>> sys.stderr = log
Package: greedy
greedyIntroductionGreedy (topological) coloring for GeoPandasgreedyis a Python package which brings topological (greedy) coloring toGeoPandas.
It offers several coloring strategies, all accessible using one line of code:gdf['colors']=greedy(gdf)DocumentationDocumentation ofgreedyis available atmartinfleis.github.io/greedy.InstallYou can installmomepyusing Conda fromconda-forge(recommended):conda install -c conda-forge greedyor from PyPI usingpip:pip install greedySee theinstallation instructionsfor detailed instructions.Copyright (c) 2017 - 2019 Martin Fleischmann, Nyall Dawson
Package: greedybfs
GreedyBFSPython Package for Implementation of Greedy BFS algorithmFree software: MIT licenseFeaturesTODOCreditsThis package was created withCookiecutterand theaudreyr/cookiecutter-pypackageproject template.History0.1.4 (2019-08-21)Fixed a bug in Graph intialization.0.1.3 (2019-08-17)Added couple of attributes and properties0.1.0 (2019-07-28)First release on PyPI.
Package: greek
Mathematical Greek for PythonWhy writepiwhen you could writeπ?This package provides - and monkey patches - Greek aliases for builtins and
standard library functions.UsageEither import the Greek aliases from thegreekmodule:fromgreekimportπOr justimport greekfirst and use the aliases from the standard library:importgreekfrommathimportπBut what if the taste of importing an English name likegreekdoesn't sit
right with you? We got you:importελληνικάfrommathimportτfromελληνικάimportΠList of aliasesOriginalGreeksumΣsum𝚺intℤcomplexℂmath.piπmath.pi𝜋math.tauτmath.tau𝜏math.e𝑒math.prodΠmath.gammaΓstatistics.stdevσ
Package: greek-alphabet
Greek AlphabetA Python module for working with the Greek alphabet.UsageImporting the modulefromgreek_alphabetimportAlphabetGetting a list of all Greek alphabet charactersalphabet_list=Alphabet.get_list()Getting a dictionary of all Greek alphabet charactersalphabet_dict=greek_alphabet.Alphabet.get_dict()Theget_dict()method takes two optional parameters:key: a function that takes anAlphabetCharobject and returns a string to use as the dictionary key. By default, the Greek name of the character is used.value: a function that takes anAlphabetCharobject and returns the value to use in the dictionary. By default, theAlphabetCharobject is used.Converting between upper and lower case# Convert a lower case letter to upper caseupper_case_char=greek_alphabet.Alphabet.upper('a')# Convert an upper case letter to lower caselower_case_char=greek_alphabet.Alphabet.lower('Γ')AlphabetChar classTheAlphabetCharclass represents a single character of the Greek alphabet. It has the following attributes:char: the character itselfcapitalized: the capitalized version of the charactername: the name of the character in Greeklower: the lower case equivalent of the characterLicenseThis module is released under the MIT License. See LICENSE for more information.
Package: greek-language-tools
Greek Language ToolsGreek Language Tools is a set of tools that will help you make easy transformations to Greek words.Installationpip install greek-language-toolsUsageImport as any other module using the namegreekltfrom greeklt import *capitalize(word)Makes a word all caps without accentuation but adds dieresis when necessary:word = "γάιδαρος"
>>> word.upper()
ΓΆΙΔΑΡΟΣ

>>> capitalize(word)
ΓΑΪΔΑΡΟΣremove_accentuation(word)Removes accentuation but adds dieresis when necessary, without capitalizing:word = "γάιδαρος"

>>> remove_accentuation(word)
γαϊδαροςWorks exceptionally well when you want to sort a list aphabetically and not based on unicode:cities = ["Όσλο", "Λευκωσία", "Άκαμπα", "Ζυρίχη", "Ρώμη"]

>>> sorted(cities)
["Άκαμπα", "Όσλο", "Ζυρίχη", "Λευκωσία", "Ρώμη"]

>>> sorted(cities, key=remove_accentuation)
["Άκαμπα", "Ζυρίχη", "Λευκωσία", "Όσλο", "Ρώμη"]convert_final_s(word)Checks last letter of each word in a string. If it is aσit is converted into aς(finalσ):>>> convert_final_s("Φάροσ φάρος ΦΑΡΟΣ")
Φάρος φάρος ΦΑΡΟΣgreek_transliteration(word)Transliterates a string written with latin characters into it's equivalent Greek (based on the keys of a QWERTY keyboard):>>> greek_transliteration("fvtia")
φωτιαThis can come quite in handy when a user forgets to change the language and the word looks the same both in latin and Greek:# ANNA written in latin (Anna)
name = "ANNA"

>>> name == greek_transliteration(name)
False

# Both look the same but are different unnicode characters
>>> ANNA == ΑΝΝΑ
FalseThere's also the abillity to convert a word from latin to it's intended accentuated once in Greek:>>> greek_transliteration("P;ita soybl;aki")
Πίτα σουβλάκι

>>> greek_transliteration("kaWiki")
καΐκι

>>> greek_transliteration("pro:yp;ouesh")
προϋπόθεση

>>> greek_transliteration("GA:IDAROS")
ΓΑΪΔΑΡΟΣNote: The function takes as given that the user intended to write the work in Greek using the correct key sequence but just didn't switch their keyboard to Greek. It doesn't convert from Greeklish!# Wrong key sequence by user.
# They're supposed to press SHIFT + W and not just w for the ΅ character to appear.
>>> greek_transliteration("kawiki")
καςικι
Package: greek-normalisation
greek-normalisationutilities for validating and normalising Ancient Greek textFor more of my work on Ancient Greek, seehttp://jktauber.com/.Installationpip install greek-normalisationDocumentation / TestsSeetests.rstfor usage examples.Also, three command-line utilitiesto2019,toNFCandtoNFDare installed which can be used to convert U+02BC and U+1FBF to U+2019 and do unicode normalisation on files (e.g.toNFC source.txt > nfc_version.txt).
Package: greeks
# greeks
derivatives[![Build Status](https://travis-ci.org/timkpaine/greeks.svg?branch=master)](https://travis-ci.org/timkpaine/greeks)
[![GitHub issues](https://img.shields.io/github/issues/timkpaine/greeks.svg)]()
[![codecov](https://codecov.io/gh/timkpaine/greeks/branch/master/graph/badge.svg)](https://codecov.io/gh/timkpaine/greeks)
[![BCH compliance](https://bettercodehub.com/edge/badge/timkpaine/greeks?branch=master)](https://bettercodehub.com/)
[![PyPI](https://img.shields.io/pypi/l/greeks.svg)](https://pypi.python.org/pypi/greeks)
[![PyPI](https://img.shields.io/pypi/v/greeks.svg)](https://pypi.python.org/pypi/greeks)
[![Docs](https://img.shields.io/readthedocs/greeks.svg)](https://greeks.readthedocs.io)
Package: greek-stemmer
This is a Python implementation of Skroutz’s Ruby Greek stemmer.UsageTo use simply do:>>> from greek_stemmer import GreekStemmer
>>> stemmer = GreekStemmer()
>>> stemmer.stem('ΘΑΛΑΣΣΑ')InstallationTo install using pip issue the following command:pipinstallgreek-stemmerTestingIn order to run the tests, you should firstly install all the necessary
dependencies:pipinstall-rrequirements.txtTests can be run using the following command:python-mpytesttests/
Package: greek-stemmer-plus
Greek StemmerThis is a Python implementation of Skroutz's Ruby Greek stemmer.Maintainer's NoteThis fork is an attempt to help maintain the repository due to its original author's inactivity. All credit for the original work remains with Andreas Loupasakis.CreditsThis project was originally developed by Andreas Loupasakis. All credits for the initial work go to him.Original repository:@alup/python_greek_stemmerAuthor's Github:@alupUsagefromgreek_stemmerimportGreekStemmerstemmer=GreekStemmer()stemmer.stem('ΘΑΛΑΣΣΑ')InstallationTo install using pip:pipinstallgreek-stemmer-plusLocal DevelopmentSetting up the local environmentClone the repository.Install Poetry:curl -sSL https://install.python-poetry.org | python -Install project dependencies using Poetry:poetry installRunning testspoetryrunpytesttests/Proposing ChangesFork the repository.Create a new branch for your changes.Make your changes and commit them usingAngular commit message conventions.Submit a pull request to the main repository.
Package: green
Green is a clean, colorful, fast python test runner.DocumentationFor full documentation please visit theGithub page for Green, or subscribe
toPython Testing with Greenon Udemy.  You can find discounts for the Udemy
course in the documentation on Github.FeaturesClean- Low redundancy in output. Result statistics for each test is vertically aligned.Colorful- Terminal output makes good use of color when the terminal supports it.Fast- Tests run in independent processes.  (One per processor by default.  Does not play nicely with gevent.)Powerful- Multi-target + auto-discovery.Traditional- Use the normalunittestclasses and methods for your unit tests.Descriptive- Multiple verbosity levels, from just dots to full docstring output.Convenient- Bash-completion and ZSH-completion of options and test targets.Thorough- Built-in integration withcoverageModern- Supports Python 3.8+.  Additionally,PyPyis supported on a best-effort basis.Portable- macOS, Linux, and BSDs are fully supported.  Windows is supported on a best-effort basis.Living- This project grows and changes.  See thechangelog
Package: green-agent
Green AgentLibrary providing uniform (mostly) abstration across foundation-models APIs + nice "interface" helpers for running experiments or crafting your own ChatGPT-style UI.For now it supports chat-tuned LLMs from OpenAI and Google (Vertex AI) - more stuff to come.UsageInside a jupyter notebook:importgreen_agentasgaag1=ga.AgentNbUI(ga.OpenAIAgent("You are a sarcastic but helpful assistant.",model="gpt-3.5-turbo"))ag1.asks("Which foods would you suggest trying when visiting Lyon, France?")How to developFirst time:poetryinstall--withtestdev
poetryshell
python-mipykernelinstall--user--namegreen-agentIn general:poetryshellNotebooks:jupyternotebook# classic UIjupyterlab# modern UIManaging dependencies with Poetrypoetry add <my-dependency>
poetry add <my-dependency> --group dev
poetry add <my-dependency> --group testpoetry export -o all-requirements.txt
Package: greenapple
#create a studentimport greenapplegco=greenapple.model.ConnectOperations()gco.con.dbengine="MySQL"gco.con.database="eshule"gco.con.username="root"gco.con.password="root"student={"first_name":"'Alexandria'","last_name":"'Nandyose'","table":"student","clause":"where id = 4"}student["last_name"]="'Marvin Stevens'"gco.insert(student)dataset=gco.select_dataset({"table":"student","clause":"where id=8"})for record in dataset:print recordPostgresql Exampleimport greenapplegco=greenapple.model.ConnectOperations()gco.con.dbengine="PSQL"gco.con.database="eshule"gco.con.username="root"gco.con.password="root"student={"first_name":"'Emmaculate'","last_name":"'Akongo'","table":"student"}gco.insert(student)student["last_name"]="'Opata'"student["clause"]="where id =1";gco.update(student)dataset=gco.select_dataset({"table":"student"})for record in dataset:print record
Package: greenbalance
greenbalancegreenbalance is a simple TCP load balancer with round-robin and weighted random support built ongeventandwr.UsageSimple example; this will make the load balancer listen on port 8080 and use a custom configuration.$ greenbalance --port 8080 --config /path/to/my.configArgumentsArguments accepted by thegreenbalancecommand.--versionShow program’s version number and exit.-h,--helpShow this help message and exit.-H,--hostIP or Hostname.-p,--portListening Port.-c,--configConfiguration file.-l,--logfileLog File-L,--loglevelLog Level (debug, info, warning, error, critical)greenbalance.confgreenbalance.confis by default placed in/etcif the package was intalled with root privileges. If you have the package installed in a virtualenv you will have to create a configuration file manually and pass it with the--configor-cargument.[settings]
host = 0.0.0.0           # Bind to this (0.0.0.0 = all)
port = 3001              # Listening port.

[logging]
loglevel = debug
logfile = /var/log/greenbalance.log

[nodes]
backend1 3101 = 20       # will serve 20% of the requests.
192.168.100.7 3102 = 40  # will serve 40% of the requests.
localhost 3103 = 40      # will serve 40% of the requests.InstallationSee below for OS-specific preparations.Installgreenbalancewith:sudo pip install greenbalanceUbuntusudo apt-get install python-pip python-gevent; sudo pip install --upgrade pipCentOSInstallpython-pipandpython-geventfromepel.DocumentationDocumentation is available atreadthedocs.orgLicenseGPL
Package: greenberry
greenBerryA one-line statement programming language, complete with classes, cli and file compatiblepython -m pip install greenberry
greenberry file.gbcontributing countries🇲🇺 🇲🇾 🇸🇮 🇰🇪 🇺🇸 🇮🇳🇨🇦 🇧🇳🔗 linkswebsitelang referencewe have a Discord channel!- Join for questions!📖 contributing guidelinesReadgreenberry/theory_notes_simple.pypython -m pip install -e .
python -m pip install -r reqs/dev.txt
pre-commit install🌄 contribution areassyntax : propose new syntax or suggest improvements for existing onelanguage : in the way python code is written so as to be more clear, efficient for examplegui : either ide or others, add new functionalities or improve UXcli : improve cli experience, add new featurescompiling engine : improve parser, add new areas of usage (of greenBerry, like on arduino? an electronics library?). also add support for approved new syntaxwebsite : improve website, update changelog (or implement changes to do this automatically)🍂 python version3.4 (moving to 3.7 if you PR a change using a 3.7 feature)🏢 structure notesengine :greenberry/greenBerry.pywebsite :docs/🌊 run filesReadhereor follow belowREPL 🔧Just runpython gb_repl.py.gb file 📁Write inmain.gband then save and runpython gb_main.pyIDE 🖥️Runpython gb_ide.pywrite and run or load a.gbfile !📋 TODORefining printAdd more support for evalAdd parameters to functions and classesAllow non-static referencing of function and classesNew syntax and implementationExpand use📧 quick contactAbdur-Rahmaanj:arj.python@gmail.comTimThuma:thumatim@gmail.comcredits@arwinneilfor opensource and madeinmoris badges
Package: greenbook-shocks
GreenbookNarrativeShocksThis package estimates up to date Romer and Romer Greenbook Narrative shocks, originally fromA New Measure of Monetary Shocks: Derivation and Implications, 2004.Installationpip install greenbookshocksUsageThe core class is theRRGB(Romer and Romer GreenBook) class. When this class is instantiated it
downloads the data necessary to create the Romer and Romer Greenbook narrative shock series.
The user needs to supply the original data appendix file fromRomer and Romer, (2004)
with the path specified by therrfnameargument in the class call, which defaults
torrfname='RomerandRomerDataAppendix.xls'. The user then needs to call theestimate_shocks()method.
The following code exactly replicates the original shock series.fromrrgbimportRRGBfromdatetimeimportdatetime# Assemble Datarrgb=RRGB(rrfname='RomerandRomerDataAppendix.xls',rr_override=True)# Estimate shocksshocks=rrgb.estimate_shocks()The final shock series will be indexed by the meeting date. The user may then aggregate the
series up with her preferred aggregation method.Advanced UsageThe original dataset used inRomer and Romer, (2004)
was drawn from the text of the Greenbook itself. This package supplements this data with the Greenbook datasets
provided by the Federal Reserve Bank of Philadelphia which is drawn from internal forecast materials prepared by
the Federal Reserve Board of Governors staff. This dataset varies slightly from the Romer and Romer dataset. For
earlier periods, the Romer and Romer dataset contains a few additional forecast observations which this package
always uses. In 1972, the Philadelphia Fed dataset has additional observations. By default this package does not
use these observations, allowing it to exactly match the original Romer and Romer dataset. If the user would like
to use the full dataset then she may specify therr_overrideargument asFalse, e.g.RRGB(rr_override=False),
the default behavior is True.Custom modelsTheestimate_shocks()method allows the user to specify the date range of the shocks, the control variables
used in the regression, wether or not to drop ZLB periods in estimation and the model to use to form the predicted
shocks. See the docstring for additional information.
Package: green-box
Green BoxПростой модуль для получения информации из Google Таблиц.УстановкаGitHubpip install git+https://github.com/QuoNaro/green-box.gitPyPipip install green-boxИспользованиеИз всей ссылки берется только ID!fromgreen_boximportTabletable=Table('1O174ca048KT5YMYkDADzQvzIJEWUMADj_0ciLAQOt34','Лист1').rows()['Фамилия', 'Имя', 'Отчество', 'Адрес']
['Сидорова', 'Елена', 'Евгеньевна', 'пр. Победы, 10']
['Петров', 'Иван', 'Александрович', 'ул. Солнечная, 5']
['Васильева', 'Ирина', 'Александровна', 'ул. Парковая, 3']
['Суворова', 'Елена', 'Ивановна', 'ул. Центральная, 1']
['Смирнова', 'Екатерина', 'Дмитриевна', 'ул. Солнечная, 5']
['Смирнов', 'Петр', 'Алексеевич', 'пр. Ленина, 20']
['Петров', 'Петр', 'Петрович', 'пр. Ленина, 20']
['Васильева', 'Мария', 'Артемьева', 'ул. Парковая, 3']
['Сидорова', 'Анна', 'Евгеньевна', 'пр. Победы, 10']Зависимостиopenpyxlnumpyrequests
Package: greencard
DocumentationThe full documentation is athttp://greencard.rtfd.org.QuickstartInstall greencard:pip install greencardThen you can use thegreencardcommand line test runner to descover and run
card tests defined as all.pyfiles in the test directory from where the
runner is executed. For more information see the usage documentation page.FeaturesA custom testing framework and test runner designed specifically for cards.History0.2.4Versions increasing rapidlyDecorator based test for each card and single library tests0.1.0First release on PyPI.
Package: greenclock
GreenClock is a time-based task scheduler using geventWith GreenClock, you can: Schedule a task to run every X seconds, daily,
weekly, monthly, or at certain times (such as application startup).GreenClock launches agreen
threadper task.
Therefore every task will be executed in a concurrent manner, without
blocking each other.StatusThis module is currently under development.Features- A simple to use API for scheduling jobs.
- Lightweight (depending on gevent only)
- Works with Python 2.7+
- Support the following scheduling scenarios:
    + run every X seconds
    + run every hour at specified minute and second
    + run at specified time (hour:minute:second) every day
    + more to comeInstallationThis library depends on gevent 1.5$pipinstallcython-egit://github.com/surfly/gevent.git@1.0rc2#egg=geventTo install GreenClock frompip:$pipinstallgreenclockYou can also install it into your Python application directory$pipinstall--install-option="--prefix=/path/to/python/app"greenclockTo install GreenClock from source:$gitclonegit@github.com:pcdinh/greenclock.git$pythonsetup.pyinstallUsagefrom greenclock.utils import Scheduler
from datetime import datetime
import time

def func_1():
    print('Calling func_1() at ' + str(datetime.now()))
    time.sleep(2)
    print('Ended call to func_1() at ' + str(datetime.now()))

def func_2():
    print('Calling func_2() at ' + str(datetime.now()))
    time.sleep(2)
    print('Ended call to func_2() at ' + str(datetime.now()))

if __name__ == "__main__":
    scheduler = Scheduler(logger_name='task_scheduler')
    scheduler.schedule('task_1', greenclock.every_second(4), func_1)
    scheduler.schedule('task_2', greenclock.every_second(1), func_2)
    # Run hourly task at 41:00 every day
    scheduler.schedule('task_3', greenclock.every_hour(minute=41, second=0), func_3)
    # Run daily task at 12:35:00
    scheduler.schedule('task_2', greenclock.every_hour(hour=12, minute=35, second=0), func_2)
    # To start the scheduled tasks immediately, specify 'once' for `start_at`
    # Other values:
    # * `next_minute`: Wait until the first seconds of the next minute to run
    # * `next_hour`: Wait until the first seconds of the next hour to run
    # * `tomorrow`: Wait until the first seconds of tomorrow to run
    scheduler.run_forever(start_at='once')Basically to schedule a periodic task or job, you need to specify the
following parameters:+ Task name: `task_1`
+ A timer that let the scheduler know how to run a periodic task# run the task for every 4 seconds
from greenclock.utils import every_second, every_hour
every_second(4)
# run the task every day at 01:10:00
every_hour(hour=1, minute=10, second=0)+ A function or callable object
+ Optional parameters to the above function or callable objectscheduler.schedule('task_1', greenclock.every_second(1), func_1, param1, param2, named_param=2)Schedulerobject can run a separate process which never exits if you
want it toscheduler.run_forever(start_at='once')
Package: greendeck-redis
greendeck-redisCreated for internalGreendeckuse only. Can be used for non-commercial purposes.A simple Redis library to create Redis sets and Redis queues and perform basic operations on them.Install from piphttps://pypi.org/project/greendeck-redis/pip install greendeck-redisHow to use ?import the libraryimportgreendeck_redisor, importredisclassesfromgreendeck_redisimportRedisQueuefromgreendeck_redisimportRedisSetfromgreendeck_redisimportRedis# This will be used for operations that require two or more redis keys (Set or Queue)initializeredisclient connection as per your requirements# declare variablesREDIS_HOST=<YOUR_REDIS_HOST>REDIS_PORT=<YOUR_REDIS_PORT>REDIS_PASSWORD=<YOUR_REDIS_PASSWORD># Here default values are REDIS_PORT='', REDIS_HOST='', REDIS_PASSWORD=Noneredis_queue=RedisQueue(REDIS_HOST,REDIS_PORT,queue_name,password=REDIS_PASSWORD)# OR/ANDredis_set=RedisSet(REDIS_HOST,REDIS_PORT,set_name,password=REDIS_PASSWORD)# OR/ANDredis_client=Redis(REDIS_HOST,REDIS_PORT,password=REDIS_PASSWORD)# This will be used for operations that require two or more redis keys (Set or Queue)usingredis setredis_set.smembers()# will return all the member strings of the RedisSet ```redis_set``` in a python list.redis_set.scard()# will return the count of members of the RedisSet ```redis_set``` as an integer.redis_set.put(item)# will insert ```item``` string in the RedisSet ```redis_set``` if not already present. RedisSet doesn't allow dupicate values.usingredisfor finding difference of two redis setsredis_client.sdiffstore(target_set_name,operand1_set_name,operand2_set_name)# this creates a new RedisSet with the name ```target_set_name``` and contains the difference of ```operand1_set_name``` and ```operand2_set_name```.usingredis queueredis_queue.qsize()# will return the count of members of the RedisQueue ```redis_queue``` as an integer.redis_queue.put(item)# will insert ```item``` string in the RedisQueue ```redis_queue``` even if it is already present. RedisQueue allows duplicate values.redis_queue.empty()# will clear all the member strings of the RedisQueue ```redis_queue``` in a python list.redis_queue.get()# will return the first member string (single) of the RedisQueue ```redis_queue``` as a string.redis_queue.get_multi(n)# will return the first ```n``` member strings (count: n) of the RedisQueue ```redis_queue``` as a python list. if the count of members in the RedisQueue is less than ```n```; it will return all the members as a python list.redis_queue.get_nowait()# will return all members of the RedisQueue ```redis_queue``` as a python list.How to build your pip packageopen an account herehttps://pypi.org/In the parent directorypython setup.py sdist bdist_wheeltwine upload dist/*referenceshttps://medium.com/small-things-about-python/lets-talk-about-python-packaging-6d84b81f1bb5Thank You