<commit_before># OpenRadiation
## Abstract
This project aims to develop a database to store environmental radioactivity measurements. It's shared in 2 parts : 
* backend : the postgresql backend database
* api : a JSON Rest-like API developed in node.js to request the database

Source code is under licence Apache 2.0 (cf https://www.openradiation.org/fr/conditions-dutilisation#licence_apache2)

First at all, to use the API you need a key. Please ask by sending an email to [<EMAIL>](mailto:<EMAIL>)
For only a few tests, you're allowed to use the following key : <KEY>

By using this API, you accept the terms of use : https://www.openradiation.org/conditions-dutilisation

This project is self-sufficient, but it is designed to work with the openradiation.org website.
There is restricted access for this website to give informations about users and qualifications.
The API is designed to be installed in two parts : the submit api and the request api.

## Structure of the data

<table>
<tr><th>API Name</th><th>Type</th><th>Available for request API</th><th>Available for submit API</th><th>Description</th></tr>
<tr><td>apparatusId</td><td>String</td><td></td><td></td><td>Unique sensor identifier</td></tr>
<tr><td>apparatusVersion</td><td>String</td><td> </td><td> </td><td>Sensor firmware version</td></tr>
<tr><td>apparatusSensorType</td><td>String</td><td> </td><td> </td><td>Sensor type : geiger, photodiode</td></tr>
<tr><td>apparatusTubeType</td><td>String</td><td> </td><td> </td><td>Tube identification (only if apparatusSensorType = geiger)</td></tr>
<tr><td>temperature</td><td>Integer</td><td></td><td></td><td>Temperature (°C) </td></tr>
<tr><td>value</td><td>Real</td><td>*</td><td>Mandatory</td><td>value (µSv/h)</td></tr>
<tr><td>hitsNumber</td><td>Integer</td><td></td><td></td><td>Hits Number</td></tr>
<tr><td>startTime</td><td>Timestamp</td><td>*</td><td>Mandatory</td><td>Date of the beginning of the measurement (ISO GMT)</td></tr>
<tr><td>endTime</td><td>Timestamp</td><td></td><td> </td><td>Date of the end of the measurement (ISO GMT)</td></tr>
<tr><td>latitude</td><td>Real</td><td>*</td><td>Mandatory</td><td>latitude</td></tr>
<tr><td>longitude</td><td>Real</td><td>*</td><td>Mandatory</td><td>longitude</td></tr>
<tr><td>accuracy</td><td>Real</td><td></td><td> </td><td>Position accuracy in meters</td></tr>
<tr><td>altitude</td><td>Integer</td><td></td><td> </td><td>Altitude above sea in meters</td></tr>
<tr><td>altitudeAccuracy</td><td>Real</td><td></td><td> </td><td>Altitude accuracy in meters</td></tr>
<tr><td>endLatitude</td><td>Real</td><td></td><td></td><td>latitude at the end of the measurement</td></tr>
<tr><td>endLongitude</td><td>Real</td><td></td><td></td><td>longitude at the end of the measurement</td></tr>
<tr><td>endAccuracy</td><td>Real</td><td></td><td></td><td>Position accuracy in meters at the end of the measurement</td></tr>
<tr><td>endAltitude</td><td>Integer</td><td></td><td></td><td>Altitude above sea in meters at the end of the measurement</td></tr>
<tr><td>endAltitudeAccuracy</td><td>Real</td><td></td><td></td><td>Altitude accuracy in meters at the end of the measurement</td></tr>
<tr><td>deviceUuid</td><td>String</td><td></td><td> </td><td>Smartphone device UUID  (see http://plugins.cordova.io/#/package/org.apache.cordova.device)</td></tr>
<tr><td>devicePlatform</td><td>String</td><td></td><td> </td><td>Smartphone device platform</td></tr>
<tr><td>deviceVersion</td><td>String</td><td></td><td> </td><td>Smartphone device OS version</td></tr>
<tr><td>deviceModel</td><td>String</td><td></td><td> </td><td>Smartphone device model</td></tr>
<tr><td>reportUuid</td><td>String</td><td>*</td><td>Mandatory</td><td>Unique measurement UUID (UUIDv4 format) client-side generated</td></tr>
<tr><td>manualReporting</td><td>Boolean</td><td></td><td></td><td>Manual Reporting : true, false (default:true). False if the data is not entered by a human being</td></tr>
<tr><td>organisationReporting</td><td>String</td><td></td><td></td><td>Software version (sample:openradiation_v1)</td></tr>
<tr><td>reportContext</td><td>String</td><td>Never</td><td></td><td>Report context : emergency, routine, exercise, test (default:test). test:data are not registrated but you can test api use, emergency and exercise:not used,routine:you should use this one !</td></tr>
<tr><td>description</td><td>String</td><td></td><td></td><td>Free description (only if userId is specified)</td></tr>
<tr><td>measurementHeight</td><td>Integer</td><td></td><td></td><td>Measurement height above the ground (in meters)</td></tr>
<tr><td>tags</td><td>Json array of string</td><td></td><td></td><td>Free tags list [tag1 ; tag2] (only if userId is specified)</td></tr>
<tr><td>enclosedObject</td><td>String</td><td></td><td></td><td>Base64 encoded Image. The size shoudn't exceeded 1mb and format should be closed from 600*800 pixels (width * height). The value should be a data URI scheme 'data:image/<subtype>;base64,<data>'. (only if userId is specified)</td></tr>
<tr><td>userId</td><td>String</td><td></td><td></td><td>Openradiation.org user id</td></tr>
<tr><td>userPwd</td><td>String</td><td>Never</td><td></td><td>Openradiation.org plain text password (mandatory if userId is specified)</td></tr>
<tr><td>measurementEnvironment</td><td>String</td><td></td><td></td><td>Measurement environment : countryside, city, ontheroad, inside, plane. (if plane, qualification is set to noenvironmentalcontext and qualificationVotesNumber is set to 0)</td></tr>
<tr><td>rain</td><td>Boolean</td><td></td><td></td><td>Rain : true if it rains during the measurement</td></tr><commit_msg>Update readme with features for plane measurement<commit_after># OpenRadiation
## Abstract
This project aims to develop a database to store environmental radioactivity measurements. It's shared in 2 parts : 
* backend : the postgresql backend database
* api : a JSON Rest-like API developed in node.js to request the database

Source code is under licence Apache 2.0 (cf https://www.openradiation.org/fr/conditions-dutilisation#licence_apache2)

First at all, to use the API you need a key. Please ask by sending an email to [<EMAIL>](mailto:<EMAIL>)
For only a few tests, you're allowed to use the following key : <KEY>

By using this API, you accept the terms of use : https://www.openradiation.org/conditions-dutilisation

This project is self-sufficient, but it is designed to work with the openradiation.org website.
There is restricted access for this website to give informations about users and qualifications.
The API is designed to be installed in two parts : the submit api and the request api.

## Structure of the data

<table>
<tr><th>API Name</th><th>Type</th><th>Available for request API</th><th>Available for submit API</th><th>Description</th></tr>
<tr><td>apparatusId</td><td>String</td><td></td><td></td><td>Unique sensor identifier</td></tr>
<tr><td>apparatusVersion</td><td>String</td><td> </td><td> </td><td>Sensor firmware version</td></tr>
<tr><td>apparatusSensorType</td><td>String</td><td> </td><td> </td><td>Sensor type : geiger, photodiode</td></tr>
<tr><td>apparatusTubeType</td><td>String</td><td> </td><td> </td><td>Tube identification (only if apparatusSensorType = geiger)</td></tr>
<tr><td>temperature</td><td>Integer</td><td></td><td></td><td>Temperature (°C) </td></tr>
<tr><td>value</td><td>Real</td><td>*</td><td>Mandatory</td><td>value (µSv/h)</td></tr>
<tr><td>hitsNumber</td><td>Integer</td><td></td><td></td><td>Hits Number</td></tr>
<tr><td>calibrationFunction</td><td>String</td><td></td><td></td><td>Calibration function used to calculate µSv/h from cps (counts per second). Format should be inline with these symbols : cps 0-9. -+/*^(). Example : 7.543*(cps-0.02)^2+0.001*(cps-0.02)</td></tr>
<tr><td>startTime</td><td>Timestamp</td><td>*</td><td>Mandatory</td><td>Date of the beginning of the measurement (ISO GMT)</td></tr>
<tr><td>endTime</td><td>Timestamp</td><td></td><td> </td><td>Date of the end of the measurement (ISO GMT)</td></tr>
<tr><td>latitude</td><td>Real</td><td>*</td><td>Mandatory</td><td>latitude</td></tr>
<tr><td>longitude</td><td>Real</td><td>*</td><td>Mandatory</td><td>longitude</td></tr>
<tr><td>accuracy</td><td>Real</td><td></td><td> </td><td>Position accuracy in meters</td></tr>
<tr><td>altitude</td><td>Integer</td><td></td><td> </td><td>Altitude above sea in meters</td></tr>
<tr><td>altitudeAccuracy</td><td>Real</td><td></td><td> </td><td>Altitude accuracy in meters</td></tr>
<tr><td>endLatitude</td><td>Real</td><td></td><td></td><td>latitude at the end of the measurement</td></tr>
<tr><td>endLongitude</td><td>Real</td><td></td><td></td><td>longitude at the end of the measurement</td></tr>
<tr><td>endAccuracy</td><td>Real</td><td></td><td></td><td>Position accuracy in meters at the end of the measurement</td></tr>
<tr><td>endAltitude</td><td>Integer</td><td></td><td></td><td>Altitude above sea in meters at the end of the measurement</td></tr>
<tr><td>endAltitudeAccuracy</td><td>Real</td><td></td><td></td><td>Altitude accuracy in meters at the end of the measurement</td></tr>
<tr><td>deviceUuid</td><td>String</td><td></td><td> </td><td>Smartphone device UUID  (see http://plugins.cordova.io/#/package/org.apache.cordova.device)</td></tr>
<tr><td>devicePlatform</td><td>String</td><td></td><td> </td><td>Smartphone device platform</td></tr>
<tr><td>deviceVersion</td><td>String</td><td></td><td> </td><td>Smartphone device OS version</td></tr>
<tr><td>deviceModel</td><td>String</td><td></td><td> </td><td>Smartphone device model</td></tr>
<tr><td>reportUuid</td><td>String</td><td>*</td><td>Mandatory</td><td>Unique measurement UUID (UUIDv4 format) client-side generated</td></tr>
<tr><td>manualReporting</td><td>Boolean</td><td></td><td></td><td>Manual Reporting : true, false (default:true). False if the data is not entered by a human being</td></tr>
<tr><td>organisationReporting</td><td>String</td><td></td><td></td><td>Software version (sample:openradiation_v1)</td></tr>
<tr><td>reportContext</td><td>String</td><td>Never</td><td></td><td>Report context : emergency, routine, exercise, test (default:test). test:data are not registrated but you can test api use, emergency and exercise:not used,routine:you should use this one !</td></tr>
<tr><td>description</td><td>String</td><td></td><td></td><td>Free description (only if userId is specified)</td></tr>
<tr><td>measurementHeight</td><td>Integer</td><td></td><td></td><td>Measurement height above the ground (in meters)</td></tr>
<tr><td>tags</td><td>Json array of string</td><td></td><td></td><td>Free tags list [tag1 ; tag2] (only if userId is specified)</td></tr>
<tr><td>enclosedObject</td><td>String</td><td></td><td></td><td>Base64 encoded Image. The size shoudn't exceeded 1mb and format should be closed from 600*800 pixels (width * height). The value should be a data URI scheme 'data:image/<subtype>;base64,<data>'. (only if userId is specified)</td></tr>
<tr><td>userId</td><td>String</td><td></td><td></td><td>Openradiation.org user id</td></tr>
<tr><td>userPwd</td><td>String</td><td>Never</td><td></td><td>Openradiation.org plain text password (mandatory if userId is specified)</td></tr>
<tr><td>measurementEnvironment</td><td>String</td><td></td><td></td><td>Measurement environment : countryside, city, ontheroad, inside, plane. (if plane, qualification is set to noenvironmentalcontext and qualificationVotesNumber is set to 0)</td></tr>
<tr><td>rain</td><td>Boolean</td><td></td><td></td><td>Rain : true if it rains during the measurement</td></tr>
<tr><td>flightNumber</td><td>String</td><td></td><td></td><td>if measurementEnvironment is plane, flightNumber of the commercial flight in capital letters (AITA code followed by number, example: AF179)</td></tr>
<tr><td>seatNumber</td><td>String</td><td></td><td></td><td>if measurementEnvironment is plane, seatNumber in capital letters with row number first (example: 14C)</td></tr>
<tr><td>windowSeat</td><td>Boolean</td><td></td><td></td><td>if measurementEnvironment is plane, windowSeat : true if the seat where is the sensor is next to the window</td></tr>
<tr><td>storm</td><td>Boolean</td><td></td><td></td><td>Storm : true if storm crossing during the measurement</td></tr>
{'fraction_non_alphanumeric': 0.21947828931229046, 'fraction_numerical': 0.005069915773979884, 'mean_word_length': 6.829705505761844, 'pattern_counts': {'":': 0, '<': 939, '<?xml version=': 0, '>': 939, 'https://': 4, 'lorem ipsum': 0, 'www.': 4, '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': '1131348', 'n_tokens_mistral': 4245, 'n_tokens_neox': 4171, 'n_words': 942}