Saravanan666/pypi-org huggingface dataset:
Package: pri3o-dmenu-desktop
pri3o-dmenu-desktopDescriptionpri3o-dmenu-desktopis a drop-in replacement forMichael Stapelberg'si3-dmenu-desktopthat adds simple application priorization.
It supports all options present ini3-dmenu-desktopand a few more.At this point priority is simply the absolute number times the program was run.
For example a program ran three times has a higher priority than a program only
run twice. It's very simple but pretty effective. In the future I might add a
time-based component as well.The priority data is stored in a sqlite database in$XDG_CONFIG_HOME/pri3o-dmenu-desktop/dmenu.db(defaults to~/.config/pri3o-dmenu-desktop/dmenu.db)
but a custom location can be specified via command line parameter. A new db will be
create if it does not exist yet.RequirementsTo run this you need Python 3, all used libraries should be present in the
standard distribution. Python 3 should already be present in any modern,
non-minimal distribution. For older/LTS distributions (e.g. CentOS 7) you may
need to install it.For RedHat based distros this can be done via:yum install python3For Debian based distros use:apt install python3InstallingThe easiest way to install is usingpip3:pip3 install pri3o_dmenu_desktopRunningJust run usingpri3o-dmenu-desktop [OPTIONS]If run without parameters, will behave likei3-dmenu-desktopwithout parameters.
The optional commandline parameters are:-d, --database=PATHpath to database file; default$XDG_CONFIG_HOME/pri3o-dmenu-desktop/dmenu.db-e, --entry-type=TYPEdisplay "Name" (TYPE=name), "Exec" (TYPE=command) or .desktop filename (TYPE=filename) in dmenu, defaultname-l, --locale=LOCALEuse LOCALE (e.g.en_GB) for localisation of "Name", default is system locale-m, --dmenu=COMMANDrun this command for dmenu, defaultdmenu -i-t, --term=COMMANDuse this command for programs that need to be run in a terminal, defaulti3-sensible-terminal -eSpeedAs some people may wonder about how fast it is:% time pri3o-dmenu-desktop --dmenu=/bin/false
pri3o-dmenu-desktop --dmenu=/bin/false  0,06s user 0,01s system 99% cpu 0,070 total

 % time i3-dmenu-desktop --dmenu=/bin/false
i3-dmenu-desktop --dmenu=/bin/false  0,11s user 0,01s system 99% cpu 0,114 total

 % time j4-dmenu-desktop --dmenu=/bin/false
j4-dmenu-desktop --dmenu=/bin/false  0,00s user 0,00s system 97% cpu 0,006 totalOn my system (SSD-only) it is slightly faster thani3-dmenu-desktop, but still
much slower thanj4-dmenu-desktop.
For all practical purposes these
differences should be negligible unless you have a lot of applications and/or
a slow hard drive.For comparison I ran the tests on an old Lenovo T61 with HDD, where the delay
is definitely noticable. These values are always for the second run (after the.desktopfiles where in RAM). For the first
run you can add around 800ms on top.% time pri3o-dmenu-desktop --dmenu=/bin/false
pri3o-dmenu-desktop --dmenu=/bin/false  0,13s user 0,02s system 99% cpu 0,154 total

 % time i3-dmenu-desktop --dmenu=/bin/false
i3-dmenu-desktop --dmenu=/bin/false  0,35s user 0,02s system 99% cpu 0,376 total

 % time j4-dmenu-desktop --dmenu=/bin/false
