Saravanan666/pypi-org huggingface dataset:
Package: real-fractions
RealFractionsPython library who adds functions related to the operation and conversion of fractions in a string format, with specific classes depending on what needs to be done.Getting StartedThese instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.PrerequisitesMake sure you have Python and that the expected version is available from your command line. You can check this by running:python--versionYou should get some output likePython 3.6.3. If you do not have Python, please install the latest 3.x version frompython.orgAdditionally, you’ll need to make sure you have pip available. You can check this by running:pip--versionIf you installed Python from source, with an installer frompython.orgyou should already have pip. If you’re on Linux and installed using your OS package manager, you may have to install pip separately, see Installingpip/setuptools/wheel with Linux Package Managers.If pip isn’t already installed, then first try to bootstrap it from the standard library:python-mensurepip--default-pipWhile pip alone is sufficient to install from pre-built binary archives, up to date copies of the setuptools and wheel projects are useful to ensure you can also install from source archives:python-mpipinstall--upgradepipsetuptoolswheelInstallingTo install the latest version of RealFractions:pipinstall-Ureal-fractionsAnd then you can import this library in Python:fromreal_fractionsimportconvertfraction="1/2"fraction=to_decimal(fraction)print(string)# Output: 0.5Or you can check the project inPyPI.Running the testsTo run automated module tests you first need to install py.test:pipinstall-Upy.testThen you must to download the source code of the module in hisgithub repository, go to the tests folder with PowerShell and run pytest:pytestSome test examplesThese are some examples of the automated testdeftest_simplify(self):"""Test simplify method from Fractions."""# Normal casesassertself.simplify("5/10")=="1/2"assertself.simplify("-12/4")=="-3/1"assertself.simplify("10/-2")=="-5/1"assertself.simplify("-20/-2")=="10/1"# Invalid argumentsassertself.simplify("10/0")isNoneassertself.simplify(True)isNoneassertself.simplify("Error")isNoneThis test is testing all the general cases of the functionsimplifyof the core module.Built WithPython- Programming language usedVS Code- Code editor usedTrello- Task manager usedContributingPlease readCONTRIBUTING.mdfor details on our code of conduct, and the process for submitting pull requests to us.VersioningWe useSemVerfor versioning. For the versions available, see thetags on this repository.AuthorsLucas Mosquera-Creator and maintainer-PurpleBoothSee also the list ofcontributorswho participated in this project.LicenseThis project is licensed under the MIT License - see theLICENSE.mdfile for detailsAcknowledgmentsThis is my second package that I publish as open source, it was a project that I proposed as a challenge to practice programming, I am still a junior programmer but I tried to do my best.
Thanks anyway for getting here, a kiss.
Package: realgas
RealGasSimple integration of real-gas effects into open source Chemical Engineering modeling and simulation environments.Chemical processes involving gas-phases, such as membrane separations,
adsorption separations, and heterogeneous catalysis, are ubiquitous.
These processes are typically modeled assuming that the gas-phase
is ideal and that component heat capacities can be approximated
by constant effective values.
The purpose of this software package is to allow these assumptions
to be relaxed by automating the tediousness of a real gas formulation.DocumentationThe online documentation is hosted atread the docs.ContributingPull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
Package: realityengine
realityengineis a library that makes it simple and easy to create games with python.
It is based ontkinterto create the window and for drawing graphics.
realityengine is open source ongithub!realityengine is in BETAso please expect bugs,
you can report them on our Github!Installationpip install realityengineHelpIf you are just getting started with realityengine,
you should be able to get started fairly quickly. There are a ton of great
and helpful tutorials out there which can help you get a head start.If you are experiencing issues it might be because you are using an older version of realityengine!
If so, you can always upgrade to the latest version of realityengine quickly by runningpip install realityengine--upgradein your terminal.If you’re ever stuck you can always look in the examples folder for
code samples and example code to help you on the way.CHANGELOG1.0.0 (26/07/2022)First Release1.1.0 (16/8/2022)Added basic line drawing capabilities with thedraw_line()methodYou can now get the tkinter canvas with theget_canvas()method in the screenAdded thetop,bottom,leftandrightproperties to gameobjectsWhen using therunfunction in the Window class it displays a message that tells you the version of realityengine.1.2.0 (12/11/2022)Added a way for gameobjects to render a spriteAdded adraw_spritemethod to theWindowclass for rendering images on their ownAdded abackground_imageproperty to theWindowclass
Package: real-json
python_js_jsonWrapper class so that you can accessdictandlistas easily as in JavascriptInstallationpython3 -m pip install real_jsonusage```python
import real_json
import json

data = {
    "a": 1,
    "b": 2,
    "c": {
        "d": 3,
        "e": 4,
    },
    "f": [5, 6, 7],
}
wrapped = real_json.ify(data)

# Test attribute access
assert wrapped.a == 1
assert wrapped.b == 2
assert wrapped.c.d == 3
assert wrapped.c.e == 4
assert wrapped.f[0] == 5
assert wrapped.f[1] == 6
assert wrapped.f[2] == 7
assert wrapped.f[3] == None
assert wrapped.g == None
assert wrapped.c.f == None

# Test item access
assert wrapped["a"] == 1
assert wrapped["b"] == 2
assert wrapped["c"]["d"] == 3
assert wrapped["c"]["e"] == 4
assert wrapped["f"][0] == 5
assert wrapped["f"][1] == 6
assert wrapped["f"][2] == 7
assert wrapped["g"] == None
assert wrapped["c"]["f"] == None

# Test set attribute
wrapped.a = 10
assert wrapped.a == 10
wrapped.g = 20
assert wrapped.g == 20

# Test set item
wrapped["b"] = 20
assert wrapped["b"] == 20
wrapped["h"] = 30
assert wrapped["h"] == 30

# Test str and repr
assert str(wrapped) == str(data)
assert repr(wrapped) == repr(data)

# Test len
print("wrapped:", wrapped)
assert len(wrapped) == 6
assert len(wrapped.c) == 2
assert len(wrapped.f) == 3

# Test bool
assert bool(wrapped) == True
assert bool(wrapped.g) == True
assert bool(wrapped.c) == True
assert bool(wrapped.f)

json.dump(wrapped.__dict__["_data"], "wrapped.json")

data = {
    "name": "John",
    "age": 30,
    "cars": [
        {"model": "Ford", "year": 2020},
        {"model": "BMW", "year": 2019}
    ]
}

wrapped_data = real_json.ify(data)

# Accessing values using dot notation
print(wrapped_data.name)  # Output: "John"
print(wrapped_data.age)  # Output: 30
# Output: [{"model": "Ford", "year": 2020}, {"model": "BMW", "year": 2019}]
print(wrapped_data.cars)

# Accessing values using square brackets notation
print(wrapped_data['name'])  # Output: "John"
print(wrapped_data['age'])  # Output: 30
# Output: [{"model": "Ford", "year": 2020}, {"model": "BMW", "year": 2019}]
print(wrapped_data['cars'])

# Accessing values that are not present in the data
print(wrapped_data.address)  # Output: None
print(wrapped_data['address'])  # Output: None

# Accessing elements of the list using index notation
print(wrapped_data.cars[0])  # Output: {"model": "Ford", "year": 2020}
print(wrapped_data['cars'][0])  # Output: {"model": "Ford", "year": 2020}

# Accessing elements of the list using index notation
print(wrapped_data.cars[0].model)  # Output: "Ford"
print(wrapped_data['cars'][0]['model'])  # Output: "Ford"

# Accessing elements of the list using index notation
print(wrapped_data.cars[2])  # Output: None
print(wrapped_data['cars'][2])  # Output: None

# Accessing elements of the list using index notation
print(wrapped_data.cars[0].color)  # Output: None
print(wrapped_data['cars'][0]['color'])  # Output: None

json.dump(wrapped_data.__dict__["_data"], "data.json")
```
Package: realkd
realkd.pyMethods for knowledge discovery from data and interpretable machine learning.
Currently, package contains primarily rule ensembles learners.>>> import pandas as pd
    >>> from sklearn.metrics import roc_auc_score
    >>> from realkd.rules import RuleBoostingEstimator, XGBRuleEstimator
    >>> titanic = pd.read_csv('../datasets/titanic/train.csv')
    >>> survived = titanic.Survived
    >>> titanic.drop(columns=['PassengerId', 'Name', 'Ticket', 'Cabin', 'Survived'], inplace=True)
    >>> re = RuleBoostingEstimator(base_learner=XGBRuleEstimator(loss=logistic_loss))
    >>> re.fit(titanic, survived.replace(0, -1), verbose=0)
       -1.4248 if Pclass>=2 & Sex==male
       +1.7471 if Pclass<=2 & Sex==female
       +2.5598 if Age<=19.0 & Fare>=7.8542 & Parch>=1.0 & Sex==male & SibSp<=1.0See the fulldocumentation.
