Combining databases and parallel computing in ...

5 downloads 63791 Views 841KB Size Report
existing solutions is best for tomographic purposes. Electrical Capacitance ... participation of many industry-leading companies and institutions including AMD, Apple .... ODBC, Perl, PHP (dedicated server for Zend Core 2 IBM),. C / C + +, Java.
1

2

3

Łukasz WĄS , Michał MAJCHROWICZ , Paweł KAPUSTA , Politechnika Łódzka, Instytut Mechatroniki i Systemów Informatycznych (1), Politechnika Łódzka, Katedra Informatyki Stosowanej (2), Politechnika Łódzka, Katedra Informatyki Stosowanej (3)

Combining databases and parallel computing in distributed enviroments to accelerate image reconstruction and algorithm development in Electrical Capacitance Tomography Abstract. . The main goal of this article is to describe the set of solutions based on the OpenCL and Xgrid technologies that would accelerate image reconstruction from measurements aquired from database calculation process in 2D and 3D Electrical Capacitance Tomography. The authors propose a new idea of performing the image reconstruction process by combining graphic cards and parallel programming techniques using OpenCL technology with distributed computing based on Xgrid clusters and Oracle database as source of measurement data. For that purpose the algorithms and methods have been designed that enable the use of developed solutions in the image reconstruction. (Combining databases and parallel computing in distributed enviroments to accelerate image reconstruction and algorithm development in Electrical Capacitance Tomography). Słowa kluczowe: elektryczna tomografia pojemnościowa, OpenCL, Xgrid, bazy danych Keywords: Electrical Capacitance Tomography, OpenCL, Xgrid, Databases

Introduction Electrical Capacitance Tomography is a modern noninvasive imaging technique, which allows the visualization of the industrial processes interior and can be applied for many branches of the industry. The image reconstruction process, especially in case of 3D reconstruction, is very complicated and may take long time to be solved using classic processors and algorithms. That leads to an inacceptable waiting time for the image reconstruction and currently limits the use of 3D Electrical Capacitance Tomography. ECT can generate a lot of data, that has to be stored and processed at later time. For that purpose tests of databases have been conducted to show which of the existing solutions is best for tomographic purposes.

Electrical Capacitance Tomography In the three-dimensional Electrical Capacitance Tomography (3D ECT) an approximation for the internal spatial permittivity distribution is computed using the knowledge about the capacitance measurement data acquired from the spatially located set of electrodes on the surface of the investigated object. It is often assumed that the electrostatic fields are simplified to the two-dimensional electrode plane and the image reconstruction is based on 2D assumptions or non-true 3D called as “2.5D” interpolation. However, the actual electrostatic field is spreading out in three dimensions and, therefore, all the volumetric structures inside an industrial process have significant effect on the reconstructed images Electrodes at the surface of the volume apply electrical potential into the surrounding area and emergent charge is measured at the boundary. The measured data is then used in an electrostatic model to determine the dielectric permittivity properties of the object. Electrical capacitance tomography is a relatively mature imaging method in industrial process tomography. 3D ECT can be important tool for imaging the volumetric distribution of electrical permittivity. 3D ECT image reconstruction presents a similar inverse problem to electrical impedance tomography (EIT), which has been extensively studied, so 3D ECT will naturally benefit from progress in 3D EIT image reconstruction. Similarly to EIT, ECT has potential to

generate images with high temporal resolution and relatively poor spatial resolution. Among other non-invasive imaging techniques, ECT characterizes much higher temporal resolution than MRI, CT etc. This makes ECT a good candidate for real-time imaging technique which is

capable of long term monitoring on fast-varying industrial process applications. To reach this goal 3D ECT computational subsystem should be able to transform capacitance data into image in fractions of seconds, which is really hard to achieve since typically 3D ECT tomography image can be composed of large number of elements. 3D ECT provides a few challenging computational issues that have been reported in the past by many researchers. It comes from the fact that most of direct and iterative 3D ECT reconstruction techniques uses matrices processing and manipulation which is too complex to be processed in a real-time using classic (even multi-core) CPUs. Applications of ECT include the monitoring of oil-gas flows in pipelines, gas-solids flows in pneumatic conveying and imaging flames in combustion, gravitational flows in silo.

