Saravanan666/pypi-org huggingface dataset:
Package: iug-gui
Bumbo: Python Web Framework built for learning purposesBumbo is a Python web framework built for learning purposes.It's a WSGI framework and can be used with any WSGI application server such as Gunicorn.InstallationpipinstallbumboHow to use itBasic usage:frombumbo.apiimportAPIapp=API()@app.route("/home")defhome(request,response):response.text="Hello from the HOME page"@app.route("/hello/{name}")defgreeting(request,response,name):response.text=f"Hello,{name}"@app.route("/book")classBooksResource:defget(self,req,resp):resp.text="Books Page"defpost(self,req,resp):resp.text="Endpoint to create a book"@app.route("/template")deftemplate_handler(req,resp):resp.body=app.template("index.html",context={"name":"Bumbo","title":"Best Framework"}).encode()Unit TestsThe recommended way of writing unit tests is withpytest. There are two built in fixtures
that you may want to use when writing unit tests with Bumbo. The first one isappwhich is an instance of the mainAPIclass:deftest_route_overlap_throws_exception(app):@app.route("/")defhome(req,resp):resp.text="Welcome Home."withpytest.raises(AssertionError):@app.route("/")defhome2(req,resp):resp.text="Welcome Home2."The other one isclientthat you can use to send HTTP requests to your handlers. It is based on the famousrequestsand it should feel very familiar:deftest_parameterized_route(app,client):@app.route("/{name}")defhello(req,resp,name):resp.text=f"hey{name}"assertclient.get("http://testserver/matthew").text=="hey matthew"TemplatesThe default folder for templates istemplates. You can change it when initializing the mainAPI()class:app=API(templates_dir="templates_dir_name")Then you can use HTML files in that folder like so in a handler:@app.route("/show/template")defhandler_with_template(req,resp):resp.html=app.template("example.html",context={"title":"Awesome Framework","body":"welcome to the future!"})Static FilesJust like templates, the default folder for static files isstaticand you can override it:app=API(static_dir="static_dir_name")Then you can use the files inside this folder in HTML files:<!DOCTYPE html><htmllang="en"><head><metacharset="UTF-8"><title>{{title}}</title><linkhref="/static/main.css"rel="stylesheet"type="text/css"></head><body><h1>{{body}}</h1><p>This is a paragraph</p></body></html>MiddlewareYou can create custom middleware classes by inheriting from thebumbo.middleware.Middlewareclass and overriding its two methods
that are called before and after each request:frombumbo.apiimportAPIfrombumbo.middlewareimportMiddlewareapp=API()classSimpleCustomMiddleware(Middleware):defprocess_request(self,req):print("Before dispatch",req.url)defprocess_response(self,req,res):print("After dispatch",req.url)app.add_middleware(SimpleCustomMiddleware)
Package: iuguclient
IuguThe Iugu provides a Python REST APIs to create, process and manage payments.InstallationUsing pip:$ pip install iuguclientUsageYou should import and create an iugu instance using yourapi token:importiuguapi=iugu.config(token=IUGU_API_TOKEN)After that you can use the instance to iniciate the module you need, example:# token apiiugu_token_api=iugu.Token()# customer apiiugu_customer_api=iugu.Customer()To see all available modules, check theiugu folderof this project.DocumentationVisitiugu.com/referencias/apifor api reference oriugu.com/documentacaofor full documentationOriginal projecthttps://github.com/iugu/iugu-python
Package: iuguCTS
IuguThe Iugu provides a Python REST APIs to create, process and manage payments.InstallationUsing pip:$ pip install iuguFrom source code:Clone the source:

    $ git clone git@github.com:iugu/iugu-python.git

Execute the setup script:

    $ cd iugu-python
    $ python setup.py installUsageYou should import and create an iugu instance using yourapi token:importiuguapi=iugu.config(token=IUGU_API_TOKEN)After that you can use the instance to iniciate the module you need, example:# token apiiugu_token_api=iugu.Token()# customer apiiugu_customer_api=iugu.Customer()To see all available modules, check theiugu folderof this project.DocumentationVisitiugu.com/referencias/apifor api reference oriugu.com/documentacaofor full documentationAuthorOriginally byFelipe TomazandArthur Furlan.ContributorAndré Kiffer.Rodolpho Pivetta Sabino.Joabe Mendes.
Package: iu-jar
iu-jarAn incremental upgrade tool for jar packagesTo installiu-jar, use pip:pip install iu-jarthen, run withiujarUsage:iujar [option]

 option:

     -h or --help: show help info

     -l target-jar [-o list-file-path]: list table of contents for jar
        target-jar:                 string, path of jar file that need to list
        list-file-path:             string, path of 'list-file' file

     -i old-jar -t new-jar [-n incremental-pkg-name] [-d incremental-pkg-dir] [-f force-path]: generate incremental jar
        old-jar:                    string, path of 'old-jar|list-file' file
        new-jar:                    string, path of new-jar file
        incremental-pkg-name:       string, name of output, default is [old-jar].incremental
        incremental-pkg-dir:        string, dir of output, default is current dir
        force-path:                 regex, match the file path that needs to be forced to update

     -u target-jar -a incremental-pkg [-n new-pkg-name] [-d new-pkg-dir] [-I ignore-path]: update jar from incremental jar
        target-jar:                 string, path of jar file that need to update
        incremental-pkg:            string, path of incremental pkg[from -i generate]
        new-pkg-name:               string, new jar name of output, default is replace target-jar
        new-pkg-dir:                string, dir of output, default is dir of target-jar
        ignore-path:                regex, match the file path that needs to be ignore to update

 example:
     %s -i temp/test.jar -t temp/test_new.jar -d temp.out -f '/BOOT-INF/(classes/*|lib/org\.ileler\..*)|/META-INF/*'
     %s -u temp/test.jar -a temp.out/test.jar.incremental -d temp.out
