Saravanan666/pypi-org huggingface dataset:
Package: curtis
ConfigurationCurtis configuration live in an INI file namedcurtis.iniin the
current directory or in the.curtis.iniin your home directory.This file use the following format.[curtis]# define the default sitedefault_site=foo# settings for the foo site[site:foo]# sentry server URLurl=https://sentry.foo..example.com# sentry API token (this one is a fake one generated using the apg command)token=IvlayltajPamthelwaj1# settings for the bar site[site:bar]url=https://sentry.bar.example.orgtoken=TeinkutbicyeckyoQuoaInstallation$pipinstallcurtisUsageOnce you have installed curtis and created a configuration file, you can use the curtis command$curtis--helpUsage: curtis [OPTIONS] COMMAND [ARGS]...

Options:
  --config-file PATH
  --site TEXT
  --help              Show this message and exit.

Commands:
  assigned-issues              Show assigned issues
  assigned-issues-by-assignee  Show issues by assignee
  browse-unseen-issues         Browse unseen issues
  check-trends                 Show evolution stats for seen issues
  mark-as-seen                 Mark issues as seen
  merge-issues                 Merge related issues together
  needs-triage                 Show issues than needs triage
  resolve-issues               Resolve outdated issuesEach command have is one set of arguments usecurtis <command>--helpto display them.
Package: curtiscloudevents
Python SDK forCloudEventsStatusThis SDK is still considered a work in progress, therefore things might (and
will) break with every update.This SDK current supports the following versions of CloudEvents:v1.0v0.3Python SDKPackagecloudeventsprovides primitives to work with CloudEvents specification:https://github.com/cloudevents/spec.Sending CloudEventsBelow we will provide samples on how to send cloudevents using the popularrequestslibrary.Binary HTTP CloudEventfromcloudevents.httpimportCloudEvent,to_binary_httpimportrequests# This data defines a binary cloudeventattributes={"type":"com.example.sampletype1","source":"https://example.com/event-producer",}data={"message":"Hello World!"}event=CloudEvent(attributes,data)headers,body=to_binary_http(event)# POSTrequests.post("<some-url>",data=body,headers=headers)Structured HTTP CloudEventfromcloudevents.httpimportCloudEvent,to_structured_httpimportrequests# This data defines a structured cloudeventattributes={"type":"com.example.sampletype2","source":"https://example.com/event-producer",}data={"message":"Hello World!"}event=CloudEvent(attributes,data)headers,body=to_structured_http(event)# POSTrequests.post("<some-url>",data=body,headers=headers)You can find a complete example of turning a CloudEvent into a HTTP requestin the samples directory.Request to CloudEventThe code below shows how to consume a cloudevent using the popular python web frameworkflask:fromflaskimportFlask,requestfromcloudevents.httpimportfrom_httpapp=Flask(__name__)# create an endpoint at http://localhost:/3000/@app.route("/",methods=["POST"])defhome():# create a CloudEventevent=from_http(request.get_data(),request.headers)# you can access cloudevent fields as seen belowprint(f"Found{event['id']}from{event['source']}with type "f"{event['type']}and specversion{event['specversion']}")return"",204if__name__=="__main__":app.run(port=3000)You can find a complete example of turning a CloudEvent into a HTTP requestin the samples directory.SDK versioningThe goal of this package is to provide support for all released versions of CloudEvents, ideally while maintaining
the same API. It will use semantic versioning with following rules:MAJOR version increments when backwards incompatible changes is introduced.MINOR version increments when backwards compatible feature is introduced INCLUDING support for new CloudEvents version.PATCH version increments when a backwards compatible bug fix is introduced.CommunityThere are bi-weekly calls immediately following theServerless/CloudEvents
callat
9am PT (US Pacific). Which means they will typically start at 10am PT, but
if the other call ends early then the SDK call will start early as well.
See theCloudEvents meeting minutesto determine which week will have the call.Slack: #cloudeventssdk channel underCNCF's Slack workspace.Email:https://lists.cncf.io/g/cncf-cloudevents-sdkContact for additional information: Denis Makogon (@denysmakogonon slack).MaintenanceWe use black and isort for autoformatting. We setup a tox environment to reformat
the codebase.e.g.pipinstalltoxtox-ereformatFor information on releasing version bumps seeRELEASING.md
Package: curtis-engine
Curtis - The engineThe cardiovascular unified real-time intelligent system is an AI-based engine whose purpose is to analyze the cardiovascular health of a given person, this is done through ECG analysis (an existent ECG measuring system is needed to obtain the required values).How does it work?Curtis acts as an expert system, a rule-based program that emulates a real-life expert way of thinking about a certain topic, those rules were obtained for Curtis using the "decision tree approach", in which some existent data was given to a decision tree classifier, and it categorized the data into branches of rules and decisions.UsageFirst, install thecurtis-enginepackage:$pipinstallcurtis-engineTo start using Curtis, theCurtisEngineclass must be imported, as well asCurtisFactsfor the facts declaration:>>>fromcurtisimportCurtisEngine,CurtisFacts>>>curtis=CurtisEngine()After that, usecurtis.declare_factsmethod to declare a newCurtisFactsobject, which should contain all the ECG values needed for a diagnosis to be performed:>>>curtis.declare_facts(...CurtisFacts(...sex=1,...age=89,...height=140,...weight=30,...HR=56,...Pd=122,...PQ=164,...QRS=118,...QT=460,...QTcFra=451...)...)Finally, to get a diagnosis over the declared fact, use thecurtis.diagnosemethod:>>>diagnosis=curtis.diagnose()>>>print(diagnosis)60Thecurtis.diagnosemethod returns a number (as seen). This number is adiagnosis index, which means it's a unique index for a given diagnosis. To see which diagnosis belongs to that index, import thediagnosis_indexesdictionary from thecurtis.utils.encodingpackage, and use the diagnosis as the index:>>>fromcurtis.utils.encodingimportdiagnosis_indexes>>>print(diagnosis_indexes[diagnosis])UnifocalprematureventricularcomplexesAnd voilà! you've made your first Curtis diagnosis. 🎉DocsTo see the docs, you can clone the repo and open thedocsfolder to serve it as a website.Usingserve:$gitclonegithub.com/gantoreno/curtis-engine.git
$cdcurtis-engine
$servedocs/curtisThe documentation should now be available athttp://localhost:5000.LicenseThis project is licensed under theGNU GPLv3license.
Package: curtislast
curtislastA simple django app to demonstarate my understanding of djangoPrerequisites
What things you need to install the software atomicwrites==1.3.0 attrs==19.1.0 certifi==2019.6.16 chardet==3.0.4 coverage==4.5.3 Django==2.2.2 entrypoints==0.3 flake8==3.7.7 gunicorn==19.9.0 idna==2.8 importlib-metadata==0.18 mccabe==0.6.1 meld3==1.0.2 more-itertools==7.1.0 packaging==19.0 pluggy==0.12.0 psycopg2==2.8.3 py==1.8.0 pycodestyle==2.5.0 pyflakes==2.1.1 pyparsing==2.4.0 pytest==5.0.0 pytest-cov==2.7.1 pytz==2019.1 requests==2.22.0 setproctitle==1.1.10 six==1.12.0 sqlparse==0.3.0 urllib3==1.25.3 wcwidth==0.1.7 zipp==0.5.1 django-prometheus==1.0.15Installing
A step by step series of examples that tell you how to get a development env running install a virtual env clone this project to your virtual run dockerRunning the tests
run tox run coverage run --source='.' manage.py test coverage report htmDeployment
Built With
Versioning
1.0.0Authors
cuttice odhiamboLicense
This project is licensed under the MIT License - see the LICENSE.md file for details
Package: curtsies
Curtsies is a Python 3.6+ compatible library for interacting with the terminal.
This is what using (nearly every feature of) curtsies looks like:importrandomimportsysfromcurtsiesimportFullscreenWindow,Input,FSArrayfromcurtsies.fmtfuncsimportred,bold,green,on_blue,yellowprint(yellow('this prints normally, not to the alternate screen'))withFullscreenWindow()aswindow:a=FSArray(window.height,window.width)msg=red(on_blue(bold('Press escape to exit, space to clear.')))a[0:1,0:msg.width]=[msg]window.render_to_terminal(a)withInput()asinput_generator:forcininput_generator:ifc=='<ESC>':breakelifc=='<SPACE>':a=FSArray(window.height,window.width)else:s=repr(c)row=random.choice(range(window.height))column=random.choice(range(window.width-len(s)))color=random.choice([red,green,on_blue,yellow])a[row,column:column+len(s)]=[color(s)]window.render_to_terminal(a)Paste it in asomething.pyfile and try it out!Installation:pip install curtsiesDocumentationPrimerFmtStrobjects are strings formatted with
colors and styles displayable in a terminal withANSI escape sequences.FSArrayobjects contain multiple such strings
with each formatted string on its own row, and FSArray
objects can be superimposed on each other
to build complex grids of colored and styled characters through composition.(the import statement shown below is outdated)Such grids of characters can be rendered to the terminal in alternate screen mode
(no history, likeVim,topetc.) byFullscreenWindowobjects
or normal history-preserving screen byCursorAwareWindowobjects.
User keyboard input events like pressing the up arrow key are detected by anInputobject.ExamplesTic-Tac-ToeAvoid the X's gameBpython-curtsies uses curtsiesMore examplesAboutCurtsies DocumentationCurtsies was written to forbpython-curtsies#bpythonon irc is a good place to talk about Curtsies, but feel free
to open an issue if you're having a problem!Thanks to the many contributors!If all you need are colored strings, consider one of theseother
libraries!
Package: curtxt-reader
Curses txt readerAboutA simple(?) ncurses-based plain text reader written in python.InstalationFrom PyPI:$ pip install curtxt-readerFrom source:$ git clone https://github.com/1256-bits/curses-txt-reader.git
$ cd curses-txt-reader
$ pip install .UsageCurses txt reader accepts text from both stdin via pipes$ echo something | curtxtand a (single) file$ curtxt file.txtWhen presented with both stdin and a file at the same time it will open the file.
Curses txt reader does not accept multiple files. Use cat instead.
Previously opened files will open on the same page they were left offControls:Arrow Up/Down - page up and down[page number]g - go to a page with specified numberQ - quit (Ctrl+C is also fine)B - toggle progress barHome - got to the first pageEnd - go to the last pageCommand line options:-h, --help - pring help message and exit
-v, --version - print version number and exit
-c, --clear - clear history file
Package: curva
Curva - ECIES based on AES and HKDFRepos:http://github.com/origamizyt/curvaSimple library for Elliptic-Curve Integrated Encryption Scheme with Rijndael and Hmac-based Key Deriviation Function.Replacement for blowcurve since blowfish is deprecated now.InstallationThis module usesecdsaandPyCryptodomemodule as backend. No DLLs are needed.This module is avaiable on PyPI:$ pip install curvaOr you can download the source .tar.gz and executesetup.pymanually:$ python setup.py installUsageThis module exposes interfaces for key agreement, signatures and encryptions.Use classcurva.Curvato access all interfaces:>>>c1=Curva()# create instance, generate keys>>>c2=Curva()Use itsexport/exportHexmethod to export local public key, andload/loadHexmethod to load remote public key:>>>c1.load(c2.export())# bytes>>>c2.loadHex(c1.exportHex())# hex stringAfter exchanging public keys, a shared secret can now be established:>>>c1.secret()==c2.secret()# shared secret (bytes)TrueUse thesign/verifymethod to create signatures and verify them:>>>data=b'data'>>>signature=c1.sign(data)>>>c2.verify(data,signature)True>>>c2.verify(b'attack!',signature)FalseUse theencrypt/decryptmethod to encrypt / decrypt data:>>>data=b'data'>>>encrypted=c1.encrypt(data)>>>c2.decrypt(encrypted)b'data'
Package: curve25519-donna
Curve25519 is a fast elliptic-curve key-agreement protocol, in which two
parties Alice and Bob each generate a (public,private) keypair, exchange
public keys, and can then compute the same shared key. Specifically, Alice
computes F(Aprivate, Bpublic), Bob computes F(Bprivate, Apublic), and both
get the same value (and nobody else can guess that shared value, even if they
know Apublic and Bpublic).This is a Python wrapper for the portable ‘curve25519-donna’ implementation
of this algorithm, written by Adam Langley, hosted athttp://code.google.com/p/curve25519-donna/
Package: curve2mesh
curve2meshOverviewcurve2meshis a Python module designed for generating 3D meshes from 2D curves. This module simplifies the process of revolving a 2D curve around the Z-axis to create a 3D mesh. It is optimized for performance with NumPy, but also works with standard Python math operations when NumPy is not available.FeaturesEase of Use: Simple interface for revolving 2D curves.Performance: Optimized with NumPy for efficient computation.Fallback Compatibility: Works with standard Python math operations in the absence of NumPy.Flexible: Suitable for a wide range of applications in graphics, modeling, and educational purposes.InstallationTo installcurve2mesh, simply run the following command:pipinstallcurve2meshOr Install directly from Github usingpipinstallgit+https://github.com/ckesanapalli/curve2meshNote: NumPy is an optional dependency but is recommended for performance enhancement.UsageHere's a basic example of how to use curve2mesh:fromcurve2meshimportrevolve_curveimportnumpyasnpimportmatplotlib.pyplotaspltfrommpl_toolkits.mplot3d.art3dimportPoly3DCollection# Sample 2D curve coordinatesx=np.linspace(0,1,100)z=x**2# Example curve (parabola)# Revolve the curveangle_count=50faces=revolve_curve(x,z,angle_count,revolve_angle=2*np.pi)# Plottingfig=plt.figure()ax=fig.add_subplot(111,projection='3d')ax.add_collection3d(Poly3DCollection(faces,facecolors='g',linewidths=1,alpha=0.5))ax.set_xlim(-x.max(),x.max())ax.set_ylim(-x.max(),x.max())ax.set_zlim(z.min(),z.max())plt.show()RequirementsPython 3.7+NumPy (optional but recommended)ContributingContributions tocurve2meshare welcome! Please read ourContributing Guidelinesfor details on how to submit pull requests, bug reports, and feature requests.LicenseThis project is licensed under the MIT License - see theLICENSEfile for details.AuthorsChaitanya Kesanapalli
Package: curveball
CurveballPredicting competition results from growth curvesThis open-source library and application implement the method described in:Ram Y, Dellus-Gur E, Bibi M, Karkare K, Obolski U, Feldman MW, Cooper TF, Berman J, Hadany L. (2019)Predicting microbial relative growth in a mixed culture from growth curve data.Proceedings of the National Academy of Sciences USAPlease see thedocumentationfor more information.
Package: curved
CurvedCurved is a Python module written in Rust that performs curve simplification. It has been heavily optimised, and currently performs better than the simplification algorithm inShapely. At the moment, only theRamer-Douglas-Peucker algorithmhas been implemented.The simplification is not limited to 2D shapes, unlike traditional implementations. It is possible to simplify the points of an N dimensional shape.InstallationSource, and limited binary packages are provided on PyPI. These can be installed via a simplepip install curved. Note, if installing from a source package, make sure you have a suitable Rust build environment available.Usageimportnumpyasnpimportcurved# Let's simplify a 1000 point circle down to just 33 pointst=np.linspace(0,2*np.pi,1000)points=np.vstack((np.cos(t),np.sin(t))).Tmask=curved.rdp(points,0.01)simplified=points[mask]ContributionsContributions are welcome. Please feel free to create issues for bugs or feature requests. If you have code to contribute, feel free to open a pull request.
Package: curve-distributions
Curve_distributionsDescriptionThis is Curve Distribution package read in data from a txt file. The txt file should have
one number (float) per line. The numbers are stored and according there are several functions
are present:Gaussian DistributionBinomial Distributionfunctions includes calculating mean,standard deviation,plotting in-from of histograms,getting
probability distribution function,plotting the normalized histogram of the data and a plot of
the probability density function along the same range,etc.ClassesGaussian distribution class for calculating and
visualizing a Gaussian distribution.Attributes:- mean (float) representing the mean value of the distribution
  - stdev (float) representing the standard deviation of the distribution
  - data_list (list of floats) a list of floats extracted from the data fileBinomial distribution class for calculating and
visualizing a Binomial distribution.Attributes:- mean (float) representing the mean value of the distribution
  - stdev (float) representing the standard deviation of the distribution
  - data_list (list of floats) a list of floats to be extracted from the data file
  - p (float) representing the probability of an event occurring
  - n (int) number of trialsFunctionsList of all the functions present that can be performed with either of the  Gaussian or Binomial
distributionsread_data_file(self,file_name)Function to read in data from a txt file. The txt file should have
one number (float) per line. The numbers are stored in the data attribute.Args:
      file_name (string): name of a file to read from

  Returns:
      Nonecalculate_mean(self)Function to calculate the mean of the data set.Args:
      None

  Returns:
      float: mean of the data setcalculate_stdev(self, sample=True)Function to calculate the standard deviation of the data set.Args:
      sample (bool): whether the data represents a sample or population

  Returns:
      float: standard deviation of the data setplot_histogram(self)Function to output a histogram of the instance variable data using
matplotlib pyplot library.Args:
      None

  Returns:
      Nonepdf(self, x)Probability density function calculator for the gaussian distribution.Args:
      x (float): point for calculating the probability density function


  Returns:
      float: probability density function outputplot_histogram_pdf(self, n_spaces=50)Function to plot the normalized histogram of the data and a plot of the
probability density function along the same rangeArgs:
      n_spaces (int): number of data points

  Returns:
      list: x values for the pdf plot
      list: y values for the pdf plot__add__(self, other)Function to add together two Gaussian distributionsArgs:
      other (Gaussian): Gaussian instance

  Returns:
      Gaussian: Gaussian distribution__repr__(self)Function to output the characteristics of the Gaussian instanceArgs:
      None

  Returns:
      string: characteristics of the GaussianInstallationStep 1: To install the packagepip install curve_distributionsStep 2: To import the package and classesfrom curve_distributions import Gaussian,Binomial
