Coder Social home page Coder Social logo

nodedge / nodedge Goto Github PK

View Code? Open in Web Editor NEW
63.0 3.0 1.0 50.31 MB

A Python3 graphic environment for next-generation engineering.

Home Page: https://www.nodedge.io

License: MIT License

Python 99.79% Makefile 0.09% Batchfile 0.11%
simulation python3 windows linux macos block-diagram engineering physical-systems pyside6 qt6

nodedge's Introduction

drawing

Nodedge

A Python3 graphic environment for next-generation engineering.

Nodedge.io

PyPI - Nodedge Version PyPI - Python Version License Test Status Test Coverage Documentation Status Code Style Code Scanning

What is Nodedge?

Nodedge is the first open-source Python editor for scientific and engineering applications. It provides a comprehensive graphic environment for accelerating the design, simulation, analysis, and deployment of complex scientific and engineering systems. With Nodedge, you can:

  • design and simulate dynamical systems such as robotic, physical, and chemical systems
  • generate Python code from your graphic models with a simple click
  • interactively plot and edit the data generated by your simulation
  • plot and analyze log files with common extensions like csv, mf4, mat, and others.

nodedge


Installation

You can install Nodedge in different ways.

Download the installer

  • Windows: download latest release
  • macOS: please bear with us, we are currently in the process of developing it!
  • Linux: please bear with us, we are currently in the process of developing it!

Install from pip

Alternatively, you can install Nodedge form pip with:

pip install nodedge

Clone from GitHub

Alternatively, you can clone our project from Github and install the requirements with:

git clone https://github.com/nodedge/nodedge nodedge
cd nodedge
pip install -r .\requirements\freeze\requirements_dev.txt

Quick start examples

The list of examples is constantly expanding. You can find an up-to-date list in the examples folder on GitHub. The examples provided below will allow you to get started with Nodedge.

Create a model in Nodedge

In this example, we demonstrate how to create a model in Nodedge to calculate the gravitational force between two objects:

  1. In Nodedge, create a new file by clicking on File > New
  2. Add input nodes to your model to represent the constant variables of the gravitational force. From the Node libraries widget on the right, drag-and-drop Input nodes to the scene and insert the constant values in their labels
  3. Rename the input nodes by editing their title in the Node details widget on the right
  4. From the Operator library, drag-and-drop Multiplication, Division, and Power nodes to the scene and connect them to the input nodes
  5. Connect an output node to display the result of the computation.

Congratulations! You have just created your first Nodedge model! If you want to compute the gravitational force for different objects, simply edit the mass values in the input nodes. Nodedge will instantly re-evaluate the model and display the updated result.


gravitational_force_example

Open a dataset in Dats

In this example, we show you how to import a dataset into Dats, plot the signals contained within it, and add new ones:

  1. Open Dats by clicking on its icon in the home page
  2. Click on File > Open then navigate to the example file examples/csv_analyzer/reinforcement_learning_data.csv
  3. Click on Open
  4. From the Variables widget on the left, select init_x and target_x by clicking on their labels
  5. Plot the curves by:
    • clicking on the Plot button, or
    • drag-and-dropping the signals to the worksheet
  6. Right-click on the worksheet window, then click on Add subplot
  7. Plot the init_y and target_y signals as done at step 5
  8. To save the current Dats configuration, click on File > Save configuration, then navigate to the folder where you want to save the configuration file and enter a file name like csv_analyzer_config.json. Click on Save

Congratulations! You have successfully analyzed your first dataset in Dats!


csv_analyzer_example

Roadmap

Nodedge development team has a lot of exciting features planned for the future! The project is actively being developed and there are plans to add support for a wide range of features. If you wish to join our efforts, do not hesitate to contact us. Any help is welcome!

Our roadmap includes, and is not limited to:

  • In Dats, extend support to other file formats, including hdf, rosag, etc.
  • In Nodedge, add support for saving and sharing Python custom nodes in a node library. In a custom node, the user can enter a custom piece of Python code that runs within the current Nodedge model. The custom node can be saved to the nodes library and reused it in the future
  • In Nodedge, add support for the simulation of dynamic systems. In particular, add a widget for the selection of a solver and its configuration, as well as start/pause/stop buttons and others
  • In Nodedge and Dats, add support for robotics-specific features, such as embedded code generation for common hardware platform, real-time data acquisition and inspection

Contributing

You can contribute to Nodedge in several ways:

For developing Nodedge, we recommend using PyCharm IDE. You can find helpful information on how to install and set it up on Nodedge Wiki and PyCharm website.

nodedge's People

Contributors

dependabot[bot] avatar don4get avatar enricaso avatar nodedge avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

cherojeong

nodedge's Issues

Comment is not taken into account for fitting model to view.

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]

Smartphone (please complete the following information):

  • Device: [e.g. iPhone6]
  • OS: [e.g. iOS8.1]
  • Browser [e.g. stock browser, safari]
  • Version [e.g. 22]

Additional context
Add any other context about the problem here.

Rename objects

Tooltips:
New: Create new Nodedge graph -> Create new Nodedge model (in the tutorials, we call it a model)
Add comment: Add comment element in current scene -> Add comment to current model
Window: Node toolbar -> Node libraries
Simulation: Eval all nodes -> Simulation: Evaluate all nodes or Evaluate all nodes
Simulation: Simulate -> Start simulation (there will also be Stop simulation and Pause simulation)

Add toolbar actions:
Window: History
Window: Node details

In history:
Delete cut edges. -> Delete edges (check if it is associated with the action of cutting an edge or not)

On the website:
objects -> items

Dats menu bar:
File > Take screenShot ->Take screenshot
View > View all -> Fit to view

Dats right click:
Fix to view -> Fit to view

