Report Fin
Report Fin
Report Fin
PROJECT REPORT
Submitted by
ARUNBALAJI S 211718104013
BALARAMAN K 211718104016
GOKUL K 211718104039
HARIHARAN S 211718104043
of
BACHELOR OF ENGINEERING
IN
COMPUTER SCIENCE AND ENGINEERING
RAJALAKSHMI INSTITUTE OF TECHNOLOGY
ANNA UNIVERSITY: CHENNAI 600 025
JUNE 2022
I
ANNA UNIVERSITY: CHENNAI 600 025
BONAFIDE CERTIFICATE
SIGNATURE: SIGNATURE:
Dr. D.C JOY WINNIE WISE, Ms. M. RAMYA,
B.E., M.E., (Ph.D), B.Tech., M.E.,
HEAD OF THE DEPARTMENT, SUPERVISOR,
Dept. of Computer Science and Dept. of Computer Science and
Engg., Engg.,
Rajalakshmi Institute of Rajalakshmi Institute of
Technology, Technology,
Kuthambakkam Post, Kuthambakkam Post,
Chennai - 600 124 Chennai - 600 124
___________________
II
ACKNOWLEDGEMENT
Above all we thank our parents and family members for their
constant support and encouragements for completing this project.
III
ABSTRACT
IV
TABLE OF CONTENTS
ABSTRACT IV
LIST OF FIGURES VII
LIST OF ABBREVATIONS VIII
1 INTRODUCTION 1
1.1 INTRODUTION 1
1.2 AIM OF THE PROJECT 3
1.3 PROJECT DOMAIN 3
1.4 SCOPE OF THE PROJECT 3
2 LITERATURE SURVEY 20
3 PROJECT DESCRIPTION 24
3.1 EXISTING SYSTEM 24
3.2 PROPOSED SYSTEM 26
3.3 FEASIBILITY STUDY 27
3.3.1 ECONOMIC FEASIBILITY 27
3.3.2 TECHNICAL FEASIBILITY 28
3.3.3 STANDARDS FEASIBILITY 28
3.4 SYSTEM SPECIFICATION 29
3.4.1 HARDWARE REQUIREMENTS 29
3.4.2 SOFTWARE REQUIREMENTS 29
V
CHAPTER NO. TITLE PAGE NO.
VI
CHAPTER NO. TITLE PAGE NO.
7 CONCLUSION AND 57
FUTURE ENHANCEMENT
8 REFERENCE 59
VII
LIST OF FIGURES
VIII
LIST OF ABBREVIATIONS
ML Machine Learning
EV Electric Vehicle
IX
1
CHAPTER 1
INTRODUCTION
1
the batteries characteristics and the EV powertrain. All of these
variables of the EV will influence the SoC and consequently the
range prediction. The batteries SoC and others relevant parameters,
are provided to the main control system through CAN-bus
communication, and then these information is stored in a Data
Base, in order to predict the range available.
The driver behavior: speed and acceleration taken from EV
through the CAN-bus communication, the driver past behavior,
weight, and driving direction that is acquired based on the GPS
information.
Environment: current location, traffic conditions taken from a web
service, road information obtained through a distance graph,
weather information wind and temperature - taken from a web
service or from an EV sensor, altitude taken from the GPS device.
2
1.2 AIM OF THE PROJECT:
To predict the remaining range of the vehicle using load cell sensor
which is based on the weight of the user and also predict the range
based on historical driven data.
DOMAIN INTRODUCTION
3
DIFFERENT TYPES OF MACHINE LEARNING
4
1.3.2 LOAD CELL
5
capacitance is directly proportional to the amount of overlap of the
plates and the dielectric between the plates and inversely proportional to
the gap between the plates.
In this particular load cell shown in above figure, there are a total of four
strain gauges that are bonded to the upper and lower surfaces of the load
cell.
When the load is applied to the body of a resistive load cell as shown
above, the elastic member, deflects as shown and creates a strain at those
locations due to the stress applied. As a result, two of the strain gauges
are in compression, whereas the other two are in tension as shown in
below animation.
6
Load Cell Types
Load cell designs can be distinguished according to the type of output
signal generated (pneumatic, hydraulic, electric) or according to the way
they detect weight (bending, shear, compression, tension, etc.)
If the load cells have been properly installed and calibrated, accuracy
can be within 0.25% full scale or better, acceptable for most process
weighing applications. Because this sensor has no electric components,
it is ideal for use in hazardous areas.
Typical hydraulic load cell applications include tank, bin, and hopper
7
weighing. For maximum accuracy, the weight of the tank should be
obtained by locating one force sensor at each point of support and
summing their outputs.
Pneumatic load cells are often used to measure relatively small weights
in industries where cleanliness and safety are of prime
concern. Miniature load cell
The advantages of this type of load cell include their being inherently
explosion proof and insensitive to temperature variations. Additionally,
they contain no fluids that might contaminate the process if the
diaphragm ruptures. Disadvantages include relatively slow speed of
response and the need for clean, dry, regulated air or nitrogen.
8
Strain-gauge load cell
Strain gauge load cells are a type of load cell where a strain gauge
assembly is positioned inside the load cell housing to convert the load
acting on them into electrical signals. The weight on the load cell is
measured by the voltage fluctuation caused in the strain gauge when it
undergoes deformation.
When there is no load on the load cell, the resistances of each strain
gauge will be the same. However, when under load, the resistance of the
strain gauge varies, causing a change in output voltage. The change in
output voltage is measured and converted into readable values using a
digital meter.
9
advantage, however. An added drawback of piezoresistive devices is
their nonlinear output. Miniature load cell
10
1.3.3 RASPBERRY PI:
It doesn't have onboard storage, but it has an SD card slot you can use to
house your operating system and files. The Raspberry Pi is small,
doesn't use much power, and is relatively inexpensive.
11
later, because of its low cost and open design, the model became far
more popular than anticipated.
Model A
Model A +
Model B
Model B +
On the other hand, the Raspberry Pi A models have a smaller and more
compact footprint and hence, these models have the reduced
12
connectivity options. Raspberry Pi Zero models, which come with or
without GPIO (general-purpose input output) headers installed, are the
most compact of all the Raspberry Pi boards types.
In this modern age when computers are sleek, Raspberry Pi seems alien
with tiny codes printed all over its circuit board. That‟s a big part of
Raspberry Pi‟s appeal. Let us have a look at what we can do with this
appealing circuit board.
1.3.1 RASPBERRY PI
Playing games
Browsing the internet
Word processing
13
Spreadsheets
Editing photos
Paying bills online
Managing your accounts.
The best use of Raspberry Pi is to learn how a computer works. You can
also learn how to make electronic projects or programs with it.
Some of the global retailers from whom you can buy your Raspberry Pi
computers are as follows. You can also refer to their respective websites
for details about the Raspberry Pi computers.
14
You can also get it from the following Raspberry Pi‟s distributors
Electronic components supplier, RS
Requirements
To use your Raspberry Pi board, you need to buy a few other bitsand
pieces. Following is the checklist of what else we might need
Monitor
Television
USB hub
15
Keyboard and Mouse
SD or MicroSD card
If you are going to use model A and A+ then, you need to buy a
USB Wi-Fi adapter for connecting to the internet. This should be done
because these Raspberry models do not have an Ethernet socket.
If you want to share your collection of music and movies, you need
to use an external hard drive with your Raspberry Pi model. You can
connect the same by using a powered USB cable.
16
Speakers
Power supply
Cables
Following are some of the cables, which you need for the connections to
the Raspberry Pi computer −
HDMI cable
HDMI-to-DVI adapter, if you are using a Digital Visual Interface
(DVI) monitor.
RCA cable, if you want to connect to an older television.
Audio cable
Ethernet cable
17
To minimize the cost, the Raspberry Pi models are designed to be used
with whatever accessories we have. But, as we know that in practice, not
all the devices can be compatible.
Before you get started with your Raspberry Pi board, you need to
provide with an OS (operating system). Linux is the most frequently
used OS on the Raspberry Pi.
18
A high-performance 64-bit quad-core processor
Dual display support with resolutions up to 4K via a pair of micro-
HDMI ports
Hardware video decoding up to 4Kp60
4 GB of RAM
A connection to the dual-band wireless local area network 2.4/5.0
GHz
Bluetooth 5.0 / Gigabit Ethernet / USB 3.0 / PoE features (via a
separate HAT PoE add-on module)
19
CHAPTER 2
LITERATURE SURVEY
20
[2] Tian, H.Y., Li, X.Y., Liu, F.: Prediction of continued driving
range of battery electric vehicle based on map information and
cyclic SVR model. Automot. Eng. 42(9), 1174–1182 (2020)
21
[3] Y. Tao, M. Huang, Y. Chen, and L. Yang, ‘‘Orderly charging
strategy of battery electric vehicle driven by real-world driving
data,’’ Energy, vol. 193, 2020.
The work preprocessed the real-world driving data of 1000 battery
electric vehicles (BEVs) in Zhengzhou, China. Then a scheduling model
of electric vehicles on time dimension was established based on the
processed data. The mathematical model could meet the operation
requirements of grid side and user side. The grid-side optimization
minimized the system‟s equivalent load fluctuation, and the user-side
was optimized to maximize the charging capacity of electric vehicles.
The mathematical model was solved by the genetic algorithm toolbox in
Matlab software. Besides, we obtained the quantity distribution of BEV
access to the power grid, parking time distribution, parking duration
distribution and initial state of charge (SOC) distribution at the
beginning of charging by analyzing the real-world driving data. These
distribution curves were used to obtain the driving and charging habits
of BEV drivers. By comparing the optimized orderly charging strategy
with the random charging, in the case of meeting the user‟s demand for
charging power, the peak and valley difference and the equivalent load
fluctuation of the power grid were significantly reduced by 22 and
22.7%, respectively. It greatly improves the security and economy of the
grid.
22
[4] Y. Luo, G. Feng, S. Wan, S. Zhang, V. Li, and W. Kong,
‘‘Charging scheduling strategy for different electric vehicles with
optimization for convenience of drivers, performance of transport
system and distribution network,’’ Energy, vol. 194, 2020.
With the popularization of electric vehicles, large-scale electric
vehicle charging may negatively impact drivers, the power grid, and
traffic conditions. Currently, research conducted on the charging and
battery swap of electric vehicles is insufficient. The objective for
optimization and the type of electric vehicle proposed by other papers
are limited in scope. In order to achieve an overall optimization of the
whole system, the driver demands, the road traffic speed, the number of
vehicles in the charging station and the charging network load are
considered in the development of the charging scheduling strategy for
electric vehicles. Such a strategy can further enhance driver convenience
in terms of making decisions for charging and battery swap of electric
vehicles. Moreover, different types of electric vehicles are taken into
account for a more practical proposed scheduling strategy. Utilizing
MATLAB and MATPOWER, a simulation platform is established to
validate the strategy. Simulation results demonstrate that the proposed
scheduling strategy can relieve local traffic jams, smooth network load
curve, increase safety and economy of the power network, and decrease
the number of charging electric vehicles in station.
23
CHAPTER 3
PROJECT DESCRIPTION
24
speed and energy efficiency; and then the accelerated battery aging
experiments were performed to obtain the battery capacity profile.
Data-driven based approaches are independent on physical models.
However, they require high-quality data preprocessing and feature
engineering, as the raw datasets may include a lot of irrelevant data
25
3.2 PROPOSED SYSTEM
3.2.1 OVERVIEW:
The below diagram consist of load cell sensor, raspberry pi, Bluetooth
module. The load cell sensor is connected with raspberry pi and it is
integrated with the mobile application. Sensor convert the physical
weight into electric signal to predict the range. The connectivity is
happening with the help of Bluetooth module. You can see the
remaining range in the mobile Application
26
Load cell Range
sensor Prediction
Mobile
Application
Raspberry Bluetooth
pi
27
3.3.2 TECHNICAL FEASIBILITY:
28
CHAPTER 4
MODULE DESCRIPTION
29
4.2 DATA FLOW DIAGRAM
30
4.3 UML DIAGRAM
UML is not a programming language but there are tools that can be
used to generate code in various languages using UML diagrams.
UML has a direct relation with object-oriented analysis and design.
31
help development teams understand the requirements of their system,
including the role of human interaction therein and the differences
between various use cases. A use case diagram might display all use
cases of the system, or just one group of use cases with similar
functionality.
32
4.3.2 CLASS DIAGRAM:
33
CHAPTER 5
MODULE 1:
DATA PREPROCESSING
The raw traffic data gathered from various loop detector sensors is pre-
processed by this module. The sensors, as explained in the section
"Datasets," give real-time traffic data such as traffic flow, occupancy
rate, and speed, among other things. In this study, historical speed data
from a variety of sensors was used for trials. The pre-processing of raw
traffic data is described in depth in the subsections that follow.
Anomalies in traffic data gathered from various loop detector sensors
can include outliers owing to noise, missing values due to sensor
failures, and so on. As a result, data must be cleaned before being used
in research. As a result, data in this study was cleaned beforehand
utilising several data cleaning approaches. For example, it was
discovered that some loop detectors have a substantial number of
missing values in the dataset. As a result, such sensors were removed
from the dataset when the number of missing values exceeded a certain
threshold.
34
MODULE 2:
35
If the construction is complete, we can go to the HX711. The four cables of
the Load Cell must be connected to the weight sensor. The green HX711,
however, has six connections, of which we only need four for the cables.
The connection is as follows:
Red: E+
Black: E-
Green: A-
White: A+
The pins labeled B+/B- remain empty. Apparently there are versions of the
sensor. Where the pins are labeled S+/S- instead of A+/A-.
Now you just have to connect the sensor to the Raspberry Pi. Since this
also has only four connections, the wiring is quite simple:
36
Schematically, the connection to a Raspberry Pi 4 then looks as follows:
cd hx711py
sudo nano example.py
37
We are looking for the line in which the reference unit is set and
comment it out with a hashtag sign, so that the line looks as follows:
1 #hx.set_reference_unit(92)
Save it with CTRL+O and exit with CTRL+X. This reference unit is the
divisor, but we must first find it out in the next step. Meanwhile you can
run the example (abort with CTRL+C). The values should appear in the
range 0 to 200, but this is not important at this point.
E-Cycle
38
MODULE 3:
REMAINING RANGE PREDICTION
39
XGBoost Algorithm
Extreme Gradient Boosting (XGBoost) is an open-source library
that provides an efficient and effective implementation of the gradient
boosting algorithm. Although other open-source implementations of the
approach existed before XGBoost, the release of XGBoost appeared to
unleash the power of the technique and made the applied machine
learning community take notice of gradient boosting more generally.
Shortly after its development and initial release, XGBoost became the
go-to method and often the key component in winning solutions for
classification and regression problems in machine learning competitions.
XGBoost is an implementation of Gradient Boosted decision
trees. XGBoost models majorly dominate in many Kaggle
Competitions. In this algorithm, decision trees are created in sequential
form. Weights play an important role in XGBoost. Weights are
assigned to all the independent variables which are then fed into the
decision tree which predicts results. The weight of variables predicted
wrong by the tree is increased and these variables are then fed to the
second decision tree. These individual classifiers/predictors then
ensemble to give a strong and more precise model. It can work on
regression, classification, ranking, and user-defined prediction
problems.
40
Gradient boosting refers to a class of ensemble machine learning
algorithms that can be used for classification or regression predictive
modeling problems.
Ensembles are constructed from decision tree models. Trees are added
one at a time to the ensemble and fit to correct the prediction errors
made by prior models. This is a type of ensemble machine learning
model referred to as boosting. Models are fit using any arbitrary
differentiable loss function and gradient descent optimization algorithm.
This gives the technique its name, “gradient boosting,” as the loss
gradient is minimized as the model is fit, much like a neural network.
41
OUTPUT DESIGN
42
5. 2 TYPES OF TESTING
The primary goal of unit testing is to take the smallest piece of testable software in
the application, isolate it from the reaminder of the code, and determine it behabes
excatly as you except. Each unit is tested seperately before integrating them into
modules to test the interfaces between moduels. Unit testing has proven its value in
that large perentage of defects are identified is unit tested.
Here testing each model before freezing its already trained layers, taking images
for the dataset, traning the model for lesser epochs is also unit tested.
Testing is done for each module. After testing all the modules are integrated and
testing of the final system is done with the test data, specially designed to show
that the system will operate successfully in all its aspects. Thus, the system testing
is a confirmation that all is correct and an opportunity to show the user that the
system works.
Functional testing is a quality assurance (QA) process and a type of black box
testing that bases its test cases on the specifications of the software component
under test. Functions are tested by feeding them input and examining the output,
and internal program structure is rarely considered. Functional testing typically
invloves five steps.
43
1. The identification of functions that the software is expected to perform.
It is the vice versa of the Black Box testing. They do not watch the internal
variables during testing. This gives a clear idea about what is going on during
execution of the system. The point at which the bug occurs were all clear and were
removed.
In this testing we give input to the system and test the output. Here I do not go for
watching the internal file in the system and what are the changes made on them for
the required output.
44
CHAPTER 6
6.2 CODE
XGBoost Model
Xgboost_light.py
import numpy as np
import pandas as pd
import os
45
import model.ml as ml
trips_path = "/media/liang/aabbf09e-0a49-40b7-a5a8-
15148073b5d7/liang/mile_estimator/tijiaocode/origin_silce_plot/train_li
st_recover"
model_save_path = "/media/liang/aabbf09e-0a49-40b7-a5a8-
15148073b5d7/liang/range_prediction/output/models"
import joblib
if _name_ == '_main_':
train_list_recover = []
trip_i_path = os.path.join(trips_path,"{}.csv".format(i))
temp_values = pd.read_csv(trip_i_path)
46
if(len(temp_values)<15):
continue
train_list_recover.append(temp_values)
train_list_recover = data_clean.delet_stopping_trips(train_list_recove
r)
scaler_path = os.path.join(model_save_path,"scaler.m")
train_x,train_y,test_x,test_y = data_clean.train_test_perpare(train_list
_recover,scaler_model_path=scaler_path)
params = ml.get_parameters_xgb()
split = "training"
if split == "training":
47
evals=[(Train, "train"), (Test, "test")], early_stopping
_rounds=1000)
joblib.dump(xgbregressor, xgboost_model_save_path)
preds = xgbregressor.predict(Test)
test_y = np.array(test_y)
test_y = test_y[end_index]
preds = preds[end_index]
print("rmse-score:", score_rmse)
print("mae-score:", score_mae)
print("mape:", score_mape)
48
print("done")
print("done")
LightGBM Model
import numpy as np
import pandas as pd
import os
import utils.vis_function as vis_function
from utils import data_clean
import lightgbm as lgb
import model.ml as ml
trips_path = "/media/liang/aabbf09e-0a49-40b7-a5a8-
15148073b5d7/liang/mile_estimator/tijiaocode/origin_silce_plot/train_list_recover
"
model_save_path = "/media/liang/aabbf09e-0a49-40b7-a5a8-
15148073b5d7/liang/range_prediction/output/models"
import joblib
from utils.common_function import rmse,mae,mape
def light_params():
params = {}
params["tast"] = "train"
params["boosting_type"] = "gbdt"
params["objective"] = "regression"
params["metric"] = {"mae", "rmse"}
params["num_leaves"] = 6
49
params["eta"] = 0.05
params["min_child_weight"] = 0.5
params["bagging_fraction"] = 0.5
params["bagging_freq"] = 1
params['feature_fraction'] = 0.66
params["max_bin"] = 200
params["lambda_l2"] = 0.6571
params["lambda_l1"] = 0.4640
params["gamma"] = 0.0468
params["verbose"] = 1
return params
if _name_ == '_main_':
lightboost_model_save_path = os.path.join(model_save_path, "lightboost.m"
)
train_list_recover = []
silces = np.random.randint(0, 2371, size=2371)
for num,i in enumerate(silces):
trip_i_path = os.path.join(trips_path,"{}.csv".format(i))
temp_values = pd.read_csv(trip_i_path)
if(len(temp_values)<15):
continue
train_list_recover.append(temp_values)
print("load %s" % str(i),num)
50
train_list_recover = data_clean.delet_stopping_trips(train_list_recover)
scaler_path = os.path.join(model_save_path,"scaler.m")
train_x,train_y,test_x,test_y = data_clean.train_test_perpare(train_list_recove
r,scaler_model_path=scaler_path)
params = light_params()
split = "training"
if split == "training":
lgbm_regressor = lgb.train(params=params, train_set=Train,
num_boost_round=50000, valid_sets=[Train,Test],
early_stopping_rounds=1000)
joblib.dump(lgbm_regressor, lightboost_model_save_path)
else:
lgbm_regressor = joblib.load(lightboost_model_save_path)
preds = lgbm_regressor.predict(test_x)
endl_array = np.array([1]).repeat(test_y.size, axis=0)
test_y = np.array(test_y)
end_index = np.argwhere(np.array(test_y) > endl_array)
test_y = test_y[end_index]
preds = preds[end_index]
score_rmse = rmse(preds, test_y)
score_mae = mae(preds, test_y)
51
score_mape = mape(preds, test_y)
print("rmse-score:", score_rmse)
print("mae-score:", score_mae)
print("mape:", score_mape)
print("done")
print("done")
Blended Model
import numpy as np
import pandas as pd
import os
import utils.vis_function as vis_function
import utils.data_clean as data_clean
import xgboost as xgb
import model.ml as ml
trips_path = "/media/liang/aabbf09e-0a49-40b7-a5a8-
15148073b5d7/liang/mile_estimator/tijiaocode/origin_silce_plot/train_list_recover
"
model_save_path = "/media/liang/aabbf09e-0a49-40b7-a5a8-
15148073b5d7/liang/range_prediction/output/models"
import joblib
from utils.common_function import rmse,mae,mape
from trainer.lightgbm_model import light_params
import lightgbm as lgb
52
if _name_ == '_main_':
xgboost_1_model_save_path = os.path.join(model_save_path, "xgboost_1.m
")
xgboost_2_model_save_path = os.path.join(model_save_path, "xgboost_2.m
")
lightboost_1_model_save_path = os.path.join(model_save_path, "lightboost_
1.m")
train_list_recover = []
silces = np.random.randint(0, 2371, size=14)
for num,i in enumerate(silces):
trip_i_path = os.path.join(trips_path,"{}.csv".format(i))
temp_values = pd.read_csv(trip_i_path)
if(len(temp_values)<15):
continue
train_list_recover.append(temp_values)
print("load %s" % str(i),num)
train_list_recover = data_clean.delet_stopping_trips(train_list_recover)
scaler_path = os.path.join(model_save_path,"scaler.m")
anchor_based = False
if anchor_based == True:
train_x,train_y,test_x,test_y,anchor_train,anchor_test = data_clean.train_te
st_perpare(train_list_recover,
scaler_model_path=
scaler_path,
53
using_anchor_based
=anchor_based)
train_y = train_y - anchor_train
test_y = test_y-anchor_test
else:
train_x, train_y, test_x, test_y= data_clean.train_test_perpare(train_list_rec
over,scaler_model_path=scaler_path)
#xgboost data
Train = xgb.DMatrix(train_x, label=train_y)
Test = xgb.DMatrix(test_x, label=np.array(test_y))
params = ml.get_parameters_xgb()
#lightgbm data
Train_lgb = lgb.Dataset(train_x, label=np.array(list(train_y)))
Test_lgb = lgb.Dataset(test_x, label=np.array(test_y))
light_parameters = light_params()
split = "training"
if split == "training":
54
joblib.dump(lgbm_1, lightboost_1_model_save_path)
output_1 = xgb_1.predict(Train)
output_2 = lgbm_1.predict(train_x)
features_for_second_layer = np.concatenate([output_1[...,np.newaxis],outp
ut_2[...,np.newaxis]],axis=1)
xgb_2 = xgb.train(params, dtrain=Train, num_boost_round=50000,
evals=[(Train, "train"), (Test, "test")], early_stopping_rounds=1000)
joblib.dump(lgbm_1, xgboost_2_model_save_path)
else:
xgb_1 = joblib.load(xgboost_1_model_save_path)
xgb_2 = joblib.load(xgboost_2_model_save_path)
lgbm_1 = joblib.load(lightboost_1_model_save_path)
output_1 = xgb_1.predict(Test)
output_2 = lgbm_1.predict(Test_lgb)
features_concat = np.concatenate([output_1[...,np.newaxis],output_2[...,np.ne
waxis]],axis=1)
features_concat = xgb.DMatrix(features_concat, label=test_y)
preds = xgb_2.predict(features_concat)
if anchor_based:
preds = preds+ anchor_test
test_y = test_y + anchor_test
endl_array = np.array([1]).repeat(test_y.size, axis=0)
test_y = np.array(test_y)
end_index = np.argwhere(np.array(test_y) > endl_array)
test_y = test_y[end_index]
preds = preds[end_index]
55
score_rmse = rmse(preds, test_y)
score_mae = mae(preds, test_y)
score_mape = mape(preds, test_y)
print("rmse-score:", score_rmse)
print("mae-score:", score_mae)
print("mape:", score_mape)
print("done")
print("done")
56
CHAPTER 7
CONCLUSION
Accurate prediction of the remaining driving range is important
to EV drivers. In this paper, a two-stage framework for the remaining
driving range prediction of EVs has been proposed by merging two
advanced machine learning algorithms of XGBoost and LightGBM. The
results of experiments show that the blended model has a smaller error
range of [−0.8, 0.8] and a lower RMSE of 0.75 as compared to the error
range of [1.4, 1.4] in previous works. Besides, we use the cumulative
output energy of the motor and the batteries to reflect the battery
degradation, and use driving patterns related features to represent the
energy consumption level. These features, which are proposed for the
first time in our method, can effectively improve the accuracy of
remaining driving range prediction. Adding the cumulative output
energy of the motor and the batteries to the blended model can decrease
the MAPE by 5.27%. Anchor-based strategy was proposed for the first
time in our method, which converts the true label (driving distance) to
the residual values between the baseline and the true label for training.
Anchor-based strategy adopted in remaining driving range prediction
can solve the unbalance distribution of training data and achieve high
performance (i.e. low error range of [-0.8, 0.8]) on the testing data that
follows different distribution from training data.
57
FUTURE ENHANCEMENTS
58
CHAPTER 9
REFERENCES
[1] Modi, S., Bhattacharya, J., Basak, P.: Convolutional neural network–
baggeddecision tree: A hybrid approach to reduce electric vehicle‟s
driver‟s range anxiety by estimating energy consumption in real-time.
Soft Comput.25(3), 2399–2416 (2021).
[3] Tian, H.Y., Li, X.Y., Liu, F.: Prediction of continued driving range
of battery electric vehicle based on map information and cyclic SVR
model. Auto_x0002_mot. Eng. 42(9), 1174–1182 (2020)
59
[5] Moawad A, Gurumurthy KM, Verbas O, Li Z, Islam E, Freyermuth
V, Rousseau, A (2021) A Deep Learning Approach for Macro-scopic
Energy Consumption Prediction with Microscopic Quality or Electric
Vehicles (nov 2021). arXiv:2111.12861.
[9] Wei, H., He, C., Li, J.Q., Zhao, L.Q.: Study on method for online
estimating driving range of battery electric vehicle based on actual
driving cycle. J.Highway Transp. Res. Dev. 37(12), 149–158 (2020)
60
[10] Chen, T.H., Wang, X.G., Chu, Y., et al.: T4SE-XGB: Interpretable
sequence-based prediction of type IV secreted effectors using eXtreme
gradient boosting algorithm. Front. Microbiol. 11, 580382 (2020).
[12] Bi, J., Wang, Y., Sai, Q., et al.: Estimating remaining driving range
of battery electric vehicles based on real-world data: A case study of
Beijing, China. Energy. 169, 833–843 (2019)
61