diff --git a/partitionmanager.cpp b/partitionmanager.cpp
index a42c303..739db52 100644
--- a/partitionmanager.cpp
+++ b/partitionmanager.cpp
@@ -34,6 +34,7 @@
 
 #include "variables.h"
 #include "common.h"
+#include "ui.h"
 #include "partitions.hpp"
 #include "data.hpp"
 #include "twrp-functions.hpp"
@@ -47,6 +48,8 @@
 	#include "cutils/properties.h"
 #endif
 
+extern RecoveryUI* ui;
+
 int TWPartitionManager::Process_Fstab(string Fstab_Filename, bool Display_Error) {
 	FILE *fstabFile;
 	char fstab_line[MAX_FSTAB_LINE_LENGTH];
@@ -452,12 +455,43 @@
 	return true;
 }
 
-bool TWPartitionManager::Backup_Partition(TWPartition* Part, string Backup_Folder, bool generate_md5, unsigned long long* img_bytes_remaining, unsigned long long* file_bytes_remaining, unsigned long *img_time, unsigned long *file_time) {
+bool TWPartitionManager::Backup_Partition(TWPartition* Part, string Backup_Folder, bool generate_md5, unsigned long long* img_bytes_remaining, unsigned long long* file_bytes_remaining, unsigned long *img_time, unsigned long *file_time, unsigned long long *img_bytes, unsigned long long *file_bytes) {
 	time_t start, stop;
+	int img_bps, file_bps;
+	unsigned long total_time, remain_time, section_time;
+	int use_compression, backup_time;
+	float pos;
 
 	if (Part == NULL)
 		return true;
 
+	DataManager::GetValue(TW_BACKUP_AVG_IMG_RATE, img_bps);
+
+	DataManager::GetValue(TW_USE_COMPRESSION_VAR, use_compression);
+	if (use_compression)
+		DataManager::GetValue(TW_BACKUP_AVG_FILE_COMP_RATE, file_bps);
+	else
+		DataManager::GetValue(TW_BACKUP_AVG_FILE_RATE, file_bps);
+
+	// We know the speed for both, how far into the whole backup are we, based on time
+	total_time = (*img_bytes / (unsigned long)img_bps) + (*file_bytes / (unsigned long)file_bps);
+	remain_time = (*img_bytes_remaining / (unsigned long)img_bps) + (*file_bytes_remaining / (unsigned long)file_bps);
+
+	pos = (total_time - remain_time) / (float) total_time;
+	ui->SetProgress(pos);
+
+	LOGI("Estimated Total time: %lu  Estimated remaining time: %lu\n", total_time, remain_time);
+
+	// And get the time
+	if (Part->Backup_Method == 1)
+		section_time = Part->Backup_Size / file_bps;
+	else
+		section_time = Part->Backup_Size / img_bps;
+
+	// Set the position
+	pos = section_time / (float) total_time;
+	ui->ShowProgress(pos, section_time);
+
 	time(&start);
 
 	if (Part->Backup(Backup_Folder)) {
@@ -470,16 +504,23 @@
 						return false;
 					if (!Make_MD5(generate_md5, Backup_Folder, (*subpart)->Backup_FileName))
 						return false;
+					if (Part->Backup_Method == 1) {
+						*file_bytes_remaining -= (*subpart)->Backup_Size;
+					} else {
+						*img_bytes_remaining -= (*subpart)->Backup_Size;
+					}
 				}
 			}
 		}
 		time(&stop);