j4-dmenu-desktop --dmenu=/bin/false  0,00s user 0,01s system 96% cpu 0,011 total
Package: priaye
Piraye: NLP UtilsA utility for normalizing persian, arabic and english textsRequirementsPython 3.11+nltk 3.4.5+InstallationInstall the latest version with pippip install pirayeUsageCreate an instance of Normalizer with NormalizerBuilder and then call normalize function. Also see list of all available
configs inconfigssection.Using builder pattern:frompirayeimportNormalizerBuilderfrompiraye.tasks.normalizer.normalizer_builderimportConfigtext="این یک متن تسة اسﺘ       , 24/12/1400 "normalizer=NormalizerBuilder().alphabet_fa().digit_fa().punctuation_fa().tokenizing().remove_extra_spaces().build()normalizer.normalize(text)# "این یک متن تست است ، ۲۴/۱۲/۱۴۰۰"Using constructor:frompirayeimportNormalizerBuilderfrompiraye.tasks.normalizer.normalizer_builderimportConfigtext="این یک متن تسة اسﺘ       , 24/12/1400 "normalizer=NormalizerBuilder([Config.PUNCTUATION_FA,Config.ALPHABET_FA,Config.DIGIT_FA],remove_extra_spaces=True,tokenization=True).build()normalizer.normalize(text)# "این یک متن تست است ، ۲۴/۱۲/۱۴۰۰"Also seeother examplesConfigsConfigFunctionDescriptionALPHABET_ARalphabet_armapping alphabet characters to arabicALPHABET_ENalphabet_enmapping alphabet characters to englishALPHABET_FAalphabet_famapping alphabet characters to persianDIGIT_ARdigit_arconvert digits to arabic digitsDIGIT_ENdigit_enconvert digits to english digitsDIGIT_FAdigit_faconvert digits to persian digitsDIACRITIC_DELETEdiacritic_deleteremove all diacriticsSPACE_DELETEspace_deleteremove all spacesSPACE_NORMALspace_normalnormal spaces ( like NO-BREAK SPACE , Tab and etc...)SPACE_KEEPspace_keepmapping spaces and not normal themPUNCTUATION_ARpunctuation_armapping punctuations to arabic punctuationsPUNCTUATION_Fapunctuation_famapping punctuations to persian punctuationsPUNCTUATION_ENpunctuation_enmapping punctuations to english punctuationsOther attributes:remove_extra_spaces : append multiple spaces togethertokenization : replace punctuation characters that just are tokensDevelopmentInstall dependencies withpip install -e .[dev]LicenseGNU Lesser General Public License v2.1Primarily used for software libraries, the GNU LGPL requires that derived works be licensed under the same license, but
works that only link to it do not fall under this restriction. There are two commonly used versions of the GNU LGPL.SeeLICENSEAbout ️Arusha
Package: price-alert-rhsm
Price AlertDescriptionThe purpose of the algorithm is to monitor the price of an asset and when it goes >= or <= to the prices we set,
a pop up appears on the screen.The script works as follows.We get the asset price from the "STOCK" market (Microsoft = MSFT, Tesla=TSLA, Ambev=ABEV) using the yFinance library.We monitor the target until the price we set. We have to enter a price above the current price and a price below the
current price.InstallationUse the package managerpipto install Price_alert.pipinstallprice-alert-rhsmGuidefromprice_alert.price_monitoringimportPriceAlertpa=PriceAlert(asset='TSLA',waiting_time=5)pa.price_alert_request()Output expected:Consult at: 2022-10-07 12:01:09.266432
Ticker TSLA - Current price = $ 228.4
Type a price bigger than 228.4:
Type a price less than 228.4:Example:Note: I ran this test on a Saturday, obviously the market was closed, to run the rule I set an equal price
current price to pop up the message box if the price is equal to or higher/lower than the current price.After entering the values to monitor, just wait for the price movement to hit the target. When this occurs, the
notification will appear in your window.Suggestion to new implementationMonitor multiple assets. Consequently, we need alert for several assets.Option to conversion result to others currency: BRL, EURO, BTC etcImplement options to calculate the price to monitoring as percentual or valueAuthorRafael MeirelesLinkedInLicenseMIT
Package: pricedisplay
pricedisplayTerminal Display for the Finnish Power PriceBuildingYou can install the dependencies and build the package with Poetry:poetry installpoetry buildYou can test the build with:poetry run python -m pricedisplayInstallingInstall the package from PyPI:python -m pip install pricedisplayCurrently you need Python 3.9 or greater.NOTE:On macOS you may get a warning from urllib3. The default installation of Python includes OpenSSL version compiled with LibreSSL, which is no longer supported. You can fix this by installing Python with Homebrew. For details seethis issue.UsageRun the display with the command:python -m pricedisplayThe package creates a settings file config.yml in your config path.OSSettings LocationmacOS~/Library/Application Support/pricedisplay/GNU/Linux~/.config/pricedisplay/Windows%APPDATA%\pricedisplay\You can also pass your own settings file as an argument:python -m pricedisplay --settings PATHNotesThe actual display of the graph depends on your terminal font and colors. For best results you should have UTF-8 encoding and a font which includes unicode East Asian ambiguous characters (in wide format). Some tested combinations are:OSTerminalFontmacOSiTerm with BashHackGNU/LinuxGnome with BashUbuntu MonoWindowsMintty with BashLucida ConsoleSample outputs
Package: pricegen
pricegenThis utility helps simulate statistically randomized series of prices, based on the models below:Geometric Brownian motionMean reversion (optional)Generating a next pricefrom pricegen import random_price

