473,395 Members | 1,379 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Calculating Estimated time?

Hello!

I have a number of files to copy. I have to total Amount of files and the
Total FileSize of this operation (for example 3453 files, 4065.4 Mb)... How
can I calculate how much time this will take so the user have an Idea of how
much time it will take to copy? This will also be something to base a
progressbar on.

regards
/Lars
Nov 20 '05 #1
5 3466
Low long is a peice of string ?

This will depend on the server the files are being copied from and to, the
speed of the network, how congested it is.

As a rule of thum, measure the time for a 5GB file transfer on a busy day
and use that as a guide.

Regards

--

OHM ( Terry Burns )
. . . One-Handed-Man . . .

Time flies when you don't know what you're doing

"Lars Netzel" <no****@no.no> wrote in message
news:uV**************@tk2msftngp13.phx.gbl...
Hello!

I have a number of files to copy. I have to total Amount of files and the
Total FileSize of this operation (for example 3453 files, 4065.4 Mb)... How can I calculate how much time this will take so the user have an Idea of how much time it will take to copy? This will also be something to base a
progressbar on.

regards
/Lars

Nov 20 '05 #2
* "Lars Netzel" <no****@no.no> scripsit:
I have a number of files to copy. I have to total Amount of files and the
Total FileSize of this operation (for example 3453 files, 4065.4 Mb)... How
can I calculate how much time this will take so the user have an Idea of how
much time it will take to copy? This will also be something to base a
progressbar on.


IMO, that's not as easy. Windows provides this information and it's (at
least on my machine) always not accurate. When copying from HDD to HDD,
speed strongly depends on how fragmented the files are, so there is no
constant copying speed. You could, for example, calculate the current
time needed to copy 1 MB and then calculate how long the rest will take,
but if the copying speed decreases, the result can change quickly.

--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/>
Nov 20 '05 #3
Lars,
In addition to the others comments, I would use a "sliding" average...

I would start assuming I am copying x bytes/minute and display the estimated
time based on that.

For each y KB I copy I would time how long those KB took, giving me a new x
bytes/minute, allowing me to display a new estimated time based on the new x
bytes/minute...

Hope this helps
Jay

"Lars Netzel" <no****@no.no> wrote in message
news:uV**************@tk2msftngp13.phx.gbl...
Hello!

I have a number of files to copy. I have to total Amount of files and the
Total FileSize of this operation (for example 3453 files, 4065.4 Mb)... How can I calculate how much time this will take so the user have an Idea of how much time it will take to copy? This will also be something to base a
progressbar on.

regards
/Lars

Nov 20 '05 #4
yeah, that makes sence!

Thanx
/Lars

"Jay B. Harlow [MVP - Outlook]" <Ja************@msn.com> skrev i meddelandet
news:eZ**************@TK2MSFTNGP12.phx.gbl...
Lars,
In addition to the others comments, I would use a "sliding" average...

I would start assuming I am copying x bytes/minute and display the estimated time based on that.

For each y KB I copy I would time how long those KB took, giving me a new x bytes/minute, allowing me to display a new estimated time based on the new x bytes/minute...

Hope this helps
Jay

"Lars Netzel" <no****@no.no> wrote in message
news:uV**************@tk2msftngp13.phx.gbl...
Hello!

I have a number of files to copy. I have to total Amount of files and the Total FileSize of this operation (for example 3453 files, 4065.4 Mb)...

How
can I calculate how much time this will take so the user have an Idea of

how
much time it will take to copy? This will also be something to base a
progressbar on.

regards
/Lars


Nov 20 '05 #5
sorry for my stupidity but isn't it just a simple case of

speed=distance/time
thus
speed = totalfilesize/time

or sumthing

and then as you copy more bites you modify the formula

speed=(totalbytescopied)/(totaltimeittooksofar)

i don't know if this will work correctly but it will definitly vary between
say
a gig of small files, a one gig file and say 12 files comprising 1 gig in
total


"Lars Netzel" <no****@no.no> wrote in message
news:ek**************@TK2MSFTNGP09.phx.gbl...
yeah, that makes sence!

Thanx
/Lars

"Jay B. Harlow [MVP - Outlook]" <Ja************@msn.com> skrev i meddelandet news:eZ**************@TK2MSFTNGP12.phx.gbl...
Lars,
In addition to the others comments, I would use a "sliding" average...

I would start assuming I am copying x bytes/minute and display the estimated
time based on that.

For each y KB I copy I would time how long those KB took, giving me a new x
bytes/minute, allowing me to display a new estimated time based on the new
x
bytes/minute...

Hope this helps
Jay

"Lars Netzel" <no****@no.no> wrote in message
news:uV**************@tk2msftngp13.phx.gbl...
Hello!

I have a number of files to copy. I have to total Amount of files and

the Total FileSize of this operation (for example 3453 files, 4065.4

Mb)... How
can I calculate how much time this will take so the user have an Idea
of how
much time it will take to copy? This will also be something to base a
progressbar on.

regards
/Lars



Nov 20 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Ron Adam | last post by:
Hi, I'm having fun learning Python and want to say thanks to everyone here for a great programming language. Below is my first Python program (not my first program) and I'd apreciate any...
0
by: Kasp | last post by:
Hi there, I am trying to make an OLAP cube on a table having two columns (datetime, Number_of_times_an_event_occured). My dimension is time and I want to measure the Min and Max times an event...
1
by: Michal Januszczyk | last post by:
I build some web aplication that needs to return some binary data using Response.BinaryWrite(byte data) All is fine, but one thing: the browser does not display "estimated time left" and the size of...
2
by: Norton | last post by:
Dear All, I have an operation which will download a very large dataset from a web service. And i would like to know if there any method to : Get the percentage completed? Get the partial...
2
by: Hervé Piedvache | last post by:
Hi, I have a database with one table with about 22 millions records. I have a script every day wich insert about 200 000 records ... Sometime my script takes 4 hours to insert the data, sometime...
2
by: Ina Schmitz | last post by:
Hi NG, does IBM Universal Database 8.2 make any difference between actual and estimated execution plans like in SQL Server ("set showplan_all on" for estimated execution plan and "set statistics...
4
by: cbrichards via SQLMonster.com | last post by:
I have a stored procedure that will execute with less than 1,000 reads one time (with a specified set of parameters), then with a different set of parameters the procedure executes with close to...
25
by: Umesh | last post by:
i want to calculate the time required to execute a program. Also i want to calcute the time remaining for the execution of the program. how can i do that? pl mention some good websites for...
0
by: awyeah | last post by:
Hello everyone, I have some very difficult task to accomplish using ADODB, or DAO in visual basic 6 whichever. This is my masters project and I am stuck!! Say I have a recordset with 4 customers...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.