Server IP : 172.67.214.6 / Your IP : 216.73.216.73 Web Server : LiteSpeed System : Linux premium900.web-hosting.com 4.18.0-553.22.1.lve.1.el8.x86_64 #1 SMP Tue Oct 8 15:52:54 UTC 2024 x86_64 User : redwjova ( 1790) PHP Version : 8.1.32 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /opt/cloudlinux/venv/lib/python3.11/site-packages/numpy/core/__pycache__/ |
Upload File : |
� � h�� � � � d Z ddlZddlZddlmZ ddlmZmZ ddlm Z ddgZ dZ ee� � Z d � Zd � Zd� Zd� Zd � Zd� Zd� Zd� Zd� Zddd�d�Z e ed�� � ddd�d�� � Zddd�d�Z e ed�� � ddd�d�� � ZdS )z& Implementation of optimized einsum. � N)�c_einsum)� asanyarray� tensordot)�array_function_dispatch�einsum�einsum_path�4abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZc �` � t | |� � }t d|dz � � }|r|dz }||z S )a� Computes the number of FLOPS in the contraction. Parameters ---------- idx_contraction : iterable The indices involved in the contraction inner : bool Does this contraction require an inner product? num_terms : int The number of terms in a contraction size_dictionary : dict The size of each of the indices in idx_contraction Returns ------- flop_count : int The total number of FLOPS required for the contraction. Examples -------- >>> _flop_count('abc', False, 1, {'a': 2, 'b':3, 'c':5}) 30 >>> _flop_count('abc', True, 2, {'a': 2, 'b':3, 'c':5}) 60 � )�_compute_size_by_dict�max)�idx_contraction�inner� num_terms�size_dictionary�overall_size� op_factors �L/opt/cloudlinux/venv/lib64/python3.11/site-packages/numpy/core/einsumfunc.py�_flop_countr sB � �>