semvec/pypi-packages huggingface dataset:
fastapi_users_db_sync_sqlalchemy 5.0.0
FastAPI Users database adapter for Sync SQLAlchemy
Requires Python: >=3.7

# FastAPI Users - Database adapter for Sync SQLAlchemy ORM

<p align="center">
  <img src="https://raw.githubusercontent.com/frankie567/fastapi-users/master/logo.svg?sanitize=true" alt="FastAPI Users">
</p>

<p align="center">
    <em>Ready-to-use and customizable users management for FastAPI</em>
</p>

[![build](https://github.com/furkan-guvenc/fastapi-users-db-sync-sqlalchemy/workflows/Build/badge.svg)](https://github.com/fastapi-users/fastapi-users/actions)
[![codecov](https://codecov.io/gh/furkan-guvenc/fastapi-users-db-sync-sqlalchemy/branch/master/graph/badge.svg)](https://codecov.io/gh/furkan-guvenc/fastapi-users-db-sync-sqlalchemy)
[![PyPI version](https://badge.fury.io/py/fastapi-users-db-sync-sqlalchemy.svg)](https://badge.fury.io/py/fastapi-users-db-sync-sqlalchemy)
[![Downloads](https://pepy.tech/badge/fastapi-users-db-sync-sqlalchemy)](https://pepy.tech/project/fastapi-users-db-sync-sqlalchemy)
<p align="center">
<a href="https://github.com/sponsors/frankie567"><img src="https://md-buttons.francoisvoron.com/button.svg?text=Buy%20me%20a%20coffee%20%E2%98%95%EF%B8%8F&bg=ef4444&w=200&h=50"></a>
</p>

---

**Documentation**: <a href="https://fastapi-users.github.io/fastapi-users/" target="_blank">https://fastapi-users.github.io/fastapi-users/</a>

**Source Code**: <a href="https://github.com/fastapi-users/fastapi-users" target="_blank">https://github.com/fastapi-users/fastapi-users</a>

---

Add quickly a registration and authentication system to your [FastAPI](https://fastapi.tiangolo.com/) project. **FastAPI Users** is designed to be as customizable and adaptable as possible.

**Sub-package for SQLAlchemy ORM support in FastAPI Users.**

## Development

### Setup environment

We use [Hatch](https://hatch.pypa.io/latest/install/) to manage the development environment and production build. Ensure it's installed on your system.

### Run unit tests

You can run all the tests with:

```bash
hatch run test
```

### Format the code

Execute the following command to apply `isort` and `black` formatting:

```bash
hatch run lint
```

## License

This project is licensed under the terms of the MIT license.
cubic-spline 0.1.1
Cubic spline interpolation with Numba compatibility
Requires Python: >=3.7

# Cubic Spline Interpolation

This package carries out cubic spline interpolation. The intended use of this package is to solve dynamic decision problems of heterogeneous agents in conjunction with the [Sequence-Space Jacobian (SSJ) package](https://github.com/shade-econ/sequence-jacobian). 

The approach differs from the `CubicSpline` method of SciPy in that our package is compatible with Numba commands which increase performance in large problems. However, for now, the package is limited to the natural boundary condition.

In this package, we use basic spline interpolation of exactly degree 3, the cubic spline. We follow the methods found here: https://en.wikipedia.org/wiki/Spline_interpolation. We use the natural boundary condition, which is extends a straight line from the end points at the same slope as that end point. In formal terms, the second derivative at the end points is equal to 0. We make this choice to efficiently solve the interpolation problem. The natural boundary gives a tridiagonal matrix when the constraints are put in matrix form, and this allows for the Thomas algorithm to quickly solve the matrix problem. In SciPy, we can carry out the same interpolation and get very nearly the same results by running

```
interpolate.CubicSpline(x, y, bc_type='natural')
```

## Installation

`cubic_spline` runs on NumPy and Numba. The pacakge was developed with Python 3.9 with NumPy version 1.21 and Numba version 0.55. To install run the following command

```
pip install cubic-spline
```


## Using the Pacakge

`cubic_spline.py` and `tools.py` are the necessary files for carrying out cubic interpolation. Users will normally only need to interact with `cubic_spline` as it contains the high level wrapper functions. The other files, `vfi_demo` and `firm_engine`, provide an application of this cubic interpolation package to a heterogeneous firm optimization problem. `firm_engine` requires the SSJ pacakge to be installed. `vfi_demo` is a notebook that walks through the canonical lumpy investment problem with value function iteration making use of the `cubic_spline` methods.
samscore 1.34
SAMScore Similarity Metric


## SAMScore: A Semantic Structural Similarity Metric for Image Translation Evaluation

[Yunxiang Li](https://www.yunxiangli.top/), Meixu Chen, Wenxuan Yang, Kai Wang, [Jun Ma](https://scholar.google.com/citations?hl=zh-CN&user=bW1UV4IAAAAJ), [Alan C. Bovik](https://www.ece.utexas.edu/people/faculty/alan-bovik), [You Zhang](https://profiles.utsouthwestern.edu/profile/161901/you-zhang.html). 

<div>
    <a href="https://arxiv.org/pdf/2305.15367.pdf"><img src="https://info.arxiv.org/brand/images/brand-logo-primary.jpg" alt="Arxiv" width=85></a> 
      <br>
    <a href="https://colab.research.google.com/github/Kent0n-Li/SAMScore/blob/main/SAMScore.ipynb#scrollTo=mCidlfXu88UY"><img src="https://colab.research.google.com/assets/colab-badge.svg" alt="Open In Colab"></a>
  </div>

  
<img src='https://i.ibb.co/fqrRYdK/overview.jpg' width=1200>

### Quick start

Run `pip install samscore`.
```python
pip install samscore
pip install git+https://github.com/facebookresearch/segment-anything.git
```

The following Python code is all you need.
```python
import requests
import os
import samscore

def download_image(url, save_path):
    response = requests.get(url)
    response.raise_for_status()  # Raise an exception if the request was unsuccessful

    with open(save_path, 'wb') as file:
        file.write(response.content)
os.makedirs('imgs', exist_ok=True)
# Example usage
image_url = 'https://i.ibb.co/yFFg5pn/n02381460-20-real.png'
save_location = 'imgs/real.png'
download_image(image_url, save_location)

image_url = 'https://i.ibb.co/GCQ2jQy/n02381460-20-fake.png'
save_location = 'imgs/fake.png'
download_image(image_url, save_location)

## Initializing the model
SAMScore_Evaluation = samscore.SAMScore(model_type = "vit_b" )
samscore_result = SAMScore_Evaluation.evaluation_from_path(source_image_path='imgs/real.png',  generated_image_path='imgs/fake.png')

print('SAMScore: %.4f'%samscore_result)
```


## Citation

If you find this repository useful for your research, please use the following.

```
@inproceedings{li2023samscore,
  title={SAMScore: A Semantic Structural Similarity Metric for Image Translation Evaluation},
  author={Yunxiang Li, Meixu Chen, Wenxuan Yang, Kai Wang, Jun Ma, Alan C. Bovik, You Zhang},
  booktitle={arxiv},
  year={2023}
}
```