OpenCL OpenCL (Open Computing Language) is the first open, royalty-free standard for cross-platform, parallel programming of modern processors found in personal computers, servers and handheld or embedded devices. It was initially developed by Apple Inc., which holds trademark rights, and refined into an initial proposal in collaboration with technical teams at AMD, IBM, Intel, and Nvidia. It is a framework for writing programs that can execute across heterogeneous platforms (consisting of CPUs, GPUs, and other processors). It is composed of a programming language (based on C99 with very specific extensions and limitations) for writing kernels (functions that can be executed on OpenCL capable devices) and APIs for defining and controlling the platform. OpenCL supports a wide range of applications, from embedded and consumer software to HPC solutions,

through a low-level, high-performance, portable abstraction. By creating an efficient, close-to-the-metal programming interface, OpenCL will form the foundation layer of a parallel computing ecosystem of platform-independent tools and applications.

recipient. Xgrid messages are encoded into dictionaries of key/value pairs and converted into XML format before being sent using BEEP network.

Figure 1. Heterogeneous computing OpenCL gives any application access to the Graphical Processing Unit for non graphical computing, so OpenCL extends the power of the Graphical Processing Unit beyond graphics. OpenCL is analogous to the open industry standards OpenGL and OpenAL, for 3D graphics and computer audio, respectively. OpenCL is managed by the non-profit technology consortium Khronos Group with the participation of many industry-leading companies and institutions including AMD, Apple, IBM, Intel, NVIDIA, QNX, Texas Instruments and many others.

Figure 2. Xgrid network

The architecture of Xgrid is designed around job based system. Every job consists of all instructions and data (files) necessary to perform a calculation. In order to fully exploit Xgrid potential all instructions provided by the controller must be able to be executed simultaneously or asynchronously.

Xgrid Xgrid is a program and distributed computing protocol developed by Advanced Computation Group a subdivision of Apple Inc. We have decided to use Xgrid as sample distributed platform. It provides administration tools for easy creation of computing clusters that tap into previously unused computational power for calculations that are easily parallelizable. Creating a cluster does not require any additional spending since Xgrid is preinstalled on all Mac OS X 10.4 or later machines. Xgrid technology consists of three components - client, controller and agent. Process of submitting new tasks is performed in following order: • The client sends jobs to the controller • The controller queues the jobs and sends them to the agent • The agent runs the job The point of the technology is to have several agents working in parallel, each on a different job. It is also possible to have several clients. All nodes communicate with each other using propriety protocol based on BEEP framework. Every machine that has Mac OS X with Xgrid installed is automatically detected by controller and added to the list of available computers to use for processing tasks. Every job send to controller is split into smaller packets called tasks. These small packets are transferred to all Xgrid-enabled computers on the network. Every node executes instructions provided by the controller and after finishing the calculations returns the results. After that the controller assembles all task results into job results and returns them to the client. The protocol consists of three types of messages that are sent between computers combined in a cluster: requests, notifications and replies. Every request requires a reply, notification does not require a reply, and replies are responses to previous requests. All messages are encapsulated into BEEP message (BEEP MSG) and acknowledge by sending an empty reply (RPY) by the

Obstacles and developed solution In ECT tomography image reconstruction requires multiplying matrices that (in binary format) are 200 MB or more in size, with small matrices that are the output from capacity sensors. Sending data is a very important issue since it introduces additional delays and hinders the whole process. Transferring large amounts of data over a LAN slows down the calculation process and makes it impossible to achieve on-line (many frames per second) image reconstruction despite using high computing power. Moreover these big matrices (sensitivity matrices) do not change, the only thing that is being replaced are small matrices provided by the ECT system (measurements). Furthermore, for performing calculation instant matrices exchange is required in every iteration of current algorithm. It should also be noted that Xgrid uses base64 format for transferring binary files which introduces overhead and increases the size by 30%. Moreover TCP/IP randomness makes it very hard to predict how long it will take to transfer all information needed to perform computation. After transferring data time to load matrices form the disk has to be also taken into consideration as it might take as long as up to 6-7 seconds with matrices 200MB in size. Unfortunately all data transferred to the clients is lost after calculation is finished. If computations are performed in a relatively short time then the amount of data that has to be transferred can have a significant impact on performance. As it was stated before Xgrid system does not provide any way of storing data for later usage. In order to achieve such functionality we have created a small program that copies all files from local directory to /tmp/xgridagent_data on remote machines. It is also capable of creating this directory and also listing, computing md5 check-sum and deleting all files from it. Our research also revealed that Xgrid has problems with transferring data that are bigger then 50 MB but thanks to presented solution it is possible to split the file