current_price = 100
next_price = random_price(current_price, sigma=0.20)Generating a series of pricesfrom pricegen import random_price, generate_prices

initial_price = 100

# Daily prices over a year (252 trading days)
price = initial_price
for _ in range(252):
    price = random_price(price, sigma=0.20, time=1.0/252)
    print(price)

# Or equivalently:
for price in generate_prices(252, initial_price, sigma=0.20, time=1.0/252):
    print(price)Volatility and time interval# These two calls are roughly equivalent

# Case 1:
random_price(price, sigma=0.20, time=1.0/252)
# Annual volatility: 20%
# Time interval: (1.0 / 252) year

# Case 2:
random_price(price, sigma=0.20/math.sqrt(252)) # time == 1.0 by default
# Daily volatility: 20% / sqrt(252)
# Time interval: 1.0 day

# Note:
# "time" represents the time interval relative to 1.0.
# "sigma" is interpreted as volatility for time == 1.0.
# Internally, there is no assumption about the unit of time (year/month/day).Mean reversionfrom pricegen import random_price

initial_price = 100

# Daily prices over a year (252 trading days)
price = initial_price
for _ in range(252):
    price = random_price(price, sigma=0.20, time=1.0/252, mean=initial_price)
    print(price)

# Mean reversion helps prevent the price from becoming too high or too low
# by attracting the price to a targe while maintaining a specific volatility.Using a custom Random classfrom pricegen import PriceGenerator

generator = PriceGenerator(random=custom_random)
# custom_random needs to have .gauss() method

generator.random_price(100, 0.20)Ad-hoc random noisefrom pricegen import random_price

random_price(100, 0.20, noise=custom_gauss(0.0, 1.0))
Package: pricegenerator
See full documentation with examples:https://github.com/Tim55667757/PriceGenerator/blob/master/README.mdPriceGenerator module documentation:https://tim55667757.github.io/PriceGenerator/docs/pricegenerator/PriceGenerator.htmlПодробная документация на русском с примерами:https://github.com/Tim55667757/PriceGenerator/blob/master/README_RU.mdДокументация на модуль PriceGenerator:https://tim55667757.github.io/PriceGenerator/docs/pricegenerator/PriceGenerator.html
Package: pricegrabber
PriceGrabberThis is a Python package to retrieve prices for specific products from all sorts of websites, such as Amazon, Aliexpress, or price comparison websites.New websites can be supported by means of a simple configuration entry. Currently supported sites include:Geizhals.{de, at}Amazon.{de, com, co.uk, probably all)Idealo.deAliexpress.comUsageUsage is pretty simple. Mostly you should be able to put in an URL to the site of a product you're interested in, and you should get out a price (or a list of prices). Here is an Example for an AliExpress product:>>>frompricegrabberimportGrabber>>>cfg={"url":"https://de.aliexpress.com/store/product/Cherry-cherry-shaft-shaft-mx-mechanical-keyboard-shaft-switch-black-shaft-tea-shaft-white-shaft-green/2230037_32682571027.html?spm=a2g0x.12010612.8148356.2.75987786TNUZUO"}>>>g=Grabber(cfg)>>>g.grab()[(8.9,'$')]So in this case we know that the pack of Cherry MX key switches from AliExpress costs $8,90. Note that a list is returned. Some sites may report multiple prices instead of just one.
Package: priceit
PRICEITAuthor: David WANGVersion 0.1.7To extract realtime or history price data of stocks or crypto currencies.
(Please note this package is based on free API (e.g. Yahoo Finance). There may be a little time lag (seconds or minutes) for some market.)To extract the latest full list of stock tickers in NASDAQ, NYSE and AMEX.To extract the financial statements.Installation:pipinstallpriceitUsage:(1) To get realtime TSLA pricefrompriceitimport*ticker='TSLA'print(getprice(ticker))Result:['TSLA', 1049.61, 'Delayed Quote', '2022-01-14 16:00:04'](Sample above is taken during weekend, when the market is close. So it shows 'Delayed Quote'. Try this when market is open, and you can get realtime quote (almost realtime). Please allow seconds or minutes time lag for certain market.)(2) To get history daily price of BTC-USD from 2022-01-12 to 2022-01-14frompriceitimport*ticker='BTC-USD'startdate='2022-01-12'enddate='2022-01-14'print(histprice(ticker,startdate,enddate))Result:{'currency': 'USD', 'symbol': 'BTC-USD', 'exchangeName': 'CCC', 'data': {'timestamp': ['2022-01-12', '2022-01-13', '2022-01-14'], 'volume': [33499938689, 47691135082, 23577403399], 'high': [44135.3671875, 44278.421875, 43346.6875], 'low': [42528.98828125, 42447.04296875, 41982.6171875], 'close': [43949.1015625, 42591.5703125, 43099.69921875], 'open': [42742.1796875, 43946.7421875, 42598.87109375], 'adjclose': [43949.1015625, 42591.5703125, 43099.69921875]}}(3) To get full list of stock ticker in NASDAQ, NYSE and AMEXfrompriceitimport*exchange='NASDAQ'print(tickerlist(exchange))Result:{'symbol': ['AAPL', 'MSFT',...], 'name': ['Apple Inc. Common Stock', 'Microsoft Corporation Common Stock',...]}(4) To get financial statementsfrompriceitimport*p=priceit()p.ticker='AAPL'print(p.statements('Q'))# 'Q' for quarter report; 'A' for annual reportResult:{'income_statement': {},'balance_sheet': {}, 'cash_flow':{}}Notes:This project is being built up. More functions will be added.If to get realtime price, please limit your frequency of data extraction.After getting the full list of stock tickers, you can save it in your local disk so as to save the network resources.About the AuthorI am currently in Grade 11 (as of 1st half of 2022). I have great interests in AI trading and real world simulation with C++, Java and Python. I am summarizing my free data sources in this project. And hopefully this can save some of your time in data extraction.
Package: pricelist-parser
Pricelist parserБиблиотека для разбора прайслистов и списков заказов в форматах CSV, XLS и XLSXВозможности:Умеет разбирать и вычленять информацию из прайслистов на русском языке.Автоматически определяет структуру прайслиста – где находится строка с названием колонок, где начинаются данные и где они заканчиваются. Не нужно задавать эти параметры вручнуюВалидирует данные и оставляет только те, которые больше всего похожи на данные из прайслиста. Не нужно волноваться, если менеджер магазина где-то нечаянно добавил лишнюю строку или переусердствовал с форматированием.Использованиеfrom pricelist_parser import parse_pricelist