+		backup_time = (int) difftime(stop, start);
+		LOGI("Partition Backup time: %d\n", backup_time);
 		if (Part->Backup_Method == 1) {
 			*file_bytes_remaining -= Part->Backup_Size;
-			*file_time += (int) difftime(stop, start);
+			*file_time += backup_time;
 		} else {
 			*img_bytes_remaining -= Part->Backup_Size;
-			*img_time += (int) difftime(stop, start);
+			*img_time += backup_time;
 		}
 		return Make_MD5(generate_md5, Backup_Folder, Part->Backup_FileName);
 	} else {
@@ -716,25 +757,27 @@
 	img_bytes_remaining = img_bytes;
     file_bytes_remaining = file_bytes;
 
-	if (!Backup_Partition(backup_sys, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time))
+	ui->SetProgress(0.0);
+
+	if (!Backup_Partition(backup_sys, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time, &img_bytes, &file_bytes))
 		return false;
-	if (!Backup_Partition(backup_data, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time))
+	if (!Backup_Partition(backup_data, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time, &img_bytes, &file_bytes))
 		return false;
-	if (!Backup_Partition(backup_cache, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time))
+	if (!Backup_Partition(backup_cache, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time, &img_bytes, &file_bytes))
 		return false;
-	if (!Backup_Partition(backup_recovery, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time))
+	if (!Backup_Partition(backup_recovery, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time, &img_bytes, &file_bytes))
 		return false;
-	if (!Backup_Partition(backup_boot, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time))
+	if (!Backup_Partition(backup_boot, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time, &img_bytes, &file_bytes))
 		return false;
-	if (!Backup_Partition(backup_andsec, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time))
+	if (!Backup_Partition(backup_andsec, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time, &img_bytes, &file_bytes))
 		return false;
-	if (!Backup_Partition(backup_sdext, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time))
+	if (!Backup_Partition(backup_sdext, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time, &img_bytes, &file_bytes))
 		return false;
-	if (!Backup_Partition(backup_sp1, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time))
+	if (!Backup_Partition(backup_sp1, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time, &img_bytes, &file_bytes))
 		return false;
-	if (!Backup_Partition(backup_sp2, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time))
+	if (!Backup_Partition(backup_sp2, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time, &img_bytes, &file_bytes))
 		return false;
-	if (!Backup_Partition(backup_sp3, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time))
+	if (!Backup_Partition(backup_sp3, Full_Backup_Path, do_md5, &img_bytes_remaining, &file_bytes_remaining, &img_time, &file_time, &img_bytes, &file_bytes))
 		return false;
 
 	// Average BPS
@@ -742,8 +785,8 @@
 		img_time = 1;
 	if (file_time == 0)
 		file_time = 1;
-	unsigned long int img_bps = img_bytes / img_time;
-	unsigned long int file_bps = file_bytes / file_time;
+	int img_bps = (int)img_bytes / (int)img_time;
+	int file_bps = (int)file_bytes / (int)file_time;
 
 	ui_print("Average backup rate for file systems: %lu MB/sec\n", (file_bps / (1024 * 1024)));
 	ui_print("Average backup rate for imaged drives: %lu MB/sec\n", (img_bps / (1024 * 1024)));
@@ -753,15 +796,35 @@
 	unsigned long long actual_backup_size = TWFunc::Get_Folder_Size(Full_Backup_Path, true);
     actual_backup_size /= (1024LLU * 1024LLU);
 
+	int prev_img_bps, prev_file_bps, use_compression;
+	DataManager::GetValue(TW_BACKUP_AVG_IMG_RATE, prev_img_bps);
+	img_bps += (prev_img_bps * 4);
+    img_bps /= 5;
+
+    DataManager::GetValue(TW_USE_COMPRESSION_VAR, use_compression);
+	if (use_compression)
+		DataManager::GetValue(TW_BACKUP_AVG_FILE_COMP_RATE, prev_file_bps);
+    else
+		DataManager::GetValue(TW_BACKUP_AVG_FILE_RATE, prev_file_bps);
+	file_bps += (prev_file_bps * 4);
+    file_bps /= 5;
+
+    DataManager::SetValue(TW_BACKUP_AVG_IMG_RATE, img_bps);
+	if (use_compression)
+		DataManager::SetValue(TW_BACKUP_AVG_FILE_COMP_RATE, file_bps);
+	else
+		DataManager::SetValue(TW_BACKUP_AVG_FILE_RATE, file_bps);
+
 	ui_print("[%llu MB TOTAL BACKED UP]\n", actual_backup_size);
 	Update_System_Details();
 	ui_print("[BACKUP COMPLETED IN %d SECONDS]\n\n", total_time); // the end
     return true;
 }
 
-bool TWPartitionManager::Restore_Partition(TWPartition* Part, string Restore_Name) {
+bool TWPartitionManager::Restore_Partition(TWPartition* Part, string Restore_Name, int partition_count) {
 	time_t Start, Stop;
 	time(&Start);
+	ui->ShowProgress(1.0 / (float)partition_count, 150);
 	if (!Part->Restore(Restore_Name))
 		return false;
 	if (Part->Has_SubPartition) {
@@ -929,23 +992,24 @@
 			ui_print("Skipping MD5 check based on user setting.\n");
 
 	ui_print("Restoring %i partitions...\n", partition_count);
-	if (restore_sys != NULL && !Restore_Partition(restore_sys, Restore_Name))
+	ui->SetProgress(0.0);
+	if (restore_sys != NULL && !Restore_Partition(restore_sys, Restore_Name, partition_count))
 		return false;
-	if (restore_data != NULL && !Restore_Partition(restore_data, Restore_Name))
+	if (restore_data != NULL && !Restore_Partition(restore_data, Restore_Name, partition_count))
 		return false;
-	if (restore_cache != NULL && !Restore_Partition(restore_cache, Restore_Name))
+	if (restore_cache != NULL && !Restore_Partition(restore_cache, Restore_Name, partition_count))
 		return false;
-	if (restore_boot != NULL && !Restore_Partition(restore_boot, Restore_Name))
+	if (restore_boot != NULL && !Restore_Partition(restore_boot, Restore_Name, partition_count))
 		return false;
-	if (restore_andsec != NULL && !Restore_Partition(restore_andsec, Restore_Name))
+	if (restore_andsec != NULL && !Restore_Partition(restore_andsec, Restore_Name, partition_count))
 		return false;
-	if (restore_sdext != NULL && !Restore_Partition(restore_sdext, Restore_Name))
+	if (restore_sdext != NULL && !Restore_Partition(restore_sdext, Restore_Name, partition_count))
 		return false;
-	if (restore_sp1 != NULL && !Restore_Partition(restore_sp1, Restore_Name))
+	if (restore_sp1 != NULL && !Restore_Partition(restore_sp1, Restore_Name, partition_count))
 		return false;
-	if (restore_sp2 != NULL && !Restore_Partition(restore_sp2, Restore_Name))
+	if (restore_sp2 != NULL && !Restore_Partition(restore_sp2, Restore_Name, partition_count))
 		return false;
-	if (restore_sp3 != NULL && !Restore_Partition(restore_sp3, Restore_Name))
+	if (restore_sp3 != NULL && !Restore_Partition(restore_sp3, Restore_Name, partition_count))
 		return false;
 
 	Update_System_Details();
diff --git a/partitions.hpp b/partitions.hpp
index e968468..c04f0cf 100644
--- a/partitions.hpp
+++ b/partitions.hpp
@@ -182,8 +182,8 @@
 
 private:
 	bool Make_MD5(bool generate_md5, string Backup_Folder, string Backup_Filename); // Generates an MD5 after a backup is made
-	bool Backup_Partition(TWPartition* Part, string Backup_Folder, bool generate_md5, unsigned long long* img_bytes_remaining, unsigned long long* file_bytes_remaining, unsigned long *img_time, unsigned long *file_time);
-	bool Restore_Partition(TWPartition* Part, string Restore_Name);
+	bool Backup_Partition(TWPartition* Part, string Backup_Folder, bool generate_md5, unsigned long long* img_bytes_remaining, unsigned long long* file_bytes_remaining, unsigned long *img_time, unsigned long *file_time, unsigned long long *img_bytes, unsigned long long *file_bytes);
+	bool Restore_Partition(TWPartition* Part, string Restore_Name, int partition_count);
 	void Output_Partition(TWPartition* Part);
 
 private:
