1. Introduction
Indonesia is a fish-producing country which is ranked in the top five in the world. Based on data from Statistics Indonesia (BPS), it is stated that production in the aquaculture sector will reach 14 million tons in 2022 [
1]. The potential for increased production from the aquaculture sector will contribute to improving the economy in Indonesia, where in 2022 Indonesia will become an exporter of fish with an achievement of 1.2 million tons [
2]. The main issues in aquaculture, especially freshwater aquaculture, are temperature conditions, pH levels, dissolved oxygen levels, and turbidity levels of pond water. This influences optimal fish growth and increases the productivity of fish yields. Aquaculture technology integrated with the Internet of Things (IoT) has been developed, such as a water monitoring system [
3], smart aquaculture system [
4], AI IoT-based buoy system [
5], temperature water control [
6], and others. The IoT system being built is a multi-sensor integration that reads data from the environment and then processes it into a control application, such as a microcontroller that drives actuators [
7]. From this system model, there are several weaknesses, including the resulting data that is only a trigger to carry out commands on the actuator, the information for users is less decisive, and the lack of utilization of the usability of data to make it valuable.
Data fusion is a new paradigm for integrating multi-sensor devices to produce decisive and reliable information. Data fusion is a data processing method to improve the accuracy and quality of the resulting output and reduce data redundancy [
8]. The data generated by sensors in a multi-sensor system are coordinated by data fusion through a special algorithm to provide quality output [
9]. Alam et al. [
10] stated that the stages in data fusion consist of four stages, i.e., signal level, pixel level, feature level, and decision level. Furthermore, there are two perspectives regarding data fusion related to IoT: the first is a single-hub data fusion system where sensors interact with only one fusion system. Second is the multi-hub data fusion sensor, where the multi-sensor system interacts first with the multi-hub sensor, and then the data are transferred to the fusion system via the multi-hub sensor. Mouli [
11] systematically describes the stages of data fusion, which begin with reading data from the sensor, signal processing, transferring data to the PC console, feature extraction, fusion technique, and condition analysis/diagnosis. Methods in data fusion are categorized into four categories: statistical method, mechanistic method, data-driven method (that has sub-categories of Ensemble, Fuzzy Association, and AI), assessment method, and evaluation of metrics in the analysis of the quality [
12]. In aquaculture, IoT through wireless sensor networks (WSNs) integrate data fusion to maximize accuracy in estimating the temperature in aquaculture ponds and minimize data redundancy through ISOA-SELM modeling [
13]. Meanwhile, Rupok et al. [
14] developed a fishery early monitoring system with WSNs combined with data fusion; the method applied is the Dempster–Shafer theory (DST), which produces an accuracy of 91.1%.
Deep reinforcement learning (DRL) is the recommended method in data fusion so that it has intelligent system capabilities that can learn continuously [
15]. The ability of agents in DRL to interact with the environment can support the achievement of long-term goals without external motivation or complete knowledge of the environment [
16]. DRL is the development of reinforcement learning (RL) combined with deep learning, which uses a neural network that works as an approximator function and determines the output, the policy, the action, and the value. Meanwhile, RL focuses on agents who interact with the environment based on perceiving the state [
17]. In the field of aquaculture, Nicolas [
18] employed deep reinforcement learning in fishery management regarding decision-making by comparing several algorithms. From the results of a comparative analysis of processing times for the nine algorithms, the TD3 algorithm has demonstrated the highest performance results.
In the related work, there are several studies related to the fusion technique, including Leal-Junior et al. [
19] who implement a polymer optical fiber (POF) sensor to estimate the water content of temperature-insensitive emulsions of oil–water. The surface plasmon resonance (SPR) principle is combined with POF to produce optimal output. The SPR POF output in the form of temperature is translated into a linear wavelength shift through analysis of temperature cross-sensitivity as the basis for data fusion performances. The mean error results with the fusion technique are 6.46 to 7.81%. Abadi et al. [
20] employ data fusion for downscaling and evaluation of the process of evapotranspiration in water balance estimation. The data are in the form of remotely sensed data, and the fusion technique used is random forest regression (RFR) and support vector machine (SVR). Model testing was carried out by calculating the mean absolute error (MAE) value. The results of the MAE RFR and SVR tests were obtained, respectively: 6.13% and 5.71%. Manoharan et al. [
21] employed a fuzzy interface algorithm in a data fusion technique for superfluous pipeline channel detection. Ultrasonic sensors are used to detect superfluous water in five scenarios with regard to the leakage point, time period of computation, period of upstream and downstream velocity, sensor performance, and cost of implementation. The final results show that the implemented data fusion model can be an alternative pattern recognition for superfluous pipeline channels in the future. Meanwhile, in this study, data fusion was implemented to integrate the data generated from the multi-sensor system, then modeling was carried out with DRL, which provides output for the user regarding the actual behavior of the object being observed in the form of a fish pond. Based on the experimental results and testing of the proposed system, which are discussed in more detail in
Section 4, it was found that the combination data fusion-deep reinforcement (DF-DRL) had an error rate percentage of 5%, which, when compared with the three data fusion techniques, DF-DRL has a lower error rate percentage.
Figure 1 shows a graph of the comparative data fusion technique:
DRL implementation employs deep learning (DL) modeling in determining the action performed by the agent, which has a major role in determining what action is performed by the system. In general, there are two main classifications of agents: model-free agents and model-based agents [
22]. The model-free agent does not focus on how the model is in the environment. The learning model is based on experience, the feedback from the environment on the actions given, as well as the trial-error process. Meanwhile, model-based agents focus on how the internal model of the environment receives states or determines actions based on those states. Within the environment, various conditions or states have been determined, as well as the actions and consequences that are carried out based on these state conditions [
23]. Previous research related to model-free agents, as has been done by Liu et al. [
24], implements model-free agents in DRL to control the load frequency. The structure algorithm uses a deep Q network (DQN), and the final results show that the agent can solve problems by controlling the load frequency and determining the appropriate power and frequency requirements. In contrast, Sanayha and Vateekul [
25] developed a model-based agent on DRL for peer-to-peer energy trading cases. Agent performance is based on an environment that has been modeled with multivariate-long short-term memory (multivariate-LSTM) with time-series data. The evaluation was carried out by forecasting the price of energy trading MAPE at 15.82%, while the predicted quantity of MAPE was 10.39%.
In this study, we employed a model-based agent where environmental conditions have been determined based on fish pond condition parameters regarding temperature, pH level, and turbidity. The agent obtains the initial conditions from the environment, the data that are integrated by the data fusion layer and then processed in the DRL framework, which becomes an action for the next stage. A detailed explanation of DRLs and agents will be discussed in detail in
Section 2.4.
This paper consists of several sections: the first is the “abstract”, which explains in full a series of studies, starting with the background, the aim of the research, the methods, and the results. Second, the “introduction” section explains the background, purpose, analysis, and literature review related to the research. Third, the “system architecture design” section explains the system architecture, as well as the software and hardware of components that have been used in the research. Fourth, the “experimental method” section describes how to integrate data fusion and DRL into an integrated system to monitor aquaculture systems. The fifth “results and discussion” section describes the results based on the experiment and testing, discussing the findings of the whole experiment. The last sections are “conclusion and future work” and “references”.
2. System Architecture Design
This section describes the system architecture design, which contains an explanation of the aquaculture monitoring system, wireless sensor networks, deep fusion in the aquaculture monitoring system, deep reinforcement learning that uses deep learning as an agent, and integration of data fusion and deep reinforcement learning in the aquaculture monitoring system.
2.1. Conventional Aquaculture Monitoring System
The aquaculture monitoring system in previous studies [
26,
27] was built with a sensor device that detects the condition of the fish pond with various parameters: temperature condition, pH level, and turbidity level. Data are read through sensors, namely the temperature sensor (type RTD PT100), pH sensor (SEN 0161), and turbidity sensor (SEN 0189), and then sent to the microcontroller connected to the Wi-Fi module. In a conventional aquaculture monitoring system, there are three layers: the physical layer, the network layer, and the application layer. The physical layer consists of sensors that are connected to a microcontroller to process data that is read by sensors from the environment. The network layer consists of Wi-Fi modules connected to internet services. The Wi-Fi module functions as an intermediary between the controller and the user via internet services. Meanwhile, the application layer is a user interface that represents the data generated by reading the device in real time from the fish pond. The applications contained in the application layer are Android-based mobile applications, which can be accessed by users anytime and anywhere. In this monitoring system, the user can only find out the current condition of the fish pond based on the parameters of temperature, pH, and turbidity. In contrast, the proposed aquaculture monitoring system not only reads the real-time condition of fish ponds but also determines whether the current condition of fish ponds is “normal” or “not normal”.
Figure 2 represents the architecture of a conventional aquaculture monitoring system.
In the proposed aquaculture water monitoring system, a more complex data fusion implementation is carried out, consisting of three main layers: the signal layer, feature layer, and decision layer. The fusion technique uses a combination of DRL and DL to produce the output of the current condition of the pond, whether it is “normal” or “not normal”. The system not only reads the current conditions of the fish pond based on temperature, pH, and turbidity, but also provides the convenience for the end user to find out whether the condition of the fish pond is normal or not.
Figure 3 is the proposed aquaculture monitoring system, which is discussed in detail in
Section 2.6:
2.2. Wireless Sensor Networks in Aquaculture Monitoring System
WSNs read the basic conditions of fish ponds through temperature, pH, and turbidity with integrated temperature sensor (RTD PT100), pH sensor (SEN 0161), and turbidity sensor (SEN 0189) components that are received by the ATmega328-type microcontroller provided by Arduino Uno R3, then connected to the internet and accessible by the user. The selection of sensors used in this study considers three aspects, i.e., low cost, precision, and convenience. The goal of this study is to construct a convenient, accurate, and low-cost aquaculture monitoring system based on data fusion through deep reinforcement learning. The microcontroller, as part of it, has an important role in processing data generated from sensors to become the basis for determining decision parameters.
Figure 4 shows a more detailed architecture, which gives an idea of how WSNs are implemented. The data that have been processed by the microcontroller are then connected to the Wi-Fi module to be stored in the Firebase data cloud. The connection mechanism used is message queuing telemetry transport (MQTT), which connects communications between IoT machines or devices—in this case, sensors, microcontrollers, and Wi-Fi module devices—with the cloud gateway in Firebase. Furthermore, the data are stored in Firebase as real-time data on the current condition of the fish pond. MQTT works as a broker that receives data from IoT devices as a client that publishes data on the temperature, pH, and turbidity of fish ponds. MQTT is sending data to the Firebase data cloud as a subscriber of MQTT [
28]. The end user or mobile applications use the Hypertext Transfer Protocol (HTTP) as a protocol that communicates data in real time on Firebase to be received by end users through Android-based mobile applications. The data communication process between the mobile application and Firebase uses “request” and “response” communication, in which the mobile application “requests” data from the system, and the system provides feedback through the “response” function by providing the latest data on fish pond conditions. The end user of the system is an Android-based application with detailed technical specifications, as referred to in
Section 3.5.
Technically, the configuration of WSNs in the aquaculture monitoring system can be seen in
Figure 5, where several nodes are integrated with each other. Inside the node are a sensor, microcontroller, and Wi-Fi module. Nodes interconnect with each other to form a network called WSNs, and data are transmitted to Firebase via the MQTT protocol as the WSN’s network communication service. The Wi-Fi module acts as a data collector and also transmits data to the base station in the form of Firebase’s real-time data cloud. During data transmission between devices and Firebase, as well as mobile devices and Firebase, there are protocols used as communication media, i.e., MQTT and HTTP. Firebase acts as a storage unit that stores data read by sensors and distributes data to mobile devices.
The WSN’s network topology in this study is a mesh topology, where all nodes are interconnected or have multiple nodes. The mesh topology has the advantage in that the connected nodes complement each other’s data; for example, if the pH sensor does not work, then the data will be provided by other pH sensors connected to the WSN network. The n-th node in
Figure 5 shows that as many nodes can be interconnected into this mesh topology as we need [
29]. The considerations in this study using a mesh topology are the aspects of scalability, cost-effectiveness, reliability, and the effectiveness of energy.
2.3. Data Fusion in Aquaculture Monitoring System
In this study, data fusion is implemented to integrate various sensors from a multi-sensor system. The system data fusion architecture is represented in
Figure 6, which consists of three levels: (1) signal level; (2) feature level; (3) decision level. At the signal level, the resulting signal output based on sensor readings is integrated for use in the next layer, where the sensor reads the condition of the fish pond with the parameter’s temperature, pH, and turbidity. The raw data that are read by the sensors that are integrated with the microcontroller are then processed and transferred via the WSN as a data control for further processing, which is transmitted to the feature level. The feature level is the second process, which is the process of extracting data generated at the signal level to produce features used as parameters in making decisions or actions to be carried out by the system. A fusion technique is involved in the inferencing process in this study which uses DRL as a fusion technique for data processing. Technically, the DRL mechanism used in the fusion technique involves deep learning when the agent makes decisions. A series of neural networks is employed to produce an accurate model for determining the resulting output; detailed descriptions of DRL and DL are explained in
Section 2.4 and
Section 2.5. The decision level is the last in the data fusion architecture, where at this level the system issues output as a result of processing data through the data fusion process. The output generated by the aquaculture monitoring system is a notification of the condition of the fish pond in a “normal” or “not normal” condition that refers to
Section 3.3. The variety of sensors used in the multi-sensor system in this study allows for a variety of complex conditions to occur, which need to be handled not only by rule-based decisions or conventional aquaculture monitoring systems, but as a whole, need to be examined from the stages of signal processing, signal information extraction, signal processing, and the output of signal processing. Therefore, the data fusion system is the choice used for this aquaculture monitoring system research.
2.4. Deep Reinforcement Learning (DRL)
The basic concept of DRL is reinforcement learning (RL), which is part of machine learning. RL is based on the Markov decision process (MDP), which is a decision-making model in random situations represented by agents as decision-makers [
30]. There are five elements in the MDP framework: agent, environment, state (
S), action (
A), and reward (
R). The agent has a function as a decision-maker for what action will be taken by the system based on the conditions of the environment. The environment has a role in giving
S to the agent so that he can make decisions in the form of
A.
A decided by the agent becomes input for the environment, which then becomes
R for the consequences decided by the agent. Each lap time is represented by t. This process takes place continuously; the process is returned to a new state,
S(t+1), for the next decision process, and the reward is returned to the agent,
R(t+1), for the next process. If it is related between
St,
At, and
Rt+1, it is formulated as a function
f(
St,
At) =
Rt+1, where
St and
At will produce a new reward, which is represented as
Rt+1 on the dotted line on the left side of
Figure 7, and then returns to the reward condition of the current
Rt. This also applies to
St, where it will become the new condition
St+1 until the dotted line, and then return to
St.
RL combined with deep learning (DL) becomes deep reinforcement learning [
31]. The neural network is employed to help the agent in the decision-making process of determining the action to be performed.
Figure 8 shows the extended RL combined with the DL, which becomes the DRL.
In DRL, the neural network that is used in deep learning has a function called a function approximator. DL has an important role in the DRL framework, especially in making decisions for random and complex conditions [
32] and providing optimal output and rewards for the next iteration of the process. State in the context of DL in this study is the condition of the fish pond which consists of temperature conditions, pH conditions, and turbidity conditions. For example, the state temperature is 25 °C, the turbidity is 24 NTU, and the pH is 7, which are denoted as
S: [
7,
24,
25]. Then, with these conditions, the action is in the form of a declaration of the condition of the fish pool in a “normal” state, which is denoted as A: normal, which then triggers the system to give a reward (
R) to become the next condition
Rt+1 and
St+1. The action determined by the agent is combined with the neural network process through the function
y =
f(
w1x1 +
w2x2 + … +
wnxn +
b) where w is the weight resulting from the model,
x is the input from the neuron, and
b is the bias. An activation function is implemented to produce optimal output which is represented by
f. The following formulation is used in Equation (1):
As explained in the Introduction section, the agent that is built is a model-based agent, which monitors the model of its environment when it is operated. The model becomes the basis for agents to predict future actions and conditions. This model contains various states and potential actions, as well as consequences or rewards that will be obtained by agents in the DRL sequence. The selection of a model-based agent is based on environmental conditions, that is, the parameters or states contained in the aquaculture monitoring system, which consist of temperature, turbidity, and pH. Therefore, this allows the agent to make the correct and accurate decisions based on environmental conditions and the state read from the environment.
2.5. Deep Learning (DL)
DL is a tool to sharpen the action produced by the agent, with random probability conditions [
33]. In previous research, in the context of DRL, many used traditional supervised learning models such as SVM or random forest [
34,
35,
36], thus the use of DL in this study is still relevant in the context of the updated method being implemented. The DL implementation in this study uses an artificial neural network (ANN), which is defined by five layers, consisting of one layer as the input layer, three layers as hidden layers, and one layer as the output layer. DL, together with the agent, accepts the state conditions, and then DL performs an algorithmic process to determine the probability of these conditions, where the input conditions are divided into three parts, namely temperature conditions, pH conditions, and turbidity conditions.
Figure 9 represents the neural network architecture in deep learning:
In
Figure 9, in which the input layer section can be seen, there are three data inputs that are the basic parameters of neurons (temperature, pH, and turbidity) to be computed in the next layer. In the hidden layer, each layer consists of 32 neurons, 16 neurons, and 16 neurons. Meanwhile, in the output layer, there is one layer in the form of binary classification 0 and 1, which represents “normal” or “not normal” fish pond water conditions. The input into each neuron is called a vector
x = (
x1,
x2,
x3, ...
xn), and the output of the neuron is represented by
y. In input processing, each neuron requires not only the input
x but also the weight (
w) that contributes to producing a strong output and provides the direction of the connection to the next neuron. To carry out
x and
w processing, an activation function (
f) is needed so that it produces a non-linear output that will be transferred to the next neurons [
37]. In the formulation Equation (2), output neurons are represented by
y, which consists of
f, which is an activation function that processes inputs
w1x1,
w2x2,
w3x3, to
wnxn and added by
b, which is a representation of the bias [
38].
In this study, the activation function formulation used is sigmoid because it has compatibility with the resulting output in the form of binary classification in the form of 0 and 1 which represent “normal” and “not normal” output conditions. Sigmoid is denoted by the formula in Equation (3), as follows:
x denotes input data in the function, while e denotes a constant value that has a value of 2.71828 [
39]. As previously described, the sigmoid is suitable for binary classification cases, where the value range of the sigmoid activation function is from 0 to 1 [
40]. This is due to the way the sigmoid activation function works: various input values become a probability value of 0 to 1. For example, if the output value is greater than 0.5, then the probability will lead to a value of 1, where in this case the value 1 is defined as a “not normal” condition, while if the output value is less than 0.5, then the probability will lead to 0, which is defined as a “normal” condition. Graphical visualization of the sigmoid activation function is represented in
Figure 10:
2.6. Combined Data Fusion and Deep Reinforcement Learning Framework
The goal of this study is to combine DF with DRL, in which there is DL to assist agents in determining the actions to be taken. Inside the DF, there is a signal layer that provides state conditions (
S) to the feature layer as a DRL trigger to determine what action (
A) is performed by the agent. Data processing is done by DL through a neural network consisting of an input layer, a hidden layer, and an output layer. The output layer instructs a reward (
R) for the next iteration process, and
A is forwarded to the decision layer which translates
A as a “normal” or “not normal” condition of data processing. The next layer is the application layer where data are represented in a user interface that can be used by end users.
Figure 11 shows a combined DF and DRL visualization:
3. Experimental Method
In this study, the experimental method is an essential part because it forms the foundation for the experimental and analytical processes to produce credible and valuable output. There are several specific goals in the experimental method, which include: (1) validating the sensors’ accuracy, which ensures that the sensors have good quality accuracy, taking into account temperature, real-time data retrieval from fish ponds, and time-series data retrieval; (2) the construction of the deep learning model that is implemented to ensure the validity of the parameters in the class label, the dataset transformation process, and the accuracy of the model used; (3) data fusion algorithm construction, which aims to integrate all layers in the aquaculture monitoring system; (4) application layer environment, which aims to ensure integration to the final process, where an Android-mobile-based user interface is built that can be accessed by end users in real time.
In the experimental process as shown in
Figure 12, there are several steps that are carried out. The initial process is carried out by validating sensor accuracy to ensure that the temperature, pH, and turbidity sensor components work properly in order to produce accurate and valid data. The validation process is carried out by testing the sensor in several conditions in the fish pond. The process of collecting test data is carried out with a range of time from morning to evening with eight timeframes beginning from 06.00 am to 08.00 pm. The results of the test are then compared with the measurement results from the measuring instrument, then a gap is sought between the sensor measurement results and the measuring instrument which shows the measurement error range. In this study, the error tolerance given in testing is a maximum of 5% or a minimum of 95% accuracy. If the conditions are not met, then the process will be repeated until it reaches a maximum error of 5%. The system built is a WSN, where the data after being read by the sensor is then transferred to the Firebase real-time cloud which will later be used as the basic parameters for the system to process data. The process of data communication between sensor devices and Firebase is carried out via the message queuing telemetry transport (MQTT) protocol so that data can be transmitted to Firebase to become real-time data. The transferred data in the form of temperature, pH, and turbidity parameters are processed by the deep reinforcement learning (DRL) system through deep learning to produce an action as the output of the agent. In the next stage, the system interprets the data into a binary classification to output 1 or 0. In this stage, DRL implementation is carried out, where the agent provides output based on deep learning modeling that has been embedded in the system. Then, the system performs the decision layer by translating the binary classification into “normal” or “not normal” conditions, where in this study output 0 is defined as a “normal” condition and output 1 is defined as a “not normal” condition. In the final stage, the mobile application receives the actual decision process from the system based on DF-DRL and the real-time conditions of the pond based on parameters of temperature, pH, and turbidity.
Further explanation in
Figure 12 relating to the validation of the sensor accuracy, WSNs, modeling of deep learning, and deep learning reinforcement algorithms are explained in detail as follows:
3.1. Validating the Sensor Accuracy
In validating the accuracy of the sensor, it is done by collecting data on the condition of the fish pond which is divided into eight sampling times in the morning, afternoon, and evening with a range of every two hours starting at 06.00 to 20.00 (08.00 pm). At the time of data collection, the environmental conditions were cloudy with occasional light rain, and the air temperature ranged from 25 °C to 30 °C.
Table 1 shows a detailed description of the test data collection, which is divided into eight timeframes:
The device configuration in
Figure 13 shows the direct interaction of the temperature, pH, and turbidity sensors on the device. The sensor is connected directly to the microcontroller, which is connected to the Wi-Fi module so that the reading data can be accessed in real time.
Testing is carried out by collecting data from the sensor, which is compared with a measurement tool, resulting in a certain error value. At this validation stage, the calculation method is performed using the mean absolute percentage error (
MAPE), with the value generated from the sensor being called the prediction value (
Pi), while the value generated by the measurement tools is called the actual value (
Ai). The difference between
Ai and
Pi produces an absolute error, which is divided by
Ai, so that the
MAPE value is formulated in Equation (4), as follows:
3.2. The Implementation of WSNs
As described in the previous section, the WSNs in this study integrate sensors to be able to communicate with Firebase cloud data. The process of transmitting sensor data through WSNs is carried out with the pseudocode as shown in
Table 2 to indicate cite
Table 2:
The implementation of WSNs for transmitting data from sensors to the cloud can be seen in
Table 3, where there is real-time data on the results of environment readings on the pH, temperature, and turbidity parameters.
3.3. Construction of Deep Learning
In the development of deep learning, generic stages are used to implement where data pre-processing, model architecture, training the model, and evaluation are carried out.
Figure 14 shows a description of each stage in deep learning in this study.
Data pre-processing is carried out by preparing a dataset that will be used in deep learning modeling that uses tabular data derived from various fish pond water conditions, with variations in temperature, pH, turbidity, and “normal” and “not normal” conditions. There are four features in the dataset, consisting of three parameter features, and one classification feature consisting of “normal” and “not normal” labels. The three feature parameters are states, which will later become knowledge for agents in deep reinforcement learning to understand actual environmental conditions so that the agent can decide which action to take under various conditions and at random. As a parameter reference,
Table 4 shows the range of normal conditions of the fish pond environment:
The classification label refers to the parameter conditions in
Table 4. For conditions outside of these parameters, the classification label becomes “not normal.” The number of dataset records used in modeling is 1000, consisting of 500 dataset records with a “normal” classification label and 500 dataset records with a “not normal” classification label.
Table 5 shows the sample dataset used in the study regarding the “normal” class referred to in
Table 4. For example, in ID 1, where the temperature is 27, the turbidity is 15, and the pH is 8, these conditions correspond to the parameter range in
Table 4 as “normal” conditions. In contrast, in ID 3, it was found that the temperature was 20, and since it is not included in the parameter range of
Table 4, the condition is included in the “not normal” class. Likewise, for ID 7, the value of the temperature is 10, turbidity is 30, and pH is 10. Referring to
Table 4, the temperature does not enter “normal” conditions, which are in the range of 25–30 °C, and the pH also does not enter “normal” conditions, which is in the pH range of 6–9. Thus, ID 7 enters the “not normal” classification. In the “class” column in ID 3 and ID 7, both have class conditions of “not normal”, but come from different parameter conditions, where in ID 3, temperature (t1) does not meet “normal” conditions, while in ID 7, temperature (t1) and pH (ph) do not meet “normal” conditions. To facilitate modeling, a classification label is transformed into binary, where “normal” conditions are represented by 0, while “not normal” conditions are represented by 1. The class after transformation is shown in column 6 in gray in
Table 5:
The sample data are sufficient for the deep learning algorithm used in the study because the data have gone through the process of data preparation and transformation so that the algorithm has well-balanced data and has no significant noise, especially in this case, which is a binary classification (the condition of the fish pond water is “normal” or “not normal”) also using three clear input parameters i.e., turbidity, pH, and temperature. As described in the previous section, the architecture model uses a deep neural network consisting of five layers. The hidden layer consists of layers, with each neuron having 32 neurons, 16 neurons, and 16 neurons. Furthermore, for the modeling process, dataset training is carried out by dividing the dataset into train data of 80% of the total dataset and test data of 20%. The learning rate used in modeling is 0.01 because this value is generally widely used in various frameworks such as PyTorch and TensorFlow; it also has a balanced value in the sense that it is neither too small nor too big. Specifically, the parameters used in the training model are listed in
Table 6 below:
Visually, data exploration from modeling can be seen in
Figure 15, where data values 0 and 1 are shown in yellow and green, respectively. It can be seen from the figure that the data are divided into two groups, but there are anomalous data that are indicated by red and orange colors.
From the results of the model training, an evaluation of the model is carried out using accuracy and the F1 score. There are several outputs generated by modeling: true positive (TP), true negative (TN), false positive (FP), and false negative (FN).
Table 7 shows the confusion matrix showing TP, TN, FP, and FN:
From the results of the confusion matrix in
Table 7 can be calculated accuracy, precision, and recall. While the results of the F1 score are based on calculations from precision and recall, the formulation is shown in Equations (5)–(8):
Therefore, based on the results of the confusion matrix, an accuracy percentage of 96.3% is obtained with a precision of 0.97, a recall of 0.95, and an F1 score of 0.96. The results of deep learning modeling show a percentage greater than 95%; this indicates that the model built has good accuracy for implementation in an aquaculture monitoring system based on DF and DRL.
3.4. Data Fusion Algorithm
Data fusion in this study is a framework that operates the system from integration and signal processing through WSNs contained in the signal layer, processing data obtained from the environment with deep reinforcement learning in the feature layer, as well as interpreting actions that produce output at the decision layer. Algorithmically, the series of processes can be represented by pseudocode as shown in
Table 8.
3.5. Application Layer Environment
The application layer in this study aims to facilitate communication between the user and the system through the user interface. The application layer is built on a mobile platform so that users can interact with the system anytime and anywhere. The developed system has minimum requirements for installation with the following parameters in
Table 9:
The user interface was developed with the Android Studio Integrated Development Environment (IDE) which was designed to consist of a main menu which can be seen in
Figure 16a and a monitoring menu in
Figure 16b.
Meanwhile, the implementation of the user interface display of the aquaculture monitoring system can be seen in
Figure 17a,b, where there is a display of the main menu and monitoring menu.
5. Conclusions
DF-DRL technology in the aquaculture monitoring system provides efficiency in the accuracy of the data generated by the system and the reliability of data that can be accessed in real time. The stage is carried out by testing the quality of sensor accuracy on WSNs, where it is obtained with an average error in MAPE of 3.80% or an accuracy of 96.2%. From the aspect of deep learning modeling, a comparative analysis has been carried out with traditional machine learning consisting of a support vector machine (SVM), k-nearest neighbor (kNN), and naïve Bayes classifier (NBC), with an average accuracy of 94.31%, while the results of deep learning modeling accuracy implemented in this study are 96.30%. Meanwhile, the effectiveness of DF-DRL performance with a rule-based algorithm with testing of 20 scenarios resulted in 95% and 85% accuracy, respectively. DF-DRL technology has 10% higher performance than rule-based algorithms.
While the DF-DRL analysis in terms of cost effectiveness is compared to labor cost through the monthly cost parameter, it is found that DF-DRL technology is far superior to labor cost, which is USD 4.63 for DF-DRL technology and USD 100 for labor cost in monthly cost. DF-DRL technology is an alternative in a low-cost aquaculture monitoring system with technology that produces significant data accuracy and validity. In future development, the system can be integrated with various sensors, such as hungry fish detectors, monitoring cameras integrated with image processing, actuators that provide automatic feeding, and various other sensors and actuators that are adaptive to various environmental conditions.