parsed_data = parse_pricelist('path/to/pricelist.csv')В ответ вернется массив объектов типа с извленными данными. Каждый объект – один товар из прайслиста или списка заказов. На данный момент объекты содержат поля:sku– артикул товара (string)price– цена товара (float)
Package: priceloop-api
priceloop-api-pythonA client library for accessing Priceloop APIInstallpip install priceloop-apiUsageFirst, create aPriceloopClient:frompriceloop_api.priceloop.authimportPriceloopClientclient=PriceloopClient.with_credentials("username","password")read and write to nocode:importpandasaspdfrompriceloop_api.priceloop.dataimportto_nocode,read_nocode# write to nocodedata=[["Alex",10],["Bob",12],["Clarke",13]]df=pd.DataFrame(data,columns=["Name","Age"])to_nocode(df,"table_name",client)# read from nocodenew_df=read_nocode("table_name",client,limit=limit,offset=offset)call your endpoint, example:frompriceloop_api.api.workspace_apiimportlist_workspaces,get_workspaceworkspaces=list_workspaces.sync(client=client)workspace=get_workspace.sync(workspaces[0],client=client)add columns to existing table:frompriceloop_api.api.column_apiimportadd_data_column,add_formula_columnfrompriceloop_api.modelsimportAddDataColumnTypeadd_data_column.sync(workspace.name,"table_name","column_name",type=AddDataColumnType.STRING,client=client)add_formula_column.sync(workspace.name,"table_name","column_name","expression",client=client)Things to know:Every path/method combo becomes has four functions:sync: Blocking request that returns parsed data (if successful) orNonesync_detailed: Blocking request that always returns aRequest, optionally withparsedset if the request was successful.asyncio: Likesyncbut async instead of blockingasyncio_detailed: Likesync_detailedbut async instead of blockingAll path/query params, and bodies become method arguments.If your endpoint had any tags on it, the first tag will be used as a module name for the function (my_tag above)Any endpoint which did not have a tag will be inpriceloop_api.api.default
Package: priceloop-api-dev1
priceloop-api-pythonA client library for accessing Priceloop APIInstallpip install priceloop-apiUsageFirst, create aPriceloopClient:frompriceloop_api.priceloop.authimportPriceloopClientclient=PriceloopClient.with_credentials("username","password")read and write to nocode:importpandasaspdfrompriceloop_api.priceloop.dataimportto_nocode,read_nocode# write to nocodedata=[["Alex",10],["Bob",12],["Clarke",13]]df=pd.DataFrame(data,columns=["Name","Age"])to_nocode(df,"table_name",client)# read from nocodenew_df=read_nocode("table_name",client,limit=limit,offset=offset)call your endpoint, example:frompriceloop_api.api.workspace_apiimportlist_workspaces,get_workspaceworkspaces=list_workspaces.sync(client=client)workspace=get_workspace.sync(workspaces[0],client=client)add columns to existing table:frompriceloop_api.api.column_apiimportadd_data_column,add_formula_columnfrompriceloop_api.modelsimportAddDataColumnTypeadd_data_column.sync(workspace.name,"table_name","column_name",type=AddDataColumnType.STRING,client=client)add_formula_column.sync(workspace.name,"table_name","column_name","expression",client=client)Things to know:Every path/method combo becomes has four functions:sync: Blocking request that returns parsed data (if successful) orNonesync_detailed: Blocking request that always returns aRequest, optionally withparsedset if the request was successful.asyncio: Likesyncbut async instead of blockingasyncio_detailed: Likesync_detailedbut async instead of blockingAll path/query params, and bodies become method arguments.If your endpoint had any tags on it, the first tag will be used as a module name for the function (my_tag above)Any endpoint which did not have a tag will be inpriceloop_api.api.default
Package: price-onixcoin
Onix prices.__________Es una aplicación django python que calcular el precio de venta y compra de onix en bolivares y dolares. La aplicación esta dirigidapara el país de venzuela, sin embargo puede ser adaptada para otros paises.Librerias._________django==2.1python3.6Inicio rápido______________1. Agrega la aplicación al INSTALL_APPS de tú proyecto django::INSTALLED_APPS = [...'price_onixcoin',]2. Ejecutas `python manage.py makemigrations price_onixcoin`3. Ejecutas `python maanage.py migrate`Instalar la aplicación______________________pip install price-onixcoinPosteriormente podrá crear unos crontad que ejecuete los siguientes comandos dentro de tu proyecto djangopython3 manage.py price_btc_localbitcoin (cada 20 min)python3 manage.py yobit_onix (cada 1 min)python3 manage.py price_onix (cada 1 min)
Package: price-process
Price process generatorA synthetic data sourceThis library provides various vectorized generators of stochastic processes modelling price dynamics.
The generated synthetic price data can be used in Monte Carlo simulations (or similar statistical experiments) and
potentially as training data.Currently the implemented generators:Geometric Wiener motionGeometric Lévy flightsIsingPlanned features:Generative adversarial network (GAN) implementationImproved interface withising.pyInstallationpip install price_processto get the current PyPi version or clone this repo and runpip install .in the directory
for most recent version.Basic usageThe textbook stochastic price modelThe standard model of stochastic price dynamics is the SDEwith solution thegeometric Brownian motionIn order to display, say 10 samples of a 1000 point process, one would runfrom price_process.process import *
price_proc = Gaussian([1000, 10]).to_geometric(0, 0.04)
price_proc.plot()Thenp.ndarrayoutput is accessed throughprice_proc.processThe Levy stable processThe most immediate generalization to the Wiener process (Brownian motion) that
is still relevant to asset pricing is theLevy stable processwhich introduces two parameters
that respectively changes the tail weight and skewness as compared to the normal
distribution.As in the previous example, we runfrom price_process.process import *
Levy(1.5, 0.02, [1000, 10]).to_geometric(0, 0.05).plot().plot()Ising price modelPerhaps the most interesting generator that is currently implemented is the Ising model of price dynamics. This
is a statistical mechanical model that captures the competition between going with the local consensus trade decision and
contradiciting the consensus. Please refer to mynotebookfor details of the model.from price_process.process import *
Ising(0.05, 500, [1000, 10]).plot()Note thatIsing(...).processis already a price process so one should not evoke.to_geometric(drift, vol). See
the documentation for all the parameters of this model and recommended ranges.Custom processCustom generators can be implemented by subclassingProcess. The only requirement is thatself.sizeto be
given as an input of shape[n_steps, n_samples]and the desired process to be assigned toself.process.Here is how one might implement the gamma process
for instancefrom price_process.process import *
from scipy.stats import gamma
import numpy as np

