Saravanan666/pypi-org huggingface dataset:
Package: wd-download-center
##版本说明：5.2.5: add ua list5.2.6: add table create function5.2.7: add ua list again5.2.8: 添加获取百度cookie的方法5.2.9: 修改百度cookie存储位置5.2.10: add *.txt file5.2.11: baidu cookie storage use sorted set5.2.12: add baidu mb cookie5.2.13: 修复本地中文乱码5.2.14: downloader fail5.2.15: downloader fail5.2.16: pymysql版本写法问题5.2.18: v1.0.0及以上请使用from pymysql.converters import escape_string5.3.0: 使用私有网络 172.17.0.*5.3.1: spider里可以打印当前ip新下载中心参数，参考 newDownloadReadme.md 文件使用方法：
config={"param": {"et":13,'cu',url}}
request = SpiderRequest(headers=headers, urls=urls,config = config)
Package: wddx
A python decoder for the WDDX XML serialisation format.WDDX was an XML data serialisation format created in 1998, initially for the
ColdFusion server environment, then open-sourced. It has faded into history
now, having lost out to JSON, YAML, and native serialisation.  According to
itsWikipedia articleWDDX was a
precursor to SOAP – which may help explain some of the latter’s
brain-damage…This module is a straight-forward decoder for WDDX packets that I wrote
while extracting the data from a PHP (which included early built-in support
for the format) project that had a home-brewed ORM.I have decoded many thousands of packets with it, YMMV.It has good support for the parts of the WDDX standard that the PHP wddx
functions actually use, but probably poor support of the full standard. It’s
impossible to actually tell because the specification is no longer online!
DNS entries for wddx.org expired in 2010, last year as I write this.ExampleThe API follows the example given by the json, pickle, and marshall modules.
You can see lots more examples in the test folder, including recursive
sequence and mapping types.>>> import wddx
>>> xml = """
... <wddxPacket version='1.0'>
... <data>
...     <number>3.1415926</number>
...     <null />
...     <string>Hello, world</string>
...     <number>42</number>
...     <dateTime>1998-06-12T04:32:12</dateTime>
... </data>
... </wddxPacket>
... """
>>> wddx.loads(xml)
[3.1415926, None, 'Hello, world', 42, datetime.datetime(1998, 6, 12, 4, 32, 12)]TODOThis module is by no means a full WDDX implementation.  The format is
practically dead – at the time of writing the WDDX specification websites
were off-line.  (Indeed, I wrote this module to help retire a legacy
data-storage engine written back when WDDX looked like a promising
interchange format.)Below are the key deficiencies.  I’m not planning on rectifying any of these
myself, they are documented here in case anybody else wants to take the module
over…Encoding SupportThe world needs less WDDX packets, not more.  I have resisted the temptation
to write the missing dump() and dumps() functions, even though it might be
fun to do so…Date-time ParsingParsing of date-time values is weak.  WDDX represents date-time values using
full ISO 8601 encoding.  This should be decoded using a full ISO 8601 parser,
not the fragile datetime.strptime() I used.  There is no such parser in the
standard library, and I was loath to bring in an external dependency for
a field I wasn’t using.Nicities and DetailsI’ve only implemented enough of the WDDX specification to handle all of the
packets I had.  Partly because that was enough to ‘stratch my itch’, but
mostly because I was unable to find a copy of the spec.For example, I found a presentation online with a slide that mentions in
passing that the WDDX string type can contain  control characters in
strings, eg. <char code=’0C’/>.  This feature, and probably many others, is
entirely unsupported.
Package: wdiffhtml
# WDIFF HTMLUses [GNU wdiff][wdiff] to generate a word baseddifffrom plain text files.The results are modified to use HTML<ins>and<del>tags and can be
wrapped in a full HTML document.# InstallationUse pip:` pip install[--user]wdiffhtml `Or clone the source and usesetup.py:` git clonehttps://github.com/brutus/wdiffhtml.gitcd wdiffhtml python setup.py install[--user]`# Usagewdiffhtmlwrites to _STDOUT_. To get a plain diff which uses<ins>and<del>tags to mark changes use:` wdiffhtml text_org.txt text_new.txt `To create a HTML file for viewing, use the–wrap-with-htmloption:` wdiffhtml--wrap-with-htmltext_org.txt text_new.txt > mydiff.html `You can use your own HTML template, CSS and / or Javascript to wrap the output.
There are command line options to set the files on fly, or you can create them
in your data directory (~/.local/share/wdiffhtml/) so they get used
automatically.Seewdiffhtml –helpfor more informations.# Contact__wdiffhtml__ is at home athttps://github.com/brutus/wdiffhtml[wdiff]:https://www.gnu.org/software/wdiff/wdiff.html
Package: wdlg
wdlgThis package is a small python library for windows.
It provides functions for creating file/directory selection dialogs and message boxes.This package is written entirely in Python.
It usesctypesmodule to display dialogs and has no dependencies ontkinteror outside the standard library.Function and argument names are almost the same as those oftkinter.
I feel that it's easy to port code fromtkintertowdlg, and vice versa.Installationpip install wdlgExample# it's easy to port code from tkinter to wdlg.# from tkinter import filedialog# from tkinter import messageboxfromwdlgimportfiledialogfromwdlgimportmessageboxdir_path=filedialog.askdirectory(initialdir="C:\\Users")messagebox.showinfo(title="Hello World",message=dir_path)LicenseBSD Zero Clause Licensesee LICENSE.txt.
Package: wdl-parsers
wdl-parsersA Python package that provides the generatedHermesandAntlr4WDL parsers for Python.VersionParser(s)Moduledraft-2Hermesdraft_2v1.0Antlr4v1_0v1.1Antlr4v1_1developmentAntlr4developmentInstallationFrom the CLI:pip install wdl_parsersUsage# the following modules are available:importwdl_parsers.draft_2importwdl_parsers.v1_0importwdl_parsers.v1_1importwdl_parsers.development# draft-2 hermes parserfromwdl_parsers.draft_2importwdl_parser# 1.0 antlr4 parserfromwdl_parsers.v1_0.WdlV1LexerimportWdlV1Lexerfromwdl_parsers.v1_0.WdlV1ParserimportWdlV1Parser# 1.1 antlr4 parserfromwdl_parsers.v1_1.WdlV1_1LexerimportWdlV1_1Lexerfromwdl_parsers.v1_1.WdlV1_1ParserimportWdlV1_1Parser# development antlr4 parserfromwdl_parsers.development.WdlLexerimportWdlLexerfromwdl_parsers.development.WdlParserimportWdlParser# parse WDL files with these parsers# ...LicenseThe grammar files come fromopenwdl/wdlunder theBSD 3-Clause "New" or "Revised" License.
Package: wdog
Watch Dogauthor= Dr. Abiira NathanA File system watch dog. Fit for monitoring and reloading a server
configuration file.
Based on watchdog moduleInstallationpip install wdogExample Usage:from wdog import WatchDog
import config

def reload_config():
    print("Reload server configiguration file")
    import importlib
    importlib.reload(config)
    # Assuming config reads reads settings from config.ini


dog = WatchDog(callback=reload_config, folder_to_track='.',
include_patterns=['*/config.ini'])
try:
    dog.monitor_forever()
except(KeyBoardInterrupt, EOFError):
    print('Bye!')You can extend this to do some fancy things.
Package: wdonate
# Как пользоваться библиотекой?Сайт: wdonate.ru
Автор питон библы: vk.com/id486001202Для установки:` pip install wdonate `Сначало инициализируем класс:`py from wdonate import wdonate wd =wdonate('токенwdonate', group_id) `Методы к котором вы можете далее обратиться:`py wd.getBalance()->float - получение баланса `Получение ссылки для оплаты:`py wd.getLink(user_id: int, amount: float = 0, payload: int = 0, pay_method: str = 'card')->dict `получение списка последних донатов:`py wd.getPayments(count: int = 0)->dict `получение текущей url callback:`py wd.getCallback()->dict `установка url callback:`py wd.setCallback(url: str)->dict `удаление текущей url callback`py wd.delCallback()->dict `
Package: wdpass
wdpassWD Passport Ultra Complete Utilities for Linux.Thanks to:Dan Lenskiforpy_sg(Python2)0-dukeandderekheforwdpassport-utils(Python2)tvladyslavfor Python3 migration ofpy_sgandwdpassport-utilsIntroThis script let you unlock, change password and erase Western Digital Passport devices on Linux platform.RequirementsInstalllsscsipackage or any package that provideslsscsicommand in your linux distro.InstallInstall the latest version from PyPisudopython3-mpipinstallwdpassInstall the latest version manuallyProvide<Python.h>header file by installing Python Developer Package. (usuallypython3-devorpython3-devel)Install the latest py3_sg frompy3_sgAnd finally installwdpassfrom this repository.For example on Ubuntu:sudoaptinstalllsscsipython3-dev
sudopython3-mpipinstallhttps://github.com/tvladyslav/py3_sg/archive/master.zip
sudopython3-mpipinstallhttps://github.com/7aman/wdpass/archive/master.zipUsageRunwdpassas root.There are few options:-h,--helpshowthishelpmessageandexitLists all possible arguments.-s,--statusCheckdevicestatusandencryptiontypeGet device encryption status and cipher suites used.-u,--unlockUnlockYou will be asked to enter the unlock password. If everything is fine device will be unlocked.-us,--unlock_with_saved_passwdUnlockwiththepasswordsavedUnlock using the saved password. If everything is fine device will be unlocked.-sp,--save_passwdSavepasswordWhen unlock password, it will save user password to passwd.bin, so you can use "-us" for next time to auto unlock.-m,--mountEnablemountpointforanunlockeddeviceAfter unlock, your operating system still thinks that your device is a strange thing attached to his usb port and he don't know how to manage. You need this option to force the O.S. to re-scan the device and handle it as a normal external usb hard drive.-c,--change_passwdChange(ordisable)passwordThis option let you to encrypt your device, remove password protection and change your current password.
If device is "without lock" and you want it to be password protect leave the "OLD password" field empty and choose insert the new password.
If the device is password protected and you want to be as a normal unencrypted device, insert the old password and leave the "NEW password" field empty.
If you only want to change password do it as usual.-e,--eraseSecureerasedevice"Erase" the device. This will remove the internal key associated to you password and all your data will be unaccessible. You will also lose your partition table and you will need to create a new one (you can use fdisk and mkfs).-dDEVICE,--deviceDEVICEForcedevicepath(ex./dev/sdb).Usuallyyoudon'tneedthisoption.The script will try to auto detect the current device path of your WD Passport device.
If something is wrong or you want to manually specify the device path yourself you can use this option.DisclaimerI'm in no way sponsored by or connected with Western Digital.
Use any of the information contained in this repository at your own risk. I accept no
responsibility.
Package: wdplot
WDPlot is a plotting library on top of matplotlib. The library places special
importance on avoiding overplotting in scatterplots. The following functions
can help to solve this problem:wdplot.prep.estimate_density: does a kernel density estimate, alowing for a scatter plot colored by density.wdplot.bivariate.hexbin: does a hexbin plot, where the transparency denotes density. Coloring can be a third variable or also density.wdplot.bivariate.hist2d: same as above, but with a 2D hist (square bins)wdplot.prep.sliding_window: does a sliding window estimate of a (x, y)-relationwdplot.bivariate.scatter_trendline: makes a scatter-plot with a sliding window trendline on topInstallUsing pip:python -m pip install wdplotCurrent stateThis package is mostly a collection of plot functions I tend to reuse during my research. There's no tests, and no guarantees for a stable API. Of course, contributions are welcome, but since the code was written for myself, there is much left to be desired regarding clean code and documentation.
Package: wd-pytools
wd_pytoolsIntroduceThis is the tools for python.wdcmdimporttimefromwdcmdimportInfo,entityclassTestServer:config_path='config.yaml'status=Truedefinfo_run(self):returnInfo("run","run application")\.set_args("c",self.config_path,"閰嶇疆鏂囦欢鍦板潃"),self.rundefrun(self,ctx):print(f"閰嶇疆鏂囦欢鍦板潃锛歿ctx.get('c')}")whileself.status:print("test run ....")time.sleep(1)defexit(self):self.status=Falseprint("server stop over")if__name__=="__main__":server=TestServer()entity.register(*server.info_run()).on_exits(server.exit).launch()
Package: wDRMetrics
AboutThis project is a GUI wrapper for pyDRMetrics:pyDRMetrics - A Python toolkit for dimensionality reduction quality assessment, Heliyon, Volume 7, Issue 2, 2021, e06199, ISSN 2405-8440,https://doi.org/10.1016/j.heliyon.2021.e06199.The original version is developed in ASP.Net MVC (http://qsi.zhangys.org.cn/research/dr/). This project has rewritten it using Flask.Install and Runpip install wDRMetrics
The package will be installed into USER\anaconda3\Lib\site-packages\wDRMetricspython -m wDRMetrics.runGo tohttp://localhost:5006/Run directly from sourcegit clonehttps://github.com/zhangys11/wDRMetrics.gitcd wDRMetrics/app/python wDRMetrics.pyGo tohttp://localhost:5006/ScreenCutTest built-in DR algorithmsAnalyze self-defined DR algorithm
Package: wdsparql
wdsparqlmagicIPython magic to run Wikidata's Sparql queries on the notebooksSample NotebookYou can run the sample notebook onbinderFeaturesMagics%%wdsparql: Runs the cell as a sparql query on your notebook%wdseturl <url>: Sets the url to run the queries against%wdreseturl: Resets the urlOther featuresAfter running a wdsparql query, a pandas dataframe will be available as_dfwd. You can run all common pandas operations against it.DevelopingPublishingJust add a new tag or release withgit tag vX.Y.Z -m "<Comment>"; git push --tagsTODO:What happens if an error occurs?Raising custom exceptionExpose the last query result to the namespace as a pandas dataframeCreate setup.pyUpload to pypiMake sample notebook (use wikipedia's queries)Write the README.mdButton to "run with binder"Explain all the magics:wdsparqlwdseturlwdreseturlTestingUnit testing for the functionsVisual testing for the sample notebookMake test, build and upload automatically using github actionsCheck linting toolsUse matrix to check with multiple python versionsFor displaying, stop using dataframes and use a custom classMake links clickableMake items appear as<a href="<link">Q1984194810</a>Display imagesDisplay mapAdding more queries than the simple ones to the notebookOptional:Making a new kernel instead of an extension (select cell language: sparql)
Package: wdtea
WDTEAv0.0.1"Why Doesn't This Exist Already"(Basically a module with stuff that I find helpful)So you don't have to go through the code yourself, have the...✨Documentation✨newLinesleeprandRangeclearfloorceilnewLineprintsxamount of newlinesCode:defnewLine(x):foriinrange(x):print()#Blank print makes a new lineUsage:print("hello")wdtea.newLine(3)print("world")Output:hello



