Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CI Python requirements #154

Merged
merged 3 commits into from
Sep 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ jobs:
needs: intro
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11"]
python-version: ["3.9", "3.10"]

# Steps represent a sequence of tasks that will be executed as part of the job.
steps:
Expand All @@ -209,11 +209,11 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
cache: 'pip'
cache-dependency-path: .github/workflows/requirements.txt

- name: Install dependencies
run: |
pip install pylint "git+https://github.com/gabryelreyes/SerialMuxProt.git#egg=SerialMuxProt&subdirectory=python/SerialMuxProt"
run: pip install -r .github/workflows/requirements.txt

- name: Analysing the code with pylint
run: |
pylint ./webots/controllers/*/*.py
run: pylint ./webots/controllers/*/*.py
10 changes: 10 additions & 0 deletions .github/workflows/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
platformio==6.1.15
numpy==1.26.4
tensorflow==2.10.0
tensorflow-probability==0.15.0
keras==2.10.0
matplotlib==3.9.0
pandas==2.2.2
pytest==8.3.2
pylint==3.2.7
git+https://github.com/gabryelreyes/SerialMuxProt.git#egg=SerialMuxProt&subdirectory=python/SerialMuxProt
10 changes: 5 additions & 5 deletions webots/controllers/RL_Supervisor/agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,11 @@
import csv
import os
import struct
import numpy as np # pylint: disable=import-error
import tensorflow as tf # pylint: disable=import-error
import tensorflow_probability as tfp # pylint: disable=import-error
from trajectory_buffer import Memory
from networks import Models
import numpy as np
import tensorflow as tf
import tensorflow_probability as tfp
from trajectory_buffer import Memory
from networks import Models

################################################################################
# Variables
Expand Down
10 changes: 5 additions & 5 deletions webots/controllers/RL_Supervisor/networks.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,11 @@
# Imports
################################################################################

import tensorflow as tf # pylint: disable=import-error
import tensorflow_probability as tfp # pylint: disable=import-error
from tensorflow import keras # pylint: disable=import-error
from keras import layers # pylint: disable=import-error
from keras.regularizers import l2 # pylint: disable=import-error
import tensorflow as tf
import tensorflow_probability as tfp
from tensorflow import keras
from keras import layers
from keras.regularizers import l2

################################################################################
# Variables
Expand Down
4 changes: 2 additions & 2 deletions webots/controllers/RL_Supervisor/plotting.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
# mini-batch steps.

# Imports
import matplotlib.pyplot as plt # pylint: disable=import-error
import pandas as pd # pylint: disable=import-error
import matplotlib.pyplot as plt
import pandas as pd

# Define the path to the CSV file
LOG_FILE = "logs/training_logs.csv"
Expand Down
2 changes: 1 addition & 1 deletion webots/controllers/RL_Supervisor/trajectory_buffer.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
# Imports
################################################################################

import numpy as np # pylint: disable=import-error
import numpy as np

################################################################################
# Variables
Expand Down