Saravanan666/pypi-org huggingface dataset:
Package: sadales-tikls-m2m
sadales-tikls-m2m-api-clientA client library for accessing Sadales Tikls M2M APIOpenAPISee preview inSwagger Editor online.Keep in mind that direct queries from browser won't work due to known CORS issue.UsageFirst, create a client:fromsadales_tikls_m2m_api_clientimportAuthenticatedClientclient=AuthenticatedClient(base_url="https://services.e-st.lv/m2m",token="SuperSecretToken")Now call your endpoint and use your models:fromsadales_tikls_m2m_api_clientimportAuthenticatedClientfromsadales_tikls_m2m_api_client.typesimportResponsefromsadales_tikls_m2m_api_client.api.defaultimportget_object_listfromsadales_tikls_m2m_api_client.modelsimportGetObjectListResponse200objects:GetObjectListResponse200=get_object_list.sync(client=client)# or if you need more info (e.g. status_code)response:Response[GetObjectListResponse200]=get_object_list.sync_detailed(client=client)Or do the same thing with an async version:fromsadales_tikls_m2m_api_clientimportAuthenticatedClientfromsadales_tikls_m2m_api_client.typesimportResponsefromsadales_tikls_m2m_api_client.api.defaultimportget_object_listfromsadales_tikls_m2m_api_client.modelsimportGetObjectListResponse200my_data:GetObjectListResponse200=awaitget_object_list.asyncio(client=client)response:Response[GetObjectListResponse200]=awaitget_object_list.asyncio_detailed(client=client)Things to know:Every path/method combo becomes a Python module with four functions:sync: Blocking request that returns parsed data (if successful) orNonesync_detailed: Blocking request that always returns aRequest, optionally withparsedset if the request was successful.asyncio: Likesyncbut the async instead of blockingasyncio_detailed: Likesync_detailedby async instead of blockingAll path/query params, and bodies become method arguments.If your endpoint had any tags on it, the first tag will be used as a module name for the function (my_tag above)Any endpoint which did not have a tag will be insadales_tikls_m2m_api_client.api.defaultBuilding / publishing this ClientThis project usesPoetryto manage dependencies  and packaging.  Here are the basics:Update the metadata in pyproject.toml (e.g. authors, version)If you're using a private repository, configure it with Poetrypoetry config repositories.<your-repository-name> <url-to-your-repository>poetry config http-basic.<your-repository-name> <username> <password>Publish the client withpoetry publish --build -r <your-repository-name>or, if for public PyPI, justpoetry publish --buildIf you want to install this client into another project without publishing it (e.g. for development) then:If that projectis using Poetry, you can simply dopoetry add <path-to-this-client>from that projectIf that project is not using Poetry:Build a wheel withpoetry build -f wheelInstall that wheel from the other projectpip install <path-to-wheel>
Package: sadam
SAdamSAdam (Scalable Adam) is an experimental optimizer that we
mathematically replace each parameters (p) in the model withp = a * exp(b)which means the convergence of Adam still holds since
we're implicitly optimizing theaandbInstallpip install sadamExampleimport torch
from torch.optim import Adam
from sadam import SAdam

optimizer_class = SAdam # Adam

inp = torch.tensor([[1., 0.], [0., 1.]])
tgt = torch.tensor([7000., 3000.])

model = torch.nn.Linear(2, 1, bias=False)
opt = optimizer_class(model.parameters(), lr=1e-3)

model.train()
for i in range(10000):
    pred = model(inp).view(-1)
    loss = torch.nn.functional.mse_loss(pred, tgt)

    opt.zero_grad()
    loss.backward()
    opt.step()

    if i % 100 == 0:
        print(i, pred, loss)Contact UsIf you have any suggestions or questions about this work, please feel free to leave an issue or send an email to thismailbox.License2023 Jijia WuThis repository is licensed under the MIT license. See LICENSE for details.
