a
    ADf                     @  s   d Z ddlmZ ddlZeeZddlmZ ddl	m
Z
mZ ddlmZ d	ZeG d
d deZG dd deZG dd deZG dd deZG dd deZG dd deZdS )z

    )annotationsN   )abstract)InstanceRequired   )	Transform)CategoricalScaleCompositeScaleLinearScaleLogScaleScalec                      s&   e Zd ZdZdd fddZ  ZS )r   a   Base class for ``Scale`` models that represent an invertible
    computation to be carried out on the client-side.

    JavaScript implementations should implement the following methods:

    .. code-block

        compute(x: number): number {
            # compute and return the transform of a single value
        }

        v_compute(xs: Arrayable<number>): Arrayable<number> {
            # compute and return the transform of an array of values
        }

        invert(sx: number): number {
            # compute and return the inverse transform of a single value
        }

        v_invert(sxs: Arrayable<number>): Arrayable<number> {
            # compute and return the inverse transform of an array of values
        }

    Nonereturnc                   s   t  j|i | d S Nsuper__init__selfargskwargs	__class__ `/nfs/NAS7/SABIOD/METHODE/ermites/ermites_venv/lib/python3.9/site-packages/bokeh/models/scales.pyr   H   s    zScale.__init____name__
__module____qualname____doc__r   __classcell__r   r   r   r   r   ,   s   r   c                      s&   e Zd ZdZdd fddZ  ZS )ContinuousScalezB Represent a scale transformation between continuous ranges.

    r   r   c                   s   t  j|i | d S r   r   r   r   r   r   r   R   s    zContinuousScale.__init__r   r   r   r   r   r#   L   s   r#   c                      s&   e Zd ZdZdd fddZ  ZS )r   zI Represent a linear scale transformation between continuous ranges.

    r   r   c                   s   t  j|i | d S r   r   r   r   r   r   r   \   s    zLinearScale.__init__r   r   r   r   r   r   V   s   r   c                      s&   e Zd ZdZdd fddZ  ZS )r   zF Represent a log scale transformation between continuous ranges.

    r   r   c                   s   t  j|i | d S r   r   r   r   r   r   r   e   s    zLogScale.__init__r   r   r   r   r   r   _   s   r   c                      s&   e Zd ZdZdd fddZ  ZS )r	   zk Represent a scale transformation between a categorical source range and
    continuous target range.

    r   r   c                   s   t  j|i | d S r   r   r   r   r   r   r   o   s    zCategoricalScale.__init__r   r   r   r   r   r	   h   s   r	   c                      sF   e Zd ZdZdd fddZeeeddZeeeddZ	  Z
S )	r
   zc Represent a composition of two scales, which useful for defining
    sub-coordinate systems.

    r   r   c                   s   t  j|i | d S r   r   r   r   r   r   r   y   s    zCompositeScale.__init__z
    The source scale.
    )helpz
    The target scale.
    )r   r   r    r!   r   r   r   r   Zsource_scaleZtarget_scaler"   r   r   r   r   r
   r   s   r
   )r!   
__future__r   logging	getLoggerr   logZcore.has_propsr   Zcore.propertiesr   r   Z
transformsr   __all__r   r#   r   r   r	   r
   r   r   r   r   <module>   s   

		
