Skip to content

ChatGPT said: The System Identification Tool is a Python–Tkinter GUI for modeling quadcopter flight dynamics, currently using placeholder models, with future plans for real algorithms, MIMO support, and GUI enhancements.

Notifications You must be signed in to change notification settings

iyad-salameh/system-identification

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

System Identification Tool for Drone Flight Data A graphical user interface (GUI) built with Python and Tkinter for analyzing, modeling, and visualizing drone flight dynamics. This tool provides a framework for applying system identification techniques to drone sensor data.

📋 Overview The System Identification Tool is designed to help engineers, researchers, and hobbyists model the behavior of a quadcopter drone. By loading input data (like motor commands) and output data (like accelerometer and gyroscope readings), users can generate mathematical models that describe the drone's response.

The application allows for data synthesis, model analysis using various methods, and visualization of the results, all through an easy-to-use interface.

✨ Features Synthesize Flight Data: Generate synthetic input (PWM) and output (IMU) data for various flight maneuvers like Hovering, Roll, Pitch, and Yaw. Perfect for testing without real flight logs.

Load Custom Data: Easily load your own flight data from .csv files.

Multiple System ID Methods: A framework to analyze data using three common modeling approaches:

AutoRegressive (AR)

Transfer Function (TF)

State-Space (SS)

Visualize Results: Automatically plots the model's output against the original data using matplotlib for a quick visual comparison of model fit.

Export Data & Models:

Export the original data combined with the model's results to a new .csv file.

Save the derived mathematical model representation to a .txt file.

Export a visual block diagram of the model as a .png image.

Live Script Editing: A built-in text editor to modify the application script on the fly (with a reset-to-default option).

⚠️ Current Status & Limitations This project is currently a proof-of-concept and a developmental framework. The core GUI and data handling workflows are in place, but the system identification algorithms are not yet fully implemented.

Placeholder Models: The current version uses hardcoded, predefined models for the AR, TF, and State-Space methods. It does not dynamically estimate the model parameters from the loaded data. The primary purpose is to demonstrate the application's workflow.

Hardcoded File Paths: The script contains absolute file paths for the script editing/resetting feature, which will need to be changed to relative paths to work on different machines.

SISO Focus: The analysis is currently configured for Single-Input, Single-Output (SISO) systems (e.g., modeling the roll angle from a specific input), even though the GUI supports other selections.

Future development will focus on replacing these placeholder models with genuine system identification algorithms.

🚀 Getting Started Follow these instructions to get a copy of the project up and running on your local machine.

Prerequisites You will need Python 3 and the following libraries. You can install them using pip:

pip install pandas numpy matplotlib scipy statsmodels

Installation Clone the repository to your local machine:

git clone https://github.com/your-username/system-identification-tool.git

Navigate to the project directory:

cd system-identification-tool

Running the Application Execute the main script from your terminal:

python sysidtool.py

📖 How to Use Launch the application.

(Optional) Synthesize Data:

Select a Flight Mode (e.g., "Roll").

Click Synthesize and Export Data.

Save the generated input_data.csv and output_data.csv files.

Load Data:

Click Load Input Data and select your input file.

Click Load Output Data and select your output file.

Configure Analysis:

Select the Logging Frequency that matches your data.

Choose a System ID Method (e.g., "TF").

Choose a System Type (e.g., "SISO").

Run Identification:

Click Run System Identification.

A plot will appear showing your original data versus the (currently placeholder) model's output.

Export Results:

Click Export Data and Analysis to save the combined data.

Click Export Model to save the model's mathematical form and a visual diagram.

🤝 How to Contribute Contributions are welcome! This project is in its early stages, and there is a lot of room for improvement. Here are some areas where you can help:

Implement Real System ID Algorithms: Replace the placeholder models in auto_regressive_model(), transfer_function_model(), and state_space_model() with actual estimation algorithms (e.g., using scipy.signal or statsmodels).

Improve GUI: Enhance the user interface, add more data visualization options, or provide real-time feedback.

Fix File Paths: Convert the hardcoded paths to relative paths to make the script portable.

Expand Model Support: Add support for MIMO, MISO, and SIMO systems.

Add Documentation: Improve code comments and expand this README.

Please feel free to fork the repository, make changes, and submit a pull request.

📄 License This project is licensed under the MIT License - see the LICENSE.md file for details.

About

ChatGPT said: The System Identification Tool is a Python–Tkinter GUI for modeling quadcopter flight dynamics, currently using placeholder models, with future plans for real algorithms, MIMO support, and GUI enhancements.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages