python startup very slow on win2000

Discussion in 'Python' started by angel, Jul 28, 2004.

  1. angel

    angel Guest

    Hi

    I use python on win2000.I found python perhaps spend 10~15 second on
    starting. How to accelerate it?

    Thanx
     
    angel, Jul 28, 2004
    #1
    1. Advertising

  2. On Wed, 28 Jul 2004 11:30:42 +0800, angel <> wrote:
    > Hi
    >
    > I use python on win2000.I found python perhaps spend 10~15 second on
    > starting. How to accelerate it?
    >


    I'm running Python 2.3.3 on Windows 2000 here at work, and while the
    startup time isn't great (about 1 second) compared with Linux at home,
    it's nowhere near that bad.

    Is there some other process taking a lot of CPU time or RAM? Are you
    talking about just starting Python itself - or are you running some
    program written in Python? How long does it take just to start the
    Python command-line shell by itself?

    dt.
     
    Derek Thomson, Jul 28, 2004
    #2
    1. Advertising

  3. Hi !

    Do you use a soft anti-virus ? Look his parameters (exclude \Python23).
     
    Michel Claveau, résurectionné d'outre-bombe inform, Jul 28, 2004
    #3
  4. angel

    angel Guest

    The cpu of my system is P3 1G, memory is 1G. The preformance is good when
    runing other application. But running python is terrible, pythonwin.exe will
    speed 30 second on startup. "python.exe -i" on command line will speed 10
    second on startup.


    "Michel Claveau, résurectionn?d'outre-bombe informatique"
    <> дÈëÏûÏ¢ÐÂÎÅ
    :ce7a0v$f3f$...
    > Hi !
    >
    > Do you use a soft anti-virus ? Look his parameters (exclude \Python23).
    >
    >
    >
     
    angel, Jul 28, 2004
    #4
  5. angel

    Peter Hansen Guest

    angel wrote:

    > I use python on win2000.I found python perhaps spend 10~15 second on
    > starting. How to accelerate it?


    There is something wrong or unexpected with your setup. Check
    for problems with the PATH (folders that map to missing network
    shares and such), virus scanning software (as Michel mentioned
    but you sort of ignored in your response), and other such things.
    Python itself definitely will not take that long on a properly
    configured system, IME.

    -Peter
     
    Peter Hansen, Jul 28, 2004
    #5
  6. angel

    Dominic Guest

    angel wrote:
    > Hi
    >
    > I use python on win2000.I found python perhaps spend 10~15 second on

    win2000 is quite slow on systems with little memory. (<=128 MB)

    On my notebook it also takes some time to start Python,
    because the hd is quite slow.

    > starting. How to accelerate it?

    Buy more memory and a fast hd.

    Or fix Python. Maybe stuffing all
    library py-files in a
    (memory mapped) file may
    help. ;-)


    >
    > Thanx
    >
    >
     
    Dominic, Jul 28, 2004
    #6
  7. angel

    angel Guest

    Thanx for your help.

    I have checked every thing you had mentioned,but no result.
    There is jython2.1 on my system. jython startup is fast, just 2~3 second.
    How strange is it!
    Dose python need configure? For example: PATH or other?


    "angel" <> дÈëÏûÏ¢ÐÂÎÅ:...
    > Hi
    >
    > I use python on win2000.I found python perhaps spend 10~15 second on
    > starting. How to accelerate it?
    >
    > Thanx
    >
    >
     
    angel, Jul 28, 2004
    #7
  8. Re-Hi !

    On my Vaio (P3 - 3,2 Ghz - 1 Go) Python-2.3 run a typical script in 11 s ;
    after STRONG optimization of XP and Norton-anti-virus, it run in 4 s (the
    first run) and 2 s (other runs).

    And it's similary with other softwares.
     
    Michel Claveau, résurectionné d'outre-bombe inform, Jul 28, 2004
    #8
  9. angel

    Dominic Guest

    Michel Claveau, résurectionné d'outre-bombe informatique wrote:
    > Re-Hi !
    >
    > On my Vaio (P3 - 3,2 Ghz - 1 Go) Python-2.3 run a typical script in 11 s ;
    > after STRONG optimization of XP and Norton-anti-virus, it run in 4 s (the
    > first run) and 2 s (other runs).

    start-up subsecond range on Windows 98 SE, PII 400MHz, 320 MB RAM
    1-2 seconds on my PIII 800 MHz, notebook, Windows XP
    >
    > And it's similary with other softwares.
    >
    >
    >
    >
     
    Dominic, Jul 28, 2004
    #9
  10. angel wrote:

    > Dose python need configure? For example: PATH or other?


    do a:

    python -vSEc "print 1"

    maybe you can identify the source of the slowdown.

    Istvan.
     
    Istvan Albert, Jul 28, 2004
    #10
  11. angel

    angel Guest

    How strange it is!
    I test "python" and "python -vSE".
    "python" startup time is 6-7 second, "python -vSE" just need 3 second.

    "Istvan Albert" <>
    ??????:p...
    > angel wrote:
    >
    > > Dose python need configure? For example: PATH or other?

    >
    > do a:
    >
    > python -vSEc "print 1"
    >
    > maybe you can identify the source of the slowdown.
    >
    > Istvan.
    >
     
    angel, Jul 29, 2004
    #11
  12. angel

    Jeff Epler Guest

    Then you've at least learned something: Files loaded due to site.py, or
    files on PYTHONPATH, add 3-4 seconds to start time.

    However, 6-7 seconds for "python -vc 'print 1'" is still excessive.
    That takes only 1/2 second here, and "python -c 'print 1'" takes 0.05
    seconds (the difference being the time to print all the "-v" lines,
    basically). (This is on an 650MHz Unix machine--A modern 2.7GHz Unix
    machine I just tested took 0.005 seconds for "python -SEc 'print 1'")

    The number one reason I've seen for slow Python startups are sys.path
    directories on the network (from personal experience). Other problems
    might be importing modules from directories without .pyc files and
    without write permissions (Python must parse and byte-compile the source
    files each time), or a module being imported attempts to do some
    network-related activity, such as find the hostname, but your network is
    misconfigured.

    .... or it could be some obscure Microsoft Windows misconfiguration that
    we'll never guess in a million years.

    Jeff

    -----BEGIN PGP SIGNATURE-----
    Version: GnuPG v1.2.4 (GNU/Linux)

    iD8DBQFBCN2KJd01MZaTXX0RAmLPAJ9yABzwgDsUUBhHJm1DaryltwieRwCfVGTm
    JSn5CHUgCm81NGJzujLtzOI=
    =P998
    -----END PGP SIGNATURE-----
     
    Jeff Epler, Jul 29, 2004
    #12
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. christof hoeke

    python startup on XP very slow

    christof hoeke, Jul 22, 2003, in forum: Python
    Replies:
    0
    Views:
    343
    christof hoeke
    Jul 22, 2003
  2. David Lees
    Replies:
    2
    Views:
    1,010
    David Lees
    Dec 19, 2008
  3. Alf P. Steinbach /Usenet

    Slow -- VERY slow brain

    Alf P. Steinbach /Usenet, Jun 16, 2011, in forum: C++
    Replies:
    17
    Views:
    542
    Noah Roberts
    Jun 29, 2011
  4. Nick Green
    Replies:
    4
    Views:
    207
    Nick Green
    Nov 18, 2009
  5. Pugi!
    Replies:
    0
    Views:
    255
    Pugi!
    Feb 5, 2007
Loading...

Share This Page