Saravanan666/pypi-org huggingface dataset:
Package: markup-parser
Markup ParserExtract JS variables content from HTML markupENGRUInstallationpipinstallmarkup-parserUsageParse variable from html text:Test content<!DOCTYPE html><htmllang="en"><head><metacharset="UTF-8"><title>Test</title></head><body></body><script>lettest_variable='You found me';</script></html>importrequestsfrommarkup_parserimportvar_from_html# Fetch html content by get requesthtml_text=requests.get('http://test.html').textvar_from_html(html_text,'test_variable')# Parse from filevar_from_html(open('test.html').read(),'test_variable')# >>> You found meParse variable from url:* This variant not recommended if you need to specify custom headers, this feature may be added in future releaseTest content<!DOCTYPE html><htmllang="en"><head><metacharset="UTF-8"><title>Test</title></head><body></body><script>lettest_variable='You found me again!';</script></html>frommarkup_parserimportvar_from_urlvar_from_url('http://test.page','test_variable')# >>> You found me again!RUENGУстановкаpipmarkup-parserПримеры использованияПолучить значение переменной из html разметки:Пример html страницы<!DOCTYPE html><htmllang="en"><head><metacharset="UTF-8"><title>Test</title></head><body></body><script>lettest_variable='You found me';</script></html>importrequestsfrommarkup_parserimportvar_from_html# Получить html разметку с помощью get запросаhtml_text=requests.get('http://test.html').textvar_from_html(html_text,'test_variable')# Прочитать из файлаvar_from_html(open('test.html').read(),'test_variable')# >>> You found meПолучить значение переменной по ссылке:* На данный момент этот вариант не рекомендуется если вам необходимы специфичные заголовки, эта функция может появтися в будущих релизахПример html страницы<!DOCTYPE html><htmllang="en"><head><metacharset="UTF-8"><title>Test</title></head><body></body><script>lettest_variable='You found me again!';</script></html>frommarkup_parserimportvar_from_urlvar_from_url('http://test.page','test_variable')# >>> You found me again!
Package: markup.py
This is markup.py - a Python module that attempts to make it easier to generate HTML/XML from a Python program in an intuitive, lightweight, customizable and pythonic way. It works with both python 2 and 3.The code is in the public domain.Version: 1.12 as of July 12 2017.Please send bug reports, feature requests, enhancement ideas or questions to nogradi at gmail dot com.Installation: Run ‘pip install markup.py” from the terminal.Documentation and further info is athttp://markup.sourceforge.net/
Package: markusapi
Markus APIPython interface to the api for aMarkUsinstance.InstallationInstall this package with pip:$ pip install markusapiRequirementspython 3.6+theurlof a runningMarkUs websiteyourapi_key(this can be obtained from the dashboard page of the MarkUs website)Compatibilityversion 0.2 of this package is compatible with MarkUs version < 2.0version 0.3 of this package is compatible with MarkUs version >= 2.0Usage ExampleCreate a new Markus Api object:import markusapi

api_key = 'mysecretapikey='
url = 'https://localhost:3000'