Package: sadbipws
sadbipws (Serializing And Deserializing Binarily Is Possible With
Sadbipws) is a binary data serializer, a bit like BSON (binary JSON),
except that it has more features. The current format definition is
defined in the Python code. The SADBIPWS format is not standardized.sadbipws is a Python 3.1+ module.Licensesadbipws is free software under the terms of the GNU General Public
License version 3 (or any later version). The author of sadbipws is
Niels Serup, contactable atns@metanohi.org. This is version 0.1.0 of
the module.InstallationTo install sadbipws, run:python3 setup.py installYou must be a superuser to do this.UseWhen sadbipws has been installed, it can be used just like any other
Python module. To see which parts of the module are useful, and to see
how those parts function, run:pydoc3 sadbipwssadbipwscan be imported with a simpleimportstatement.Developmentsadbipws uses Git for branches. To get the latest branch, download it
from gitorious.org like this:$ git clone git://gitorious.org/sadbipws/sadbipws.gitLogoThe sadbipws logo (located in thelogodirectory) has been put
into the public domain (or, if that is not possible, made available
under the Creative Commons Zero 1.0 license).This documentCopyright (C) 2011  Niels SerupCopying and distribution of this file, with or without modification,
are permitted in any medium without royalty provided the copyright
notice and this notice are preserved.  This file is offered as-is,
without any warranty.
Package: sadcat
My ssh config is hell. Even if its not much, its hell. I have ~190 host
entries which results in 1094(!) lines of sshconfig. Which I maintain
manually. Man-u-a-ll-y!Why is that?I use a lot of aliases to remember all my hosts. Which is probably my
fault but im used to it. A typical entry looked likeHost nyc-cexapsdrap21.company.com drap21 pdrap21
  Hostname nyc-cexapsdrap21.company.com
  User myuser
  Port 22
  IdentiyFile ~/.ssh/project_id_rsaYou can do a lot of stuff with wildcards in sshconfig. What you cant do
is having dynamic aliases (at least what I know). This would require a
templating like option.And thats why i wrote this tiny script.install & usageas usual.pipinstallsadcatsadcat~/.ssh/sadcat.tomlPersonally i use two aliases# set refresh aliasaliassshre="$SADCAT$HOME/.ssh/sadcat.toml >$HOME/.ssh/config"# set edit aliasaliassshedit="$EDITOR$HOME/.ssh/sadcat.toml"configrangesA minimal config would look like this.[hosts][hosts.nyc-dpzzt]hostname="nyc-dpzzt[01-03]"andsadcatgenerates 3 ssh entries for you callednyc-dpzzt01,nyc-dpzzt02andnyc-dpzzt03. Simple.templatesTo save more lines you can apply a template to a hosts group[hosts][hosts.twoleadingzeros]hostname="fra1024mfoo[001-005]"template="fra1024"[templates][templates.fra1024]user="otheruser"port="2202"Of course, setting a variable inhostswill always overwrite those
being set intemplates.There is a special template that is applied to every host if its
configured called “default”. ([templates.default])aliasesthose can be specified inhostsusing atomlarray if multiple
or a string. Range numbers (if available) will be applied at the end.
Thats just how i like it. Theres no deeper meaning.[hosts.hostsaliases]hostname="nyc-dpzzt[5-9]"template="company"alias=["dypppt","dzzzpt"]would result inHost nyc-dpzzt5 dypppt5 dzzzpt5
  hostname ...

Host nyc-dpzzt6 dypppt6 dzzzpt6
  hostname ...but as said,aliascan also be just a string[hosts.hostsaliases]hostname="nyc-dpzzt[5-9]"alias="dypppt"single hostsAs you might expected, if you dont have aRangedefined in a