into many parts and transfer every part to target machine separately. We have also modified source code of xgridagent-java, a program that can be run on machines with Windows or Linux operating systems installed, that is capable of connecting to Xgrid network, accepting and running tasks. As a result every computer running one of mentioned operating system can be used to accelerate the calculations. The combination of tools require creating tasks in form of C programs that can be compiled on any of mentioned systems and providing three binary files one without the extension (for Mac OS X) with exe extension (for Windows) and with lin extension (for Linux). After creating such environment we were able to easily distribute OpenCL executables that performed LBP algorithm and, as a result, achieve significant acceleration of image reconstruction process.

Database as source of input In order to speed up the development an off-line spurce of previously prepared tomographic data had to be used.. The simplest solution is to use files for storing such information nevertheless data distribution can be problematic in such scenario. Authors have decided to use SQL database since implementing it didn’t require many changes in existing architecture and simplified providing new tomographic measurements. For that purpose four databases have been tested to check which one will be best for tomographic purposes.

DB2 IBM DB2 database v9.5 is offered in three commercial editions: Express, Workgroup, and Enterprise and the free edition of DB2 Express-C. All editions of DB2 are based on the same code and different licensing restrictions resulting from the used hardware platform and any optional components. All editions contain the same set of graphical administrative tools that are available as standard in the Polish language. Free edition DB2 Express-C can be used in commercial solutions and not limit the size of the database. For each server, free database technical support can be purchased for one year (DB2 Express-C FTL). Purchased technical support allows access to regularly published by IBM code updates and provides the ability to configure database architecture for high availability. Compressed format of records in DB2 allows for significant space saving storage arrays with a small overhead associated with using an extra processor. Compression in DB2 uses algorithms tested for years in mainframe (technology, "Venom"). Tests on production data show an average of 60-80% compression ratio, which means that the occupancy of the database tables is reduced approximately threefold compared to an uncompressed format. Data compression in DB2 is based on the dictionary patterns, which is being built globally on the table or partition table. The repeating pattern in the record is converted to a symbol from the dictionary compression. Records on disk and in memory are stored in compressed form and are decompressed only when sending a data stream to an application or an evaluation record. Due to compressed format, the record can be much more efficient I/O operations, because at the same base load drive reads into memory a lot more records. Implemented in the DB2 V9 database model combines the features of a purely relational systems, as well as dedicated systems for XML. This is achieved by integrating two previously independently operating engine databases: relational and hierarchical. This approach provides much better performance XML processing in comparison to

techniques based on binary BLOB objects and techniques for the decomposition of relational tables. IBM DB2 v9 database server is operating in parallel with the three most popular techniques for data partitioning: partitioning to scope, partitioning, multidimensional partitioning, and mixed. Partition ranges - based on sharing a table at the fragments of the partitioning key. Inserted lines are shared between partitions on the basis of the established range partitioning key. Partitioning mixed - the data is divided on the basis of the values returned by the hash function generated on the basis of the partitioning key and the number of partitions. This method is used by the Database Partitioning Feature (DPF) in order to automatically distribute data on multiple computers. Partitioning multi-dimensional - is based on the physical organization of tables in a special block in which the records are grouped with the same key values of Multidimensional Clustering (MDC). For MDC tables organized mechanism to automatically create the bitmap indexes for faster location of the blocks. In order to enhance the potential of huge volumes of data calculation SQL queries are automatically divided into subtasks and executed in parallel on all clusters. Therefore, clustering is of utmost importance in multidimensional systems, such as OLAP and data warehouses. The major advantages of partitioning the data are classified as: • Increase the capacity of the amount of stored data in one table. • Easier management boards with a huge amount of data • Optimization of SQL queries to obtain results • Opportunities to gain quick release (roll-out) and append (roll-in) data sets. • Load Manager DB2 supports both SQL and XQuery and XPath. It also supports popular programming languages such as CLI ODBC, Perl, PHP (dedicated server for Zend Core 2 IBM), C / C + +, Java. IBM DB2 V9 also has extensive support for MS platforms. NET.