Package: curve-fit.annealing
Most curve fitting algorithms rely on local optimization routines. These demand good estimates of the fit parameters.Instead, this module allows to useglobal optimizationroutines ofscipy.optimizeto minimize the squared deviation function.InstallationThis module can be installed from PyPIpip3 install curve_fit.annealingExampleLet us fit a beat signal with two sinus functions, with a total of 6 free parameters.By default, thecurve_fitfunction of this module will use thescipy.optimize.dual_annealingmethod to find the global optimum of the curve fitting problem. The dual annealing algorithm requires bounds for the fitting parameters.
Other global optimization methods likescipy.optimize.basinhoppingrequire an initial guess of the parameters instead.import numpy as np
from matplotlib import pyplot as plt
from curve_fit import annealing

def f(x,p):
      # Sum of two sinus functions
      return p[0]*np.sin(p[1]*x + p[2]) + p[3]*np.sin(p[4]*x+p[5])


  xdata = np.linspace(-100,100,1000)
  ydata = f(xdata, [1, 1, 0, 1, 0.9, 0])

  plt.plot(xdata, ydata, label='data')
  bounds=[[0,2],[0,2],[0,2*np.pi],[0,2],[0,2],[0,2*np.pi]]

  result = annealing.curve_fit(f, xdata, ydata, bounds=bounds)

  p_opt = result.x # optimal fit parameters
  ydata_res = f(xdata, p_opt)
  plt.plot(xdata, ydata_res, label='fit')
  plt.legend()
  plt.grid()

  plt.show()Or usescipy.optimize.basinhoppingresult = annealing.curve_fit(f, xdata, ydata, method='basinhopping', x0=np.zeros(6))APIcurve_fit(f, xdata, ydata,[method='dual_annealing',args, kwargs])Fit functionfto data with selectable optimization method
fromscipy.optimize.Parameters:f: callableThe model function,f(xdata, p). The second argument holds the
fitting parameters.xdataarray_like or objectThe independent variable where the data is measured.
Should usually be an M-length sequence or an (k,M)-shaped array for
functions with k predictors, but can actually be any object.ydataarray_likeThe dependent data, a length M array - nominallyf(xdata,...).methodstrscipy.optimize method to use for non-linear least squares minimization.
Default is ‘dual_annealing’.args, kwargstuple and dict, optionalAdditional arguments passed to the optimization method.Returns:ReturnOptimizeResultobject. Thexattribute holds the fitting
parameters.
Package: curvefitting
Curve Fitting ToolAn easy-use and MATLAB-like graphical curve fitting tool, for Python, Jupyter Notebook and other environments.InstallpipinstallcurvefittingUsageimport this modulefromcurvefittingimportcftoolpop up the fitting windowcftool(globals())for more usages, see Help --> HelpPlease contact me through my e-mail:fanpeilin123@126.comIf you find it useful, please fork me onGithub.
Package: curve-method
The Curvature MethodA quantitative approach to select the optimal number of clusters in a dataset.Table of contentsIntroductionInstallationExamplesDependenciesReferencesLicenseIntroductionClustering is a major area in Unsupervised Machine Learning. In many
clustering algorithms, the number of desired clusters is given as a
parameter. Selecting a dataset's true cluster numberkcan be
challenging, as model accuracy increases with additional clusters, yet
too high of akvalue leads to overfitting, and a less meaningful model.
Because the value ofkhas a dramatic impact on clustering results,
it is important to select it carefully.The most common method of selecting a true cluster number is known as
the "Elbow Method", which involves manually selecting a point along an
evaluation graph that appears to contain the sharpest corner. There are
several problems with this approach, as it is empirical and requires direct
intervention. Additionally, the axes of the evaluation graph tend to lie on
significantly different scales, which makes it difficult to recognize the
optimalkvalue visually. In contrast, the Curvature Method is a recent
approach that quantitatively finds the optimalkvalue[1]. This
approach can be used in a broad range of clustering applications, further
decoupling the learning process from human intervention.InstallationThis project can be installed using pip:pip install curve-methodExamplesFirst, obtain a dataset as a 2D NumPy array. In these examples, we use themake_blobs()generator from Scikit-Learn to simulate a real dataset.fromsklearn.datasetsimportmake_blobsX,_=make_blobs(n_samples=10000,n_features=4,centers=5)EvaluationTo view the curvature index for eachkvalue up to a specified maximum,
use thecurve_scores()function.fromcurve_methodimportcurve_scorescurve_scores(X,k_max=10)Or, to obtain thekvalue with maximum curvature, use thetrue_k()function.fromcurve_methodimporttrue_ktrue_k(X,k_max=10)PlottingTo view the evaluation graph from the Curvature Method, use thescatter()function. If desired, points can be connected on the graph by
settingline=True.fromcurve_methodimportscatterscatter(X,k_max=12,line=False)As an alternative, use the polyfit() function to generate an evaluation
graph with a polynomial approximation. The degree of the polynomialncan be specified by settingdeg=n.fromcurve_methodimportpolyfitpolyfit(X,k_max=12,deg=3)DependenciesNumPyMatplotlibScikit-learnReferences[1] Zhang, Y., Mańdziuk, J., Quek, C.H. and Goh, B.W., 2017.
Curvature-based method for determining the number of clusters.
Information Sciences, 415, pp.414-428.LicenseThis project is licensed under the terms of the MIT License.