hostname this entry will result in one single host.[hosts.singlehost]hostname="fra1024mfoo23"user="foo"customIf all that is still not enough flexibility, you can add custom snippets
to your ssh config by defining multiline strings in the[custom]section with full hosts.[custom]hostsb='''

Host bar.foo
  hostname bla
  user foo

Host foo.bar
  hostname foo
  user bar
  port par
'''strangehost='''

Host baz
  hostname baz
  port 666
  user evil
'''For more detailed examples seeconf.tomlin this repo.sadcat?I used a project name generator and liked it.
Package: sa-decor
sa_decorSQLAlchemy decorators for an optional connection/session dependency injection.usage with SQLAlchemy CoreYou can set a globalengineif you're using only one in your application.importsa_decorsa_decor.set_global_engine(my_engine)Annotate a function and add a named parameterconnection.fromsa_decorimportwith_connection@with_connection()deffoo(a,b,*,connection):...connection.execute(stmt)...If you're using multiple engines, you can provide them to each function separately.@with_connection(engine=my_other_engine)defbar(a,b,*,connection):...connection.execute(stmt)...Then either call the function without the parameter to let the decorator connect for you, or supply an existing connection.foo(1,2)foo(1,2,connection=my_connection)usage with SQLAlchemy ORM sessionsThere is a similar functionality available for ORM sessions, but you need to provide asessionmakerobject instead of anengineand add asessionparameter. You also need to choose whether the session should be committed when the function finishes or even when the function raises an exception.sa_decor.set_global_sessionmaker(my_sessionmaker)@with_session(commit=False)deffunction_that_only_queries_data(*,session):...session.execute(select_stmt)...@with_session(commit=True)deffunction_that_updates_the_db(*,session):...session.execute(insert_stmt)...raiseException# the insert WILL NOT be commited@with_session(force_commit=True)deffunction_that_commits_no_matter_what(*,session):...session.execute(insert_stmt)...raiseException# the insert WILL be commitedThe commit behaviour is ignored when the function is called with an existing session.function_that_commits_no_matter_what(session=my_session)# not commited automatically!my_session.commit()notesThis is the most useful when you have a bunch of functions that all rely on a connection/session but are sometimes called independently and sometimes from within a different function that also needs a connection.@with_connection()defget_stuff(*,connection):...@with_connection()defdo_stuff(*,connection):...get_stuff(connection=connection)# nested calls can use the same connection...# somewhere else in the code, e.g. an API controllerdefget():...stuff=get_stuff()...defpost():...result=do_stuff()...
Package: sadf
python-sadf provides a simple way to create system utilisation reports using sysstat and the Pandas api.Exampleimport sadf
from sadf import fieldgroups as fg

cmd = sadf.SadfCommand(start_time='09:00:00',
                       end_time='18:00:00')

cmd.field_groups = [
    fg.CPULoad(all_fields=True),
    fg.Queue(),
    fg.ProcessAndContextSwitch(),
    fg.IO(),
    fg.Memory(all_fields=True),
]

report = cmd.run()

memory_report = report.reports['memory']\
    .resample('30T').mean()

ldavg_report = report.reports['queue']\
    .resample('10T').rolling(window=3).mean()\
    .dropna()\
    .loc[:, ['ldavg-1', 'ldavg-5', 'ldavg-15']]AuthorJoshua Griffiths <jgriffiths@x86-64.io>LicenseApache - See LICENSE file