Package: iupdatable
IUpdatable封装常用函数详细文档：https://www.cnblogs.com/IUpdatable/articles/12500039.htmlInstallation首次安装：pipinstalliupdatable更新安装：pipinstall--upgradeiupdatable更新日志：v 0.2.4: 增加  WeiXinCrawler 类, 用于抓取微信公众号历史消息。v 0.2.2: 增加 Timer 类Timer 主要函数：获取 Unix 时间戳（精确到秒）：timestamp、unix、unix10获取 Unix 时间戳（精确到毫秒）：timestamp13、unix13随机等待若干秒：sleep_range、sleep_range_asyncUnix 时间戳转换成 datetime：unix_to_datetime、timestamp_to_datetimeUnix 时间戳转换成 datetime 字符串：unix_to_datetime_str、timestamp_to_datetime_strv 0.2.0: 修复多进程下写入日志报错问题多进程下操作日志会报错：[WinError 32] 另一个程序正在使用此文件，进程无法访问。
这里通过添加 concurrent_log_handler 模块 替换掉系统内置的 TimedRotatingFileHandler 解决。v 0.1.9: 添加 Status 类详细说明文章：[Python] iupdatable包：Status 模块使用介绍文件 - Fileread： 读取文件write： 写入文件append：追加写入文件append_new_line：新建一行，然后追加写入文件read_lines： 按行一次性读取文件write_lines：按行一次性写入文件write_csv：写入CSV文件read_csv：读取CSV文件exist_within_extensions: 检查一个文件是否存在（在指定的几种格式中）get_file_path_within_extensions: 获取一个文件的路径（在指定的几种格式中）简单实例:fromiupdatable.system.io.FileimportFilesample_text='this is sample text.'sample_texts=['123','abc','ABC']append_text='this is append text.'# 写入File.write('1.txt',sample_text)File.write_lines('2.txt',sample_texts)File.append('1.txt',append_text)File.append_new_line('2.txt',append_text)# 读取read_text1=File.read('1.txt')read_text2=File.read_lines('2.txt')# 打印输出print(read_text1)print(read_text2)日志 - logging简单实例：fromiupdatable.logging.LoggerimportLoggerfromiupdatable.logging.LogLevelimportLogLeveldeftest_logging():# 日志等级：# CRITICAL  同：FATEL，下同# ERROR# WARNING# INFO# DEBUG# NOTSET    按照 WARNING 级别输出# 设置为 DEBUG，输出所有信息# 设置为 WARNING, INFO、DEBUG 级别的日志就不会输出Logger.get_instance().config(log_level=LogLevel.DEBUG)Logger.get_instance().debug('debug message1')Logger.get_instance().info('info message1')Logger.get_instance().warning('warning message1')Logger.get_instance().error('error message1')Logger.get_instance().debug('debug message1',is_with_debug_info=True)# 要想输出具体的调试信息Logger.get_instance().fatal('fatal message1')Logger.get_instance().critical('critical message1')# fatal = critical# 也可以输出变量abc=[1,2,4]Logger.get_instance().info(abc)test_logging()Base64encode：base64编码decode：base64解码encode_multilines：base64多行解码decode_multilines：base64多行解码CSProductfromiupdatable.system.hardwareimportCSProduct# 一次性获取所有的CSProduct信息cs_product=CSProduct.get()print("CSProduct: "+str(cs_product))print(cs_product["Caption"])# 或者# 使用各项函数单独获取print("Caption: "+CSProduct.get_caption())print("Description: "+CSProduct.get_description())print("IdentifyingNumber: "+CSProduct.get_identifying_number())print("Name: "+CSProduct.get_name())print("SKUNumber: "+CSProduct.get_sku_number())print("UUID: "+CSProduct.get_uuid())print("Vendor: "+CSProduct.get_vendor())print("Version: "+CSProduct.get_version())UMeng友盟统计这里使用了自定义事件统计的功能创建网站类型的统计，第一个参数是统计代码中的idUMeng.log_stat(1211111111,'来源页面','目录','行为','标签')LicenseMIT
Package: iupy
iupyIan Underwood Python Kit (IUPY)AboutThis package is a set of Python functions that I have built out and found useful in my travels as a network engineer.  This is the base package for all iupy additional packages to follow.This functions in this package are meant to be standalone packages and have no other package dependencies beyond a base Python installation.  These functions are designed to be light on requirements.This package has been built and tested against Python 3.9, and should work down to 3.7 but I can't guarantee that.Function Summarymisc.pyiupy.text_header : Returns a text header returning the time, user, and system a given output was generated on.  Additional options allow for identifying a source, as well as another user if specified.  A footer may also be defined.iupy.merge_dict : Returns a combined dictionary given two dictionary inputs.myconfig.pyiupy.get_file_handle_ro : Returns a file handle given a name, or None if the file cannot be found or is inaccessible.  Exceptions are logged to DEBUG.iupy.get_my_config : Moves through a series of directories looking for a configuration file needed by a script.  This returns a data dictionary containing the data, the filename used, and the file's timestamp.  Useful for baking portable CLI utilities and automated scripts.network.pyHost Informationiupy.get_my_ip : Returns a string, the source IP given a remote IP address or destination.  Returns None if there is a SocketError which prevents the source from being determined.  If no destination is specified, the function assumes well-known DNS server 4.2.2.1ACL and Bitmask Toolsiupy.v4_bits_to_mask : Returns a string,  a netmask based upon the number of bits in relation to 0.0.0.0/bits.  Returns None if the mask is out of range.ippy.v4_mask_to_bits : Returns a string, as the largest number of consecutive bits given an IP address.  This is far more forgiving than the ipaddress library, which may be useful to some.iupy.v4_wildcard : This function returns a compliant wildcard for a given IP address.  This is similar to, but different than a host mask as a wildcard does not need to have a series of consecutive bits in order to be valid.iupy.aclv4_hostmask : Takes an IPv4 host or host/mask and returns a Cisco-compatible string for use in ACL generation.iupy.routev4_hostmask : Takes an IPv4 host or host/mask and returns a cisco-compatible string for use in generating static route statements.Session Announcement Protocoliupy.sap_segment : This function generates the segment portion of an RFC-2974 Session Announcement Protocol packet.  The segment still needs to but put on the wire with a UDP socket.  The keywords cover the fields the segment requires.  Returns None if any of the keywords are invalid or incomplete.
Package: iupy-restconf
iupy-restconfIan Underwood's Python RESTCONF ModuleAboutThis package provides a RESTCONF class to manage interactions with network devices that use the RESTCONF protocol as defined in RFC-8040.This document is woefully incomplete.InstallationModule installation can be managed with PIP:pip3 install iupy-restconfUsageThis provides a top-level restconf import which should be imported into your project as such:import restconf

