Skip to content

本项目是我发表于期刊 Expert Systems with Applications 的论文《Energy-efficient mechanism of task offloading and resource allocation for hierarchical MEC in UAV-assisted mmWave IABN》的官方代码实现。我们提出了一种基于深度学习的方法,旨在最小化复杂的无人机辅助边缘计算网络中的系统能耗,同时保证服务质量。

License

Notifications You must be signed in to change notification settings

Zhangziqiang997/IOPO-main

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

无人机辅助毫米波IABN网络中分层MEC的任务卸载与资源分配节能机制

本仓库包含论文 《Energy-efficient mechanism of task offloading and resource allocation for hierarchical MEC in UAV-assisted mmWave IABN》 的官方代码实现,该论文发表于 Expert Systems with Applications

摘要

本项目解决无人机(UAV)辅助的毫米波(mmWave)一体化接入和回传(IABN)网络中分层移动边缘计算(Hierarchical MEC)场景下的任务卸载和资源分配问题。我们提出了一种基于深度学习的节能机制,智能地为用户设备(UE)的计算任务确定最优执行位置(本地处理或卸载到无人机服务器),核心优化目标是最小化系统总能耗,同时满足任务处理时延要求。

🚀 项目亮点

  • 智能决策: 利用训练好的深度学习模型,实现对新任务的快速、近乎最优的卸载决策
  • 能量高效: 核心优化目标专注于最小化整个系统的能量消耗
  • 服务质量保证: 考虑任务处理截止时间,通过超时惩罚机制确保及时完成
  • 完整仿真: 包含数据生成、模型训练和对比测试的完整流程

🔬 系统架构

系统由用户设备、多个无人机边缘服务器和一个集中的donor节点(基站)组成。用户设备产生的计算任务可以选择在本地执行,或者卸载到任意一个无人机上进行处理。我们的目标是找到一个总能耗最低的分配方案。

⚙️ 项目结构

IOPO-main/
├── Dataset/                          # 存放生成的训练和测试数据集
├── Log/                             # 存放训练和测试过程中的日志文件
├── Saved_model/                     # 存放训练好的模型参数
├── Config/                          # 存放数据和实验的配置文件
├── exp/                            # 存放实验分析和绘图相关的代码
├── Model_MLP.py                    # 神经网络模型定义
├── dataclass.py                    # 数据生成和系统环境定义
├── train.py                        # 模型训练脚本
├── test_compare_diff_methods.py    # 多种方法对比测试脚本
├── opt3.py                         # 优化算法相关实现
├── run.sh                          # 自动化运行脚本
└── requirements.txt                # Python 依赖包

📦 安装

  1. 克隆本项目到本地:

    git clone [你的项目链接]
    cd IOPO-main
  2. 建议使用虚拟环境:

    conda create -n iopo python=3.8
    conda activate iopo
  3. 安装依赖包:

    pip install -r requirements.txt

▶️ 使用方法

通过自动化脚本执行完整流程(数据生成 → 模型训练 → 测试):

  1. 配置参数: 修改 run.sh 中的参数:

    • uav_number: 无人机数量
    • user_number: 用户数量
    • number_of_train_data: 训练数据量
    • train_iter: 训练迭代次数
  2. 执行脚本:

    bash run.sh <uav_number> <user_number>

    例如,运行5个无人机和20个用户的场景:

    bash run.sh 5 20
  3. 查看结果:

    • 训练日志: ./Log/user:<user_number>_uav:<uav_number>/
    • 训练模型: ./Saved_model/user:<user_number>_uav:<uav_number>/
    • 生成数据: ./Dataset/user:<user_number>_uav:<uav_number>/

📜 引用

如果您在研究中使用了本代码,请引用我们的论文:

