Saravanan666/pypi-org huggingface dataset:
Package: openmc-geometry-plot
Create axis slice plots of OpenMC geomtry:Interactive plots with hovertext :speech_balloon:Specify the zoom :mag:Color by materials or cells :art:Outline by materials or cells :pencil2:Switch plotting backends between 📉 MatPlotLib and 📈 PlotlyThis package is deployed onxsplot.comas part of theopenmc_plotsuite of plotting appsLocal installYou will need to first install openmc. There are several methods but perhaps the quickest is to use Conda.condainstall-cconda-forgeopenmcThen you can installopenmc_geometry_plotwith pippipinstallopenmc_geometry_plotUsageAfter installing run theopenmc_geometry_plotcommand from the terminal and the GUI should launch in a new browser window.
Package: openmcmc
openMCMCopenMCMC is a package for constructing Bayesian models from distributional components, and then doing parameter
estimation using Markov Chain Monte Carlo (MCMC) methods. The package supports a number of standard distributions used
in Bayesian modelling (e.g. Normal, gamma, uniform), and a number of simple functional forms for the parameters of
these distributions. For a model constructed in the toolbox, a number of different MCMC algorithms are available,
including simple random walk Metropolis-Hastings, manifold MALA, exact samplers for conjugate distribution choices,
and reversible-jump MCMC for parameters with an unknown dimensionality.Installing openMCMC as a packageSuppose you want to use this openMCMC package in a different project.
You can install it fromPyPithrough pippip install openmcmc.
Or you could clone the repository and install it from the source code. After activating the environment you want to
install openMCMC in, open a terminal, move to the main openMCMC folder
where pyproject.toml is located and runpip install ., optionally you can pass the-eflag is for editable mode.
All the main options, info and settings for the package are found in the pyproject.toml file which sits in this repo
as well.ExamplesFor some examples on how to use this package please check out theseExamplesContributionThis project welcomes contributions and suggestions. If you have a suggestion that would make this better you can
simply open an issue with a relevant title. Don't forget to give the project a star! Thanks again!For more details on contributing to this repository, see theContributing guide.LicensingDistributed under the Apache License Version 2.0. See thelicense filefor more information.
Package: openmc-mesh-tally-to-vtk
Convert an OpenMC mesh tally to a VTK file with optional unit conversionInstallationpipinstallopenmc-mesh-tally-to-vtkPython API UsageThe package can be used in conjunction with OpenMC to produce a VTK file of aopenmc.RegularMeshtally.The simplest example is to read in an OpenMC tally and write it out as a VTK file which can then be opened with programs likeParaview.fromopenmc_mesh_tally_to_vtkimportwrite_mesh_tally_to_vtkimportopenmc# assumes you have a statepoint file from the OpenMC simulationstatepoint=openmc.StatePoint('statepoint.3.h5')# assumes the statepoint file has a RegularMesh tally with a certain namemy_tally=statepoint.get_tally(name='tally_on_regular_mesh')# converts the tally result into a VTK filewrite_mesh_tally_to_vtk(tally=my_tally,filename="vtk_file_from_openmc_mesh.vtk",)AcknowledgeThis package is based on aGitHub Gist byby Patrick Shriwise
Package: openmc-plasma-source
OpenMC-plasma-sourceThis python-based package offers a collection of pre-builtOpenMCneutron sources for fusion applications.InstallationOpenMC is required to use this package.To install openmc-plasma-source, simply run:pip install openmc-plasma-sourceUsageTokamak SourceCreate a source with a spatial and temperature distribution of a tokamak plasma.
The OpenMC sources are ring sources which reduces the computational cost and the settings.xml file size.
Each source has its own strength (or probability that a neutron spawns in this location).The equations implemented here are taken fromthis paper.fromopenmc_plasma_sourceimportTokamakSourcemy_source=TokamakSource(elongation=1.557,ion_density_centre=1.09e20,ion_density_peaking_factor=1,ion_density_pedestal=1.09e20,ion_density_separatrix=3e19,ion_temperature_centre=45.9,ion_temperature_peaking_factor=8.06,ion_temperature_pedestal=6.09,ion_temperature_separatrix=0.1,major_radius=9.06,minor_radius=2.92258,pedestal_radius=0.8*2.92258,mode="H",shafranov_factor=0.44789,triangularity=0.270,ion_temperature_beta=6).make_openmc_sources()For a more complete example check out theexample script.Ring SourceCreate a ring source with temperature distribution of a 2000 eV plasma.fromopenmc_plasma_sourceimportFusionRingSourcemy_plasma=FusionRingSource(angles=(0.,6.28318530718),# input is in radiansradius=400,# units in cmtemperature=20000.,# ion temperature in eVfuel='DT'# or 'DD')Point SourceCreate a point source with temperature distribution of a 2000 eV plasma.fromopenmc_plasma_sourceimportFusionPointSourcemy_plasma=FusionPointSource(coordinate=(0,0,0),temperature=20000.,# ion temperature in eVfuel='DT'# or 'DD')TestingTo run the tests, simply runpytest tests/
Package: openmc-plot
A Python app for plotting OpenMC.This repository contains the source code for the OpenMC plot.Try the web app athttp://openmc-plot.xsplot.comThis repository contains:A PythonStreamlitbased GUI 🐍A Dockerfile that provides the hosting environment for the web app 🐳Plot geometryPlot sourcesPlot regular mesh talliesPlot weight windowsPlot cylindrical mesh talliesInstallFirst you will need toinstall OpenMCOpenMC_plot can then be install directly from the Python package index (PyPi) using pip.pip install openmc_plotUsageIn the terminal type ...openmc_plotYour default web browser should then load with the GUI.You will also need to haveOpenMC installed.Run web app locally (developers)To host your own local version ofxsplot.comyou will needDockerinstalled and then can build and run the Dockerfile
with the following commands.First clone the repositorygitclonehttps://github.com/fusion-energy/openmc_plotThen navigate into the repository foldercdopenmc_plotThen build the docker imagedockerbuild-topenmc_plot.Then run the docker imagedockerrun--networkhost-topenmc_plotThe URL of your locally hosted version should appear in the terminal, copy and paste this URL into a web browser address bar.Maintenance (developers)Pushing to the main branch of this repository triggers an automatic rebuild and
deployment of the new code using Google Cloud build atxsplot.com
Package: openmc-regular-mesh-plotter
A minimal Python package that plots slices of OpenMC regular mesh tallies with the model geometry.Features:straight_ruler: Axis units in in helpful units mm, cm, m, km:eyes: Supports all 3 viewing basis (xy, xz, yz):hocho: Automaticly finds central slice or allows user specified slice index:dart: Supports all values (mean, std_dev etc):black_square_button: Adds outlines for geometry cells or material at different pixel resolution:arrow_right_hook: Customisable by passing keywords to underlying matplotlib functions colorbar, contour and imshow:arrow_right_hook: supports further customisations throughtmatplotlib.rc():heavy_plus_sign: Add tally results together to get combined plot.|||Local installFirst you will need openmc installed, then you can install this package with pippipinstallopenmc_regular_mesh_plotterUsageSee theexamples folderfor example scriptsWeb AppThis package is deployed onxsplot.comas part of theopenmc_plotsuite of plotting apps
Package: openmc-tally-unit-converter
This Python package aims to help convert OpenMC tallies to user specified units.Installationpipinstallopenmc_tally_unit_converterUsageOpenMC tally results are save into a statepoint h5 file without units.This package ascertains the base units of common tallies by inspecting their
tally filters and scores.The following worked example is for a heating tally. Other supported tallies
are heating-local, flux, effective dose and damage-energy (used to find DPA)
tallies are also supported.importopenmc_tally_unit_converterasotucimportopenmc# loads up tally from an openmc statepoint output filestatepoint=openmc.StatePoint(filepath="statepoint.2.h5")my_tally=statepoint.get_tally(name="my_cell_heating_tally")# gets the base units of the tallytally=otuc.process_tally(tally=my_tally)print(tally)>>>218559.22320927electron_volt/source_particleThe package then allows users to scale the base tally units to different units. For example the package can easily convert cm to meters or electron volts to joules.converted_tally=otuc.process_tally(tally=my_tally,required_units="joules / source_particle")print(converted_tally)>>>3.50170481e-14Joules/source_particleAdditional inputs can be applied to normalize the the tallies and convert the
units further:The source strength of the source in particles per second can be specified with thestrength_strengthargument. This allows the tally results to be converted from the units of score per simulated particle to score per unit time (e.g seconds, hours, days etc).converted_tally=otuc.process_tally(tally=my_tally,source_strength=1e20,# input units for this argument are particles per secondrequired_units="joules / minute")print(converted_tally)>>>2.10102288e+08joules/source_particleThe volume of the cell in cm3 can also be specified with thevolumeargument. This allows the tally result to be converted from the base units to base units per unit volume.converted_tally=otuc.process_tally(tally=my_tally,source_strength=13458.3,# input units for this argument are particles per secondvolume=12,# input units are in cm3required_units="joules / second / meter **3")print(converted_tally)>>>3.92724948e-05Joules/meter**3/second:point_right:Further examples
Package: openmdao-extensions
OpenMDAO ExtensionsSet of specialized classes to handle specific methods using OpenMDAO framework.EgoboxEgorDriver: an OpenMDAO driver for Egor optimizer fromEgoboxlibraryEgoboxDOEDriver: an OpenMDAO driver for Mixint LHS DoE fromEgoboxlibraryOneraSegoDriver: an OpenMDAO driver for Onera Super EGO optimizersSmtDOEDriver: an OpenMDAO driver for sampling methods from surrogateSMTlibrarySalibDOEDriver: an OpenMDAO driver for Morris or Saltelli DoE from sensitive analysisSALiblibraryOpenturnsDoeDriver: an OpenMDAO driver for DoE following distributions fromOpenTURNSlibraryRecklessNonlinearBlockGS: a specialized version of theNonlinearBlockGSsolver to select variables used in the convergence criterion.Installationpipinstallopenmdao-extensionsLicenseLicensed under the Apache 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 athttp://www.apache.org/licenses/LICENSE-2.0Unless 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: openmeeg
The OpenMEEG software is a C++ package for solving the forward
problems of electroencephalography (EEG) and magnetoencephalography (MEG).OpenMEEG is distributed under the French opensource license CeCILL-B. It is
intended to give users the freedom to modify and redistribute the software.
It is therefore compatible with popular opensource licenses such as the GPL
and BSD licenses. The CeCILL-B license imposes to anybody distributing a
software incorporating OpenMEEG the obligation to give credits (by citing the
appropriate publications), in order for all contributions to be properly
identified and acknowledged.Cite this softwareThe references to be acknowledged areGramfort A, Papadopoulo T, Olivi E, Clerc M. OpenMEEG: opensource software for quasistatic
bioelectromagnetics. Biomedical engineering online (2010) vol. 9 (1) pp. 45

Kybic J, Clerc M, Abboud T, Faugeras O, Keriven R, Papadopoulo T. Generalized head models for MEG/EEG: boundary element method
beyond nested volumes. Phys. Med. Biol. (2006) vol. 51 pp. 1333-1346
Package: openmesh
OpenMesh Python Bindings (1.2.1)OpenMesh is a versatile halfedge-based data structure for representing and manipulating polygon meshes.
The OpenMesh Python bindings are are tightly integrated withnumpyand are implemented usingpybind11.Exampleimportopenmeshasomimportnumpyasnpmesh=om.TriMesh()# add a a couple of vertices to the meshvh0=mesh.add_vertex([0,1,0])vh1=mesh.add_vertex([1,0,0])vh2=mesh.add_vertex([2,1,0])vh3=mesh.add_vertex([0,-1,0])vh4=mesh.add_vertex([2,-1,0])# add a couple of faces to the meshfh0=mesh.add_face(vh0,vh1,vh2)fh1=mesh.add_face(vh1,vh3,vh4)fh2=mesh.add_face(vh0,vh3,vh1)# add another face to the mesh, this time using a listvh_list=[vh2,vh1,vh4]fh3=mesh.add_face(vh_list)#  0 ==== 2#  |\  0 /|#  | \  / |#  |2  1 3|#  | /  \ |#  |/  1 \|#  3 ==== 4# get the point with vertex handle vh0point=mesh.point(vh0)# get all points of the meshpoint_array=mesh.points()# translate the mesh along the x-axispoint_array+=np.array([1,0,0])# write and read meshesom.write_mesh('test.off',mesh)mesh_2=om.read_trimesh('test.off')For further examples see the documentation or refer to theunit tests.InstallationUsingpippip install openmeshUsingcondaThanks to Martin Drawitsch you can also install openmesh-python viaconda:conda install -c conda-forge openmesh-pythonBuilding from sourcerecursively clone the repocdto repo dirensure the correct virtualenv is activatedpip install -e .
Package: openmeta
pythonic file tagging==========================Simple-to-trivial wrapper for OpenMeta_. Rather than re-implementing OpenMetausing, say, Bob Ippolito's excellent xattr_, I decided to do it by wrappingthe already-functional CLI binary, on advice from those more experienced thanmyself who suggested that the pain in getting OpenMeta working as advertisedfrom the direct xattr business was great and terrible.Warning - this thing does rely on parsing the output of CLI apps, with theflakiness and performance troubles that implies. However, it's workingreliably for me.Usage----->>> import openmeta>>> open('./test.txt', 'w').close()>>> openmeta.set_tags('./test.txt', ['foo', 'bar'])>>> openmeta.get_meta('./test.txt')['tags']['foo', 'bar']TODO-----* more graceful error message when the openmeta CLI binary is not installedCredits-------- OpenMeta_- xattr_.. _OpenMeta: http://code.google.com/p/openmeta/.. _xattr: http://undefined.org/python/#xattrNews====0.1.1dev------*Release date: 16-March-2011** update email to allow upload, and bump version accordingly0.1dev------*Release date: 16-March-2011** I spin this package off https://bitbucket.org/howthebodyworks/possumpalace_kit/src/23e924ba53e8/_lib/citeulike/
Package: openmetadata-ingestion
—
This guide will help you setup the Ingestion framework and connectors
—![Python version 3.7+](https://img.shields.io/badge/python-3.7%2B-blue)OpenMetadata Ingestion is a simple framework to build connectors and ingest metadata of various systems through OpenMetadata APIs. It could be used in an orchestration framework(e.g. Apache Airflow) to ingest metadata.PrerequisitesPython &gt;= 3.7.x### DocsPlease refer to the documentation herehttps://docs.open-metadata.org/connectors<img referrerpolicy=”no-referrer-when-downgrade” src=”https://static.scarf.sh/a.png?x-pxid=c1a30c7c-6dc7-4928-95bf-6ee08ca6aa6a” />
Package: openmetadata-ingestion-core
This guide will help you set up OpenMetadata Core ModelsThese models arepydanticmodels automatically generated from the
central JSON Schemas that define our APIs and Entities.PrerequisitesPython >= 3.8.xDocsPlease refer to the documentation herehttps://docs.open-metadata.org/connectorsContributionIn order to contribute to this package:cdingestion-core
python-mvirtualenvvenvsourcevenv/bin/activate
python-mpipinstall".[dev]"OBS: During development we might need to treat this in a different
virtual environment if we are yet to update the reference to the core
package inopenmetadata-ingestion.
Package: openmetadata-simplescheduler
OpenMetadata Simple SchedulerWe are going to build a library
based on simple scheduler for only cron-related ingestion purpose.Scheduleropenmetadata-simplescheduleris a flexible python library for building your own cron-like system to schedule jobs, which is to run a tornado process to serve REST APIs and a web ui.Try it NOWFrom source code:git clone https://github.com/open-metadata/simplescheduler.git
cd simplescheduler
make simpleOpen your browser and go tolocalhost:7777.How to build Your own cron-replacementInstall simpleschedulerUsing pip (from GitHub repo)#
# Put this in requirements.txt, then run
#    pip install -r requirements.txt
#

# If you want the latest build
git+https://github.com/open-metadata/simplescheduler.git#egg=simplescheduler


pip install -e git+https://github.com/open-metadata/simplescheduler.git#egg=simpleschedulerThree thingsYou have to implement three things for your scheduler, i.e.,Settings,Server, andJobs.SettingsIn your implementation, you need to provide a settings file to override default settings (e.g.,settings in simple_scheduler). You need to specify the python import path in the environment variableSIMPLESCHEDULER_SETTINGS_MODULEbefore running the server.All available settings can be found indefault_settings.pyfile.ServerYou need to have a server file to import and runsdscheduler.server.server.SchedulerServer.JobsEach job should be a standalone class that is a subclass ofsdscheduler.job.JobBaseand put the main logic of the job inrun()function.After you set upSettings,ServerandJobs, you can run the whole thing like this:SIMPLESCHEDULER_SETTINGS_MODULE=simple_scheduler.settings \
PYTHONPATH=.:$(PYTHONPATH) \
	    python simple_scheduler/scheduler.pyInstall dependencies# Each time we introduce a new dependency in setup.py, you have to run this
make installRun unit testsmake testClean everything and start from scratchmake clean
Package: openmeteo-py
openmeteopyDownload Meteorological Data from OPEN-METEO API (https://open-meteo.com/en)Open-Meteo collaborates with National Weather Services providing Open Data with 11 to 2 km resolution. Our high performance APIs select the best weather model for your location and provide data as a simple JSON API.APIs are free without any API key for open-source developers and non-commercial use. You can embed them directly into your app.What is it?openmeteopy is a client Python wrapper library for Open-Meteo  web API. It allows quick and easy consumption of OM data from Python applications via a simple object model and in a human-friendly fashion.openmeteopy runs on Python 3.6+.print(mgr.get_data())Options input parameterslatitude - Latitude (float)longitude - Longitude (float)windspeed_unit - wind speed unit (string, optional)precipitation_unit - precipitation amount units (string, optional)timeformat - If format unixtime is selected, all time values are returned in UNIX epoch time in seconds.
Please note that all time is then in UTC! For daily values with unix timestamp, please apply utc_offset_seconds again to get the correct date. (string, optional)timezone - If timezone is set, all timestamps are returned as local-time and data is returned starting at 0:00 local-time.
Any time zone name from the time zone database is available under timezones.py . (string, optional)past_days - If past_days is set, yesterdays or the day before yesterdays data are also returned.Installationgitclonehttps://github.com/m0rp43us/openmeteopycdopenmeteopy-main/
pip3install.ExampleDownload Meteorological datafromopenmeteo_py.HourlyimportHourly,Daily,Options,OWmanager# Latitude, Longitude for Rabat,Moroccolatitude=33.9842longitude=-6.8675hourly=Hourly()daily=Daily()options=Options(latitude,longitude)mgr=OWmanager(options,hourly.all(),daily.all())# Download datameteo=mgr.get_data()print(meteo)_Contributors (coding, testing, packaging, reporting issues) are welcome!
Package: open-meteo-weather-sample-jpcity
A sample Python projectPythonの配布パッケージの作り方と配布方法を学ぶためのサンプルパッケージ。USAGEpython -m open_meteo_weather_sample_jpcityToDo: 本パッケージが提供する機能を記載する。更新履歴0.0.dev2, 機能list_locations()を追加0.0.dev1, PyPIへの公開手順の試行のためのパッケージ作成。機能などの説明は後日にアップデート予定
Package: openmeter
OpenMeter Python SDK[https://pypi.org/project/openmeter](On PyPI)PrerequisitesPython version: >= 3.9InstallThe Python SDK is in preview mode.pipinstallopenmeterQuickstartThe client can be initialized withopenmeter.Client():fromosimportenvironfromopenmeterimportClientENDPOINT=environ.get("OPENMETER_ENDPOINT")or"http://localhost:8888"# it's recommended to also set the Accept header at the client levelclient=Client(endpoint=ENDPOINT,headers={"Accept":"application/json"},)Asyncclient can be initialized by importing theClientfromopenmeter.aio.Ingest events:fromcloudevents.httpimportCloudEventfromcloudevents.conversionimportto_dictevent=CloudEvent(attributes={"type":"tokens","source":"openmeter-python","subject":"user-id",},data={"prompt_tokens":5,"completion_tokens":10,"total_tokens":15,"model":"gpt-3.5-turbo",},)resp=client.ingest_events(to_dict(event))PublishUpdate version number inpyproject.toml.
Run the following commands:poetryconfigpypi-token.pypi{your_pypi_api_token}poetrypublish--build
Package: openmeter-client
OpenMeter ClientA Python client to interact with the OpenMeter API endpoints.InstallationYou can install the OpenMeter Client with pip using:pipinstallopenmeter_clientInitialization and usagefromopenmeterimportOpenMeterClientclient=OpenMeterClient('your_access_token')For more details and examples please check outhttps://openmeter-python-client.readthedocs.io/en/latest/openmeter.html#openmeter.client.OpenMeterClient
Package: openmetrics-liveness-probe
openmetrics-liveness-probeБиблиотека для получения времени, когда сервис в последний раз считался живым.
Результат экспортируется в формате OpenMetrics. Пример вывода:# HELP liveness_probe_unixtime Unixtime последней liveness probe
# TYPE liveness_probe_unixtime gauge
liveness_probe_unixtime{service="test"} 1.659455742252334e+09В многопоточном режиме:# HELP liveness_probe_unixtime Multiprocess metric
# TYPE liveness_probe_unixtime gauge
liveness_probe_unixtime{pid="12821",service="example"} 1.6596198592194734e+09
liveness_probe_unixtime{pid="13521",service="example"} 1.6796198592194734e+09Для начала необходимо объявить переменные окружения:OPENMETRICS_LIVENESS_PROBE_ENABLED=True
OPENMETRICS_LIVENESS_PROBE_HOST=0.0.0.0
OPENMETRICS_LIVENESS_PROBE_PORT=8000
OPENMETRICS_LIVENESS_PROBE_SERVICE_NAME=example
OPENMETRICS_LIVENESS_PROBE_NAME_POSTFIX=liveness_probe_unixtime
OPENMETRICS_LIVENESS_PROBE_ENABLE_DEFAULT_PROMETHEUS_METRICS=False
PROMETHEUS_MULTIPROC_DIR=NoneВсе переменные по-умолчанию будут равны значениям, указанным в списке выше, Но переменная окруженияSERVICE_NAMEдолжна быть обязательно изменена.Переменная окруженияENABLE_DEFAULT_PROMETHEUS_METRICSвключает метрики по-умолчанию доступные вprometheus_client:PROCESS_COLLECTOR,PLATFORM_COLLECTOR,GC_COLLECTOR.По-умолчанию их отображение выключено.Переменная окруженияPROMETHEUS_MULTIPROC_DIRпозволяет запускать prometheus сервер в многопоточном режиме. По умолчанию эта переменная равнаNone.Для активации этого режима нужно задать путь для переменной окруженияPROMETHEUS_MULTIPROC_DIR, например:/tmp.СодержаниеУстановкаУстановкаОписание установкиpippip install openmetrics_liveness_probe