Package: sadice
Self-adjusting Dice LossThis is an unofficial PyTorch implementation of theDice Loss for Data-imbalanced NLP Taskspaper.UsageInstallationpipinstallsadiceText classification exampleimporttorchfromsadiceimportSelfAdjDiceLosscriterion=SelfAdjDiceLoss()# (batch_size, num_classes)logits=torch.rand(128,10,requires_grad=True)targets=torch.randint(0,10,size=(128,))loss=criterion(logits,targets)loss.backward()NER exampleimporttorchfromsadiceimportSelfAdjDiceLosscriterion=SelfAdjDiceLoss(reduction="none")# (batch_size, num_tokens, num_classes)logits=torch.rand(128,40,10,requires_grad=True)targets=torch.randint(0,10,size=(128,40))loss=criterion(logits.view(-1,10),targets.view(-1))loss=loss.reshape(-1,40).mean(-1).mean()loss.backward()
Package: sadie
Sadie: Stochastic Agents in DIscrete time and Euclidean spaceSadie is an agent-based modelling environment for stochastic agents in discrete time in Euclidean space. It is intended
to serve as a simple, convenient replacement for more complex agent-based modelling frameworks such as Repast and Mesa
where customisation and adaptation to specific use cases is required. In particular, Sadie is designed for simulating
random walks in various complex interactions, including Lévy walks, avoidant walks, homesick and other stochastic
mobility models in Euclidean space.Free software: MIT licenseDocumentation:https://sadie.readthedocs.io.FeaturesSpatial agents, including various random walk agentsTargetable objects, with target-following abilityModel objects with extensive ability to report and collate dataEasily extensible over a wide range of use cases in mobility, analytics, foraging, spatial statistics, epidemiology and many other areasCreditsThis package was created withCookiecutterand theaudreyr/cookiecutter-pypackageproject template.Sadieis named after Dickin medal winnerSadie, an explosives detection dog who saved hundreds of lives when detecting a secondary explosive charge after a bombing outside UN Headquarters, Kabul, Afghanistan, in November 2005.History0.1.0 (2020-08-28)First release
Package: sadie-antibody
SequencingAnalysis andData Library forImmunoinformaticsExplorationAboutDocumentation:https://sadie.jordanrwillis.comSource Code:https://github.com/jwillis0720/sadieColab:https://colab.research.google.com/github/jwillis0720/sadieSADIE is theSequencingAnalysis andData library forImmunoinformaticsExploration. The key feautures include:Provide pre-builtcommand line applicationsfor popular immunoinformatics applications.Provide alow-level API frameworkfor immunoinformatics developers to build higher level tools.Provide atestableandreusablelibrary that WORKS!Provide acustomizableandverifiedgermline reference library.Maintain data formats consistent with standards governed by theAIRR communityPortabilityready to use out the box.SADIE is billed as a "complete antibody library", not because it aims to do everything, but because it aims to meet the needs of all immunoinformatics users. SADIE contains both low, mid and high level functionality for immunoinformatics tools and workflows. You can use SADIE as a framework to develop your own tools, use many of the prebuilt contributed tools, or run it in a notebook to enable data exploration. In addition, SADIE aims to port all code to python because relies heavily on thePandaslibrary, the workhorse of the data science/machine learning age.InstallationInstallation is handled using the python package installerpip$pipinstallsadie-antibodyDevelopment installation.Pull requests are highly encouragedhere. The development installation usespre-commit,flake8linting andblackstyle formatting to maintain code readability and reausability.$gitclonegit@github.com/jwillis0720/sadie.git$pipinstallpoetry$poetryinstall--withdevQuick UsageConsult thedocumentationfor complete usage. Or checkout ourColabnotebookCommand Line UsageAnnotate antibody sequences only from functional human imgt antibodies to a gzip output$sadieairrmy_sequence.fastaAPIfromsadie.airrimportAirr# define a single sequencepg9_seq="""CAGCGATTAGTGGAGTCTGGGGGAGGCGTGGTCCAGCCTGGGTCGTCCCTGAGACTCTCCTGTGCAGCGTCCGGATTCGACTTCAGTAGACAAGGCATGCACTGGGTCCGCCAGGCTCCAGGCCAGGGGCTGGAGTGGGTGGCATTTATTAAATATGATGGAAGTGAGAAATATCATGCTGACTCCGTATGGGGCCGACTCAGCATCTCCAGAGACAATTCCAAGGATACGCTTTATCTCCAAATGAATAGCCTGAGAGTCGAGGACACGGCTACATATTTTTGTGTGAGAGAGGCTGGTGGGCCCGACTACCGTAATGGGTACAACTATTACGATTTCTATGATGGTTATTATAACTACCACTATATGGACGTCTGGGGCAAAGGGACCACGGTCACCGTCTCGAGC""".replace("\n","")# initialize the apiair_api=Airr("human")# run single sequence stringairr_table=air_api.run_single("PG9",pg9_seq)LicenseCopyright © Jordan R. Willis, Troy M. Sincomb & Caleb K. Kibet
Package: sadire
SADIRE: Sampling from scatter-plot visualizationsScatter plot-based representations of dimensionality reduction (such as t-SNE and UMAP) can help us to understand various patterns in high-dimensional datasets. However, due to the huge size of datasets in practical applications, these representations often result in cluttered layouts. With SADIRE, you can reduce the size of the dataset while preserving the context and structural relations imposed by dimensionality reduction techniques.RequirementsSADIRE uses a QuadTree for selecting representative data points, we chose Pyqtree for this matter:PyqtreeInstalationpip install sadireCitation@article{MarcilioJr2020_SADIRE,author="MarcÃ­lio-Jr, W. E. and Eler, D. M.",year="2020",title="SADIRE: a context-preserving sampling technique for dimensionality reduction visualizations",journal="Journal of Visualization",pages="999--1013"}UsageSADIRE samples from a 2D representation of a multidimensional dataset. It was designed to preserve the relationship imposed by a dimensionality reduction technique.Load a dataset and reduceiris_data=load_iris()X,y=iris_data.data,iris_data.targetReduce to 2Dreducer=umap.UMAP(random_state=0)embedding=reducer.fit_transform(X)Use SADIREimportsadire"""SADIRE uses the concept of windows to select samples and remove redundancy.* alpha is the size of the window* beta is the size of each block (or superpixel) in a windowThe greater are these parameters, more scattered will be the representative data points.Using alpha = 2 or 3 and beta between 4 and 10 works fine for the datasets we have tested.Please, see the paper for more details."""model=sadire.SADIRE(alpha=1,beta=3)# SADIRE returns the representative indicessamples=model.fit_transform(embedding)ExampleSee SADIRE on the MNIST dataset on top.SupportPlease, if you have any questions feel free to contact me atwilson_jr@outlook.com
Package: sadisplay
AboutSimple package for describing SQLAlchemy schema and display raw database
tables. Relation detecting byForeignKeycolumns.
Supports mapped class inherit. BSD licensed.Output formats:PlantUMLclass diagramDOTgraphviz directed graphsRequirementspython >= 2.5SQLAlchemy >= 0.5Installpip install sadisplayFrom bitbucket:pip install http://bitbucket.org/estin/sadisplay/get/tip.tar.gz
# or
easy_install http://bitbucket.org/estin/sadisplay/get/tip.tar.gzUsageWrite simple script in your project environment:import codecs
import sadisplay
from yourapp import model

