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

Missing iteration over number of profiles in algorithm description #32

Closed
Bachibouzouk opened this issue May 20, 2022 · 3 comments · Fixed by #33
Closed

Missing iteration over number of profiles in algorithm description #32

Bachibouzouk opened this issue May 20, 2022 · 3 comments · Fixed by #33

Comments

@Bachibouzouk
Copy link
Collaborator

Here is the algorithm reproduced here form https://doi.org/10.1016/j.energy.2019.04.097 for convenience

    1. identify the expected peak time frame;

    2. for each User type , for each user of User, and for each Appliance of User check if the Appliance instance is used
    based on the weekly frequency of use. If not, ignore the appliance; otherwise,
    compute:
            a. the randomised total time of use ;
            b. the randomised vector of time frames in which the appliance can be on ;
        Subsequently:

            c. compute a random switch-on time (with random switch-on even duration >= t_{min, jik}) within the available use frames;
            d. compute the randomised power required by the appliance for the switch-on event under consideration P_{jik}.
            e. compute the actual power absorbed by the Appliance instance during the switch-on event considering a random numerosity in the range [0, m_{jik}]

        Repeat steps 2.c - 2.e until the sum of the durations of all the switch-on events equals the randomised total time of use.



    3. Aggregate all profiles in a total load profile.

Should we then repeat 1. -3. for each profile of range(num_profile) ?
If yes then step 1 is only done once once before iterating over range(num_profile)

Otherwise step 2. should mention a loop over the number of profiles as well

@Bachibouzouk
Copy link
Collaborator Author

I noticed it while refactoring the code to eliminate copy pasting and making it more readable to newcomer in rl-institut#1

@FLomb FLomb changed the title Algorithm described in seminal article does not reflect exactly the code executed Missing iteration over number of profiles in algorithm description May 23, 2022
@FLomb
Copy link
Contributor

FLomb commented May 23, 2022

Hi, thanks for bringing this up. Yes, step 1 is only done once and is not iterated over each (daily) profile. I think this is a bit implicit in the paper and comes across more clearly only in the paragraph following the procedure description. In such a paragraph, we discuss more specifically the way to calculate the peak time frame, from which it is clear that no parameter would change across subsequent daily profiles (and so that there's no point repeating it).

More generally, the description of the procedure in the paper that you have copy-pasted here was not meant to be a super-precise algorithmic description of the workflow, but rather a qualitative description to give a general understanding. The code (which was/is open and linked to the publication) remains the reference for any details about the algorithm. Actually, the code has changed quite a lot since the original paper, so we should definitely add such details in the README here if we deem them important. Code changes, papers don't!

Would you like to add an "Algorithm" section to the documentation with a PR? That would be very helpful.

@Bachibouzouk
Copy link
Collaborator Author

Yes I could do this :)

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

Successfully merging a pull request may close this issue.

2 participants