semvec/pypi-packages huggingface dataset:
dropbox-pi-cli 0.0.5
A command line tool for raspberry py
Requires Python: >=3.7

# dropbox-pi-cli
A dropbox command line tool

Before start you need to setup the envar:
```bash
export DROPBOX_ACCESS_TOKEN='YOUR AUTH TOKEN HERE'
```

### Install

after clone cd to project folder and execute
```bash
make -B build
make install
```

### Uninstall

cd to project folder and execute
```bash
make uninstall
```
## Usage
The command line is only able to upload and download from/to dropbox app folder.

### Download
```
dropbox-pi file-download [OPTIONS]

Options:
  --remote-path TEXT  The path of the file to download.
  --local_path TEXT   The path of the file on the local moachine.
  --help              Show this message and exit.
```

### Upoload
```
dropbox-pi file-upload [OPTIONS]

Options:
  --remote_path TEXT      Path in the user's Dropbox to save the file
  --local-path TEXT       Path in the user's local to save the file
  --mode TEXT             Selects what to do if the file already exists. The
                          default for this union is add

  --autorename TEXT       If there's a conflict, as determined by mode, have
                          the Dropbox server try to autorename the file to
                          avoid conflict. The default for this field is False.

  --mute TEXT             Normally, users are made aware of any file
                          modifications in their Dropbox account via
                          notifications in the client software. If true, this
                          tells the clients that this modification shouldn't
                          result in a user notification. The default for this
                          field is False

  --strict-conflict TEXT  Be more strict about how each WriteMode detects
                          conflict. For example, always return a conflict
                          error when mode = WriteMode.update and the given
                          'rev' doesn't match the existing file's 'rev', even
                          if the existing file has been deleted. This also
                          forces a conflict even when the target path refers
                          to a file with identical contents. The default for
                          this field is False

  --help                  Show this message and exit.

```
nojazz 0.0.3
A collection of one-off functions I use for various tasks as a Data Scientist-- if it ain't broke, don't fix it.

## nojazz

A collection of one-off functions I use for various tasks as a Data Scientist-- if it ain't broke, don't fix it.

Name inspired by my favorite Pearls Before Swine comic

![img](docs/comic.jpg)

Disclaimer: I also like jazz

## Installation

`nojazz` [is hosted on PyPI](https://pypi.org/project/nojazz/) and can be installed with a simple

`pip install nojazz`

## Features

As mentioned above, I finally sat down to make this package after noticing that I was copying a lot of the same helper methods from project to project. To that end, `nojazz` is hardly comprehensive (nor necessarily related, submodule to submodule) but has a few, small "figured it out once and packaged it for reuse" utilities for:

### sqlite3

My first and biggest re-use culprit. `nojazz` provides a simple context manager to allow that handles all of the connection/commit/closing of sqlite database functions.

``` python
with connect_to_db('test.db') as cursor:
    cursor.execute('some sql')
```

Note, this will generate a `nojazz_conf.py` at the root of your project when calling. The library uses this to read the *directory* location for all of these database connections (i.e. on another drive, perhaps)

### pandas

There are all kinds of tricks to this library. For now, `nojazz` provides the following helper methods

#### `fill_time_series_nulls`

For a given dataset with rows: agents and columns: observations, there are applications where want to consider `NULL` values as `0`, *but only after the user has shown up for the first time*. This function does this, at the row-level and returns a copy of the original DataFrame. For example

```
   0    1     2     3     4
0  1   NaN   NaN    1    NaN
1 NaN  NaN   1     NaN    1

```
transforms to

```
   0    1     2     3     4
0  1    0     0     1    NaN
1 NaN  NaN    1     0     1

```

#### `realign_nonnull_data`

Similar to `fill_time_series_nulls`, this function is used when you want to line all of your records up to the same starting period. Like so

```
    0     1     2    3
0  NaN   NaN   NaN   1
1  NaN   NaN    1    1
2  NaN    1     1    1
```

transforms to

```
    0     1     2    3
0   1    NaN   NaN   NaN
1   1     1    NaN   NaN
2   1     1     1    NaN
```

Note, this likely means needing to rename the columns to something more appropriate. Furthermore, we maintained the shape of the original DataFrame by padding all extra fields with `NaN`