Skip to main content

Expedite array circulation

Project description

加速数组循环库(Accelerated array loop library)

1. 简介(abstract)

由于python语言的自身特性,导致其在循环上的效率很低,因此得采取一定措施提升速度。本库依托于numba库,加速数组循环的同时完成求差、和、均值等功能,目的是避免重复编写加速代码。
Due to the characteristics of the python language, its efficiency in the loop is very low, so some measures must be taken to improve the speed. This library relies on numba library to accelerate the array cycle while completing the difference, sum, mean and other functions, the purpose is to avoid repeated writing of acceleration code.

2. 使用说明(Use Method)

  • install the lib: pip install michaelPanExpediteLib

  • import numpy as np
    from michaelPanExpediteLib.expedite_array_circulation import circulation_array
    
    
    arr1 = np.array([[1, 2, 3], [4, 5, 6], [7, 8, 9]])
    arr2 = np.array([[1, 2, 3], [4, 5, 6], [7, 8, 9]])
    temp_array = np.ones((3, 3))
    temp_array_num = np.zeros((3, 3))
    x_dim = 3
    y_dim = 3
    # circulation_array(data1, data2, temp_array, y_dim, x_dim, data_fill, method, temp_array_num=None)
    temp_array, temp_array_num = circulation_array(arr1, arr2, temp_array, y_dim, x_dim, 1, 'add', temp_array_num)
    

3.作者及联系方式

# ***************************************************************
# Maintainers:
#     chuntong pan <panzhang1314@gmail.com>
# Date:
#     2023.8
# ***************************************************************

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

michaelPanExpediteLib-0.0.3.tar.gz (15.0 kB view hashes)

Uploaded Source

Built Distribution

michaelPanExpediteLib-0.0.3-py3-none-any.whl (15.4 kB view hashes)

Uploaded Python 3

Supported by

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