worldsleepWaits forxmillilsecondsCode:defsleep(x):time.sleep(x/1000)#Converted to millisecondsExample Usage:print("hello")sleep(1000)print("world")Example Output:hellorandRangeReturns a random integer betweenminandmaxCode:defrandRange(min,max):returnrandom.randrange(min,max)Example Usage:randRange(1,10)Example Output:9clearClears the consoleCode:defclear():os.system('clear')Example Usage:clear()Example Output:(It clears the console what did you expect for the example output?)floorRounds downCode:deffloor(x):returnmath.floor(x)Example Usage:floor(15.75)Example Output:15ceilRounds upCode:defceil(x)returnmath.ceil(x)Example Usage:ceil(21.23)Example Output:22To-Do:Fix progBar functionFix delLine functionProfit
Package: wea
wea.pyWhat is wea?Giving the package a meaning - wea stands for Wrapped Exchange Array. If you want to share array-packed data with different processes, remote nodes or different language executables ( yes, that's the vision ), wea is aiming to be a lean, lightweight and convenient alternative toProtocol Buffersand Co.It's inspired and adopted partly from Julia’sInterProcessCommunicationWrappedArray.The wrapped exchange array can be accessed like a numpy array because under the hood, numpy is applied.If this sounds good to you, just give it a try.Getting startedInstall the package from PypipipinstallweaQuick API guideShared memoryimportweaimportnumpyasnp...wa=wea.shared_memory.create_shared_array('/awesome-1',np.dtype('float64'),(10,2))wa[:]=my_new_data[:]...Creating a shared memory segmentIn order to create a new shared memory segment, use the following snippetimportweaimportnumpyasnptype=np.dtype('float64')dims=(10,2)wa=wea.shared_memory.create_shared_array('/awesome-1',type,dims)wa[:]=np.random.randn(dims[0],dims[1])If creating was not possible because the segment already exists , aFileExistsErrorexception will be thrown.Attaching to an existing shared memory arrayIf a wrapped exchange array was already created, you can attach to it simply byimportweaimportnumpyasnpwa=wea.shared_memory.attach_shared_array('/awesome-1')wa[:]=np.random.randn(dims[0],dims[1])The metadata of the array are stored in the shared memory header segment and will be retrieved for the numpy array creation.If attaching was not possible because the segment does not exist so far, aFileNotFoundErrorexception will be thrown.Bytearray buffer memoryimportweaimportnumpyasnp...wa=wea.buffered_memory.create_buffered_array(np.dtype('float64'),(10,2))wa[:]=my_new_data[:]buf=wa.exchange_buffershare(buf)# where share calls your prefered communication protocol...Creating a buffered memory segmentIn order to create a new buffered memory segment, use the following snippetimportweaimportnumpyasnptype=np.dtype('float64')dims=(10,2)wa=wea.buffered_memory.create_buffered_array(type,dims)wa[:]=np.random.randn(dims[0],dims[1])buf:bytearray=wa.exchange_bufferActually it copies the content from the numpy array into the buffer. Thus, the current behavior is like a deep copy.Loading from an existing buffered memory segmentIf a wrapped exchange array was already created, you can load from it simply byimportweaimportnumpyasnpbuf:bytearray=receive()# where receive via your prefered communication protocolwa=wea.buffered_memory.load_buffered_array(buf)The metadata of the array are stored in the buffered memory header segment and will be retrieved for the numpy array creation.ContributingI welcome any contributions, enhancements, and bug-fixes.Open an issueon GitHub andsubmit a pull request.Licensewea.py is 100% free and open-source, under theMIT license. Use it however you want.This package isTreeware. If you use it in production, then we ask that youbuy the world a treeto thank us for our work. By contributing to the Treeware forest you’ll be creating employment for local families and restoring wildlife habitats.
Package: wea-clt
wea is an ASCII decorated command-line program to get a weather report in your terminal, for any location and in multiple languages.FeaturesCurrent weather report.Forecast for the next 5 days.Several weather conditions:Temperature and apparent temperature.Wind direction and speed.Atmospheric pressure.Rainfall rate and probability of precipitation.Visibility distance.Metric and imperial unit system.Multilingual support.SetupYou will needPython >= 3.6pipa free API key for OpenWeather. You can find yourshere, after signing in.InstalationNow you can install wea usingpip:pip install wea-cltUsageYou can see all available commands typingwea -hwhich displays the following help message:usage: wea.exe [-h] [-c | -f | -l  [...] | -u [default | metric | imperial] | --lang  | -k  | --config]

options:
  -h, --help            show this help message and exit
  -c, --current         Shows current weather for the set location.
  -f, --forecast        Shows weather forecast for the set location.
  -l  [ ...], --location  [ ...]
                        Sets a location.
  -u [default | metric | imperial], --units [default | metric | imperial]
                        Changes unit system
  --lang                Sets new language.
  -k , --key            Sets the OpenWeather API key.
  --config              Shows current user configuration path and content.If no arguments were provided, wea shows current and weather forecast for the location set in the user's configuration file.You can also see a weather report for a location without changing the configuration file. Try:wea London -cLicensewea is released under theMIT License.This project uses source code from the filestranslations.pyfromhttps://github.com/chubin/wttr.in, licensed under theApache License 2.0.ascii-art-table.gofromhttps://github.com/schachmat/wego, Copyright (c) 2014-2017,teichm@in.tum.de, licensed under theISC License.
Package: weak-annotators
Weak Annotators (NER)Experiments with weak annotators for NER using different models and methods including LLMs.Installationpipinstallgit+https://github.com/imvladikon/weak_annotators.gitUsageUsingUniversalNERextractor:fromweak_annotatorsimportUniversalNerExtractortext="""The patient was prescribed 100 mg of aspirin daily for 3 days.""".strip()labels=["DRUG","DISEASE","SYMPTOM","DURATION"]extractor=UniversalNerExtractor(labels=labels)print(extractor(text))# [Span(start=37, end=44, text='aspirin', label='DRUG'), Span(start=55, end=61, text='3 days', label='DURATION')]It returns a list ofSpansbut if passreturn_dict=Trueit will return a list of dictionaries:print(extractor(text,return_dict=True))# [{'start': 37, 'end': 44, 'text': 'aspirin', 'label': 'DRUG'}, {'start': 55, 'end': 61, 'text': '3 days', 'label': 'DURATION'}]UsingmedalpacaLLM:It requires labels descriptions:fromweak_annotatorsimportMedAlpacaExtractorlabels=["DRUG","DISEASE","SYMPTOM","DURATION"]labels_descriptions={"DRUG":"Drug or medication","DISEASE":"Any disease, syndrome, or medical condition","SYMPTOM":"Any symptom or sign of a disease or medical condition","DURATION":"Any period of time",}extractor=MedAlpacaExtractor(labels=labels,labels_description=labels_descriptions)text="""The patient was prescribed 100 mg of aspirin daily for 3 days.""".strip()annotations=extractor(text)print(annotations)Optionally, it's possible to passprompt_templatetoMedAlpacaExtractor.prompt_template="Extract entities of type{}from the following text:"extractor=MedAlpacaExtractor(labels=labels,labels_description=labels_descriptions,prompt_template=prompt_template)Usingflair(TARS extractor):fromweak_annotatorsimportFlairExtractorlabels=["DRUG","DISEASE","SYMPTOM","DURATION"]extractor=FlairExtractor(labels=labels)print(extractor(text))