Skip to content

Conversation

@SaraBe01
Copy link

Inizio lavori progetto Berselli e Ferrari

@hstairs
Copy link
Owner

hstairs commented Jun 23, 2025

Can you please remove all unnecessary files from the commit? Meaning those like *.DS files. Can you also please merge enhsp-20 backend into your fork and solve conflicts? Usually you don't want to have open conflicts at the time of the pull request

@hstairs
Copy link
Owner

hstairs commented Jun 23, 2025

Can you also add a few lines into the README.md file explaining how to operate the library in order to have it working with post-hoc visualisation.

Copy link
Owner

@hstairs hstairs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Try to address all comments, and then I'll do a final check on Monday (7 of July)

private final int id;
private final Integer parentId;

private static SearchEventLogger eventLogger;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The choice to have a private static event logger is not great. Are we sure this needs to be a property of SearchNode? I understand you need a global access because you have many Search Nodes but this is not a good design solution. I think there is a way to handle the logging information externally by taking information written in the Search Node to analyse.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The static property eventLogger had been removed in the "Fix required" commit

public Object[] helpfulActions;

public SearchNode (State s1, Object action, SearchNode father, float g, float h) {
private static int NEXT_ID = 0;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is connected to the EventLogger problem. Please try to limit as much as possible the use of static variables

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We tried to remove the static variable NEXT_ID from SearchNode but we didn't find a possible solution. Also increasing the parent-id during the generation of the son is not correct because all "brothers" would have the same id.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems you are completely changing the algorithm here. Is this wanted? What are you doing here? @SaraBe01

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are you removing the credits? @SaraBe01

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Credits readded

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What are you doing here? Again, this seems like a complete change of the algorithm. Please explain. @SaraBe01

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

LinkedList plan = new LinkedList<>();
lastState = c.s;
while (c.transition != null) {
if (c.transition != null) {//this is an action
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We didn't remove the line of code but only the comment, so we added it again

}

public void initHandle(SearchNode init){
searchSpaceHandle = init;//this needs to have an handle on the initial state for saving it into a json file
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We didn't remove the line of code but only the comment, so we added it again


public int numberOfSons;
public float minSoFar;
private static int nextId = 0; //only way tohav a global ID for all nodes
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix comment

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment fixed

@@ -1,208 +1,175 @@
/*
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are you removing the credits?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Credits readded

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants