Schoener loggen
This commit is contained in:
parent
a10cd1486d
commit
f8715d1ea8
1 changed files with 6 additions and 5 deletions
|
@ -1,6 +1,6 @@
|
||||||
#!/usr/local/bin/python
|
#!/usr/local/bin/python
|
||||||
|
|
||||||
# $Schlepperbande: src/tivomirror/tivomirror,v 1.52 2014/03/02 22:19:36 stb Exp $
|
# $Schlepperbande: src/tivomirror/tivomirror,v 1.53 2014/05/30 20:53:01 stb Exp $
|
||||||
#
|
#
|
||||||
# Stefans Script, um die Sendungen vom Tivo runterzuladen und in MPEG4
|
# Stefans Script, um die Sendungen vom Tivo runterzuladen und in MPEG4
|
||||||
# zu transkodieren.
|
# zu transkodieren.
|
||||||
|
@ -252,8 +252,9 @@ def download(file, url, mak, target):
|
||||||
now = time.time()
|
now = time.time()
|
||||||
if (now - upd) > 60:
|
if (now - upd) > 60:
|
||||||
upd = now
|
upd = now
|
||||||
mb = count / 1024.0 / 1024.0
|
dur = now - start
|
||||||
print " %5.1f MB downloaded, %.3f MB/s" % (mb, mb / now)
|
mb = count / 1e6
|
||||||
|
print " %5.3f GB downloaded in %.0f min, %.3f MB/s" % (mb / 1e3, dur / 60, mb / dur)
|
||||||
finally:
|
finally:
|
||||||
try:
|
try:
|
||||||
p_decode.stdin.close()
|
p_decode.stdin.close()
|
||||||
|
@ -267,8 +268,8 @@ def download(file, url, mak, target):
|
||||||
raise TivoException("downloaded file is too small")
|
raise TivoException("downloaded file is too small")
|
||||||
elapsed = time.time() - start
|
elapsed = time.time() - start
|
||||||
throughput = size / elapsed
|
throughput = size / elapsed
|
||||||
print "%5.3fGB transferred in %.f.%02.f hours, %.1fkB/s" % (
|
print "%5.3fGB transferred in %d:%02d, %.1f MB/s" % (
|
||||||
size/1e9, elapsed/3600, int(elapsed / 60) % 60, throughput/1e3)
|
size/1e9, int(elapsed/3600), int(elapsed / 60) % 60, throughput/1e6)
|
||||||
|
|
||||||
|
|
||||||
def download_decode(item, mak):
|
def download_decode(item, mak):
|
||||||
|
|
Loading…
Reference in a new issue