§
    Ò¬¸jò  ã            
      ó~  — d dl mZ d dlZd dlmZmZmZ d dlmZ d dl	m
Z
 d dlmZ d dlmZ d dlmZ  ej        e¦  «        5  d d	lmZ ddd¦  «         n# 1 swxY w Y   erd d
lmZ d dlmZ d dlmZ d dlmZ d dlmZ  e¦   «         dddd dddddœd)d&„¦   «         Z e¦   «         dddd dddddœd*d(„¦   «         Z dS )+é    )ÚannotationsN)ÚIOÚTYPE_CHECKINGÚLiteral)Úunstable)Úwrap_ldf)Úget_sources)Ú!_init_credential_provider_builder)ÚScanOptions)ÚPyLazyFrame)ÚPath)ÚStorageOptionsDict)Ú	DataFrame)ÚCredentialProviderFunction)Ú	LazyFrameÚlineTÚauto©ÚnameÚn_rowsÚrow_index_nameÚrow_index_offsetÚglobÚstorage_optionsÚcredential_providerÚinclude_file_pathsÚsourceúcstr | Path | IO[str] | IO[bytes] | bytes | list[str] | list[Path] | list[IO[str]] | list[IO[bytes]]r   Ústrr   ú
int | Noner   ú
str | Noner   Úintr   Úboolr   úStorageOptionsDict | Noner   ú3CredentialProviderFunction | Literal['auto'] | Noner   Úreturnr   c               óV   — t          | ||||||||¬¦	  «	                             ¦   «         S )uh	  
    Read lines into a string column from a file.

    .. warning::
        This functionality is considered **unstable**. It may be changed
        at any point without it being considered a breaking change.

    Parameters
    ----------
    source
        Path(s) to a file or directory
        When needing to authenticate for scanning cloud locations, see the
        `storage_options` parameter.
    name
        Name to use for the output column.
    n_rows
        Stop reading from parquet file after reading `n_rows`.
    row_index_name
        If not None, this will insert a row index column with the given name into the
        DataFrame
    row_index_offset
        Offset to start the row index column (only used if the name is set)
    glob
        Expand path given via globbing rules.
    storage_options
        Options that indicate how to connect to a cloud provider.

        The cloud providers currently supported are AWS, GCP, and Azure.
        See supported keys here:

        * `aws <https://docs.rs/object_store/latest/object_store/aws/enum.AmazonS3ConfigKey.html>`_
        * `gcp <https://docs.rs/object_store/latest/object_store/gcp/enum.GoogleConfigKey.html>`_
        * `azure <https://docs.rs/object_store/latest/object_store/azure/enum.AzureConfigKey.html>`_
        * Hugging Face (`hf://`): Accepts an API key under the `token` parameter: \
          `{'token': '...'}`, or by setting the `HF_TOKEN` environment variable.

        If `storage_options` is not provided, Polars will try to infer the information
        from environment variables.
    credential_provider
        Provide a function that can be called to provide cloud storage
        credentials. The function is expected to return a dictionary of
        credential keys along with an optional credential expiry time.

        .. warning::
            This functionality is considered **unstable**. It may be changed
            at any point without it being considered a breaking change.
    include_file_paths
        Include the path of the source file(s) as a column with this name.

    See Also
    --------
    scan_lines

    Examples
    --------
    >>> pl.read_lines(b"Hello\nworld")
    shape: (2, 1)
    â”Œâ”€â”€â”€â”€â”€â”€â”€â”�
    â”‚ line  â”‚
    â”‚ ---   â”‚
    â”‚ str   â”‚
    â•žâ•�â•�â•�â•�â•�â•�â•�â•¡
    â”‚ Hello â”‚
    â”‚ world â”‚
    â””â”€â”€â”€â”€â”€â”€â”€â”˜
    r   )Ú
scan_linesÚ_collect_eager)	r   r   r   r   r   r   r   r   r   s	            ú_/root/private/project/pallet_detection_v2/.venv/lib/python3.11/site-packages/polars/io/lines.pyÚ
read_linesr+      sD   € õr ØØØØ%Ø)ØØ'Ø/Ø-ð
ñ 
ô 
÷ ‚nÑÔð
ó    r   c               óÐ   — t          | ¦  «        }	t          ||	|d¦  «        }
~t          j        |	t	          |�||fnd|�d|fnd||||
¬¦  «        |¬¦  «        }t          |¦  «        S )u�	  
    Construct a LazyFrame which scans lines into a string column from a file.

    .. warning::
        This functionality is considered **unstable**. It may be changed
        at any point without it being considered a breaking change.

    Parameters
    ----------
    source
        Path(s) to a file or directory
        When needing to authenticate for scanning cloud locations, see the
        `storage_options` parameter.
    name
        Name to use for the output column.
    n_rows
        Stop reading from parquet file after reading `n_rows`.
    row_index_name
        If not None, this will insert a row index column with the given name into the
        DataFrame
    row_index_offset
        Offset to start the row index column (only used if the name is set)
    glob
        Expand path given via globbing rules.
    storage_options
        Options that indicate how to connect to a cloud provider.

        The cloud providers currently supported are AWS, GCP, and Azure.
        See supported keys here:

        * `aws <https://docs.rs/object_store/latest/object_store/aws/enum.AmazonS3ConfigKey.html>`_
        * `gcp <https://docs.rs/object_store/latest/object_store/gcp/enum.GoogleConfigKey.html>`_
        * `azure <https://docs.rs/object_store/latest/object_store/azure/enum.AzureConfigKey.html>`_
        * Hugging Face (`hf://`): Accepts an API key under the `token` parameter: \
          `{'token': '...'}`, or by setting the `HF_TOKEN` environment variable.

        If `storage_options` is not provided, Polars will try to infer the information
        from environment variables.
    credential_provider
        Provide a function that can be called to provide cloud storage
        credentials. The function is expected to return a dictionary of
        credential keys along with an optional credential expiry time.

        .. warning::
            This functionality is considered **unstable**. It may be changed
            at any point without it being considered a breaking change.
    include_file_paths
        Include the path of the source file(s) as a column with this name.

    See Also
    --------
    read_lines

    Examples
    --------
    >>> pl.scan_lines(b"Hello\nworld").collect()
    shape: (2, 1)
    â”Œâ”€â”€â”€â”€â”€â”€â”€â”�
    â”‚ line  â”‚
    â”‚ ---   â”‚
    â”‚ str   â”‚
    â•žâ•�â•�â•�â•�â•�â•�â•�â•¡
    â”‚ Hello â”‚
    â”‚ world â”‚
    â””â”€â”€â”€â”€â”€â”€â”€â”˜
    r(   Nr   )Ú	row_indexÚ	pre_slicer   r   r   r   )ÚsourcesÚscan_optionsr   )r	   r
   r   Únew_from_scan_linesr   r   )r   r   r   r   r   r   r   r   r   r0   Úcredential_provider_builderÚpylfs               r*   r(   r(   €   s¤   € õr ˜&Ñ!Ô!€Gå"CØ˜W o°|ñ#ô #Ðð 	åÔ*ØÝ ð "Ð-ð  Ð!1Ð2Ð2àà%+Ð%7�q˜&�k�k¸TØ1ØØ+Ø ;ð
ñ 
ô 
ð ðñ ô €Dõ" �D‰>Œ>Ðr,   )r   r   r   r   r   r    r   r!   r   r"   r   r#   r   r$   r   r%   r   r!   r&   r   )r   r   r   r   r   r    r   r!   r   r"   r   r#   r   r$   r   r%   r   r!   r&   r   )!Ú
__future__r   Ú
contextlibÚtypingr   r   r   Úpolars._utils.unstabler   Úpolars._utils.wrapr   Úpolars.io._utilsr	   Ú,polars.io.cloud.credential_provider._builderr
   Úpolars.io.scan_options._optionsr   ÚsuppressÚImportErrorÚpolars._plrr   Úpathlibr   Úpolars._typingr   Úpolars.dataframe.framer   Úpolars.io.cloudr   Úpolars.lazyframe.framer   r+   r(   © r,   r*   ú<module>rF      s4  ðØ "Ð "Ð "Ð "Ð "Ð "à Ð Ð Ð Ø -Ð -Ð -Ð -Ð -Ð -Ð -Ð -Ð -Ð -à +Ð +Ð +Ð +Ð +Ð +Ø 'Ð 'Ð 'Ð 'Ð 'Ð 'Ø (Ð (Ð (Ð (Ð (Ð (ðð ð ð ð ð ð 8Ð 7Ð 7Ð 7Ð 7Ð 7à€ZÔ˜Ñ%Ô%ð (ð (Ø'Ð'Ð'Ð'Ð'Ð'ð(ð (ð (ñ (ô (ð (ð (ð (ð (ð (ð (øøøð (ð (ð (ð (ð ð 1ØÐÐÐÐÐà1Ð1Ð1Ð1Ð1Ð1Ø0Ð0Ð0Ð0Ð0Ð0Ø:Ð:Ð:Ð:Ð:Ð:Ø0Ð0Ð0Ð0Ð0Ð0ð 
€�„ð ØØ!%ØØØ15ØOUØ%)ð)bð bð bð bð bñ „ðbðJ 
€�„ð ØØ!%ØØØ15ØOUØ%)ð)pð pð pð pð pñ „ðpð pð ps   ÁAÁAÁA