• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 75
  • Last Modified:

How to reduce the processing time of a C# application that merges tif image files using VS2010 with .Net Framework 4.0 ?

I am developing a C# application using VS2010 and .Net Framework 4.0

I have attached my C# code.

Basically I am reading a directory that has over 10,000 check images.
For each check, there are 2 check image files (front side of check and back side of check):   XXX represents the filename.  
XXX._Front.TIF
XXX._Rear.TIF

I have a function named "ProcessDirectory" that retrieves each check's file name and then calls a function titled "ProcessImage"
which merges the front check image file and back check image file into 1 check image file per check that shows the front check image on the top and the back check image on the bottom of the merged file.

This executable takes over 90 minutes to run. Can you think of a way to reduce the processing time by modifying the code?
0
zimmer9
Asked:
zimmer9
1 Solution
 
Fernando SotoRetiredCommented:
What code?
0
 
zimmer9Author Commented:
0
 
David Johnson, CD, MVPOwnerCommented:
90 minutes per image or 90 minutes to process 10K images? Have you profiled your code to see where it is bogging down? What are your disk queue's like? How many iops do you have available? (read/write to an SSD might help). What is your cpu percentage?  Lots of free memory?
Why still using VS2010?
0
Cloud Class® Course: CompTIA Healthcare IT Tech

This course will help prep you to earn the CompTIA Healthcare IT Technician certification showing that you have the knowledge and skills needed to succeed in installing, managing, and troubleshooting IT systems in medical and clinical settings.

 
zimmer9Author Commented:
90 minutes to process the 10K images.
0
 
käµfm³d 👽Commented:
Have you profiled your code to see where the most time is being spent?
0
 
Kyle AbrahamsSenior .Net DeveloperCommented:
Also have you tried to go multithreaded?

eg:
get a distinct list of the check images
then pass to a thread to with the file name to do the actual processing.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Cloud Class® Course: MCSA MCSE Windows Server 2012

This course teaches how to install and configure Windows Server 2012 R2.  It is the first step on your path to becoming a Microsoft Certified Solutions Expert (MCSE).

Tackle projects and never again get stuck behind a technical roadblock.
Join Now