router = restconf.RestConf()

router.connect(transport='https',
               host='192.168.1.1',
               un='restuser',
               pw='restpass')From there, using the module is a matter of defining the method and path that is useful for your application:response = router.get("data/native/interfaces")Operations such as push, post, and patch use a second positional arguement as a dictionary that provides the structure required.response = router.post("data/openconfig-interfaces:interface", newconfig_dict)Since RESTCONF is authorized on a per-request basis, there is no connection open or close method as with a general REST API which generates an stores a session.Device CapabilitiesRouters that are RFC-8040 compliant provide a list of modules that they support.  This allows a script to check for basic capabilities.router.get_data_modules()

if router.check_data_modules("Cisco-IOS-XE-native"):
    print("This supports IOS-XE Native Calls")
Package: iutest
IUTest"IUTest" stands for "Interactive UnitTest", it is an interactive python unit-test runner that aims to support various unit-test frameworks likenose2,pytest, etc.It has a pretty yummy Chinese name "Youtiao", which is Chinese fried breadstick typically for breakfast :)To install IUTest# For system default python or virtual envpipinstalliutest# For pipenv pythonpipenvinstalliutestIUTest Command Line Interface# Get version:iutest--version# Run IUTest UI:iutest# oriutest--ui# Run all tests recursively within a directory:iutest--runner"nose2"--runTests"E:/projects/iutest"# Run tests by python module paths:iutest--runner"nose2"--runTests"iutest.tests.test_dummypyunits"--runTests"iutest.tests.iutests"# Run test but stop at first error / failure:iutest--runner"nose2"--runTests"iutest"--stopOnErrorRun tests in pythonimportsystesterPath='E:/projects/iutest'# Change to your path!iftesterPathnotinsys.path:sys.path.append(testerPath)importiutest# Run all tests under given file system path:iutest.runTests("nose2",'path/To/Test/RootDir')# Run tests by given python module paths:iutest.runTests("nose2","iutest.tests.test_dummytests","iutest.tests.iutests")Run UI in pythonimportsystesterPath='E:/projects/iutest'# Change to your path!iftesterPathnotinsys.path:sys.path.append(testerPath)importiutestiutest.runUi()Run IUTest in DCC application, e.g.MayaIt is easy to usepip with Maya, with pip available in mayapy, you just need to domayapy -m pip install packageNamefor each package we need: iutest, reimport, nose2 or pytest.However, pip requires root privilege and it did introduce many potential risks, so to use iutest in Maya without pip:DownloadIUTestand its dependency libraries:reimport,nose2orpytestMake these libraries available to Maya by adding their paths tosys.path.Install thecodeabove as a Maya shelf button.Click on the shelf button to run IUTest UI.
Package: iutils
This package includes various utility modules I find useful.Installpip install iutilspcolrmUsage: pcolrm [OPTIONS] COL_NUMS

  Remove columns from a file.

  This utility mimics what colrm does. One of the differences is that columns
  are separated by delimiters instead of each single character representing
  one column.

  Like colrm, this utility reads its input from the standard input and writes
  its output to the standard output.

  COL_NUMS is a list of comma separated column numbers that are to be removed.
  You can use '-' to specify a range. For example, 1,2,4 or 1-2,4 etc.

  Column numbering starts with one, not zero.

Options:
  -d, --delimiter TEXT  Delimiter.  [default:  ]
  --help                Show this message and exit.
Package: iv
iv: Terminal Image Viewer for iTerm2ivis a utility for viewing images in the terminal using iTerm2'simage display capability. It's useful for dealing with images on a remote server, for example with large image processing tasks.When displaying single images,ivwill resize them to speed up
transfer over an SSH connection:When displaying multiple images,ivwill produce a "contact sheet"
of images with filenames. These images are decoded and resized in
parallel:Installationivcan be installed using pip:$ pip3 install ivIfivcan't find any suitable TrueType fonts on your system it'll use
an ugly default bitmap font. To get some nicer fonts on Linux, install
the Open Sans or msttcorefonts collections (fonts-open-sansorttf-mscorefonts-installerpackages on Debian-like distributions).UsageUsage: iv [OPTIONS] FILENAME...

  Display images within an iTerm2 terminal.

  iv will resize images to reduce the time taken to display them over SSH
  connections, and it will combine multiple images into a single image, with
  filenames.

  Usage:

    iv ./file.jpg # Display a single file, resizing as appropriate.
    iv *.jpg      # Display a number of files combined into a single image, with filenames.

  The IV_SIZE environment variable can be used to set the output image size
  instead of the -s/--size option.

Options:
  --version           Show the version and exit.
  -s, --size INTEGER  Maximum output image width in pixels.
  --help              Show this message and exit.LimitationsiTerm2 may refuse to display extremely large images, and replace them with a
