Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-59638

Quarters time splitting method excludes activities which due date is based on the section they belong to

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.4
    • Fix Version/s: 3.4
    • Component/s: Analytics
    • Labels:
    • Testing Instructions:
      Hide
      1. Download the attached test-mdl-57791.php file and place it in moodle root
      2. Execute php test-mdl-57791.php createcourses, this will create 3 courses: a noteaching course you can ignore (it was important for MDL-57791) a course for training the machine learning algorithm and another one to get predictions. These courses start and end dates are set accordingly to what is needed:
        • students at risk of dropping out training course is already finished
        • students at risk of dropping out prediction course just passed 50% of the course duration
      3. In predictyeah and trainingyeah courses create a page activity and a resource activity in topic 2
      4. Enrol 5 new users as students into predictyeah and trainingyeah new courses, in predictyeah course log in as 2 of these users and access the page and the resource refresh page like 10 times as we need some activity logs; in trainingyeah course log in as 2 of these users and access the page and the resource, also refresh page like 10 times as we need some activity logs
      5. Execute php test-mdl-57791.php movelogsback this will update the logs timecreated attribute to some time ago so they make sense according to start and end course dates
      6. Return to the web interface (site admin > reports > analytic models)
      7. Edit "Students at risk of dropping out" model:
        • tick "Enabled"
        • select "Quarters" time splitting method
        • remove all assign, book, chat, choice, database, feedback, folder, forum, glossary, ims package, label, lesson, LTI, quiz, scorm, survey and workshop indicators (we need to do this because we are not training with much data and if we don't reduce the amount of nulls or increase the amount of samples [students in this case] we machine learning algorithm is not smart enough to predict correctly, it would probably work removing just a couple of modules' indicators, but this should be enough and we are not testing the predictor accuracy here)
        • save changes and return to admin/tool/analytics
      8. Select "Get predictions" action from "Students at risk of dropping out" model in admin/tool/models/index.php
      9. You should not see the id of trainingyeah course under "Training results" and you should see it under "Prediction results"
      10. You should see the id of predictyeah course under "Training results" and you should not see it under "Prediction results"
      11. Click "Continue" to return to admin/tool/models/index.php, you should see a dropdown menu in "Insights" column -> "Students at risk of dropping out" row. Select "predictyeah"
      12. You should see 3 student at risk and 2 not at risk.
      Show
      Download the attached test-mdl-57791.php file and place it in moodle root Execute php test-mdl-57791.php createcourses , this will create 3 courses: a noteaching course you can ignore (it was important for MDL-57791 ) a course for training the machine learning algorithm and another one to get predictions. These courses start and end dates are set accordingly to what is needed: students at risk of dropping out training course is already finished students at risk of dropping out prediction course just passed 50% of the course duration In predictyeah and trainingyeah courses create a page activity and a resource activity in topic 2 Enrol 5 new users as students into predictyeah and trainingyeah new courses, in predictyeah course log in as 2 of these users and access the page and the resource refresh page like 10 times as we need some activity logs; in trainingyeah course log in as 2 of these users and access the page and the resource, also refresh page like 10 times as we need some activity logs Execute php test-mdl-57791.php movelogsback this will update the logs timecreated attribute to some time ago so they make sense according to start and end course dates Return to the web interface (site admin > reports > analytic models) Edit "Students at risk of dropping out" model: tick "Enabled" select "Quarters" time splitting method remove all assign, book, chat, choice, database, feedback, folder, forum, glossary, ims package, label, lesson, LTI, quiz, scorm, survey and workshop indicators (we need to do this because we are not training with much data and if we don't reduce the amount of nulls or increase the amount of samples [students in this case] we machine learning algorithm is not smart enough to predict correctly, it would probably work removing just a couple of modules' indicators, but this should be enough and we are not testing the predictor accuracy here) save changes and return to admin/tool/analytics Select "Get predictions" action from "Students at risk of dropping out" model in admin/tool/models/index.php You should not see the id of trainingyeah course under "Training results" and you should see it under "Prediction results" You should see the id of predictyeah course under "Training results" and you should not see it under "Prediction results" Click "Continue" to return to admin/tool/models/index.php, you should see a dropdown menu in "Insights" column -> "Students at risk of dropping out" row. Select "predictyeah" You should see 3 student at risk and 2 not at risk.
    • Affected Branches:
      MOODLE_34_STABLE
    • Fixed Branches:
      MOODLE_34_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      MDL-59638_master

      Description

      This has been discovered during MDL-57791 testing.

      In students at risk of dropping out model we read logs from activities which due dates are part of the time range we want to predict dropouts for (e.g. half of the course). If activities do not have a due date and use topics format, we based that date the activity should be completed by in the section it belongs to.

      MDL-57791 simple setup the testing instructions use 4 sections (1 for each quarter of the course) the problem is that we deduct 1 second from the end of each quarter (aka time range in time splitting methods entity) so 1 timestamp does not belong to 2 different time ranges, but instead of that what we should do is to increase the start of the next time range by 1 second otherwise activities' due dates are not part of that quarter of the course and predictions fail to match data from the finished course with data from the ongoing course.

        Attachments

        1. screenshot-1.png
          screenshot-1.png
          11 kB
        2. screenshot-2.png
          screenshot-2.png
          79 kB
        3. test-mdl-57791.php
          3 kB

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  13/Nov/17