Skip to main content

This is an tool box contains tools for mgedata.Some of code are non-originality, just copy for use. All the referenced code are marked,details can be shown in their sources

Project description

MGE tool

Some useful base tools for other mge packages, but without specific task.

Python Versions Version pypi Versions

Install

pip install mgetool

Contains

export

Store

Store files in batches.(无差别存储数据)

import

Call

Import files in batches.(无差别导入数据)

show

BasePlot

Draw picture quickly.(快速画图)

corr_plot

Draw correlation coefficient graph.(相关系数图)

tool

tt

from mgetool.tool import tt
tt.t
...
tt.t
tt.p

Record the time of this site, and print uniformly.(测试代码块时间)

time_this_function

Time the function(测试函数运行时间,@)

parallelize

Parallelize the for loop (并行化)

logg

Get the name of function(输出函数信息,@)

newclass

from mgetool.newclass import create

import numpy as np
def ff(x, y):
    print(y * 1000)
    return x

Foo = create("Foo", np.ndarray, lenn=dict, spam=1, fu=ff)
foo = Foo([1, 2, 3])
a = foo.fu(2, 4)

Build a simple class quickly.(No initialization parameters)(快速创建新类)

packbox

from mgetool.packbox import Toolbox

def func(a, b=1, c=2, name=4, **kwargs):
    print(a, b, c, name, kwargs)
    pass


to = Toolbox()

to.register("a", func, 1, 5, abss=3)
to.refresh("a", 3, 4, 6, name=3, abss=4)
to.a()

Build a toolbox and you can add function to it.(函数集合)

draft

from mgetool.draft import DraftPyx

bd = DraftPyx("hello.pyx")
bd.write()
a= bd.quick_import(build=True, with_html=True)
# bd.remove()

Build for .cpp or .pyx temporary .(编译cython和cpp ,自动创建setup.py)

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

mgetool-0.0.38.tar.gz (48.5 kB view details)

Uploaded Source

File details

Details for the file mgetool-0.0.38.tar.gz.

File metadata

  • Download URL: mgetool-0.0.38.tar.gz
  • Upload date:
  • Size: 48.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/3.10.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.8.8

File hashes

Hashes for mgetool-0.0.38.tar.gz
Algorithm Hash digest
SHA256 8c977292b8f40765c60f4c95b4ac96c31caadbbfb2d8416a52c88e3ab2232dbe
MD5 78a538f5c7943398e9055b3d3ac6e0a3
BLAKE2b-256 8daec6136f7f2d6f65ce43fee3e6b7f834c295c3abde3056393e06b812a4f3a7

See more details on using hashes here.

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