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

Merge DotaWorld #17

Closed
wants to merge 0 commits into from
Closed

Merge DotaWorld #17

wants to merge 0 commits into from

Conversation

Nostrademous
Copy link
Collaborator

Issue #9

This also adds initial ability_leveling policy updates.

I worry we are diverging too much.

@Nostrademous
Copy link
Collaborator Author

Just added tracking of tower units for enemies and allies.

Also, tested ability leveling (by forcing it to always level the first option). Not sure how to implement it in torch sensibly. I create a int32 Tensor for it but not sure how to determine selection in a ML way.

policy.py Outdated
@@ -161,6 +184,9 @@ def select_actions(cls, head_prob_dict):
else:
ValueError("Invalid Action Selection.")

# determine ability to level up
action_dict['ab_level'] = head_prob_dict['ability_levelup'][0][0][0].item()
Copy link
Collaborator Author

@Nostrademous Nostrademous Jan 17, 2019

Choose a reason for hiding this comment

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

Very HACKY!!!!

Come up with a better method, perhaps method above...

the [0][0][0] is necessary to get through the tensor dimensions

policy.py Outdated
@@ -122,6 +144,7 @@ def forward(self, env, allied_heroes, enemy_heroes, allied_nonheroes, enemy_nonh
y=F.softmax(action_scores_y, dim=2),
# delay=F.softmax(action_delay_enum, dim=2),
target_unit=F.softmax(action_unit_attention, dim=2),
ability_levelup=ability_leveling,
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

ability_leveling is a 1x15 IntTensor

Not sure what to pass over it to smartly try various leveling skills

@TimZaman TimZaman force-pushed the master branch 6 times, most recently from 3ea0098 to 3e24314 Compare January 18, 2019 08:59
@Nostrademous
Copy link
Collaborator Author

@TimZaman what do you want to do with this PR? I was going to start implementing ability affines but also think we need to greatly improve the basic_unit info provided.

I really would like to move over to the dotaworld use since it creates the necessary classes to enable tracking the data we need.

Thoughts?

@Nostrademous
Copy link
Collaborator Author

rebased and force-pushed this PR after your latest commits

@Nostrademous
Copy link
Collaborator Author

Okay, you made a lot of changes and you don't seem to want this monolithic PR. Let me remove it and make new PRs for various pieces with your latest code in ideally individual branches so as not to mix various idaes.

@TimZaman
Copy link
Owner

TimZaman commented Jan 21, 2019 via email

@Nostrademous
Copy link
Collaborator Author

I agree, but I think we are shooting ourselves in the foot a bit by not including certain things to help the agent learn.

For example - attack_target_handle & ability_target_handle for basic_unit affine. Without those it is hard for the agent to learn why it is taking damage... sure, based on HP it can figure out that it is taking damage, but not why.

@TimZaman
Copy link
Owner

TimZaman commented Jan 21, 2019 via email

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.

2 participants