class Gamma(Process):
    def __init__(self, alpha, beta, size, initial=0, T=1):
        super().__init__(size, initial=initial, T=T)
        self.alpha, self.beta = alpha, beta
        self.rvs = gamma.rvs(alpha, size=self.size, scale=1/self.beta)
        self.process = np.cumsum(self.rvs, axis=0)Seethis notebookfor a more advanced use case (Gamma sampled
Wiener process).
Package: prices
Prices: Python price handling for humansMoney:frompricesimportMoneya=Money(10,'USD')a+=Money(20,'USD')a.value# Decimal('30')a=a.quantize()a.value# Decimal('30.00')a=Money('5.00','JPY')a.quantize()a.value# Decimal('5')Taxed money:frompricesimportMoney,TaxedMoneyp=TaxedMoney(net=Money(20,'EUR'),gross=Money(30,'EUR'))p.net# Money('20', 'EUR')p.gross# Money('30', 'EUR')p.tax# Money('10', 'EUR')p=p.quantize()p.net# Money('20.00', 'EUR')Taxed ranges:frompricesimportMoney,TaxedMoney,TaxedMoneyRangeprice1=TaxedMoney(Money(1,'USD'),Money(1,'USD'))price2=TaxedMoney(Money(10,'USD'),Money(10,'USD'))pr=TaxedMoneyRange(price1,price2)pr.min_price# TaxedMoney(net=Money('1', 'USD'), gross=Money('1', 'USD'))pr.max_price# TaxedMoney(net=Money('10', 'USD'), gross=Money('10', 'USD'))price3=TaxedMoney(net=Money(5,'USD'),gross=Money(5,'USD'))price3inpr# Truepr=pr.quantize()pr.min_price.net# Money('1.00', 'USD')Taxes:fromdecimalimportDecimalfrompricesimportMoney,TaxedMoney,TaxedMoneyRange,flat_taxp=TaxedMoney(Money('1.99','GBP'),Money('1.99','GBP'))p=flat_tax(p,Decimal('0.23'))p=p.quantize()p.gross# Money('2.45', 'GBP')While protecting you from all sorts of mistakes:frompricesimportMoneyMoney(10,'USD')<Money(15,'GBP')# ValueError: Cannot compare amounts in 'USD' and 'GBP'frompricesimportMoney,TaxedMoneyprice1=TaxedMoney(Money(5,'BTC'),Money(5,'BTC'))price2=TaxedMoney(Money(7,'INR'),Money(7,'INR'))price1+price2# ValueError: Cannot add amount in 'BTC' to 'INR'