semvec/pypi-packages huggingface dataset:
undocker 7
Unpack docker images

Unpacks a Docker image.

## Usage

    usage: undocker.py [-h] [--ignore-errors] [--output OUTPUT] [--verbose]
                       [--debug] [--list] [--layer LAYER]
                       image

    positional arguments:
      image

    optional arguments:
      -h, --help            show this help message and exit
      --ignore-errors, -i   Ignore OS errors when extracting files
      --output OUTPUT, -o OUTPUT
                            Output directory (defaults to ".")
      --verbose, -v
      --debug, -d
      --list, --ls          List layers in an image
      --layer LAYER, -l LAYER
                            Extract only the specified layer

## Examples

Extract an entire image:

    $ docker save busybox | undocker -i -o busybox busybox

The `-i` option is necessary here because I am not running as root,
and the extract operation will fail when it attempts to create device
nodes.

List the layers in an image:

    $ docker save busybox | undocker --list
    511136ea3c5a64f264b78b5433614aec563103b4d4702f3ba7d4d2698e22c158
    df7546f9f060a2268024c8a230d8639878585defcc1bc6f79d2728a13957871b
    ea13149945cb6b1e746bf28032f02e9b5a793523481a0a18645fc77ad53c4ea2
    4986bf8c15363d1c5d15512d5266f8777bfba4974ac56e3270e7760f6f0a8125

Extract only specific layers:

    $ docker save busybox |
      undocker -o busybox -v \
      -l 4986bf8c15363d1c5d15512d5266f8777bfba4974ac56e3270e7760f6f0a8125 \
      busybox
    INFO:undocker:extracting image busybox (4986bf8c15363d1c5d15512d5266f8777bfba4974ac56e3270e7760f6f0a8125)
    INFO:undocker:extracting layer 4986bf8c15363d1c5d15512d5266f8777bfba4974ac56e3270e7760f6f0a8125

## License

undocker -- a tool for decomposing Docker images  
Copyright (C) 2015 Lars Kellogg-Stedman <lars@oddbit.com>

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program.  If not, see <http://www.gnu.org/licenses/>.
sudoku-py 1.0.0
A Python Sudoku solver and generator
Requires Python: >=3.6

# Sudoku-py

## Overview
Sudoku-py allows you to represent Sudoku boards easily. While also giving you the ability to solve and generate your own Sudoku boards.

## Examples
### Generator Example
```python
from sudoku_py import SudokuGenerator

sudokuGenerator = SudokuGenerator(board_size=9)

sudokuGenerator.generate(cells_to_remove=50, symmetry_removal=True)

print(sudokuGenerator)
0 0 0 | h 0 0 | d e 0 
e 0 0 | 0 0 0 | 0 0 h 
0 h 0 | b 0 0 | 0 0 0 
---------------------
d b a | g h 0 | 0 0 e 
0 e i | a 0 f | g d 0 
c 0 0 | 0 b d | h a i 
---------------------
0 0 0 | 0 0 b | 0 h 0 
f 0 0 | 0 0 0 | 0 0 c 
0 d h | 0 0 g | 0 0 0 

sudokuGenerator.board_exchange_values({'a': 9, 'b': 8, 'c': 7, 'd': 6, 'e': 5, 'f': 4, 'g': 3, 'h': 2, 'i': 1})

print(sudokuGenerator)
0 0 0 | 2 0 0 | 6 5 0 
5 0 0 | 0 0 0 | 0 0 2 
0 2 0 | 8 0 0 | 0 0 0 
---------------------
6 8 9 | 3 2 0 | 0 0 5 
0 5 1 | 9 0 4 | 3 6 0 
7 0 0 | 0 8 6 | 2 9 1 
---------------------
0 0 0 | 0 0 8 | 0 2 0 
4 0 0 | 0 0 0 | 0 0 7 
0 6 2 | 0 0 3 | 0 0 0 
```

### Sudoku Board
```python
from sudoku_py import Sudoku
Sudoku(board=[
    [0,0,0,2,0,0,6,5,0],
    [5,0,0,0,0,0,0,0,2],
    [0,2,0,8,0,0,0,0,0],
    [6,8,9,3,2,0,0,0,5],
    [0,5,1,9,0,4,3,6,0],
    [7,0,0,0,8,6,2,9,1],
    [0,0,0,0,0,8,0,2,0],
    [4,0,0,0,0,0,0,0,7],
    [0,6,2,0,0,3,0,0,0]
])

print(sudoku)
0 0 0 | 2 0 0 | 6 5 0 
5 0 0 | 0 0 0 | 0 0 2 
0 2 0 | 8 0 0 | 0 0 0 
---------------------
6 8 9 | 3 2 0 | 0 0 5 
0 5 1 | 9 0 4 | 3 6 0 
7 0 0 | 0 8 6 | 2 9 1 
---------------------
0 0 0 | 0 0 8 | 0 2 0 
4 0 0 | 0 0 0 | 0 0 7 
0 6 2 | 0 0 3 | 0 0 0 

sudoku.solve(solutions=1)

print(sudoku)
1 3 8 | 2 4 7 | 6 5 9 
5 7 4 | 6 3 9 | 1 8 2 
9 2 6 | 8 1 5 | 4 7 3 
---------------------
6 8 9 | 3 2 1 | 7 4 5 
2 5 1 | 9 7 4 | 3 6 8 
7 4 3 | 5 8 6 | 2 9 1 
---------------------
3 1 7 | 4 5 8 | 9 2 6 
4 9 5 | 1 6 2 | 8 3 7 
8 6 2 | 7 9 3 | 5 1 4 

```