@article{MA2025126145,
  title = {Energy-efficient mechanism of task offloading and resource allocation for hierarchical MEC in UAV-assisted mmWave IABN},
  journal = {Expert Systems with Applications},
  volume = {267},
  pages = {126145},
  year = {2025},
  issn = {0957-4174},
  doi = {https://doi.org/10.1016/j.eswa.2024.126145},
  url = {https://www.sciencedirect.com/science/article/pii/S0957417424030124},
  author = {Zhongyu Ma and Ziqiang Zhang and Zhanjun Hao and Qun Guo},
  keywords = {Integrated access and backhaul, Mobile edge computing, Deep learning, Task offloading, Energy efficiency}
}

Energy-efficient Mechanism of Task Offloading and Resource Allocation for Hierarchical MEC in UAV-assisted mmWave IABN

This repository contains the official implementation of the paper "Energy-efficient mechanism of task offloading and resource allocation for hierarchical MEC in UAV-assisted mmWave IABN" published in Expert Systems with Applications.

Abstract

This project addresses the task offloading and resource allocation problem in Hierarchical Mobile Edge Computing (MEC) scenarios within UAV-assisted millimeter wave (mmWave) Integrated Access and Backhaul Networks (IABN). We propose a deep learning-based energy-efficient mechanism that intelligently determines the optimal execution location for user equipment (UE) computational tasks—either local processing or offloading to UAV servers—with the primary objective of minimizing total system energy consumption while satisfying task processing delay requirements.

🚀 Key Features

  • Intelligent Decision Making: Utilizes trained deep learning models for fast, near-optimal offloading decisions for new tasks
  • Energy Efficiency: Core optimization objective focuses on minimizing total system energy consumption
  • Quality of Service (QoS) Guarantee: Considers task processing deadlines with timeout penalty mechanisms
  • Comprehensive Simulation: Complete pipeline including data generation, model training, and comparative testing

🔬 System Architecture

The system consists of user equipment, multiple UAV edge servers, and a centralized donor node (base station). Computational tasks generated by user devices can be executed locally or offloaded to any UAV for processing. Our goal is to find an allocation scheme that minimizes total energy consumption.

⚙️ Project Structure

IOPO-main/
├── Dataset/                          # Generated training and testing datasets
├── Log/                             # Training and testing log files
├── Saved_model/                     # Trained model parameters
├── Config/                          # Data and experiment configuration files
├── exp/                            # Experimental analysis and plotting code
├── Model_MLP.py                    # Neural network model definition
├── dataclass.py                    # Data generation and system environment
├── train.py                        # Model training script
├── test_compare_diff_methods.py    # Comparative testing script
├── opt3.py                         # Optimization algorithm implementation
├── run.sh                          # Automated execution script
└── requirements.txt                # Python dependencies

📦 Installation

  1. Clone the repository:

    git clone [your-repository-url]
    cd IOPO-main
  2. Create a virtual environment (recommended):

    conda create -n iopo python=3.8
    conda activate iopo
  3. Install dependencies:

    pip install -r requirements.txt

▶️ Usage

Execute the complete pipeline (Data Generation → Model Training → Testing) using the automated script:

  1. Configure parameters: Modify parameters in run.sh:

    • uav_number: Number of UAVs
    • user_number: Number of users
    • number_of_train_data: Training data size
    • train_iter: Training iterations
  2. Run the script:

    bash run.sh <uav_number> <user_number>

    Example for 5 UAVs and 20 users:

    bash run.sh 5 20
  3. View results:

    • Training logs: ./Log/user:<user_number>_uav:<uav_number>/
    • Trained models: ./Saved_model/user:<user_number>_uav:<uav_number>/
    • Generated datasets: ./Dataset/user:<user_number>_uav:<uav_number>/

📜 Citation

If you use this code in your research, please cite our paper:

@article{MA2025126145,
  title = {Energy-efficient mechanism of task offloading and resource allocation for hierarchical MEC in UAV-assisted mmWave IABN},
  journal = {Expert Systems with Applications},
  volume = {267},
  pages = {126145},
  year = {2025},
  issn = {0957-4174},
  doi = {https://doi.org/10.1016/j.eswa.2024.126145},
  url = {https://www.sciencedirect.com/science/article/pii/S0957417424030124},
  author = {Zhongyu Ma and Ziqiang Zhang and Zhanjun Hao and Qun Guo},
  keywords = {Integrated access and backhaul, Mobile edge computing, Deep learning, Task offloading, Energy efficiency}
}

About

本项目是我发表于期刊 Expert Systems with Applications 的论文《Energy-efficient mechanism of task offloading and resource allocation for hierarchical MEC in UAV-assisted mmWave IABN》的官方代码实现。我们提出了一种基于深度学习的方法,旨在最小化复杂的无人机辅助边缘计算网络中的系统能耗,同时保证服务质量。

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published