Magic Lantern Forum

Developing Magic Lantern => General Development => Topic started by: a1ex on January 31, 2017, 09:51:00 PM

Title: Experiment - Dynamic My Menu
Post by: a1ex on January 31, 2017, 09:51:00 PM
Today I was a bit tired of debugging low-level stuff like Lua tasks or camera-specific quirks, but still wanted to write something cool. So here's something I wanted for a long time (https://www.magiclantern.fm/forum/index.php?topic=7889.msg70266#msg70266). The feedback back then wasn't exactly positive, so it never got implemented, but I was still kinda missing it.

Turns out, it wasn't very hard to implement, so there you have it.

What is it?

You already know the Modified menu (where it shows all settings changed from the default value), and My Menu (where you can select your favorite items manually). This experiment attempts to build some sort of "My Menu" dynamically, based on usage counters.

How it works?

After a short while of navigating ML menu as you usually do, your most recently used items and also your frequently used items should appear there. As long as you don't have any items defined for My Menu, it will be built dynamically. The new menu will be named "Recent" and will keep the same icon as My Menu.

(http://a1ex.magiclantern.fm/bleeding-edge/menus/recent-menu.png)

Every time you click on some menu item, the usage counter for that item is incremented. All the other items will have a "forgetting factor" applied, so the most recently used items will raise to the top of the list fairly quickly.

Clicking the same item over and over will only be counted once (so scrolling through a long list of values won't give extra priority to menu items). Submenu navigation doesn't count; only changing a value or running an action are counted.

Time is discrete (clicks-based). It doesn't care if you use the camera 10 hours a day or a couple of minutes every now and then.

To have both good responsiveness to recent changes, but also learn your habits over a longer time, I've tried two usage counters: one for short term and another for long term memory. If, let's say during some day, you need to keep toggling a small set of options, it should learn that quickly. But, if no longer need those options after that special day, those menu items will be forgotten quickly, and the ones you use daily (stored in the "long term memory") should be back soon.

So, the only difference between the "long term" and the "short term" counters is the forgetting factor: 0.999 vs 0.9. In other words, the "long term" counters have more inertia.

When deciding whether a menu item is displayed or not, the max value between the two is used, resulting a list of "top 11 most recently or frequently used menus". The small gray bars from the menu are the usage counters (debug info).

I have no idea how well this works in practice - it's something I came up with a few hours ago, and the tuning parameters are pretty much arbitrary.

Source code committed, and if there is interest, I can prepare an experimental build as well.
Title: Re: Experiment - Dynamic My Menu
Post by: DeafEyeJedi on January 31, 2017, 10:08:52 PM
Quote from: a1ex on January 31, 2017, 09:51:00 PM
Source code committed, and if there is interest, I can prepare an experimental build as well.

Awesome stuff a1ex and I'm definitely interested in this one yet another useful feature!
Title: Re: Experiment - Dynamic My Menu
Post by: Markus on January 31, 2017, 10:26:46 PM
Cool :-).
Title: Re: Experiment - Dynamic My Menu
Post by: Licaon_Kter on January 31, 2017, 11:12:56 PM
I see this as useful :)
Title: Re: Experiment - Dynamic My Menu
Post by: RenatoPhoto on February 01, 2017, 02:08:38 AM
Yes looks interesting.  I use My menu in Canon menu for quick access to the most important functions.
What happens when you switch from one config file to the next?  I use multiple config files for specific recording options.. will this menu be built across all of the config files or will it only be specific to each config file.
Title: Re: Experiment - Dynamic My Menu
Post by: a1ex on February 01, 2017, 08:55:24 AM
Currently, the config file presets are used for all settings, including menu customization.
Title: Re: Experiment - Dynamic My Menu
Post by: Tom_LS on February 01, 2017, 09:34:22 AM
Hi, ML is amazing, thanks.
Is there any solution to use ML menu like canon user presets? For example:
preset 1 "RAW" turn on RAW Video, MLV Sound, Crop Mode, etc.
preset 2 "h.264" turn off RAW Video, MLV Sound, Crop Mode, etc.
Title: Re: Experiment - Dynamic My Menu
Post by: Walter Schulz on February 01, 2017, 11:52:54 AM
http://www.magiclantern.fm/forum/index.php?topic=8499.0
Title: Re: Experiment - Dynamic My Menu
Post by: Tom_LS on February 01, 2017, 12:11:05 PM
thnx
Title: Re: Experiment - Dynamic My Menu
Post by: cybermarmotte on February 01, 2017, 03:04:11 PM
+1
Title: Re: Experiment - Dynamic My Menu
Post by: DeafEyeJedi on February 01, 2017, 06:55:37 PM
Just for shits and giggles... This is how I go out and about for my basic daily needs within the Modified settings.

https://vimeo.com/202070321

Now let's just imagine how much more fluid this would be with @a1ex's latest Dynamic My Menu coming out of the magic hat?

:D
Title: Re: Experiment - Dynamic My Menu
Post by: NoCp_Albert on February 01, 2017, 07:09:21 PM
Very interesting, at the moment I use the Canon Presets c2, c3 for 1920x1080x25fps and 1280x720x50fps as Basics for either ML FPS-override 25fps ore ML FPS-Override 50fps. 25Fps as preset for FHD and 3xcrop mode recording and 50fps for 5x centered Crop, 10bit.
It will be a dream to get a "ML Menu" Version where the user can select 2-3 config files as presets for a quick Change for different recording situations.
If I like to make a quick change in front of a rear Animal or Bird in Nature and I touch the wrong Button the session is over, restart and maybe Battery, skipping Module loading, stop again and start new is the normally way to restart the System. To avoid this will be a very great step and help.
Title: Re: Experiment - Dynamic My Menu
Post by: Walter Schulz on February 01, 2017, 07:54:19 PM
Quote from: NoCp_Albert on February 01, 2017, 07:09:21 PM
It will be a dream to get a "ML Menu" Version where the user can select 2-3 config files as presets for a quick Change for different recording situations.

2-3? How about 13?
http://www.magiclantern.fm/forum/index.php?topic=8499.0
For German speakers:
http://www.magiclantern.fm/forum/index.php?topic=15045.msg147465#msg147465
Title: Re: Experiment - Dynamic My Menu
Post by: goldenchild9to5 on February 02, 2017, 07:45:09 AM
Awesome  :D
Title: Re: Experiment - Dynamic My Menu
Post by: garry23 on February 02, 2017, 08:25:09 AM
Like others, I'm looking forward to using this.

Such a feature was why I played around with the 'Toggler' idea, especially on the EOSM.

https://gist.github.com/pigeonhill/156ea0e55cd0a029bc447f8bf5593224

The Toggler lets me cycle through different ML 'use states', without going into the ML menu.
Title: Re: Experiment - Dynamic My Menu
Post by: a1ex on February 02, 2017, 05:59:39 PM
Experimental build posted.

The Junkie menu is now auto-generated as well. Please post screenshots.
Title: Re: Experiment - Dynamic My Menu
Post by: DeafEyeJedi on February 02, 2017, 08:03:33 PM
https://vimeo.com/202255426
Title: Re: Experiment - Dynamic My Menu
Post by: RenatoPhoto on February 02, 2017, 09:04:24 PM
Looks pretty cool.
Title: Re: Experiment - Dynamic My Menu
Post by: budafilms on February 04, 2017, 09:04:44 AM
Great work! And very esthetic!
Title: Re: Experiment - Dynamic My Menu
Post by: a1ex on February 05, 2017, 02:04:33 AM
Pull request open: http://bitbucket.org/hudson/magic-lantern/pull-requests/812/dynamic-my-menu-and-junkie-menu-based-on/commits
Title: Re: Experiment - Dynamic My Menu
Post by: a1ex on April 22, 2017, 09:04:34 PM
Recently I had to change often a setting that was normally hidden under Advanced, in a submenu (that was mlv_lite -> raw video -> preview). This required a bit too many clicks for my taste. Of course, it's easy to move this particular setting back to main menu, but I was thinking at something more generic.

Since we already have usage counters, a submenu with more than say 8 items could auto-hide the less frequently used ones, overriding my default choice of simple/advanced options.

Is this something worth looking into?
Title: Re: Experiment - Dynamic My Menu
Post by: DeafEyeJedi on April 22, 2017, 10:30:41 PM
Quote from: a1ex on April 22, 2017, 09:04:34 PM
...Since we already have usage counters, a submenu with more than say 8 items could auto-hide the less frequently used ones, overriding my default choice of simple/advanced options.

Is this something worth looking into?

Sure. It would be nice.
Title: Re: Experiment - Dynamic My Menu
Post by: Licaon_Kter on June 29, 2017, 06:30:48 PM
This works nicely indeed.

One glitch that I saw, I enabled DualISO, set recovery ISO, set normal ISO, whatever shoot, later went to MyMenu to toggle it off but I could only see the sub-menu (where you set normal ISO and recovery ISO), so I had to go back to the main menu, turn it off from there and then coming back I had DualISO is MyMenu too.
Title: Re: Experiment - Dynamic My Menu
Post by: a1ex on November 06, 2017, 08:33:59 AM
Update - this has been available for a while in some experimental builds (lua_fix, crop_rec_4k, 1200D). If you have used any of these builds for a longer time, please post:

- a screenshot of your (automatically created) My Menu (Recent ★)
- a screenshot of your Junkie menu (press the MENU key while in ML menu)
- your comments on whether the contents of this menu match your most used options, or anything was missed
- whether or not you have actually noticed / used / found this menu useful
- your ML/SETTINGS directory from the card, to allow me to reproduce your screenshot in QEMU

Note: if you clear ML settings, this feature will forget everything it has "learned" about your ML menu browsing habits :)

Thanks.
Title: Re: Experiment - Dynamic My Menu
Post by: axelcine on November 07, 2017, 10:38:18 PM
Dynamic My Menu is an extremely good idea. Is it possible to have the Dynamic My Menu pop up as an automatic menu choice when we activate ML? (Like Canon in Creative modes)? Anyway the Dynamic My Menu is a godsend. Thanx A1ex.
Title: Re: Experiment - Dynamic My Menu
Post by: a1ex on November 07, 2017, 10:48:40 PM
If you leave the menu while on the Recent ★ tab, it should re-open there at the next startup.

Even more - if you press MENU while in ML menu to enter Junkie mode, that menu is auto-generated, based on the most recently used entries; in this state, ML menu will be auto-generated by default. With this request (http://www.magiclantern.fm/forum/index.php?topic=18884.msg192812#msg192812), I'm trying to find out how well it works in practice.
Title: Re: Experiment - Dynamic My Menu
Post by: a1ex on December 15, 2017, 06:58:05 PM
Got the first screenshot from a user on irc:
(https://i.imgur.com/dRsLQgk.png)

(that magenta color shouldn't be there; probably a screenshot bug, though I remember fixing that; will double-check)


The following is still valid, btw:

Quote from: a1ex on November 06, 2017, 08:33:59 AM
Update - this has been available for a while in some experimental builds (lua_fix, crop_rec_4k, 1200D). If you have used any of these builds for a longer time, please post:

- a screenshot of your (automatically created) My Menu (Recent ★)
- a screenshot of your Junkie menu (press the MENU key while in ML menu)
- your comments on whether the contents of this menu match your most used options, or anything was missed
- whether or not you have actually noticed / used / found this menu useful
- your ML/SETTINGS directory from the card, to allow me to reproduce your screenshot in QEMU

Note: if you clear ML settings, this feature will forget everything it has "learned" about your ML menu browsing habits :)

Thanks.