desc = sadisplay.describe(
    [getattr(model, attr) for attr in dir(model)],
    show_methods=True,
    show_properties=True,
    show_indexes=True,
)
with codecs.open('schema.plantuml', 'w', encoding='utf-8') as f:
    f.write(sadisplay.plantuml(desc))
with codecs.open('schema.dot', 'w', encoding='utf-8') as f:
    f.write(sadisplay.dot(desc))

# Or only part of schema
desc = sadisplay.describe([model.User, model.Group, model.Persmission])
with codecs.open('auth.plantuml', 'w', encoding='utf-8') as f:
    f.write(sadisplay.plantuml(desc))
with codecs.open('auth.dot', 'w', encoding='utf-8') as f:
    f..write(sadisplay.dot(desc))Render PlantUML class diagram:$ java -jar plantuml.jar schema.plantuml

# or for svg format
$ java -jar plantuml.jar -Tsvg schema.plantumlRender graph by graphviz:$ dot -Tpng schema.dot > schema.pngAlso you can display you sql database tables by reflecting feature:$ sadisplay -u <URL connection string to db> -r dot > schema.dot
$ dot -Tpng schema.dot > schema.png
Package: saenopy
SAENOPYSAENOPY is a free open source 3D traction force microscopy software. Its material model is especially well suited for
tissue-mimicking and typically highly non-linear biopolymer matrices such as collagen, fibrin, or Matrigel.It features a python package to use in scripts and an extensive graphical user interface.Check out ourDocumentationon how to install and use it.InstallationStandaloneTo use saenopy without a complicated installation you can use our standalone binaries to get started right away on Windows or Linux.Windowshttps://github.com/rgerum/saenopy/releases/download/v1.0.2/saenopy.exeLinuxhttps://github.com/rgerum/saenopy/releases/download/v1.0.2/saenopyUsing PythonIf you are experienced with python or even want to use our Python API, you need to install saenopy as a python package.
Saenopy can be installed directly using pip:``pip install saenopy``Now you can start the user interface with:``saenopy``Getting startedTo get started you can have a look at our collection ofexample datasets.PreprintIf you want to cite saenopy you can reference our preprint.Dynamic traction force measurements of migrating immune cells in 3D matricesDavid Böhringer, Mar Cóndor, Lars Bischof, Tina Czerwinski, Andreas Bauer, Caroline Voskens, Silvia Budday,
Christoph Mark, Ben Fabry, Richard GerumbioRxiv 2022.11.16.516758; doi:https://doi.org/10.1101/2022.11.16.516758
Package: saeonobspy
saeonobspysaeonobspy is a Python package for interacting with theSouth African Environmental Observation Network(SAEON)observations databaseAPI. It provides a simple interface to view available datasets and download observation data.InstallationInstall saeonobspy using pip:pipinstallsaeonobspyAuthorisationTo use saeonobsr you need to first register an accountSAEON
observations database. Once
registered you need to login and retrieve an API token fromhttps://observations.saeon.ac.za/account/token. This token will be
valid for 1 month.Before starting set your API access token usingimportosos.environ["OBSDB_KEY"]="xxx"UsageBelow is an example of using the package to view available datasets and download a set of observations:importgeopandasasgpdfromsaeonobspyimportSAEONObsAPI# Initialize the APIsaeon_api=SAEONObsAPI()# View available datasetsdatasets_df=saeon_api.view_datasets()# Filter datasets by a specific area (optional)extent_gdf=gpd.read_file('path/to/extent/shapefile.shp')spatial_datasets_gdf=saeon_api.view_datasets(extent=extent_gdf,spatial=True)# Filter the datasets DataFrame based on your criteriafiltered_datasets_df=datasets_df[datasets_df['siteName']=='Constantiaberg']filtered_datasets_df=filtered_datasets_df[filtered_datasets_df['description']=='Air Temperature - Daily Minimum - Degrees Celsius']# Download observation dataobs_data=saeon_api.get_datasets(filtered_datasets_df,start_date='2020-01-01',end_date='2020-12-31')print(obs_data)For more information on how to use the package, please refer to the documentation in the source code.LicenseThis package is licensed under the MIT License. See the LICENSE file for more information.
Package: sae-python-dev
SAE Python development server - experimentalAll Rights Reserved 2011SAE Python Team目前支持的服务包括：mysql, taskqueue, memcache, storage, mail。大部分的服务直接运行dev_server.py进行调试就可以了，部分服务需要做一些配置。注意： 本工具仅为应用开发便利之用，对sae python环境的模拟并不完整。Install--------------sudo python setup.py install基本使用------------使用svn检出app代码之后，建立以数字为标识的发布目录，切换到发布目录:$ pwd/home/jaime/source/blackfire/1编辑index.wsgi和config.yaml:$ vi index.wsgiimport saedef app(environ, start_response):status = '200 OK'response_headers = [('Content-type', 'text/plain')]start_response(status, response_headers)return ['Hello, world! reloading test3']application = sae.create_wsgi_app(app)$ vi config.yaml---name: blackfireversion: 1...运行dev_server.py:$ dev_server.pyMySQL config not found: app.pyStart development server on http://localhost:8080/访问 http://localhost:8080 端口就可以看到Hello, world!了。使用MySQL服务----------------配置好MySQL本地开发server，使用 `--mysql` 参数运行dev_server.py。$ dev_server.py --mysql=user:password@host:port现在你可以在应用代码中像在SAE线上环境一样使用MySQL服务了。dev_server.py默认使用名为 `app_应用名` 的数据库。使用storage服务---------------使用 `--storage-path` 参数运行dev_server.py。$ dev_server.py --storage-path=/path/to/local/storage/data本地的storage服务使用以下的目录结构来模拟线上的storage。storage-path/domain1/key1key2domain2/domain3/--storage-path配置的路径下每个子文件夹会映射为storage中的一个domain，而每个子文件夹下的文件映射为domain下的一个key，其内容为对应key的数据。.. note:为方便调试，dev_server自带的sae.storage在某个domain不存在的情况下会自动创建该domain。线上环境中的domain需要在sae后台面板中手动创建。使用pylibmc--------------dev_server自带了一个dummy pylibmc，所以无须安装pylibmc就可以直接使用memcache服务了。该模块将所有的数据存贮在内存中，dev_server.py进程结束时，所有的数据都会丢失。使用kvdb----------------kvdb默认数据存在内存中，dev_server.py进程结束时，数据会全部丢失，如果需要保存数据，请使用如下命令行启动dev_server.py$ dev_server.py --kvdb-file=/path/to/kvdb/local/file