Memuat
Memuat
Want to go deeper?
Join one of our courses or ask us directly on WhatsApp.
Picked from the software, topic, and level of “Class 5G Resource Allocation Deep RL #2: Simple Cellular Network Simulator: Channel, SINR, Throughput”.
Other ways we can help with Python.
Learn with a mentor
Scheduled AI & Machine Learning courses with live guidance and a certificate.

Multi-Objective Optimization Course: NSGA-II, MOPSO & Hybrid Algorithms (Python)

ECG Arrhythmia Classification Course with Wavelet & Deep Learning (PyTorch)

ANFIS + PSO/GA Course for Non-Linear Time Series Forecasting (Python)
Have it built for you
No time to learn Python? Our team can do the project for you.

Python Machine Learning — Prediction Models, Customer Segmentation, Fraud Detection & AI Apps

AI Image Creation with Stable Diffusion — Unlimited Custom Visual Production
★ 4.9

AI Image & Video Creation with Leonardo AI — All-in-One Visuals for Business
★ 4.9
Get notified about new Python classes
At most one email a week. Unfollow anytime with one click.
The full narration of this video. The current sentence is highlighted while the video plays; click any sentence to jump there.
Here is the final result, the 5G cellular network simulator we wrote ourselves. Complete with 6 interfering neighboring cells, fading that makes the signal fluctuate every millisecond, and SINR and throughput calculations for each user. Let's get started. Hello, welcome to episode two of the 5G resource allocation series with Deep Reinforcement Learning. To train the artificial intelligence agent, we need a sufficiently realistic simulator. User positions vary, signals are blocked by buildings, fading due to reflections, and interference from neighboring cells. Today we are building it.
Create a file named jaringan.py with the Network class. Our cells have a radius of 500 meters, surrounded by 6 neighboring base stations in a hexagonal layout. The reset function spreads 8 users uniformly at random within the cell, then adds log-normal shadowing of 6dB due to building obstruction, so users at the same distance can have different signal quality. We also calculate the gain from each user to each neighboring base station.
The step function advances the simulation by one slot. Fading is modeled as an autoregressive process of order 1 with a correlation of 0.95, so the channel changes gradually, not randomly. Each neighboring base station is active on each RB with a 50% probability, resulting in changing interference. The SINR function calculates the signal divided by interference plus noise for all users and all RBs, and the serve function calculates the bits received by each user as well as the transmit energy for one allocation decision.
Create a file named uji underscore jaringan.py, simulate 2000 slots, or 1 second, then run it. The closest user at 193 meters has an average SINR of 25.3 decibels and 2.37 megabits per second per RB. Users at the edge of the cell are weaker, A user even achieves minus 2 decibels with just 0.19 megabits per second per RB because it is close to the neighboring station. The median SINR for all users is 5.4 decibels. This system is limited by interference, like a real cellular network. Let's take a look at the graph.
The cell map shows the user color, yellow near the tower, purple at the edge near the neighboring cell. CDF SINR shows a difference in user quality up to 20 decibels. The graph on the right shows the SINR of 1 RB fluctuating by tens of decibels within milliseconds due to fading. Smart scheduling takes advantage of these fading peaks.
Done. We have already built a cellular network simulator with shadowing, fading rally correlated, neighbor cell interference, SINR, and throughput. In the next episode, we write a comparator scheduler, round robin, max separate eye, proportional fair, and water filling. Working on a thesis, Thesis, or research in the field of telecommunications and artificial intelligence? Cerdas Inovasi Digital helps implement cellular network research, from 5G simulators, channel models and SINR, proportional fair and water filling scheduling, up to pre-inforcement learning with PyTorch, as well as opening Python programming courses for electrical engineering and telecommunications. Want to master the entire series? From resource block concepts to agent efficiency evaluation The QN? All 6 episodes, complete with step-by-step PDF guides and source code, are available to premium tutorial subscribers. Subscribe starting at Rp69.000 per month, save 28% with the 12-month package, or one-time payment of Rp999.000 for lifetime access. Want a single class only? Buy single classes with lifetime access. Subscribe now at the premium page cerdasinovasidigital.com Contact us via WhatsApp, or visit cerdasinovasidigital.com Thank you for watching, see you in the next episode.
Type a question or keyword; we find the part of this episode that explains it and jump the video there.
Notes are saved with the current video time and are only visible to you.
Stuck on a step? Ask here; the instructor and other learners can answer.
No questions yet.

Cerdas Inovasi Digital Team
Software developers, BIM & 3D engineers, and AI practitioners
We build software, BIM models, games and AI automations for clients every day, and turn that hands-on work into step-by-step classes: every step is shown on screen and comes with a PDF guide you can keep.
See our clients →