api = markusapi.Markus(api_key, url)Print all user informationuser_info = api.get_all_users()
print(user_info)Additional InfoCheck out the MarkUs API documentation for details on API calls:https://github.com/MarkUsProject/Markus/wiki/RESTfulApiDocumentation
Package: markus_exam_matcher
MarkUs Exam MatcherInstallationIt is recommended to use avirtual environmentto install this package, as it contains many pinned runtime dependencies.Production Installation (Recommended)To install the production version of the package, run the following command in the console:$pipinstallgit+https://github.com/MarkUsProject/markus-exam-matcher.gitBranch InstallationTo install the version specified by a particular branch (when permissions are granted), run the following command in the
console:$pipinstallgit+https://github.com/MarkUsProject/markus-exam-matcher.git@branch_nameCommit Hash InstallationTo install the version specified by a specific commit, the commit hash can be used by running the following command in
the console:$pipinstallgit+https://github.com/MarkUsProject/markus-exam-matcher.git@commit_hashUsageThis package works under the assumption that the characters to be detected are surrounded by boxes that are placed
side-by-side. An example image with this format is displayed below:Below is a sample usage that generates a prediction from the file shown above, assuming it was titledmy_example.jpg.$python3-mmarkus_exam_matcher./my_example.jpgdigit0001250981DevelopersFirst, clone this repository.Open a terminal in this repo, and create a newvirtual environment.Run `pip install -e ".[dev]" to install the dependencies.Then run `pre-commit install`` to install the pre-commit hooks (for automatically formatting and checking your code on each commit).
Package: markus-jupyter-extension
markus-jupyter-extensionA Jupyter extension to support integration withMarkUs.InstallationThis extension is available as a Python package.
To install it:$pipinstallmarkus-jupyter-extensionThen install and enable the extension:$jupyternbextensioninstall--py--usermarkus-jupyter-extension$jupyternbextensionenable--py--usermarkus-jupyter-extensionEnsure that the MarkUs instances that this extension will integrate with have included the host name of the server that is running your Jupyter instance.For example, if you are installing this extension to a Jupyter instance running at www.my_jupyter.com, then make sure that 'my_jupyter.com' is included in thejupyter_server.hostssettingson MarkUs.DevelopmentTo begin development on the extension, first clone this repository:$gitclonehttps://github.com/MarkUsProject/markus-jupyter-extension.gitThen go into the cloned repository and install the contained Python package in editable mode:$pipinstall-e.You'll also need to install Jupyter notebook:$pipinstallnotebookCheck setup usingexamplesTo test whether your extension is working properly:Start the MarkUs server (seeMarkUs development instructionsfor details).Login as a student in MarkUs and go to the "Account Settings" page using the dropdown at the top-right of the website.Copy the API key for the student.Run the Jupyter notebook server from theexamplesdirectory:$cdexamples$jupyternotebookThe Jupyter front-end client should launch automatically in your web browser.Create a new file calledmarkus-api-key.txtand save the API key you copied in step 3.Open the demo notebook. Optionally, you can run the notebook cell to see the notebook's metadata (including the"markus"metadata)Click on the MarkUs icon button in the toolbar, which will submit the file to MarkUs.If you then go back to MarkUs as the student, you should see the file submitted to the specified assignment.ReferencesJupyter notebook documentation: Custom front-end extensions
Package: markwrap
Python wrappers around common dependenciesGoalsThe goal of this Python package is to simplify calling common dependencies.  Each module of the package wraps the calls of a dependency.  Additionally, each module:logs every stage of the dependency call, as well as an errors that occurrigoriously validates the input before passing it to a dependencyliberally raises exceptionsA client of this package should be confident that no silent error has occured.  Additionally, if an error occurs, the client should be able to easily trace it in the logs.  Finally, if no error is brought to attend, then the client should be confident the functionality of the dependency correctly occured.DependenciesPython dependencies:Seesetup.pyfor runtime dependenciesSeerequirements.txtfor all dependenciesTo install:pip install-rrequirements.txtNon-python dependencies:HomebrewSeeBrewfileTo install:brew bundleTestinggpg --import markwrap/test/tst.resources/4C7798F2.asc
echo -e "5\ny\n" | gpg --command-fd 0 --edit-key 4C7798F2 trust
pytest --log-format="[%(levelname)s] %(module)s.%(funcName)s - %(message)s"Warning: the 4C7798F2 will be added to your default gpg keyring on whichever system this command is runNote: the 4C7798F2 was a publically available key retrieved from thepython-gnupgtest_secring.gpg
Package: markyp-rss
markyp-rssmarkyp-based RSS 2.0 implementation.InstallationThe project is listed on the Python Package Index, it can be installed simply by executingpip install markyp-rss.Getting startedIf you are not familiar with the basic concepts ofmarkyp, please start by having a look at its documentationhere.Creating an RSS 2.0 feed usingmarkyp-rssis as easy as instantiating the required RSS elements and converting theRSSobject to string when the feed is ready.fromtypingimportList,Optionalfrommarkyp_rss.elementsimportCategory,Channel,Image,Item,RSSdefget_items()->Optional[List[Item]]:"""Returns the items to be included in the channel."""return[Item("First","https://markyp.demo/first"),Item("Second","https://markyp.demo/second"),Item("Third","https://markyp.demo/third")]rss=RSS(Channel("markyp-rss RSS 2.0 Demo Channel","https://markyp.demo/channel.rss","RSS 2.0 example built using markyp-rss.",language="en-us",image=Image("markyp-rss RSS 2.0 Demo Channel","https://markyp.demo/channel.jpeg","https://markyp.demo/channel.rss"),ttl=40,categories=[Category("Demo"),Category("Example")],items=get_items()))print(rss)For more details, please have a look at themarkyp_rss.elementsmodule.Community guidelinesIn general, please treat each other with respect and follow the below guidelines to interact with the project:Questions, feedback: Open an issue with a[Question] <issue-title>title.Bug reports: Open an issue with a[Bug] <issue-title>title, an adequate description of the bug, and a code snippet that reproduces the issue if possible.Feature requests and ideas: Open an issue with an[Enhancement] <issue-title>title and a clear description of the enhancement proposal.Contribution guidelinesEvery form of contribution is welcome, including documentation improvements, tests, bug fixes, and feature implementations.Please follow these guidelines to contribute to the project:Make sure your changes match the documentation and coding style of the project, includingPEP 484type annotations.mypyis used to type-check the codebase, submitted code should not produce typing errors. Seethis pagefor more information onmypy.Smallfixes can be submitted simply by creating a pull request.Non-trivial changes should have an associatedissuein the issue tracker that commits must reference (typically by adding#refs <issue-id>to the end of commit messages).Please writetestsfor the changes you make (if applicable).If you have any questions about contributing to the project, please contact the project owner.As mentioned in thecontribution guidelines, the project is type-checked usingmypy, so first of all, the project must passmypy's static code analysis.The project is tested usingpytest. The chosen test layout is that tests are outside the application code, seethis pagefor details on what it means in practice.Ifpytestis installed, the test set can be executed using thepytest testcommand from within the project directory.Ifpytest-covis also installed, a test coverage report can be generated by executingpytest test --cov markyp_rssfrom the root directory of the project.License - MITThe library is open-sourced under the conditions of the MITlicense.
Package: marl-aquarium
Aquarium EnvironmentA Comprehensive Framework for Exploring Predator-Prey Dynamics through Multi-Agent Reinforcement Learning Algorithms using the pettingzoo interface.Installpipinstallmarl-aquariumExamplefrommarl_aquariumimportaquarium_v0env=aquarium_v0.env()env.reset(seed=42)foragentinenv.agent_iter():observation,reward,termination,truncation,info=env.last()ifterminationortruncation:action=Noneelse:# this is where you would insert your policyaction=env.action_space(agent).sample()env.step(action)env.render()env.close()Customize the environmentParameterDescriptionDefault Valuerender_modeThe mode of rendering. Options include "human" for on-screen rendering and "rgb_array"."human"observable_wallsNumber of observable walls for the agents.2widthThe width of the environment window.800heightThe height of the environment window.800captionThe caption of the environment window."Aquarium"fpsFrames per second, controlling the speed of simulation.60max_time_stepsMaximum number of time steps per episode.3000action_countNumber of possible actions an agent can take.16predator_countNumber of predators in the environment.1prey_countNumber of prey in the environment.16predator_observe_countNumber of predators that can be observed by an agent.1prey_observe_countNumber of prey that can be observed by an agent.3draw_force_vectorsWhether to draw force vectors for debugging.Falsedraw_action_vectorsWhether to draw action vectors for debugging.Falsedraw_view_conesWhether to draw view cones for debugging.Falsedraw_hit_boxesWhether to draw hit boxes for debugging.Falsedraw_death_circlesWhether to draw death circles for debugging.Falsefov_enabledWhether field of view is enabled for agents.Truekeep_prey_count_constantWhether to keep the prey count constant throughout the simulation.Trueprey_radiusRadius of prey entities.20prey_max_accelerationMaximum acceleration of prey entities.1.0prey_max_velocityMaximum velocity of prey entities.4.0prey_view_distanceView distance of prey entities.100prey_replication_ageAge at which prey entities replicate.200prey_max_steer_forceMaximum steering force of prey entities.0.6prey_fovField of view for prey entities.120prey_rewardReward for prey survival per time step.1prey_punishmentPunishment for prey being caught.1000max_prey_countMaximum number of prey entities in the environment.20predator_max_accelerationMaximum acceleration of predator entities.0.6predator_radiusRadius of predator entities.30predator_max_velocityMaximum velocity of predator entities.5.0predator_view_distanceView distance of predator entities.200predator_max_steer_forceMaximum steering force of predator entities.0.6predator_max_ageMaximum age of predator entities.3000predator_fovField of view for predator entities.150predator_rewardReward for predator catching prey.10catch_radiusRadius within which predators can catch prey.100procreateWhether entities can procreate within the environment.Falseenv=aquarium_v0.env(draw_force_vectors=True,draw_action_vectors=True,draw_view_cones=True,draw_hit_boxes=True,draw_death_circles=True,)
Package: marlben
Marlben is a multi-agent reinforcement learning benchmark based on theNeuralMMOgame engineInstallationhttps://github.com/jbr-ai-labs/marlben/wiki/Quick-Start#installationInstallation via PipPython3.9is requiredpip install marlbenInstallation with RLlib dependencies:pip install marlben[rllib]Usagehttps://github.com/jbr-ai-labs/marlben/wiki/Quick-Start#launching-an-environmentExamplesExamples are located inexamplesfolderrllib_integration.pydemonstrates how to start learning process with default config forCorridorenvrllibinstallation is requiredoverride_config.pydemonstrates how to customize configs by inheriting from default classcustom_map_generator.pydemonstrates how to customize map generation for any environmentcustom_environment.pydemonstrates how to customize whole environment structure by overriding all building blocks of the benchmarkWikihttps://github.com/jbr-ai-labs/marlben/wiki
Package: marley
MarleyMarley is a framework for multi-agent reinforcement learning. It lets you design a game and run experiments with multiple AI-powered agents playing that game.Marley isn't ready for use yet; it works for my research purposes, but I haven't yet made the work needed to make it easy to understand for others.If you're still interested in using it, feel free to read the code oremail mefor help.I hope to make Marley easier to use soon.GridRoyaleView the live version here!GridRoyaleis a life simulation. It's a case study that's bundled with Marley.GridRoyale is similar toGame of LifeorGridWorld,
except I added game mechanics to encourage the players to behave socially. These game mechanics are
similar to those in thebattle royalegenre of
computer games, which is why it's called GridRoyale.How to run GridRoyaleInstallation:$pipinstallmarleyRun the server:$marleygrid_royaledemoThis will automatically open a browser window and show you your simulation.
Package: marlib
MARLib - A Music and Audio Research LibraryUnder development by the Music and Audio Research Lab (MARL) at NYUhttp://marl.smusic.nyu.edu=====Provides1. Abstracted audio file reading & writing (internal buffering)2. Integration with SoX for various CODEC supportUnder Development1. Basic time-frequency transforms2. Integration with SoX for various CODEC supportHow to use the documentation----------------------------Documentation is available inline as docstrings provided within the code. Intime, it is our intention to host a Sphynx-like online reference to facilitateease of use.Examples provided assume that each module has been imported as its firstcharacters in uppercase::>>> import marlib.audiofile as AF>>> import marlib.timefreq as TF......where code snippets are indicated by three greater-than signs.Use the built-in ``help`` function to view a function's docstring::>>> help(TF.mel)Available subpackages---------------------audiofiletimefreqsignalutilsDependencies-----------------------------------This package builds upon freely available Python libraries at variousstages of maturity:- NumPy: Numerical Computing in Python- SciPy: Scientific Computing in PythonAdditionally, this library takes advantage of SoX, a commandline utility for non-wave file support and audio file conversion.If you do not currently have SoX, it can be obtained here:http://sox.sourceforge.netSoX functionality is currently supported under Unix-like OS's only,(sorry, Windows). However, extending this library should be straightforwardif necessary. Note that SoX is required only for file conversions andnon-wave file formats, so - while strongly encouraged - SoX is nottruly mandatory.
Package: marlin-binary-protocol
Provides implementation of the Marlin Binary Transfer Protocol Mark II as described here:https://github.com/MarlinFirmware/Marlin/pull/14817Requires:Marlin firmware from 2.0.x bugfix branch:https://github.com/MarlinFirmware/Marlin/tree/bugfix-2.0.xBINARY_FILE_TRANSFER feature enabled in Configuration_adv.h:https://github.com/MarlinFirmware/Marlin/blob/8b637e436c775c7566820eb1defd00bb209d06b4/Marlin/Configuration_adv.h#L1198As the comments in the PR state, the protocol is a work in progress and will change.This code is essentially the same as the code provided by user p3p on that pull request.Look at the provided transfer utility, transfer.py, for example usage.
Package: marlin-bookmark
MarlinSwim between bookmarks in the terminal!Marlin is an easy to use bookmark manager for the terminal. Choose a folder, bookmark it and swim there whenever you want!Usagepip install marlin-bookmarkBookmarkbookmark [bookmark-name]Remove a Bookmarkrmark [bookmark-name]List BookmarksmarlinSwim!marlin [bookmark-name]TODOcommand shortcuts (e.g.$ git add .tomarlin ga.)
Package: marlin-cli
Marlin: The fastest path to modern web apps90% of software is the exact same; the final 10% is what differentiates a product. Marlin helps developers build the first 90% fast, so they can focus on what matters.InstallationMarlin can be built from source with the included build.sh script. Run the script and a single file executable will be written to./dist/marlin. Add this to your path or envoke it directly.DocumentationEventually we're going to put docs hereContributeMarlin-cli uses pyenv for environment management and Poetry for dependcy management. These can be installed with the includeddev_setup.shscript.VSCodeOpen VSCode and run the following commands in the terminalpoetry shell
poetry env info --path | pbcopyOpen the VSCode command palette withcmd+shift+Pand search forPython: select interpretor. Open it, clickEnter interpreter path...and paste the path copied from poetry above.
Package: marlinfs
DocumentationSee theAPI Docs.Installingpip install marlinfsUsageLoginmarlin.login()Batch Ingestiontransform_client=marlin.transform_client(namespace,name,version,entities)@transform_client.process_functiondefprocess():dep1=transform_client.add_dependency('n1','t1','v1',['f1','f2'])# Reading by timestampingestion_time_read=dep1.read_by_ingestion_ts(1612140982,1612150982)event_time_read=dep1.read_by_event_ts(1612140982,1612150982)# Reading by dateingestion_date_read=dep1.read_by_ingestion_date("2021-01-02-03","2021-01-02-04")event_date_read=dep1.read_by_event_date("2021-01-02-03","2021-01-02-04")# To commit metadata and store datatransform_client.commit()# assumption is df contains event_timestamp column in date in this format: 2021-01-02-03.# To pass different date format change return statement to df, {'date_format': 'str_date', 'str_date_format_type': '<python date format>' e.g. %Y-%m-%d})# To pass event_timestamp in seconds change return statement to df, {'date_format': 'seconds'}returndfBatch Servingbatch_serving_client=marlin.batch_training_client(namespace,name,version)# batch_serving_client = marlin.batch_scoring_client(namespace, name, version)@batch_serving_client.serving_functiondefprocess():entity_df=None# Some entity dfdep1=batch_serving_client.add_dependency('n1','t1','v1',['f1','f2'])dep2=batch_serving_client.add_dependency('n2','t1','v1',['f1','f2'])entity_df=pd.DataFrame([[1,1,1,1,"2021-01-02-03"],[1,1,1,1,"2021-01-02-03"]],columns=['A','B','C','D','target_timestamp'])dep1.point_in_time_join_by_date(entity_df)dep1.point_in_time_join_across_inputs_by_date(entity_df,[dep2])entity_df=pd.DataFrame([[1,1,1,1,1612140982],[1,1,1,1,1612140982]],columns=['A','B','C','D','target_timestamp'])dep1.point_in_time_join_by_ts(entity_df)dep1.point_in_time_join_across_inputs_by_ts(entity_df,[dep2])# To commit metadatabatch_serving_client.commit()Exploration Clientexploration_client=marlin.exploration_client()tf1=exploration_client.get_transform('n1','t1','v1')tf2=exploration_client.get_transform('n2','t2','v1')entity_df=pd.DataFrame([[1,1,1,1,"2021-01-02-03"],[1,1,1,1,"2021-01-02-03"]],columns=['A','B','C','D','target_timestamp'])tf1.point_in_time_join_by_date(entity_df)tf1.point_in_time_join_across_inputs_by_date(entity_df,[tf2])entity_df=pd.DataFrame([[1,1,1,1,1612140982],[1,1,1,1,1612140982]],columns=['A','B','C','D','target_timestamp'])tf1.point_in_time_join_by_ts(entity_df)tf1.point_in_time_join_across_inputs_by_ts(entity_df,[tf2])# Reading by timestampingestion_time_read=tf1.read_by_ingestion_ts(1612140982,1612150982)event_time_read=tf1.read_by_event_ts(1612140982,1612150982)# Reading by dateingestion_date_read=tf1.read_by_ingestion_date("2021-01-02-03","2021-01-02-04")event_date_read=tf1.read_by_event_date("2021-01-02-03","2021-01-02-04")
Package: marlowe
MARLOWE-PYPython bindings for Marlowe_Langmarlowe-rs.FeaturesDeserialize contracts from: cbor-hex, dsl, json.Deserialize datums & redeemers from cbor-hex,json.Serialize contracts to json, dsl.Serialize datums & redeemers to cbor-hex, json.Unstable: View contract expected next inputs and other state info.Unstable: Define contracts directly in Python.Unstable: Code generator: Convert any contract to equivalent Python codeProject goalsProvide easy to use API's for everything marlowe-rs supports.Provide easy to use way of designing Marlowe contracts in Python.How to installpipinstallmarloweAlternatives:pip install wlh files directly using builds artifacts from CI:https://github.com/OlofBlomqvist/marlowe-py/actions/workflows/build_wheels.ymlclone the repo, install prereqs: rust,python,maturin; run wheels.ps1 or wheels.shHow to useSee the example notebookhere.Basic contract construction:When(case=[Deposit(by=Role("GUY1"),value=Constant(42000000),of_token=ADA,into_account=Role("GUY2"),then_continue_with=raw(Close())# or merkleized("some hash"))],timeout=TimeConst(999999999),timeout_continuation=Close())Building from sourceSeedevelopment.md