semvec/pypi-packages huggingface dataset:
x11util 1.3
Wrapper fucntions to make X11 low-level Xlib programming easier

# x11util Package

x11util - Wrapper fucntions to make X11 low-level Xlib programming easier

# DESCRIPTION

This manual page documents **x11util** module, a Python module providing
several wrapper function for Xlib programming easier.

# EXAMPLE

```python
import time
from Xlib import X, display
from x11util import create_window, create_gcs, load_font, draw_str, flush

disp = display.Display()
font = load_font(disp)
screen = disp.screen()
window = create_window(disp, screen, width=320, height=240, x=100, y=200)
gcs = create_gcs(disp, screen, window, font)
draw_str(disp, screen, window, gcs, 'Hello, World!', 10, 20)
draw_str(disp, screen, window, gcs, 'Hello, World!', 11, 21, level=50)
flush(disp, screen)
time.sleep(10)
```

# FUNCTIONS

**x11util** module provides the following functions.

- create_window(disp, screen, width=640, height=480, x=0, y=0, override=1, mask=X.ExposureMask)

  Create a new window on screen SCREEN in display DISP with given WIDTH and
  HEIGHT, which is placed at the geometry of (X, Y) using Xlib's
  XCreateWindow.  override_redirect and event_mask can specified by OVERRIDE
  and MASK, respectively.

- load_font(disp, font=None)

  Load bitmap font FONT in display DISP, and return the loaded font object.
  If font loading failed, return None.

- create_gcs(disp, screen, window, font)

  Create GCs (Graphics Content) on screen SCREEN in display DISP for window
  WINDOW with font FONT.  GCs are returned as a dictionary, whose key is the
  color name (e.g., 'SteelBlue') and the value is a dictionary, whose items
  are (LEVEL, GC), where LEVEL is a brightness between 0 and 100 and GC is the
  GC for that brightness.

- clear(window)

  Erase the window WINDOW.

- draw_str(disp, screen, window, gcs, astr, col=0, row=0, color='PaleGreen', level=100, reverse=False)

  Render a string ASTR on window WINDOW on screen SCREEN in display DISP using
  graphics contents GC.  Text color and brightness can be specified by COLOR
  and LEVEL, respectively.  Reverse video is enabled if REVERSE is True.

- flush(disp, screen)

  Flush all pending X11 requests.

# CUSTOMIZATION

On startup, **x11util** module loads per-user RC script (`~/.x11utilrc`) if it
exists.  The RC script is any valid Python script.  You can change the
behavior of **x11util** using the RC file.

An example `~/.x11utilrc` file is as follows.

```python
global FONT_NAME
FONT_NAME = '-hiro-fixed-medium-r-normal--8-80-75-75-c-80-iso646.1991-irv'
```

# INSTALLATION

```python
pip3 install x11util
```

# AVAILABILITY

The latest version of **x11util** module is available at PyPI
(https://pypi.org/project/x11util/) .

# SEE ALSO

- Xlib - C Language X Interface
- python3-xlib (https://pypi.org/project/python3-xlib/)

# AUTHOR

Hiroyuki Ohsaki <ohsaki[atmark]lsnl.jp>
coci 0.2.0
Collective Observation on Causal Inference

# COCI

<strong>C</strong>ollective <strong>O</strong>bservation on <strong>C</strong>ausal <strong>I</strong>nferences

Coci makes it easy to observe the changes in predictions from machine learning models based on the alterations of 
feature values.

## Why Coci?

Machine learning has always been understood as a black box algorithm, which makes the decision makers hesitant to trust 
the predictions from this approach.

<a href="https://github.com/slundberg/shap">Shap</a> and <a href="https://github.com/marcotcr/lime">Lime</a> has 
unveiled a lot of mysteries around the effects of the presence of each feature on outcomes. However, these methods 
cannot show the change in outcomes when features are tweaked.

Coci takes it a step further, and reveals the effects on outcomes when changing feature values. 


# Installation

`pip install coci==0.1.7`

# Summary Plot

## Sample code

```
import coci

explainer = coci.TreeExplainer(model)

explainer.sensitivity(X_test, 
                    feature_names=feature_names,
                    split_num=2,
                    sample_size=300)

explainer.summary_plot(max_display=10)

```

## Reading the summary plot

![Summary Plot](images/summary_plot.png)

# Trend Plot
## Sample code
```
import coci 

explainer = coci.TreeExplainer(model)

explainer.sensitivity(X_test, 
                    feature_names=feature_names,
                    split_num=2,
                    sample_size=300)

explainer.trend_plot(feature_name=['要介護認定等基準時間（食事）'])

## or show by index
explainer.trend_plot(feature_index=[1276])

## or show the top ranked features
explainer.trend_plot(max_display=10)

```

## Reading the trend plot
naive-translator 0.0.1
A naive word by word translator
Requires Python: >=3.2

# naive_translator

A very simple translator based on a word to word dictionary

(Though this project is designed to convert traditional 
Chinese to simplified, it owns the ability to do more things.)

[Chinese Doc](docs/README_CH.md)

## 1. How to Use

### 1.1 Installation

```bash
pip3 install naive_translator
```

### 1.2 Use as a package

```text
>>> from naive_translator import translator
>>> translation = translator('豐田的上門女婿和女人')
>>> print(translation)
丰田的上门女婿和女人
```

### 1.3 Use as a server

To start the server, run the following command

```bash
naive_translator 8001
```

Then you could visit

|Url|Explanation|
|:---|:---|
|http://localhost:8001|A welcome page|
|http://localhost:8001/dicts|List all available dictionaries|
|http://localhost:8001/translate?dict=&text=|Translate|

## Others

- Dictionary files are placed in `naive_translator/data` directory
- Configure file is `naive_translator/config.py`
aquacroppy 0.0.0.3
AquaCrop Python

# AquaCropPy

[![PyPI](https://img.shields.io/pypi/v/aquacroppy.svg?maxAge=2592000?style=plastic)](https://pypi.python.org/pypi/aquacroppy)


Crop growth model to address food security and assess the effect of the environment and management on crop production. Python code to run an AquaCrop simulation. AquaCrop was developed by the The Food and Agriculture Organization (FAO).

![matlab code structure](https://github.com/noah-de/AquaCropPy/blob/master/References/legacy-code-map.png)

## Building with tests included

This module was [built](https://docs.python.org/3.7/distutils/builtdist.html#creating-built-distributions) to be tested, released and installed like any other [python package](https://packaging.python.org/tutorials/packaging-projects/). Someday users will be able to *pip install* it from Pypi.

For now, developers will need to download the repo and instal it in '[editable mode](https://docs.pytest.org/en/latest/existingtestsuite.html#existingtestsuite)' to avoid having to re-build it:

    pip install -e .

### Running tests
Leveraging [pytest](https://docs.pytest.org/) with the pytest-cov module:

    pytest -v --cov=aquacroppy

Alternatively, you could run the unit tests with [nose](https://nose.readthedocs.io/en/latest/):

    nosetests  --with-coverage --cover-package=aquacroppy -v

### Test Driven Development
The idea is to only write code that meets a specification. Generally speaking, the specifications are the tests.

Here is a sample workflow:
  - start with a test suite that passes
  - write a test for code that does not yet exist
  - run the test, (confirm that it fails)
  - write the minimal amount of code to get the test to pass
  - run the entire test suite again (confirm that new code doesn't break other parts of the application)
  - commit code repository
  - repeat

### Building distribution
After checking out the repo, run the following command if you want to generate distributions:

    python3 setup.py sdist bdist_wheel