Saravanan666/pypi-org huggingface dataset:
Package: ocfl-py
ocfl-pyis a Python reference implementation of the Oxford Common File Layout
(OCFL). It also provides a number of command-line tools that may be useful for
validating and manipulating OCFL Objects and OCFL Storage Roots. The code
attempts to follow the currentDraft OCFL specification v1.1while retaining support forv1.0. Seeimplementation status for errors and warningsfor
details of validator support.See alsoOCFL-Corewhich is another Python implementation
of OCFL, designed to support the InvenioRDM repository, andother OCFL implementations.InstallingThis code requires Python 3.This code attempts to support the OCFL specifications v1.1 draft and v1.0. To get
the most up to date version check out themainbranch from github.I hope to keep a fairly current version onPyPI, which can be installed or upgraded
with:pip install –upgrade ocfl-pyThe latest version is in themainbranch ongithub.UseThere should then be four command-line scripts available:ocfl-validate.py- validate OCFL objects, OCFL storage roots or standalone OCFL inventory filesocfl-object.py- build, manipulate, extract from or validate an OCFL objectocfl-store.py- add or access OCFL objects under an OCFL storage rootocfl-sidecar.py- update OCFL inventory sidecar file (useful for manually building examples and test cases)Each script takes-hfor help.Seeexamples in docs folderfor use of these scripts.The code is also available as a moduleocflfor other python code to use.ContributingBug reports welcome asgithub issues.SeeCONTRIBUTING.mdfor guidelines for contributing.Copyright and LicenseCopyright 2018–2022 Simeon Warner andcontributors.
Provided under the MIT license, seeLICENSE.txt.
Package: ocfl-rehydration
OCFL RehydrationOCFL Rehydration reconstitutes DRS objects from their OCFL representationThis tool has no dependencies on any external services such as the DRS database or storage.
The expectation is that the OCFL object root directory for a DRS object exists on local disk.
This tool takes as input the location of the OCFL object root directory and recreates the a representation of the DRS object in a form similar to what the depositor initially supplied in the DRS batch for ingest.
Specifically, the resultant object is created in a directory named after the supplied object name;
the data files are created with their supplied file names within directories named with their supplied names.BuildThe tool is a python command-line application that is designed to be run within a Docker container.
To build the Docker image:docker build -t rehydrate:latest .UsageTo run the application after a Docker image has been built as detailed above:docker run --rm --mount type=bind,source=${PWD},target=/tmp -it rehydrate -h

usage: main.py [-h] -i INPUT_DIR -o OUTPUT_DIR

Converts the OCFL form of a DRS Object and reconstitutes (rehydrates) a form expected by curators. The input is the OCFL
object root directory of object to rehydrate.

options:
  -h, --help            show this help message and exit
  -i INPUT_DIR, --input_dir INPUT_DIR
                        Local directory containing the OCFL Object root of the object to rehydrate
  -o OUTPUT_DIR, --output_dir OUTPUT_DIR
                        Local directory where rehydrated object will be writtenExampleThe directory '102559752' is the OCFL object root directory for a DRS object.
OCFL object root directories contain the top-level 'inventory.json', the object version namaste file (e.g. '0=ocfl_object_1.0') and OCFL version directories.docker run --rm --mount type=bind,source=${PWD},target=/tmp -it rehydrate -i /tmp/input/102559752 -o /tmp/output
Package: ocflzw-decompress
OCF LZW DecompressImplements "OCF decompresion" as used by Cerner.Python port ofhttps://gist.github.com/pgodwin/7d66729444173146ad698d154f2b9b6cfromocflzw_decompress.lzwimportLzwDecompresslzw=LzwDecompress()uncompressed=lzw.decompress(blob_contents)forbtinuncompressed:uncompressed_text+=chr(bt)uncompressed_text=uncompressed_text.rstrip('\x00')
Package: ocf-ml-metrics
ocf-ml-metricsCollection of simple baseline models and metrics for standardized evaluation of OCF forecasting models.This package computes a variety of baselines and error metrics
including persistence of both last value and last day of generation,
comparison to PVLive, and max and zero baselines.InstallationInstall withpip install ocf-ml-metricsUsageThe easiest way to use this package is to use the
convenience functionocf_ml_metrics.metrics.errors.compute_metricsthat
computes all the basic error metrics overall, with and without night time,
for different parts of the year, different times of day, and all forecast
horizons by default.There is alsoocf_ml_metrics.evaluation.evaluation.evaluationthat computes metrics after taking in a pandas
dataframe. These metrics are computed for the raw values, normalized values, against simple baseline models,
and per ID in the input dataframe. The input dataframe required data can be found in the docstringAnd example usage would befromocf_ml_metrics.evaluation.evaluationimportevaluationimportpandasaspdresults_df=pd.read_csv('<path to csv>')metrics:dict=evaluation(results_df=results_df,model_name='<model name>')
Package: ocgan
# Tensorflow Implementation of OCGAN
This repository provides a [Tensorflow](https://www.tensorflow.org/) implementation of theOCGANpresented in
CVPR 2019 paper “[OCGAN: One-class Novelty Detection Using GANs with Constrained Latent Representations](http://openaccess.thecvf.com/content_CVPR_2019/papers/Perera_OCGAN_One-Class_Novelty_Detection_Using_GANs_With_Constrained_Latent_Representations_CVPR_2019_paper.pdf)”.The author’s implementation ofOCGANin MXNet is at [here](https://github.com/PramuPerera/OCGAN).## Installation
This code is written inPython 3.5and tested withTensorflow 1.13.Install using pip or clone this repository.1. Installation using pip:`bash pip install ocgan `and`python from ocgan import OCGAN `Clone this repository:`bash git clonehttps://github.com/nuclearboy95/Deep-SVDD-Tensorflow.git`
Package: ocha-anticipy
OCHA AnticiPy: Access data for anticipating humanitarian riskOCHA AnticiPy is a Python library for simple downloading and processing
of data related to the anticipation of humanitarian risk,
from climate observations and forecasts to food insecurity.The datasets that we currently support are:CHIRPS rainfallCOD ABs (Common Operational Datasets administrative boundaries)FEWS NET food insecurityGloFAS river dischargeIRI seasonal rainfall forecastUSGS NDVI (normalized difference vegetation index)For more information, please see thedocumentation.InstallingInstall and update usingpip:pipinstallocha-anticipySome modules of the toolbox have specific dependencies not installed by default.
These are documented within each module, but all dependencies can be installed
using.pipinstall-Uocha-anticipy[full]A Simple ExampleOCHA AnticiPy downloads data to the directory referenced by the
environment variableOAP_DATA_DIR. Before beginning, please make
sure that this environment variable is defined and points to where you would
like the data to go.Next, you can simply download the admin boundary CODs for Nepal,
and retrieve provinces as a GeoDataFrame:fromochanticipyimportcreate_country_config,CodABcountry_config=create_country_config('npl')codab=CodAB(country_config=country_config)codab.download()provinces=codab.load(admin_level=1)ContributingFor guidance on setting up a development environment, see thecontributing guidelinesLinksDocumentationChangesPyPI ReleasesSource CodeIssue Tracker
Package: ochelper
A sample Python projectA sample project that exists as an aid to thePython Packaging User
Guide'sTutorial on Packaging and Distributing
Projects.This project does not aim to cover best practices for Python project
development as a whole. For example, it does not provide guidance or tool
recommendations for version control, documentation, or testing.The source for this project is available here.Most of the configuration for a Python project is done in thesetup.pyfile,
an example of which is included in this project. You should edit this file
accordingly to adapt this sample project to your needs.This is the README file for the project.The file should use UTF-8 encoding and can be written usingreStructuredTextormarkdownwith the appropriatekey set. It will be used to generate the project webpage on PyPI and will be
displayed as the project homepage on common code-hosting services, and should be
written for that purpose.Typical contents for this file would include an overview of the project, basic
usage examples, etc. Generally, including the project changelog in here is not a
good idea, although a simple “What's New” section for the most recent version
may be appropriate.
Package: ochlero
# OCHLEROOchlero is a script that monitors the systemd journal for specific events thattrigger publications on an MQTT queue."Ochlero" comes from "Ochlerotatus Triseriatus", a species of tree hole breedingmosquitoes (https://en.wikipedia.org/wiki/Ochlerotatus_triseriatus), iemosquitoes that like logs...## Running and testingOchlero is tested against and runs on python 2.7 and python 3.5.With python 2.x you need to install the systemd and mqtt wrappers on your system.On CentOS or Fedora, you can do so with the following command (extra repositoriessuch as EPEL might need to be activated):```bashsudo yum install systemd-python python-paho-mqtt```This is necessary due to a problem in the PyPI version of the systemd wrapper.With python 3.5, running```bashpip install -r requiremenits.txt```should be enough.To start ochlero, simply run```bashochlero -c /path/to/config/file.yaml```## The configuration fileOchlero uses a yaml configuration file to define the mosquitto service to publishto, and the processes and events to look for. See etc/ochlero.yaml for an example.### Writing patternsWhen ochlero is running, it will attempt to match log lines associated with a givenunit or command against patterns. A pattern is basically a regular expression.Please refer to python's documentation for details on syntax, for examplehttps://docs.python.org/2/howto/regex.htmlMost of the time, you will want to pick some information from the log line andpublish it to MQTT. These elements of interest are defined in the pattern likebash variables, ie "${ELEMENTNAME}. You must then define the regex matching foreach variable in the directive "where" of your event. For example:```yamlevents- name: hello worldpattern: "hello, my name is ${PERSON}"where:PERSON: [A-Za-z]+publish: "Hi ${PERSON}!"```A log message like "Hello, my name is Mark" will publish the message "Hi Mark!".### Predefined substitution typesTo make it easier for you, some substitutions are included in ochlero so you don'thave to write annoying regular expressions:* \_ALPHANUMERIC\_* \_INT\_* \_URL\_* \_EMAIL\_* \_IPv4\_* \_SYSLOGTIMESTAMP\_### Writing messages to publishVariables can be reused as they are in publish messages (see previous example). Somepredefined "macros" can also be used:* \_EPOCH\_ : the Unix Epoch timestamp at parsing time.## ContributingOchlero is developped in **Software Factory** and contributions follow a review workflow.To contribute:1. Log in once to Software Factory at https://softwarefactory-project.io2. Set up your ssh key in Gerrit's settings page3. Clone the project:```bashgit clone ssh://<your_username>@softwarefactory-project.io:29418/software-factory/ochlero.git```4. Set up git review```bashcd ochlero && git review -s```5. Work on your feature, make a commit, then send the review```bashgit commit -m'my feature' && git review```
Package: ochoneycomb
OpenCensus Python exporter for HoneycombA simple exporter to translate OpenCensus span data into Honeycomb traces.Exampleimporttimeimportosfromopencensus.traceimporttracerastracer_modulefromochoneycombimportHoneycombExporterexporter=HoneycombExporter(writekey=os.getenv("HONEYCOMB_WRITEKEY"),dataset=os.getenv("HONEYCOMB_DATASET"),service_name="test-app")# exporter = file_exporter.FileExporter(file_name='traces')# Initialize a tracer, by default using the `PrintExporter`tracer=tracer_module.Tracer(exporter=exporter)defdo_something_to_trace():time.sleep(1)# Example for creating nested spanswithtracer.span(name='span1')asspan1:do_something_to_trace()withtracer.span(name='span1_child1')asspan1_child1:span1_child1.add_annotation("something")do_something_to_trace()withtracer.span(name='span1_child2')asspan1_child2:do_something_to_trace()withtracer.span(name='span2')asspan2:do_something_to_trace()InstallpipinstallochoneycombRequirementspipinstallopencensus
pipinstalllibhoney
Package: ochre
ochre🏜️A down-to-earth approach to colorsochre is a tiny Python package for working with colors in a pragmatic way. The
focus is on simplicity and ease of use, but also on human perception.Features🎨 Focus onRGBandHCLcolor spaces🖥️Web color names♻️ Color conversions that easily integrate with thestandardcolorsysmodule🗑️ Zero dependencies🐍 Python 3.8+Installation$pipinstallochreUsageIn[1]:fromochreimportHexIn[2]:color=Hex("#CC7722")In[3]:color.web_colorOut[3]:WebColor('peru')In[4]:color=color.hclIn[5]:color.hueOut[5]:0.6373041934059377In[6]:importmathIn[7]:color.hue+=math.radians(30)In[8]:color.hueOut[8]:1.1609029690042365In[9]:color.web_colorOut[9]:WebColor('goldenrod')CreditsPhotobyNicola CarteronUnsplash.
Package: ochre-gym
OCHRE GymAll authors are with the National Renewable Energy Laboratory (NREL).OverviewOCHRE (pronounced "Oh-ker") Gym is a Gymnasium environment based on the purely Python-basedOCHREresidential energy building simulator. OCHRE is a high-fidelity, high-resolution residential building model developed by NREL with behind-the-meter DERs and flexible load models that integrates with controllers and distribution models in building-to-grid co-simulation platforms. It has been benchmarked against EnergyPlus to quantify the tradeoff between fidelity and speed. Read more about OCHREhere.OCHRE Gym features:No EnergyPlus; each Dwelling consists of multiple RC circuits implemented in pure PythonWorks with any building that OCHRE supports: get building models from NREL End-Use Load Profiles, ResStock, BEopt, etc.Flexible control of building equipment (HVAC, Water Heater)--support coming for DERs (PV, Battery, EV)Customizable observation space with equipment-level, building-level, and building metadataSimple reward: minimize cost of energy use while maintaining comfort3 different demand response (DR) cost functions: Real-Time Pricing (RTP), Time-of-Use (TOU), and Power Constraints (PC)Read our docsto get started quickly.InstallationInstall from PyPIpip install ochre_gym.Or,Install in editable mode withpip install -e .from the root of this repo.Usingcondaorvenv, create an environment withpython >= 3.9:conda create -n ochre_gym python=3.9.Clone this repo:git clone git@github.com/NREL/ochre_gym.gitcd ochre_gympip install -e .Test your installation withunittestby runningpython3 -m unittestfrom the root of this repo.Quick StartInit one of the provided buildings (e.g.,basic-v0) withochre_gym.load():importochre_gymenv=ochre_gym.load(env_name="basic-v0",)forstepinrange(1000):# Sample an action from the action spaceaction=env.action_space.sample()# Step the environment with the sampled actionobs,rew,terminated,truncated,info=env.step(action)# Check if the episode is doneifterminated:print("Episode finished after{}timesteps".format(step+1))breakTheochre_gym.load()function will handle creating the OCHRE building simulator instance using the properties, schedule, and weather files located inochre_gym/buildings/basic-v0.
Keyword arguments passed toloadcan be used to override the defaults in theochre_gym/buildings/defaults.tomlconfig file.Funding AcknowledgementThis work was authored by the National Renewable Energy Laboratory (NREL), operated by Alliance for Sustainable Energy, LLC, for the U.S. Department of Energy (DOE) under Contract No. DE-AC36-08GO28308. This work was supported by the Laboratory Directed Research and Development (LDRD) Program at NREL. The views expressed in the article do not necessarily represent the views of the DOE or the U.S. Government. The U.S. Government retains and the publisher, by accepting the article for publication, acknowledges that the U.S. Government retains a nonexclusive, paid-up, irrevocable, worldwide license to publish or reproduce the published form of this work, or allow others to do so, for U.S. Government purposes.
Package: ochsner-web2com
ochsner_web2comochsner_web2comis a Python module that read or write paramters of a web2com interface from ochser heat pump via SOAP requests.Exampleimportochsner_web2com.web2comasweb2com## Connect to a web2com server with default eBus and device id.w2c=web2com.Service('192.168.188.50','OEM','password')## Change the id's of ebus or device.w2c.set_eBus_id(1)w2c.set_device_id(2)## get value via chain idresult=w2c.get_value('/1/2/1/125/9')print(result)## set value via chain idresult=w2c.set_value('/1/2/4/99/6',20.0)print(result)## get value via predefined enumresult=w2c.get(web2com.HEAT_PUMP.Thermal_energy_kWh)print(result)## set value via predefined enumresult=w2c.set(web2com.HEATING_CIRCUIT.Normal_setpoint_room_temperature_heating,20.0)print(result)## get values via list of id's (eBus and device will be added)result=w2c.get([1,125,9])print(result)## set value via list of id's (eBus and device will be added)result=w2c.set([4,99,6],20.0)print(result)The first parameter of the result holds the HTTP result code
and the second paramter the value of the paramter.Paramter List:DescriptionID chainheat pump: State heat generator control/1/2/1/125/0heat pump: Flow temperature heat generator/1/2/1/125/1heat pump: Return flow temperature heat generator/1/2/1/125/2heat pump: Heat source outlet temperature/1/2/1/125/3heat pump: Heat source inlet temperature/1/2/1/125/4heat pump: Operation cycles/1/2/1/125/5heat pump: Operation hours/1/2/1/125/6heat pump: Volume flow heat energy/1/2/1/125/7heat pump: Flow rate heat source/1/2/1/125/8heat pump: Thermal energy kWh/1/2/1/125/9heat pump: Thermal energy MWh/1/2/1/125/10heat pump: Energy DHW kWh/1/2/1/125/11heat pump: Energy DHW MWh/1/2/1/125/12auxiliary: State heat generator control/1/2/2/126/0auxiliary: Flow temperature heat generator/1/2/2/126/1auxiliary: Operation cycles/1/2/2/126/2auxiliary: Operation hours/1/2/2/126/3auxiliary: Thermal energy kWh/1/2/2/126/4auxiliary: Thermal energy MWh/1/2/2/126/5heating circuit: State heating circuit control/1/2/4/119/0heating circuit: Outdoor temperature/1/2/4/119/1heating circuit: Outdoor temperature average value/1/2/4/119/2heating circuit: Setpoint room temperature/1/2/4/119/3heating circuit: Actual heating circuit flow temperature/1/2/4/119/4heating circuit: Setpoint heating circuit flow temperature/1/2/4/119/5DHW: State DHW control/1/2/7/121/0DHW: Actual DHW temperature/1/2/7/121/1DHW: DHW setpoint/1/2/7/121/2Manager: Storage tank temperature top/1/2/8/122/0Manager: Storage tank temperature center/1/2/8/122/1Manager: Plant flow temperature/1/2/8/122/2Manager: Plant CH setpoint flow temperature/1/2/8/122/3Manager: Heating power in heating mode/1/2/8/122/4Manager: Heating power in DHW mode/1/2/8/122/5Manager: State heating manager/1/2/8/122/6Default paramter:DescriptionIDeBus1device2
Package: oci
AboutThis is the Python SDK for Oracle Cloud Infrastructure. Supported Python versions are mentionedhere.>>>importoci# Set up config>>>config=oci.config.from_file(..."~/.oci/config",..."DEFAULT")# Create a service client>>>identity=oci.identity.IdentityClient(config)# Get the current user>>>user=identity.get_user(config["user"]).data>>>print(user){
  "compartment_id": "ocid1.tenancy.oc1...",
  "description": "Test user",
  "id": "ocid1.user.oc1...",
  "inactive_status": null,
  "lifecycle_state": "ACTIVE",
  "name": "test-user@corp.com",
  "time_created": "2016-08-30T23:46:44.680000+00:00"
}The project is open source and maintained by Oracle Corp. The home page for the project ishere.InstallationIt is highly recommended that a Python virtual environment be used when installing oci.Please consult theInstalling packages using pip and virtualenvguide from the Python Software Foundation for more information about virtual environments.Seethe installation guidefor installation troubleshooting and alternative install methods.Once your virtual environment is active, oci can be installed using pip.pip install ociDevelopmentSee thedevelopment readmefor information on how to make changes, run tests and build the documentation and wheel for the Python SDK.ExamplesExamples can be foundhere.DocumentationFull documentation, including prerequisites and installation and configuration instructions, can be foundhere.API reference can be foundhere.A downloadable version of the documentation is include with in the release zip, which can be foundhere.HelpSee the “Questions or Feedback” sectionhere.ChangesSeeCHANGELOG.Contributingoci-python-sdk is an open source project. SeeCONTRIBUTINGfor details.Oracle gratefully acknowledges the contributions to oci-python-sdk that have been made by the community.Known IssuesYou can find information on any known issues with the SDKhereand under the “Issues” tab of this
project’sGitHub repository.SurveyAre you a Developer using the OCI SDK? If so, please fill out our survey to help us make the OCI SDK better for you.
Clickherefor the survey page.LicenseCopyright (c) 2016, 2021, Oracle and/or its affiliates.  All rights reserved.
This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown athttps://oss.oracle.com/licenses/uplor Apache License 2.0 as shown athttp://www.apache.org/licenses/LICENSE-2.0. You may choose either license.SeeLICENSEfor more details.