<commit_before>SAW-Testbed
===========

Testbed for paper: "SaW, Social Distributed Web-based Computing for Hardware-accelerated Image Analysis"

## Introduction

Our deployed SaW solution works over a client-server architecture On the server side there is a SaW
Scalable Server (S3) which manages a server cluster in order to provide a consistent, scalable and unique service front-end
to the clients. It deals with balancing the load through the different available servers. The SaW client side is completely
Web browser oriented to be executed on a connected device such as PCs, smartphones or tablets. SaW offers the Web
service providers an API to enhance their social services with seamless background image analysis tasks by means of taking
beneﬁt from the hardware resources of its big user community.

To test our system we have used a matrix multiplication (m1=1024x1024)*(m2=1024x1024) based on graphics hardware accelerations that brings WebGL.
This testbed use some nice code : http://github.com/bunions1/matrixMultiplyGpu 

## Features
 
 * Distribute large jobs
 * Use GPU for complex calculations
 * Enhance server-side infrastructure
 * Tested at smart-phone, tablets and pc (web browsed)


## Requisite

 * node.js
 * mongodb

## Quick Start

Install node.js all dependencies:
```bash
npm install
```

Start server:
```bash
node server.io.js
```
Set work resource:

```url
http://ip:5000/changetask?taskname=cl_matrix_mult.js
```
or :

```url
http://ip:5000/changetask?taskname=1.js
```
Reset queue:

```url
http://ip:5000/reset
```
Create new collection of jobs:
```url
http://ip:5000/createdb?numTask=20&taskname=1.js
```
Add hardware resource to server :
```url
http://ip:5000/add.html
```
Start Saw :
```url
http://ip:5000/start

```
## Important Note

The 1.js task does a matrix multiplication through webgl , 
cl_matrix_mult.js does with webcl.

We used a local servers to testbed, for trying yourself it will be necessary to change add.html sources; servers variable.
For simple test it is not need to work-balance at server so with localhost will be fine.<commit_msg>readme updated<commit_after>SAW-Testbed
===========

Testbed for paper: "SaW, Social Distributed Web-based Computing for Hardware-accelerated Image Analysis"

## Introduction

Our deployed SaW solution works over a client-server architecture On the server side there is a SaW
Scalable Server (S3) which manages a server cluster in order to provide a consistent, scalable and unique service front-end
to the clients. It deals with balancing the load through the different available servers. The SaW client side is completely
Web browser oriented to be executed on a connected device such as PCs, smartphones or tablets. SaW offers the Web
service providers an API to enhance their social services with seamless background image analysis tasks by means of taking
beneﬁt from the hardware resources of its big user community.

To test our system we have used a matrix multiplication (m1=1024x1024)*(m2=1024x1024) based on graphics hardware accelerations that brings WebGL.
This testbed use some nice code : http://github.com/bunions1/matrixMultiplyGpu 

## Features
 
 * Distribute large jobs
 * Use GPU for complex calculations
 * Enhance server-side infrastructure
 * Tested at smart-phone, tablets and pc (web browsed)


## Requisite

 * node.js
 * mongodb

## Quick Start

Install node.js all dependencies:
```bash
npm install
```

Start server:
```bash
node server.io.js
```
Set work resource:

```url
http://ip:5000/changetask?taskname=cl_matrix_mult.js
```
or :

```url
http://ip:5000/changetask?taskname=1.js
```
Reset queue:

```url
http://ip:5000/reset
```
Create new collection of jobs:
```url
http://ip:5000/createdb?numTask=20&taskname=1.js
```
Add hardware resource to server :
```url
http://ip:5000/add.html
```
Start Saw :
```url
http://ip:5000/start

```
## Important Note

The 1.js task does a matrix multiplication through webgl , 
cl_matrix_mult.js does with webcl.

We used a local servers to testbed, if you want to tested it will be necessary  change the add.html file; servers variable. Just for a simple test  is not need to work-balance at server so with localhost will be fine.
{'fraction_non_alphanumeric': 0.08533969010727056, 'fraction_numerical': 0.0233611442193087, 'mean_word_length': 4.693351424694709, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6730399', 'n_tokens_mistral': 1298, 'n_tokens_neox': 1145, 'n_words': 531}