Skip to main content

A high level Line Integral Convolution (LIC) library, including post-processing and visualization

Project description

lick

PyPI pre-commit.ci status Ruff

Line Integral Convolution Knit : clothe a 2D field (ex: density field) with a LIC texture, given two vector fields (ex: velocity (vx, vy)).

This package builds on top of rLIC, adding post-processing and visualization functionalities.

Authors: Gaylor Wafflard-Fernandez, Clément Robert

Author-email: gaylor.wafflard@univ-grenoble-alpes.fr

Installation

Install with pip

pip install lick

To import lick:

import lick as lk

The important functions are lick_box and lick_box_plot. While lick_box interpolates the data and perform a line integral convolution, lick_box_plot directly plots the final image. Use lick_box if you want to have more control of the plots you want to do with the lic. Use lick_box_plot if you want to take advantage of the fine-tuning of the pcolormesh parameters.

Example

import numpy as np
import matplotlib.pyplot as plt
from lick import lick_box_plot

fig, ax = plt.subplots()
x = np.geomspace(0.1, 10, 128)
y = np.geomspace(0.1, 5, 128)
a, b = np.meshgrid(x, y)
v1 = np.cos(a)
v2 = np.sin(b)
field = v1 ** 2 + v2 ** 2
lick_box_plot(
    fig,
    ax,
    x,
    y,
    v1,
    v2,
    field,
    size_interpolated=256,
    xmin=1,
    xmax=9,
    ymin=1,
    ymax=4,
    niter_lic=5,
    kernel_length=64,
    cmap="inferno",
    stream_density=0.5
)
plt.show()

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

lick-0.7.1.tar.gz (17.3 kB view details)

Uploaded Source

Built Distribution

lick-0.7.1-py3-none-any.whl (17.4 kB view details)

Uploaded Python 3

File details

Details for the file lick-0.7.1.tar.gz.

File metadata

  • Download URL: lick-0.7.1.tar.gz
  • Upload date:
  • Size: 17.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for lick-0.7.1.tar.gz
Algorithm Hash digest
SHA256 e82d06c8a08cf0c712b6548e252ac9ed3d97bfe56b4277c2b0ff3ce58ab85b6d
MD5 05eac8c97a08c51d66b44f133ea679da
BLAKE2b-256 ebc8c468aec449180f1a02b0a677aeaf202ef6b47f52701d0cb41cfd48f2a8c1

See more details on using hashes here.

Provenance

The following attestation bundles were made for lick-0.7.1.tar.gz:

Publisher: cd.yml on volodia99/lick

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file lick-0.7.1-py3-none-any.whl.

File metadata

  • Download URL: lick-0.7.1-py3-none-any.whl
  • Upload date:
  • Size: 17.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for lick-0.7.1-py3-none-any.whl
Algorithm Hash digest
SHA256 f7d884b1337cbab1b35e5a03f8cbdecb006e50a62ec9355419f09afd1339f784
MD5 b50bd5ded5660075c7fca2597eda7875
BLAKE2b-256 00f3cbef1197f31c023d3f3fb199ba36dc33443d7e4d22f3899856a8e2101b08

See more details on using hashes here.

Provenance

The following attestation bundles were made for lick-0.7.1-py3-none-any.whl:

Publisher: cd.yml on volodia99/lick

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page