retro "broken image" icon. You can always right-click and "Open image"
to view the image with an external viewer.
Package: iv2
iv2简介将图片转成向量，可用于以图搜图和图片相似度比较向量纬度为 512⭐️ 🌟 ✨ ⚡️ ☄️ 💥依赖Python 解释器:CPython : 3.8 及以上版本安装方式:pipinstalliv2参考项目cnnimageretrieval-pytorchImageRetrieval-LSH
Package: iva2k-how-long
Simple Decorator to measure a function execution time.Very lightweight project to get familiar with poetry publishing to PyPi, built from tutorialhttps://www.pythoncheatsheet.org/blog/python-projects-with-poetry-and-vscode-part-1Examplefromiva2_how_longimporttimer@timerdefsome_function():return[xforxinrange(10_000_000)]
Package: ivadomed
ivadomedis an integrated framework for medical image analysis with deep learning.The technical documentation is availablehere.  The more detailed installation instruction is availablethereInstallationivadomedrequires Python >= 3.7 and < 3.10 as well as PyTorch == 1.8. We recommend working under a virtual environment, which could be set as follows:python-mvenvivadomed_envsourceivadomed_env/bin/activateInstall from release (recommended)Installivadomedand its requirements fromPypi <https://pypi.org/project/ivadomed/>__:pipinstall--upgradepip
pipinstallivadomedInstall from sourceBleeding-edge developments builds are available on the project's master branch on Github. Installation procedure is the following:gitclonehttps://github.com/neuropoly/ivadomed.gitcdivadomed
pipinstall-e.ContributorsThis project results from a collaboration between theNeuroPoly Laband theMila. The main funding source isIVADO.List of contributorsConsult our Wiki(https://github.com/ivadomed/ivadomed/wiki) here for more help
Package: ivaluemart-channel-advisor
channel_advisorimport channel_advisorget_access_token(headers, payload)get_product_id(token, sku)get_fba_product_id(token, asin)get_product_by_id(token, product_id)get_bundle_components(token, product_id)get_components(token, product_id)add_or_update_attribute(token, product_id, attribute_name, attribute_value)get_product_with_attributes_by_id(token, product_id)get_product_quantity(token, product_id)delete_product(token, product_id)reset_buffer(token, product_id, updated_quantity)update_buffer(token, product_id, buffer)update_dimensions(token, product_id, height, length, width, weight, location)update_quantity(token, sku, product_id, quantity, dc_id)get_product_id_by_supplier_sku(token, mpn)get_product_id_by_mpn(token, mpn)get_sku_by_upc(token, upc)
Package: ivan-datadog-lambda
datadog-lambda-pythonDatadog Lambda Library for Python (3.7, 3.8, and 3.9) enablesenhanced Lambda metrics,distributed tracing, andcustom metric submissionfrom AWS Lambda functions.InstallationFollow theinstallation instructions, and view your function's enhanced metrics, traces and logs in Datadog.ConfigurationFollow theconfiguration instructionsto tag your telemetry, capture request/response payloads, filter or scrub sensitive information from logs or traces, and more.Opening IssuesIf you encounter a bug with this package, we want to hear about it. Before opening a new issue, search the existing issues to avoid duplicates.When opening an issue, include the Datadog Lambda Library version, Python version, and stack trace if available. In addition, include the steps to reproduce when appropriate.You can also open an issue for a feature request.Lambda Profiling BetaDatadog'sContinuous Profileris now available in beta for Python in version 4.62.0 and layer version 62 and above. This optional feature is enabled by setting theDD_PROFILING_ENABLEDenvironment variable totrue. During the beta period, profiling is available at no additional cost.The Continuous Profiler works by spawning a thread which periodically wakes up and takes a snapshot of the CPU and Heap of all running python code. This can include the profiler itself. If you want the Profiler to ignore itself, setDD_PROFILING_IGNORE_PROFILERtotrue.Major Version Notes4.x / Layer version 61+Python3.6 support has beendeprecatedby AWS, and support removed from this library.dd-traceupgraded from 0.61 to 1.4, full release notes are availablehereget_correlation_ids()has been changed toget_log_correlation_context(), which now returns a dictionary containing the activespan_id,trace_id, as well asserviceandenv.ContributingIf you find an issue with this package and have a fix, please feel free to open a pull request following theprocedures.CommunityFor product feedback and questions, join the#serverlesschannel in theDatadog community on Slack.LicenseUnless explicitly stated otherwise all files in this repository are licensed under the Apache License Version 2.0.This product includes software developed at Datadog (https://www.datadoghq.com/). Copyright 2019 Datadog, Inc.
Package: ivanov
Ivanov###========================
##TL; DR: All sh*t in one place!
###========================What for?Connect to SAS MAConnect to SASCSConnect to SAS ScoringSAS SPK object extractionGet vault secretsSAP BO blx parsingA lot's of other things (hidden inside)##Examples:Connection to SAS MAfrom ivanov import SASMA
sasma = SASMA(user='user@domain', password='may_be_empty_in_jupiter')
sasma.endsas() # do not forget to close session!Connection to SAS CSfrom ivanov import SASCSS
sascs = SASCS(user='user@domain', password='may_be_empty_in_jupiter')
sascs.endsas() # do not forget to close session!Connection to SAS Scoring on vs221from ivanov import SASScoringVS221
sas_vs221 = SASScoringVS221(user='user@domain', password='secret', appserver='SASApp - Workspace Server')
sas_vs221.endsas() # do not forget to close session!Connection to SAS Scoring on vs235from ivanov import SASScoringVS235
sas_vs235 = SASScoringVS235(user='user@domain', password='secret', appserver='SASApp - Workspace Server')
sas_vs235.endsas() # do not forget to close session!Connection to SAS OA on vs235from ivanov import SASOA
sas_vs990 = SASOA(user='user@domain', password='secret')
sas_vs990.endsas() # do not forget to close session!Current status:Check SAS MA connectionCheck SAS CS connectionCheck SAS Scoring vs235 connectionCheck SAS Scoring vs221 connectionCheck SAS OA (vs990) connectionCheck BO BLX parsingCheck SAS Support funcs...Check vault integrations