ImageJ is a very popular Java-based open-source software developed by the National Institute of Health (NIH) primarily for biomedical image processing and microscopy, as it is easy to use and very simple to implement new tools and macros to make it more useful. However, processing and filtering high-resolution images or stacks composed of a very large number of slides can often be very time-consuming, so it is important to reduce time to improve processing efficiency. One way to improve it is to use threads. A multi-threaded program contains two or more parts that can run simultaneously. Each part of such a program is called a thread, and each defines an independent execution path. Thus, multithreading is a specialized form of multitasking. In a thread-based multitasking environment, the thread is the smallest unit of dispatchable code. This means that a single program can perform two or more tasks simultaneously. Multithreading enables efficient programs to be written that take full advantage of the processing power available on the system. Although ImageJ employs multithreading, it is sometimes not sufficient to speed up processes. Therefore, in this work, threads were implemented inside several filters written as ImageJ plugins to speed up their performance in such situations. For the experiment, ten images were scaled to different dimensions and the processing times of the threaded versus non-threaded filters were noted. On average, a 24% speedup was observed. This performance improvement would be even more useful for even larger images and image stacks.
|