Oracle Oracle Database is the official name of the relational database system (RDBMS) developed by Oracle Corporation. It uses a standard SQL query language and has an internal language to create stored procedures PL / SQL - which is shielded procedurally SQL. As a language to create stored procedures in Oracle databases (version 8i) can also use the Java language. The structure of the instance SCHEMA - schema is a collection of objects belonging to the user. Most installations have a default Oracle schema named SCOTT. After the installation process will create the example tables, the user (user) can log on to a database system with username: scott and default password: tiger. SCOTT schemy name comes from one of the first employees of Oracle Corporation. (Bruce Scott) whose cat wabił the Tiger. Other default schemy include: • SYS (the basic structure of the database and tools) • SYSTEM (additional database structures and utilities, and privileged account) • OUTLN (used to store metadata for the queryoptimizer.



BI, IX, HR, OE, PM, SH (extended schemy sample containing more data and structures than the original schema SCOTT)

Memory Structure Oracle database instance consists of shared memory structures (to which access to all the processes that support department) and private structures that are available only for processes that these structures allocated. The basic structure of SGA is a mind that is System Global Area or Shared Global Area depending on the terminology. The SGA consists of: • Shared Pool - Shared pool • Library Cache • Shared SQL Area - the space that stores parsed SQL and PL / SQL programs • PL / SQL Area - space PL / SQL Code • SQL Area - the space was last executed SQL • Data Dictionary Cache - cache database dictionaries • Database Buffer Cache - the area of structured data buffer in the LRU list • Redo Log Buffer Cache - a buffer area records reps, which is the transaction log database • Large Pool (structure optional) - is used, inter alia, communication between parallel processes • Java Pool (structure optional) - the space intended for the use of stored procedures written in Java Structures should also be shared Software Code Area structure which holds the executable code of Oracle processes. The occurrence of this area is dependent on the operating system. Outside the structures of shared space is available PGA or Program Global Area. PGA is only available for a process that creates them, and includes: • Space Stack (Stack Space) • About the Process • Sort Area - collation area Background processes included in the Oracle instance: • Database Writer (DBWn) - the process of "browsing" database cache and write modified blocks on the disks. • Log Writer (LGWR) - the process of recording the history of transaction log files repeats. • Checkpoint (CKPT) - the process of pursuing the implementation of the control points • System Monitor (SMON) - monitors database instance • Process Monitor (PMON) - monitors user processes and performs the "cleaning up" the process incorrectly completed users • Archiver (ARCn) - the process of copying files logs filled with repetitions • Recovery (RECO) - the process responsible for replicating distributed transactions that have failed in the performance of 2PC protocol • Lock (LCKn) - exists only in the RAC configuration and is used to synchronize access to resources • Queue Monitor (QMNn) - monitors the message queue With each user connected to the database instance is associated process designed to support it. Oracle database has two modes of customer service: dedicated and shared. In the case of dedicated mode, each client is appointed the new process, which is responsible for simplifying the processing of queries, reading data from disk to buffer or to locate existing data in the buffer, writing changed as a result

of client operations to the buffer blocks. For shared configurations are appointed for life processes: • Dispatcher (Dnnn) • Shared Server (Snnn) After connecting to a database connection to one of the existing processes Dispacher and the request is properly queued and sent to a process called Shared Server supports. In the configuration of the shared number of user processes is determined by the parameters of the database, but the configuration of dedicated number of processes equals the number of simultaneously connected users. In addition to those during the operation of Oracle instances can run a variety of processes related to, inter alia, the use of specific features of the database. On the Windows platform, Oracle Database is unning on multithreading architecture rather than multi-process, therefore, the processes described are implemented as threads of the process that supports the main database instance. Storage Structure The Oracle database includes: • parameter file - a file describing the parameters of the Oracle database instance and the path to control files • control files - multiplied store information about the structure of the database (information about data files, backup stories, SCN numbers, information on the archival log of repetitions, the mode of the database) • logs repetitions - keep repeated information about transactions carried out in the system and are omni - after filling the information is overwritten • archive logs repetitions - repetitions executed copies of the newspapers after their full • data files - which are stored in the system collects data and support structures (eg indexes). Oracle database instead of files can also use the socalled raw devices (partitions unformatted). The data in Oracle database is stored in tables in table spaces (tablespace). A single table space can span multiple data files and a single file can only belong to one space. Space tables may logically consist of various segments (sets of data blocks allocated to the object database.) The segment is the group of extents, which in turn are continuous sets of data blocks. Blocks are the smallest unit of space allocation. Oracle Database can use blocks of different sizes. The most important area of tables for the operation of the database is a space that holds all the dictionaries which is called System database.

MS SQLServer 2005 Microsoft SQL Server is a database management system, supported and distributed by Microsoft Corporation. This is the main product of the company's database, which is characterized by the fact that as the query language is used primarily Transact-SQL, which is a development of the ANSI / ISO. MS SQL Server database platform is a client-server. Compared to Microsoft Jet, which is used in MS Access, delivers a better performance, reliability and scalability. First of all, here are implemented in all the mechanisms affecting the safety of operations (including triggers). SQL Server 2005 provides a platform for data management and analysis. The database allows you to increase the security, scalability and availability to enterprise data and analytical applications, and at the same time greatly simplifies the task creation, implementation and administration of data.

Database SQL Server 2005 is designed to help companies meet these challenges. SQL Server 2005 provides a platform for data management and analysis. The database allows you to increase the security, scalability and availability to enterprise data and analytical applications, and at the same time greatly simplifies the task creation, implementation and administration of data. SQL Server 2005 provides an integrated data management and analysis solution that enables organizations of all sizes: • Build and deploy more secure, scalable and reliable industry applications, • Increase the productivity of IT by reducing the complexity of creating, deploying and managing database applications, • Equipment developers in functional, flexible and modern development environment for creating more secure database applications, • Data sharing across platforms, applications and devices, making it easier to combine internal and external systems, • Toward a comprehensive, integrated business intelligence solutions that help make better decisions and enhance productivity across the organization, • Control costs without sacrificing performance, availability and scalability. Enterprise data management In the era of wider communication, information and systems that manage that data must be continuously available to users. Users and corporate IT managers will benefit from the use of SQL Server 2005, the reduced application downtime, increased scalability and performance, and tight security controls. In SQL Server 2005 enterprise data management improved in the following areas: • Availability - investment in high availability technologies, additional opportunities for creating and reading backup and replication enhancements enable organizations to create and deploy reliable applications. • Scalability - making techniques such as partitioning, snapshot replication, and support for 64-bit processors allows you to build and deploy SQL Server 2005 platform, even the most demanding applications. • Security - the introduction of setting the "secure by default" (safe defaults), and enhanced security model allows you to maintain a high degree of data security company. • Easiness of use - a new set of management tools that extend the functionality of the database autotuning and a new, enhanced programming model that contribute to increasing the productivity database administrators. • Interoperability - full support for industry standards, web services and integration with the platform. NET Framework to enable collaboration SQL Server 2005 with multiple platforms, applications and devices. SQL Server 2005 database is designed to help companies meet these challenges. SQL Server 2005 provides a platform for data management and analysis. The database allows you to increase the security, scalability and availability to enterprise data and analytical applications, and at the same time greatly simplifies the task creation, implementation and administration of data.

My SQL MySQL is a freely available relational database management system data. It is developed by Oracle. Previously, most of the time it dealt with the creation of a Swedish company MySQL AB. MySQL was written more for speed than compatibility with the SQL standard - for a long time MySQL did not support even a transaction that was indeed the main argument of opponents of the project In version 5 was added, among others: • stored procedures (called Stored Procedures) – current version 5.0, • triggers (called triggers) - present from version 5.0.2 • Perspective (called views) • cursors - from the current version 5.1 • table partitioning - from version 5.1 • schedule of tasks - from version 5.1 which brings the latest versions of MySQL to PostgreSQL in terms of functionality. MySQL provides support for database replication (in a master-slave) and multilingualism - each table, and even each field can have its own setting for character encoding. Platforms for which MySQL is available. The MySQL server is available for all popular platforms and different processor architectures. It is also available in the source, which allows to compile it for any other platform. Officially, they are binary versions available for the following platforms and architectures (MySQL 4.1): • Linux (x86, S/390, IA64 (Itanium), Alpha, PowerPC, AMD64 / EM64T) • Windows (x86, x64) • Solaris (SPARC, x86) • FreeBSD (x86) • MacOS X • HP-UX (PA-RISC, IA64) • AIX (RS6000) • i5/OS (IBM System I) • QNX (x86) • Novell NetWare (x86) • SGI • DEC OSF. According to information from the documentation server, MySQL can also compile for platforms: Amiga, BSDI, Digital Unix, NetBSD, OpenBSD, OS / 2 Warp, SCO OpenServer, SCO UnixWare, SunOS, Tru64 Unix. Like the server MySQL client libraries, enabling the use of the database server from an application are available for many platforms and programming languages - including for C, C, Delphi, and PHP. Types of supported database mechanisms MySQL offers different types of mechanisms, database, each type is designed for other uses. These include: • MyISAM - the default mechanism that does not support the transaction or even foreign keys, and allows (in contrast to other types), full-text search. • MEMORY (for version 4.1 - HEAP) - the fastest, because everything is stored only in RAM. However, it has several limitations, among other things does not store the data after excluding the MySQL server. • InnoDB - transactions support. • BerkeleyDB - supports transactions, as yet not fully integrated with MySQL. • MERGE - to call the MyISAM tables. • Federated - enables the creation of distributed databases.

• •

CSV - stores data in standard CSV files. ARCHIVE - (version 4.1) stores data in compressed archives. Only allows you to add and retrieve records.

cache indexes and therefore speeds up executing of next ones.

Figure 3. Query execution time on IBM DB2 Database

Figure 5. Query execution time on Oracle Database

Figure 4. Query execution time on MySQL database

Figure 6. Query execution time on MS SQL database

Databases analysis In order to choose datbase that would be best for processing tomographic measurements we had to perform additional analysis. All tests were conducted with indexing turned on using 100 queries on table with 266898 records. In case of DB2 database it can be seen that only first query takes more than 350 milliseconds. After that execution time was much shorter, oscilating around 150 ms. Tests on MySQL database gave similar results. However this time oscillation was much more intense. It’s also very interesting that spikes occurred in the same places as in case of IBM DB2. On Oracle tests show much more stable results. The oscillation is barely noticeable. Only two small spikes show different amplitude. Tests on MS SQL Server revealed more spikes than in case of Oracle database. The graph is more similar to IBM DB2 and MySQL. In all cases we can notice that first query takes much more time than any other. Probably database uses it to

As can be seen on the graphs 3-6 the amplitude of oscillation and number of random spikes of time of execution were the lowest in case of Oracle database. Therefore that was the DBMS that was used during testing.

Tests We have conducted a series of tests with our proposed solution. They included: • executing the algorithm locally on a CPU • executing the algorithm on our Xgrid distributed system (on a CPU) • executing the algorithm on Xgrid system using GPU computations Because OpenCL is still in an early development phase authors were unable to perform combined CPU - GPU computations, as there is currently no possibility of running calculations on Intel processors with Nvidia graphics cards installed, which was the configuration of our test systems.

All the CPU tests were performed on a Intel Core 2 Duo processors with 2,53 GHz clock and GPU tests were carried out on Nvidia 8700M GT cards. For our tests we have used a simple method of achieving image reconstruction in ECT called LBP algorithm, described by equation (1):

(1)

parallelizable algorithms can greatly benefit from running them in parallel on systems that utilize OpenCL technology.

REFERENCES [1] M.K.White, “Apple Training Series: Mac OS X Support Essentials”, Berkley, Peachpit Press 2008 [2] D.A.Kshemkalyani, “Distributed Computing: Principles, Algorithms, and Systems”, Cambridge, Cambridge University Press 2008

ε = S*C

where S is the sensitivity matrix, C is the vector of capacity

measurements and ε is the image vector. We have chosen this algorithm as it is easily parallelizable. A more advanced algorithm for image reconstruction, that will give much better image quality and will also be fully parallelizable is currently under development and we have calculated, that it's computation complexity will be at least forty times higher than LBP. That is why we are performing our tests by calculating the LBP algorithm that many times before returning the results to simulate the new algorithm's requirements for computing power. We have used relatively big matrices for our tests to show that even in such scenario near real-time image reconstruction would be possible with the help of parallel and distributed computing. The graph on Figure 3 shows the results of our testing. Four cases are described: • Calculations done entirely on local computer. • Calculations done on a distributed system consisting of two identical computers. • Calculations done on CPU, but with four machines. • Calculations done entirely on GPUs, with four machines connected into an Xgrid system.

[3] B.D.Kirk, “Programming Massively Parallel Processors: A Hands-on Approach”, San Francisco, Morgan Kaufmann 2010 [4] M. Herlihy, “The Art of Multiprocessor Programming”, San Francisco, Morgan Kaufmann 2008 [5] Wajman R., Banasiak R., Mazurkiewicz Ł., Dyakowski T., Sankowski D., Spatial imaging with 3D capacitance measurements, Measurement Science and Technology, vol. 17, no. 8, August 2006, pp. 2113-2118. [6] Soleimani M., Three-dimensional electrical capacitance tomography imaging, Insight, Non-Destructive Testing and Condition Monitoring, Vol. 48, (2006), No. 10, Pages: 613617. [7] Warsito W. and Fan L-S Development of 3-Dimensional Electrical Capacitance Tomography Based on Neural Network Multi-criterion Optimization Image Reconstruction, rd World Congress on Industrial Process proc. of 3 Tomography (Banff 2003), pp. 942-947. [8] Soleimani, M., Mitchell, C. N., Banasiak, R., Wajman, R., Adler, A., Four-dimensional electrical capacitance tomography imaging using experimental data, Progress In Electromagnetics Research-PIER (2009), 90, pp. 171-186. [9] Romanowski A., Grudzien K., Banasiak R., Williams R.A, Sankowski D., Hopper Flow Measurement Data th Visualization: Developments Towards 3D, proc of 5 World Congress on Industrial Process Tomography, Bergen, Norway 2006. [10] Yang W Q., Peng L., Image reconstruction algorithms for electrical capacitance tomography, Institute of Physics Publishing 2002 [11] Microsoft SQL Server 2005. Podręcznik programisty, Denielle Otey, Michael Otey, Helion 2007

Figure 7 Time of computations It is clearly visible that distributing calculations, especially when using graphic cards for computations, proves to be highly effective. It has to be noted however, that not all algorithms can be accelerated in such a way, only those in which the ratio of calculations to transfers is very high because the proposed architecture introduces overhead to all transfers as we are using LAN based networks for simplicity, scalability and ease of implementation.

Conclusion As can be seen on figure 7, ECT image reconstruction process can by significantly accelerated by combining GPU computing with Xgrid technology. Although presented architecture has many flaws such as Xgrid data transfer problems or lack of CPU support in NVIDIA's implementation of OpenCL, it proves that many

[12] Adam Machanic, Joseph Sack, Julian Skin, Rob Walters, Robin Dewson, Thomas Rizzo, SQL Server 2005, Helion 2007 [13] Andrew J. Brust; Stephen Forte, Programowanie Microsoft SQL Server 2005, Microsoft Press 2006 [14] Kalen Delaney, Microsoft SQL Server 2005: Podstawy baz danych krok po kroku, Microsoft Press 2006 [15]

http://www.khronos.com/opencl/

Autorzy: MSc Łukasz Wąs, Politechnika Łódzka, Instytut Mechatroniki i Systemów Informatycznych, ul. Stefanowskiego 18/22, 90-924 Łódź ,E-mail: ; MSc Michał Majchrowicz, Politechnika Łódzka, Katedra Informatyki Stosowanej, ul. Stefanowskiego 18/22, 90-924 Łódź ,E-mail: [email protected] MSc Paweł Kapusta, Politechnika Łódzka, Katedra Informatyki Stosowanej, ul. Stefanowskiego 18/22, 90-924 Łódź ,E-mail: [email protected]