semvec/pypi-packages huggingface dataset:
odim 0.1.33
Simple Python ORM/ODM specifically designed to be used with Pydantic and FastAPI
Requires Python: >=3.6

# odim
Simple Python ORM/ODM specifically designed to be used with Pydantic and FastAPI


## Simple syntax
In order to nicely work with databases you just create your Pydantic models. Odim does not care if it is 
MongoDB or SQL.


```python3
from pydantic import BaseModel

class MyModel(BaseModel):
    id : int
    field : str

    class Config:
        db_uri = "mongodb://user:pwd@10.0.0.1/db1"
        collection_name = "mymodel"
```
Then you can easily perform CRUD operations.

```python3
obj = MyModel(id=1, field="asdf 213")
await Odim(obj).save()

obj2 = await Odim(MyModel).get(123)

for x in await Odim(MyModel).find({"field" : "asdf 213"}):
  print(x)
  
await Odim(MyModel).count({"field" : 1})

```

In case you are using amazin FastAPI. We have our extended router, that gives you CRUD API endpoint

```python3
from odim.router import OdimRouter

router = OdimRouter()

router.mount_crud("/api/mymodel/", model=MyModel, tags=["mymodel"])
```

Or you can generate these API stubs with
```python3
router.generate("/api/mymodel/", model=MyModel, tags=["mymodel"])
```
fractal-network 0.0.2
Creating fractal networks
Requires Python: >=3.6

This package creates Fractal networks.

The steps for installationa are as follows:

1) pip install package_name
2) from fractal_network import NetworkGenerator
3) NetworkGenerator.graph(num_of_levels,num_of_nodes_in_a_clique)

OUTPUT:
A file will be created in the current directory having the name num_of_nodes_in_a_clique-num_of_levels.dat.
Example: If NetworkGenerator.graph(4,3) is entered then a dat file with name "3-4.dat" will be created.

Column 1: node number
Column 2: label
Column 3: Degree 

The next columns indicate the neighbour amd the level of connection between the node and neighbour alternately.
For example:

12 10110 3 10 2 13 1 14 1

12 is the node numer, 10110 is the label, 3 is the degree.

10 2 indicates a connection between 12 and 10 having level 2
13 1 indicates a connection between 12 and 13 having level 1
14 1 indicates a connection between 12 and 14 having level 1
hemlock-berlin 0.0.3
Hemlock extension for the adaptive Berlin numeracy test
Requires Python: >=3.6

# Hemlock-Berlin

Hemlock-Berlin is a <a href="https://dsbowen.github.io/hemlock" target="_blank">hemlock</a> extension which allows you to add a <a href="http://www.riskliteracy.org/" target="_blank"> Berlin numeracy test</a> to hemlock projects.

## Installation

With the hemlock-CLI (recommended):

```bash
$ hlk install hemlock-berlin
```

With pip:

```
$ pip install hemlock-berlin
```

## Quickstart

This example shows how to add an adaptive Berlin numeracy test to your hemlock survey and display the participant's score to him/her.

In `survey.py`:

```python
from flask_login import current_user
from hemlock import Branch, Page, Label, route
from hemlock_berlin import berlin

@route('/survey')
def start():
    return Branch(
        berlin(),
        Page(
            Label(compile=display_score), 
            terminal=True
        )
    )

def display_score(label):
    label.label = '<p>Berlin score: {}</p>'.format(
        current_user.g['BerlinScore']
    )
```

`app.py` is standard from the hemlock template.

Run the app with the hemlock command line interface:

```bash
hlk serve
```

or with python:

```bash
python app.py
```

## Citation

```
@software{bowen2020hemlock-berlin,
  author = {Dillon Bowen},
  title = {Hemlock-Berlin},
  url = {https://dsbowen.github.io/hemlock-berlin/},
  date = {2020-10-05},
}

@article{cokely2012measuring,
  title={Measuring risk literacy: The Berlin numeracy test.},
  author={Cokely, Edward T and Galesic, Mirta and Schulz, Eric and Ghazal, Saima and Garcia-Retamero, Rocio},
  journal={Judgment and Decision making},
  year={2012},
  publisher={Society for Judgment and Decision Making}
}
```

## License

Users must cite this package in any publications which use it.

