• wolf71

    @mikael Great Job. Thanks

    posted in Pythonista read more
  • wolf71

    iPhone X (Pythonista V3.2 , Python 2.7)

    (1000 * 1000),Total Time:6.435
    math.sin:2.250
    numpy.sin1:1.697
    numpy.sin2:0.111

    posted in Pythonista read more
  • wolf71

    all devices run same code.

    posted in Pythonista read more
  • wolf71

    import numpy as np
    import time
    import math
    
    bt = time.time()
    n = 1000
    for i in range(1):
        a = np.random.uniform(low=0., high=1., size=(n, n)).astype(np.float32)
        b = np.random.uniform(low=0., high=1., size=(n, n)).astype(np.float32)
        a = a.dot(b)
    print ('(%d * %d),Total Time:%.3f'%(n,n,time.time()-bt))
    
    start = time.clock()
    x = [i * 0.001 for i in xrange(10000000)]
    for i, t in enumerate(x):
        x[i] = math.sin(t)
    print ("math.sin:%.3f"%(time.clock() - start))
    
    start = time.clock()
    y = [i * 0.001 for i in xrange(10000000)]
    y = np.array(y)
    print ("numpy.sin1:%.3f"%(time.clock() - start))
    start = time.clock()
    np.sin(y,y)
    print ("numpy.sin2:%.3f"%(time.clock() - start))
    
    
    '''
    * ipad Pro 9.7 
    (1000 * 1000),Total Time:8.840
    math.sin: 3.04883
    numpy.sin: 2.668903 (2.517,0.177)
    
    =====Android Termux=====
    (1000,1000) 0.627
    math.sin: 33.899
    numpy.sin: 14.953
    
    =====MacBook Air 13 @2010====
    (1000,1000) 0.234
    math.sin: 8.95
    numpy.sin: 4.71 (3.88,0.48)
    
    ====Microsoft Surface 3 @2015====
    (1000,1000) 0.203
    math.sin: 12.739
    numpy.sin: (5.419,0.380)
    
    

    Why iOS numpy (1000,1000) very slow ???

    posted in Pythonista read more
  • wolf71

    thanks.

    Del the enum folder,and restart, all ok.

    posted in Pythonista read more
  • wolf71

    Upgrade to V3.2.

    On iPad Pro 9.7 (iOS V11.2.1). When start app. this error message show on console:

    Traceback (most recent call last):
      File "/var/containers/Bundle/Application/A44685BD-F481-4B46-A86F-DF888CAC5D0D/Pythonista3.app/Frameworks/Py3Kit.framework/pykit_startup.py", line 51, in <module>
        main()
      File "/var/containers/Bundle/Application/A44685BD-F481-4B46-A86F-DF888CAC5D0D/Pythonista3.app/Frameworks/Py3Kit.framework/pykit_startup.py", line 47, in main
        import importcompletion
      File "/var/containers/Bundle/Application/A44685BD-F481-4B46-A86F-DF888CAC5D0D/Pythonista3.app/Frameworks/Py3Kit.framework/pylib/importcompletion.py", line 26, in <module>
        import imp
      File "/var/containers/Bundle/Application/A44685BD-F481-4B46-A86F-DF888CAC5D0D/Pythonista3.app/Frameworks/Py3Kit.framework/pylib/imp.py", line 28, in <module>
        import tokenize
      File "/var/containers/Bundle/Application/A44685BD-F481-4B46-A86F-DF888CAC5D0D/Pythonista3.app/Frameworks/Py3Kit.framework/pylib/tokenize.py", line 34, in <module>
        import re
      File "/var/containers/Bundle/Application/A44685BD-F481-4B46-A86F-DF888CAC5D0D/Pythonista3.app/Frameworks/Py3Kit.framework/pylib/re.py", line 143, in <module>
        class RegexFlag(enum.IntFlag):
    AttributeError: module 'enum' has no attribute 'IntFlag'
    
    

    And when console run: import re, the pythonista crash.

    posted in Pythonista read more
  • wolf71

    iPad Pro 9.7 256G iOS 11.1

    Python 2.7

    Pystone(1.1.1) time for 50000 passes = 0.346581
    This machine benchmarks at 144266 pystones/second

    Python 3.5

    Pystone(1.1.1) time for 50000 passes = 0.427856
    This machine benchmarks at 116862 pystones/second

    posted in Pythonista read more
  • wolf71

    @zrzka Thanks,it's work.

    can add cmd+up cmd+down to page up and page down?

    posted in Pythonista read more
  • wolf71

    using pip install blackmamba

    and then run:

    #!python3
    
    import blackmamba as bm
    bm.main()
    
    

    Error:
    ImportError: No module named 'httplib'

    posted in Pythonista read more
  • wolf71

    cool,perfect,thanks.

    and wish @omz next pythonista update can support it native.

    posted in Pythonista read more

Internal error.

Oops! Looks like something went wrong!