Dats menu bar: add
Window > Logs
Window > Signals

Move Tools before Help

Tests fail with python 3.8.0

Describe the bug
$ pytest PySide2/__init__.py: Unable to import shiboken2 fro m C:\github\nodedge\venv38\Scripts\pytest.exe, C:\U sers\a.debortoli\AppData\Local\Programs\Python\Pyth on38\python38.zip, C:\Users\a.debortoli\AppData\Loc al\Programs\Python\Python38\DLLs, C:\Users\a.debort oli\AppData\Local\Programs\Python\Python38\lib, C:\ Users\a.debortoli\AppData\Local\Programs\Python\Pyt hon38, c:\github\nodedge\venv38, c:\github\nodedge\ venv38\lib\site-packages INTERNALERROR> Traceback (most recent call last): INTERNALERROR> File "c:\github\nodedge\venv38\lib \site-packages\_pytest\main.py", line 236, in wrap_ session INTERNALERROR> config._do_configure() INTERNALERROR> File "c:\github\nodedge\venv38\lib \site-packages\_pytest\config\__init__.py", line 91 1, in _do_configure INTERNALERROR> self.hook.pytest_configure.call_ historic(kwargs=dict(config=self)) INTERNALERROR> File "c:\github\nodedge\venv38\lib \site-packages\pluggy\hooks.py", line 308, in call_ historic INTERNALERROR> res = self._hookexec(self, self. get_hookimpls(), kwargs) INTERNALERROR> File "c:\github\nodedge\venv38\lib \site-packages\pluggy\manager.py", line 93, in _hoo kexec INTERNALERROR> return self._inner_hookexec(hook , methods, kwargs) INTERNALERROR> File "c:\github\nodedge\venv38\lib \site-packages\pluggy\manager.py", line 84, in <lam bda> INTERNALERROR> self._inner_hookexec = lambda ho ok, methods, kwargs: hook.multicall( INTERNALERROR> File "c:\github\nodedge\venv38\lib \site-packages\pluggy\callers.py", line 208, in _mu lticall INTERNALERROR> return outcome.get_result() INTERNALERROR> File "c:\github\nodedge\venv38\lib \site-packages\pluggy\callers.py", line 80, in get_ result INTERNALERROR> raise ex[1].with_traceback(ex[2] ) INTERNALERROR> File "c:\github\nodedge\venv38\lib \site-packages\pluggy\callers.py", line 187, in _mu lticall INTERNALERROR> res = hook_impl.function(*args) INTERNALERROR> File "c:\github\nodedge\venv38\lib \site-packages\pytestqt\plugin.py", line 218, in py test_configure INTERNALERROR> qt_api.set_qt_api(config.getini( "qt_api")) INTERNALERROR> File "c:\github\nodedge\venv38\lib \site-packages\pytestqt\qt_compat.py", line 111, in set_qt_api INTERNALERROR> self.QtCore = QtCore = _import_m odule("QtCore") INTERNALERROR> File "c:\github\nodedge\venv38\lib \site-packages\pytestqt\qt_compat.py", line 95, in _import_module INTERNALERROR> m = __import__(_root_module, glo bals(), locals(), [module_name], 0) INTERNALERROR> File "c:\github\nodedge\venv38\lib \site-packages\PySide2\__init__.py", line 91, in <m odule> INTERNALERROR> _setupQtDirectories() INTERNALERROR> File "c:\github\nodedge\venv38\lib \site-packages\PySide2\__init__.py", line 57, in _s etupQtDirectories INTERNALERROR> import shiboken2 INTERNALERROR> File "c:\github\nodedge\venv38\lib \site-packages\shiboken2\__init__.py", line 27, in <module> INTERNALERROR> from .shiboken2 import * INTERNALERROR> ImportError: DLL load failed while i mporting shiboken2: The specified procedure could n ot be found.
To Reproduce
Steps to reproduce the behavior:

  1. pytest tests
  2. Test fail.

Expected behavior
As in setup.py, the compatibility is 3.6+, tests should pass with 3.8.0

Desktop (please complete the following information):

  • OS: Win10 pro
  • Version: master branch

Workaround
It works with 3.8.3.

Rename Dats actions

Rename the following:
Remove log -> Close log (symmetric to Open)
Create worksheet -> Add worksheet
Create workbook -> Add workbook

Add Add suplot to File menu, right above Add worksheet

image

Failure when a csv contains numeric and string columns.

When opening a csv that contains both numbers and strings Dats fails. Add a check each column content. If the content is made of strings (or has at least one string), then discard the column. When there are only numeric columns Dats works properly. Of course, the header can be made of strings.

Fix text bar in comment

The text bar behaves strangely in comments: in editing mode, sometimes it blinks while other times it is still and other times does not even appear.

Decouple logs and workbooks.

At the moment, we can import two logs and plot signals from both of them in a worksheet. However, only those of the selected log will be displayed. We could either allow plot signals from different logs in the same worksheet or at least in different worksheet/books.

Set less visible color for Dats suplot grid

At the moment, in the Dark theme the grid is very bright, which is disturbing for the analysis of the curves (also very bright).
I guess that there is the same issue for the Light theme, but it needs to be checked.

Show code window is very small and does not show arrows for enlarging it.

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]

Smartphone (please complete the following information):

  • Device: [e.g. iPhone6]
  • OS: [e.g. iOS8.1]
  • Browser [e.g. stock browser, safari]
  • Version [e.g. 22]

Additional context
Add any other context about the problem here.

test issue

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]

Smartphone (please complete the following information):

  • Device: [e.g. iPhone6]
  • OS: [e.g. iOS8.1]
  • Browser [e.g. stock browser, safari]
  • Version [e.g. 22]

Additional context
Add any other context about the problem here.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.