It is licensed with the MIT [License](https://github.com/dsbowen/hemlock-berlin/blob/master/LICENSE).
hemlock-big5 0.0.2
Hemlock extension for the big 5 personality inventory
Requires Python: >=3.6

# Hemlock Big 5

Hemlock-big5 is a <a href="https://dsbowen.github.io/hemlock/" target="_blank">hemlock</a> extension for creating big 5 personality questionnaires.

## Installation

With hemlock-CLI (recommended):

```
$ hlk install hemlock-big5
```

With pip:

```
$ pip install hemlock-big5
```

## Quickstart

This assumes you are using the hemlock template. In `survey.py`:

```python
from hemlock import Branch, Page, Label, route
from hemlock_big5 import big5

@route('/survey')
def start():
    return Branch(
        big5(page=True),
        Page(
            Label('The end.'), 
            terminal=True
        )
    )
```

## Citation

Hemlock-big5 includes several versions of big 5 personality questionnaires. Please cite the appropriate questionnaire along with hemlock.

### Hemlock-big5

```
@software{bowen2021hemlock-big5,
  author = {Dillon Bowen},
  title = {Hemlock-Big5},
  url = {https://dsbowen.github.io/hemlock-big5/},
  date = {2021-02-17},
}
```

### IPIP 50-item inventory (IPIP-50)

```
@article{donnellan2006mini,
  title={The mini-IPIP scales: tiny-yet-effective measures of the Big Five factors of personality.},
  author={Donnellan, M Brent and Oswald, Frederick L and Baird, Brendan M and Lucas, Richard E},
  journal={Psychological assessment},
  volume={18},
  number={2},
  pages={192},
  year={2006},
  publisher={American Psychological Association}
}
```

### Ten-item personality inventory (TIPI)

```
@article{gosling2003very,
  title={A very brief measure of the Big-Five personality domains},
  author={Gosling, Samuel D and Rentfrow, Peter J and Swann Jr, William B},
  journal={Journal of Research in personality},
  volume={37},
  number={6},
  pages={504--528},
  year={2003},
  publisher={Elsevier}
}
```

### Ten-item big five inventory (BFI-10)

```
@article{rammstedt2007measuring,
  title={Measuring personality in one minute or less: A 10-item short version of the Big Five Inventory in English and German},
  author={Rammstedt, Beatrice and John, Oliver P},
  journal={Journal of research in Personality},
  volume={41},
  number={1},
  pages={203--212},
  year={2007},
  publisher={Elsevier}
}
```

## License

Users must cite this package in any publications which use it.

It is licensed with the MIT [License](https://github.com/dsbowen/hemlock-big5/blob/master/LICENSE).
hemlock-demographics 0.0.8
Hemlock extension for demographic information
Requires Python: >=3.6

# Hemlock demographics

Hemlock-demographics is a <a href="https://dsbowen.github.io/hemlock/" target="_blank">hemlock</a> extension for collecting demographic information.

## Installation

With hemlock-CLI (recommended):

```
$ hlk install hemlock-demographics
```

With pip:

```
$ pip install hemlock-demographics
```

## Quickstart

```python
from hemlock import Branch, Page, Label, route
from hemlock_demographics import comprehensive_demographics

@route('/survey')
def start():
    return Branch(
        comprehensive_demographics(page=True),
        Page(
            Label('<p>The end.</p>'), 
            terminal=True
        )
    )
```

## Citation

Hemlock-demographics is based largely on the demographics section of the [World Values Survey](http://www.worldvaluessurvey.org/).

```
@software{bowen2020hemlock-demographics,
  author = {Dillon Bowen},
  title = {Hemlock-Demographics},
  url = {https://dsbowen.github.io/hemlock-demographics/},
  date = {2020-10-05},
}

@dataset{inglehart2014wvs,
    author = {Inglehart, R., and C. Haerpfer, and A. Moreno, and C. Welzel, and K. Kizilova, and J. Diez-Medrano, and M. Lagos, and P. Norris, and E. Ponarin and B. Puranen and et al.},
    title={World Values Survey: Round Six},
    url = {http://www.worldvaluessurvey.org/},
    date = {2014.}
}
```

## License

Users must cite this package in any publications which use it.

It is licensed with the MIT [License](https://github.com/dsbowen/docstr-md/blob/master/LICENSE).
synthSportPlayer-DJS 1.2.0
A package to simulate synthetic sports players/teams
Requires Python: >=3.6

# synthSportPlayer Package

Last updated - 11/3/2021

The purpose of the code within this package is to simulate sports players/teams that compete against each other in both classic 1v1 elimination tournaments and round robin tournaments. Originally the classes & code were created in support of another project but grew larger than expected and therefore large enough to become it own package.
At this point in time it is planned that the code shall continue to be developed.

For the project homepage and issue tracking please see [the github repo.](https://github.com/DrJStrudwick/Synthetic-Sport-Player)

For documentation please see [the docs.](https://synthetic-sport-player.readthedocs.io/en/latest/index.html)

# Install & import
Install the project by running:
```
pip install synthSportPlayer-DJS
```
and import with:
```
import synthSportPlayer
```

There are 5 primary classes contained within this package:
1. `player` These are the teams/players that do the competeing. They are simply defined by a 'skill' level and a variance and whenever they have to 'compete' that is created from a normal distribution defined by these two properties.
2. `match` This is a match to handle two player competing where one will win and one will lose. The winner is determine by both players performing and the highest value wins. If they are equal then the winner is chosen randomly.
3. `tournament` This is an event that a collection of players enter and compete pair-wise with the winners moving forward to the next round, and is complete when there is one player remaining.
4. `robin` This is an event that a collection of players enter where every player will compete against every other player and recieve points for how many wins they had.
5. `season` This is a collection of tournaments that are played in order. At the end of the tournament the players recieve point based on how far they got in that tournament.

There are three extra child classes that were written. The first two extend both `tournament` and `season` to be able to have 'real-time' functionality for dashboarding purposes. The third is to facilitate byes in tournaments. They are:
1. `liveTourn`
2. `liveSeason`
3. `bye`

The main difference with `liveTourn` and `liveSeason` is their respective `playTourn` and `playSeason` function. In the parent classes the functions would run to completion of the tournament/season. In these child classes they move forward one step in the current tournament.