Package: realm
Realmrealmis a Python open-source tool inspired bylernaandnx. It is designed to manage multiple Python packages/projects within the same Git repository. The primary focus is on running tasks across all projects in the repository and performing tasks on projects affected by specific changes.FeaturesPoetry Integration:realmis built to manage projects that usepoetry. Therefore, each project within the repository should have apyproject.tomlfile.Dependency Management:realmscans thepyproject.tomlfiles to identify localpathdependencies managed within the repository. If a project depends on a library, changes to that library will be considered when determining affected projects.Commandsrealm init:Initializes a newrealmrepository.realm install:Executespoetry installon all projects.realm ls:Lists all projects managed byrealm.realm run:Executes a command on all projects.realm task:Runs apoetrytask on projects containing that task (requirespoethepoet).FilteringYou can apply filters to affect only specific projects. For example, to install only changed projects:$realminstall--sinceorigin/masterAvailable filters:--since- Includes only projects changed since the specified reference.--scope- Includes only projects that match the given pattern.--ignore- Excludes projects that match the given pattern.--match- Filters projects by a field specified in the pyproject.toml file.Feel free to contribute, report issues, or suggest improvements. Happy coding withrealm!
Package: realm-cli
realm-cliA command line utitily to provide services offered by realm (a rust-elm web
framework).UsageTo create a new realm projectrealm-cli init <project_name>eg:realm-cli init helloTo build projectMove to the project directory and runrealm-cli buildIn our example:$ cd hello $ realm-cli buildTo get server up and running$ realm-cli debugDevelopmentUse local package:$ pip install -e .use blackblack realm-clifrom time to time.run test:realm-cli test.
Package: real-money
real-moneyMoney class for Python 3.7 and higher. Forked frompy-money. It has been
forked as the original library seems unmantained, and some of the currencies
have changed since the last update.Unlike other Python money classes, this class enforces that all monetary
amounts are represented with the correct number of decimal places for the
currency. For example, 3.678 USD is invalid, as is 5.5 JPY.InstallationInstall the latest release with:pipinstallreal-moneyIf you want to have localised formatting, you should install withBabel:pipinstallreal-money[babel]UsageAMoneyobject can be created with an amount (specified as a string) and a
currency from theCurrencyclass:frommoneyimportCurrency,Moneym=Money("9.95",Currency.GBP)m# GBP 9.95If you try to use more decimals than declared for the currency in theISO 4217standard, it will throw an error:m=Money("4.624",Currency.EUR)# InvalidAmountError: Invalid amount for currencym=Money("1200.5",Currency.JPY)# InvalidAmountError: Invalid amount for currencyMoneyobjects can also be created from and converted to sub units:m=Money.from_sub_units(499,Currency.USD)m# USD 4.99m.sub_units# 499Moneyis inmutable and supports most mathematical and logical operators:m=Money("10.00",Currency.USD)m/2# USD 5.00m+Money("3.00",Currency.USD)# USD 13.00m>Money("5.55",Currency.USD)# Truem<Money("5.55",Currency.USD)# FalseMoneywill automatically round to the correct number of decimal places for
the currency:m=Money("9.95",Currency.EUR)m*0.15# EUR 1.49m=Money("10",Currency.JPY)m/3# JPY 3Money can be formatted for different locales (if you haveBabel):Money("3.24",Currency.USD).format("en_US")# $3.24Money("9.95",Currency.EUR).format("es_ES")# 9,95 €Money("7.36",Currency.EUR).format("en_UK")# £7.36Money("94",Currency.JPY).format("ja_JP")# ￥94Moneydoes not support conversion between currencies. Mathematical and
logical operations between two money objects are only allowed if both objects
are of the same currency. Otherwise, an error will be thrown:Money("1.25",Currency.USD)+Money("2",Currency.EUR)# CurrencyMismatchError: Currencies must matchFor more examples, check out the test file!Acknowledgementsreal-moneyis a fork ofpy-money.Much of the code is borrowed fromcarlospalol/money. Much of the logic for
handling foreign currencies is taken fromsebastianbergmann/money. Money
formatting is powered byBabel.
Package: realmz
RealmzThis is a very small module built for a private project. Should you want to do more than the basis functionalities
supported by this package, then you are looking on the wrong place. A service component that will send birthday
wishes to employees. The service extracts a list of employees whose birthdays occur today using the Realm Digital
Employee API and create a generic message E.g. “Happy Birthday {name 1}, {name 2}” and send the message to an
email address configured for the component.https://interview-assessment-1.realmdigital.co.za/Example:from realmz import main as realmz_maindef test():realmz.start_wish()test()You’d input the database full path in case you’d like to save data to a database instead of a json file.
Please note that we currently only support sqlite.When prompted with options:BirthdayAnniversaryThis package uses ‘https://pypi.org/project/python-dotenv/’ to handle .env variable for this project.This package uses ‘https://pypi.org/project/schedule/’ to schedule the app, when and how it would run.
Package: realog
Atria Debugatria debugis a simple python librairy that permit to display application logs on console with a atria level.![Badge](https://badge.fury.io/py/realog.pngInstructionsSimply include the log system:from realog import debugConfigure the level:## Set log level of the console log system
## parameter: Value of the log level:
##              0: None
##              1: error
##              2: warning
##              3: info
##              4: debug
##              5: verbose
##              6: extreme_verbose
debug.set_level(6)Enable the color:enable_color()
disable_color()Use it:debug.error("lkjlkjlkj" + "kljhlkj" + str(1513))
debug.warning("lkjlkjlkj" + "kljhlkj" + str(1513))
debug.ingo("lkjlkjlkj" + "kljhlkj" + str(1513))
debug.debug("lkjlkjlkj" + "kljhlkj" + str(1513))
debug.verbose("lkjlkjlkj" + "kljhlkj" + str(1513))
debug.extreme_verbose("lkjlkjlkj" + "kljhlkj" + str(1513))git repositoryhttp://github.com/HeeroYui/realog/Documentationhttp://HeeroYui.github.io/realog/InstallationRequirements:Python >= 2.7andpipJust run:pip install realogInstall pip on debian/ubuntu:sudo apt-get install pipInstall pip on ARCH-linux:sudo pacman -S pipInstall pip on MacOs:sudo easy_install pipLicense (MPL v2.0)Copyright realog Edouard DUPINLicensed under the Mozilla Public License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License athttps://www.mozilla.org/MPL/2.0/Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
Package: realoot
READMEPreambuleThe application solves the averaged optimal minimum time orbit transfer problem. It is initially inspired by [MIPELEC] that uses the averaged optimal control formulation.
This application however includes important upgrade, such as:different terminal conditionsinclusion of zonal gravitational field perturbation to model secular evolution of node and apoapsis lines, around an oblate body.IMPORTANT WARNINGSThe optimal control is the solution of the averaged optimal control problem.It cannot be used as such for high fidelity propagation,It cannot currently be used for rendezvous problems (e.g. interplanetary)The solution starts diverging from the non-averaged optimal control problem solution for very large thrust accelerations.Running under pythonInstallation from repositorypip install realootThe module works with Python 3.Installation from sourcesPlease follow the instructions in COMPILE.Example UsageImportimport realoot.main as ltThen either, as for the application, open a script file withproblemDefinition, problemContext = lt.readXml("examples/ex2.xml")
	lt.solve(problemDefinition, problemContext, problemSolution, True)Or define manually your problem filling the structureproblemContext = lt.LtProblemContext()
	problemDefinition = lt.LtProblemDefinition()Then calllt.solve(problemDefinition, problemContext, problemSolution, True)Please see the examples for details.You will needmatplotlibto run the examples.CreditsMIPELECAn averaging optimal control tool for low thrust minimum-time transfers
Package: realpath
realpathLike os.path.realpath, but for Python objectsWARNING: This repo is in development. It was automatically generated withmkpylib. If you're reading this message, it means that I use this repo for my own purposes right now. It might not do anything at all; the default functionality isprint('TODO').If you really want to try it out, feel free. I recommend reading through the code and commit history to see if it does what you need, orask mefor status updates.Stay tuned!Installpython3 -m pip install -U realpathUsageimportrealpathprint('TODO')LicenseMITContactA library byShawn Presser. If you found it useful, please considerjoining my patreon!My Twitter DMs are always open; you shouldsend me one! It's the best way to reach me, and I'm always happy to hear from you.Twitter:@theshawwnPatreon:https://www.patreon.com/shawwnHN:sillysaurusxWebsite:shawwn.com
Package: realpy-feed
realpy-feedhttps://realpython.com/pypi-publish-python-package/The realpy-feed is a basicweb feedreader that can download the latest Real Python tutorials from theReal Python feed.For more information see the tutorialHow to Publish an Open-Source Python Package to PyPIon Real Python.InstallationYou can install the realpy-feed fromPyPI:python-mpipinstallrealpy-feedHow to useThe Feed Reader is a command line application, namedrealpy-feed. To see a list of thelatest Real Python tutorials, call the program without any arguments:$ realpy-feed
The latest tutorials from Real Python (https://realpython.com/)
 0 How to Publish an Open-Source Python Package to PyPI
 1 Python "while" Loops (Indefinite Iteration)
 2 Writing Comments in Python (Guide)
 3 Setting Up Python for Machine Learning on Windows
 4 Python Community Interview With Michael Kennedy
 5 Practical Text Classification With Python and Keras
 6 Getting Started With Testing in Python
 7 Python, Boto3, and AWS S3: Demystified
 8 Python's range() Function (Guide)
 9 Python Community Interview With Mike Grouchy
10 How to Round Numbers in Python
11 Building and Documenting Python REST APIs With Flask and Connexion - Part 2
12 Splitting, Concatenating, and Joining Strings in Python
13 Image Segmentation Using Color Spaces in OpenCV + Python
14 Python Community Interview With Mahdi Yusuf
15 Absolute vs Relative Imports in Python
16 Top 10 Must-Watch PyCon Talks
17 Logging in Python
18 The Best Python Books
19 Conditional Statements in PythonTo read one particular tutorial, call the program with the numerical ID of the tutorial as a parameter:$ realpy-feed 0
# How to Publish an Open-Source Python Package to PyPI

Python is famous for coming with batteries included. Sophisticated
capabilities are available in the standard library. You can find modules for
working with sockets, parsing CSV, JSON, and XML files, and working with
files and file paths.

However great the packages included with Python are, there are many
fantastic projects available outside the standard library. These are most
often hosted at the Python Packaging Index (PyPI), historically known as the
Cheese Shop. At PyPI, you can find everything from Hello World to advanced
deep learning libraries.

[... The full text of the article ...]You can also call the Python Feed Reader in your own Python code, by importing from thereaderpackage:>>> from reader import feed
>>> feed.get_titles("https://realpython.com/atom.xml")
['How to Publish an Open-Source Python Package to PyPI', ...]
Package: realpython-django-receipts
This is sample code used in the Real Python article [Writing an Installable Django App](???). The article describes how to take an app from an existing Django project and make it a stand-alone installable package avilable on PyPI.Installable AppThis app models a list of items on a receipt. Each item has a description and a cost. A receipt may reference multiple items.This app can be installed and used in your django project by:$pipinstallrealpython-django-receiptsEdit yoursettings.pyfile to include‘receipts’in theINSTALLED_APPSlisting.INSTALLED_APPS=[...'receipts',]Edit your projecturls.pyfile to import the URLs:url_patterns=[...path('receipts/',include('receipts.urls')),]Finally, add the models to your database:$./manage.pymakemigrationsreceiptsThe “project” BranchThemaster branchcontains the final code for the PyPI package. There is also aproject branchwhich shows the “before” case – the Django project before the app has been removed.Docs & SourceArticle:https://realpython.com/installable-django-app/Source:https://github.com/realpython/django-receiptsPyPI:https://pypi.org/project/realpython-django-receipts/