BrushCue Example: RGB Color Mix Aesthetic¶

Open In Colab

You can use this tool online at https://www.brushcue.com/tools/rgb-color-mix-aesthetic

In [ ]:
!pip install brushcue
In [1]:
import brushcue
from PIL import Image
import io

input_image_1 = brushcue.composition_monet_women_with_parasol() # insert your own image here
float_constant_2 = brushcue.float_constant(1.0)
float_constant_3 = brushcue.float_constant(0.0)
float_constant_4 = brushcue.float_constant(0.0)
float_constant_5 = brushcue.float_constant(0.0)
float_constant_6 = brushcue.float_constant(0.0)
float_constant_7 = brushcue.float_constant(0.0)
float_constant_8 = brushcue.float_constant(0.0)
float_constant_9 = brushcue.float_constant(0.0)
float_constant_10 = brushcue.float_constant(0.0)
float_constant_11 = brushcue.float_constant(0.0)
float_constant_12 = brushcue.float_constant(1.0)
float_constant_13 = brushcue.float_constant(0.05999999865889549)
float_constant_14 = brushcue.float_constant(1.0)
float_constant_15 = brushcue.float_constant(2.0)
float_constant_16 = brushcue.float_constant(1.0)
float_constant_17 = brushcue.float_constant(2.0)
strength_18 = brushcue.float_passthrough(float_constant_13)
float_subtract_19 = brushcue.float_subtract(float_constant_14, strength_18)
float_multiply_20 = brushcue.float_multiply(strength_18, float_constant_15)
float_multiply_21 = brushcue.float_multiply(strength_18, float_constant_17)
float_subtract_22 = brushcue.float_subtract(float_constant_16, float_multiply_21)
composition_rgba_linear_transform_23 = brushcue.composition_linear_transform(input_image_1, float_constant_2, strength_18, float_constant_3, float_constant_4, float_constant_5, float_subtract_19, strength_18, float_constant_6, float_constant_7, float_multiply_20, float_subtract_22, float_constant_8, float_constant_9, float_constant_10, float_constant_11, float_constant_12)

ctx = brushcue.Context()
result = composition_rgba_linear_transform_23.execute(ctx)
composition = result.as_composition()
data_bytes = composition.to_image_bytes(ctx)
img = Image.open(io.BytesIO(data_bytes))
img.thumbnail((400, 400)) # remove this line for full resolution
img
Out[1]:
No description has been provided for this image