Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Unity Analytics Heatmaps: Official Thread

Discussion in 'Unity Analytics' started by marc_tanenbaum, Sep 30, 2015.

Thread Status:
Not open for further replies.
  1. marc_tanenbaum

    marc_tanenbaum

    Unity Technologies

    Joined:
    Oct 22, 2014
    Posts:
    637
    Nope, looks like you're good! (Though I really need to look at that bug and fix it!)
     
  2. imansueto

    imansueto

    Joined:
    Jul 10, 2014
    Posts:
    6
    Hello @marc_tanenbaum,

    Are heatmap events the only ones to show up in the raw data export api? I thought it would include custom events as well but so far I'm not seeing anything.
     
  3. marc_tanenbaum

    marc_tanenbaum

    Unity Technologies

    Joined:
    Oct 22, 2014
    Posts:
    637
    Heatmap events are custom events...at a technical level, there's no distinction. So the answer is "no", there's nothing special about Heatmap events; all Custom Events get exported in a single batch.
     
    imansueto likes this.
  4. Erawn

    Erawn

    Joined:
    Dec 31, 2015
    Posts:
    1
    Hi,

    I've been trying for a couple days to get heatmaps working, but I think there is something wrong with my data export. In the validator I can see my custom events coming through, and see them as well on the metric viewer, but when I paste the data export link in my browser I can only see "appStart" events being logged. What can I do about this?


    Thanks!
     
  5. marc_tanenbaum

    marc_tanenbaum

    Unity Technologies

    Joined:
    Oct 22, 2014
    Posts:
    637
    @Erawn please PM me with your project ID, and I'll investigate.
     
  6. mkg2w

    mkg2w

    Joined:
    Aug 19, 2013
    Posts:
    54
    Is it recommended to use this in Production? Is there any update to the project, to optimize data that is submitted to Unity's severs?
     
  7. marc_tanenbaum

    marc_tanenbaum

    Unity Technologies

    Joined:
    Oct 22, 2014
    Posts:
    637
    Heatmaps is not currently intended for production use. That said, we are working on several features that will make it likely that you will be able to use them in production.

    As far as data optimization, could you be more specific?
     
  8. wg_havi

    wg_havi

    Joined:
    Dec 2, 2015
    Posts:
    2
    @marc_tanenbaum Hi Marc, I started trying out the Heatmaps feature with a test project earlier this week. It looks like my heatmap events are flowing in just fine, and I checked the batches that the Heatmapper is downloading and see my events and data in the files. However, when it goes to render I get spammed with thousands of ArgumentOutOfRangeExceptions at line 186 in HeatmapMeshRenderer. It looks like every time it runs, m_GameObjects is empty when it gets to that point. Any thoughts?
     
  9. marc_tanenbaum

    marc_tanenbaum

    Unity Technologies

    Joined:
    Oct 22, 2014
    Posts:
    637
  10. wg_havi

    wg_havi

    Joined:
    Dec 2, 2015
    Posts:
    2
    Thanks, that does indeed work.
     
  11. mkg2w

    mkg2w

    Joined:
    Aug 19, 2013
    Posts:
    54
    Can we now submit Heatmaps collection from Distribution builds ?
     
    Last edited: Feb 3, 2016
  12. Mangatome

    Mangatome

    Joined:
    Mar 5, 2014
    Posts:
    13
    Hi. Is the Data Export API only able to retrieve heatmap events, or can it also be used to retrieve non-Heatmap raw custom events that were sent prior to data export being enabled in the analytics project?

    I'm trying to determine if and how I can harness the data export to perform more in-depth analysis on other data I have in my project.
     
  13. erika_d

    erika_d

    Joined:
    Jan 20, 2016
    Posts:
    413
    Hi @mkg2w and @Mangatome,

    @mkg2w,
    No, we are still requesting that you do not put heatmap events in distribution builds. As mentioned by @marc_tanenbaum, if you have a case where you think you absolutely need them in your distribution build, please talk to us and we'll see what we can do, but otherwise lets still try to keep them in pre-release builds.

    @Mangatome,
    Yes, the Raw Data Export API will retrieve non-heatmap events in addition to the heatmap ones. However it only captures the data going forward from when data export is enabled, it will not retrieve data sent prior to that time.
     
  14. mkg2w

    mkg2w

    Joined:
    Aug 19, 2013
    Posts:
    54
    We have a large 120-level game (and growing), targeted at Casual gamers, involving driving cars around cities. There are AI cars, 12 different types of vehicles and a city with different weather patterns. Having the ability to record at what location and any other associated meta-data a player crashes in a game, would be very useful. The alternative would be to map the coordinates with a bunch of meta-data, and send these figures to Flurry.

    if we could only track the crash locations per user, along with necessary meta-data such as vehicle collided into, level type,etc it helps us build better games for our consumers. Sticking to Unity tools also keeps the process of testing and analysis simpler.

     
  15. Mangatome

    Mangatome

    Joined:
    Mar 5, 2014
    Posts:
    13
    Hi @erika_d, thank you for your answer. I saw indeed batches with custom data just now, so I think this is working. Great!

    Didn't UA store raw event data somewhere prior to heatmaps being activated? Is there anyway I might get a dump of this data, even if for a short time window? I'm trying to chart custom events according to several of their parameters, and there seems to be no way of doing this from vanilla UA at the moment.
     
  16. erika_d

    erika_d

    Joined:
    Jan 20, 2016
    Posts:
    413
    Hi @mkg2w,

    Can you fill out a support ticket so that we can discuss the specifics of your situation in more detail? Thanks!

    Hi @Mangatome,

    I'm sorry, but unfortunately because of the way our system currently aggregates the data, we're not able to do any retroactive data export.
     
  17. vividhelix

    vividhelix

    Joined:
    Mar 20, 2013
    Posts:
    78
    I'm afraid I already know the answer to these but here goes anyway:

    1. Are heatmaps still limited to development builds? I'm showcasing my game at a conference and would love to use heatmaps but I don't want the "Development build" sticker...

    2. Heatmaps being custom events, that means the 100 events per hour is still applied? That's very limiting for a heatmap - it does work maybe for an FPS, but for a top down 2D game the player can reach different areas of the level every few seconds so it would need way more data points.
     
  18. marc_tanenbaum

    marc_tanenbaum

    Unity Technologies

    Joined:
    Oct 22, 2014
    Posts:
    637
    If that's all that's stopping you, then create a development build to show it off. We're not actually watching the "development build" flag. Rather, we're looking at the number of events we receive. So long as the numbers are modest, we're not going to worry too much. The core concern here (just to be clear) is that if a 100M DAU game was sending us a metric tonne of heatmap data, it could impact the overall health of the system, which would be bad.

    Actually, no! Heatmaps comes complete with extra headroom for sending more events. So once you've signed up, you'll be able to send an awful lot of heatmap events to make the service useful.

    Sign up here: https://unity3d.com/services/analytics/
     
    lourd likes this.
  19. vividhelix

    vividhelix

    Joined:
    Mar 20, 2013
    Posts:
    78
    Sweet, thanks Marc!

    I'll get on it right away...Hoping I can make it for Monday :)
     
  20. marc_tanenbaum

    marc_tanenbaum

    Unity Technologies

    Joined:
    Oct 22, 2014
    Posts:
    637
    @vividhelix Is this for GDC? If you'll be here stop by the Unity booth and introduce yourself!
     
  21. vividhelix

    vividhelix

    Joined:
    Mar 20, 2013
    Posts:
    78
    Yes, I'll be in the megabooth, I'll drop by and say hi.

    One last question, how's support for offline mode? I don't think my demo machine will be connected, but I remember reading that it will send the events next time it's run when it gets a connection. Does that apply for regular Windows builds as well? Where is this data stored between sessions?
     
  22. marc_tanenbaum

    marc_tanenbaum

    Unity Technologies

    Joined:
    Oct 22, 2014
    Posts:
    637
    Awesome!

    Events are stored in a local cache when offline (in Library/Application Support on a Mac...I'm afraid I don't recall the analogous location on PC), so you should just be able to do exactly that.

    BTW, we're doing a presentation on heatmaps at the Unity booth, which will include an intro, plus some hints at stuff we're working on for the future. Thursday, 4pm and again Friday 1pm!
     
  23. coshea

    coshea

    Joined:
    Dec 20, 2012
    Posts:
    319
    When do you think heatmaps will be allowed into public release products?

    Thanks
     
  24. mpinol

    mpinol

    Joined:
    Jul 29, 2015
    Posts:
    317
    Hey @coshea,

    I cannot really give you any sort of timeline of when this might possibly happen but it is something we have been talking about and are interested in allowing.
     
  25. chrisscott

    chrisscott

    Joined:
    Feb 24, 2014
    Posts:
    6
    I signed up for Heatmap access on Friday but have yet to receive confirmation, does it normally take a while? We have some focus group testing on Monday and I would love to have heat maps to play with after.
     
  26. erika_d

    erika_d

    Joined:
    Jan 20, 2016
    Posts:
    413
    Hi @chrisscott,

    I'm so sorry for this issue! Can you DM me your app-id and I will get it activated right away!

    *Edit* I appear to be having some issues starting a direct message with you so if you have the same issue you can also fill out a support ticket here: https://analytics.cloud.unity3d.com/support And I'll get the email and get it set up that way :) *Edit*

    Thanks for your patience!
     
    Last edited: Apr 13, 2016
    chrisscott likes this.
  27. amandine13

    amandine13

    Joined:
    Apr 4, 2016
    Posts:
    27
    Hello, thanks for this heatmaps plug-in it's very helpful.
    But I have a question, is it possible to draw heatmap with data records from an eye tracker. I've tried the following script :
    Code (CSharp):
    1. using UnityAnalyticsHeatmap;
    2. using UnityEngine;
    3. using TETCSharpClient;
    4. using Newtonsoft;
    5. using TETCSharpClient.Data;
    6.  
    7. public class test : MonoBehaviour {
    8.  
    9.     public void OnGazeUpdate (GazeData gazeData)
    10.     {
    11.         UnityAnalyticsHeatmap.HeatmapEvent.Send (gazeData.SmoothedCoordinates.X, gazeData.SmoothedCoordinates.Y);
    12.     }
    13. }
    But I've got this following error message : the overloaded method has invalid arguments.

    Guess I have a problem with the fact that I've put it in OnGazeUpdate() , but I'm a begginer at Unity so I've got some issues to understand everything.

    Many thanks for helping
     
  28. erika_d

    erika_d

    Joined:
    Jan 20, 2016
    Posts:
    413
    Hi @amandine13,

    I believe you need to adjust the formatting of your heatmap event a bit: the first parameter you send should be a string, some sort of name for the event (like "GazeData", perhaps) and the second should be a vector for your positional data.

    It would look something like:
    Code (CSharp):
    1. UnityAnalyticsHeatmap.HeatmapEvent.Send("GazeData", new Vector2(gazeData.SmoothedCoordinates.X, gazeData.SmoothedCoordinates.Y));
    Check out this page for more info on the options for sending Heatmap events: https://bitbucket.org/Unity-Technologies/heatmaps/wiki/Step 1: Sending Heatmap Events
     
    amandine13 likes this.
  29. amandine13

    amandine13

    Joined:
    Apr 4, 2016
    Posts:
    27
    Thanks for reply it helps me but I've still have some issues indeed, I've got the following script :
    Code (CSharp):
    1. using UnityEngine;
    2. using System.Collections;
    3. using UnityAnalyticsHeatmap;
    4. using Newtonsoft.Json;
    5. using TETCSharpClient;
    6. using TETCSharpClient.Data;
    7.  
    8. public class essai : MonoBehaviour {
    9.  
    10.     void debut(GazeData gazeData)
    11.     {
    12.         float x = (float)(gazeData.SmoothedCoordinates.X);
    13.         float y = (float)(gazeData.SmoothedCoordinates.Y);
    14.         UnityAnalyticsHeatmap.HeatmapEvent.Send("GazeData", new Vector2 (x,y));
    15.     }
    16. }
    As my data were double I convert in float in order to make it works because double seems not supported by heatmap.
    So I've tested my script and have the following error when I've tried to draw the heatmap :
    NullReferenceException: Object reference not set to an instance of an object HeatmapMeshRenderer..RenderHeatmap() (at Assets/Plugins/Heatmaps/Renderer/HeatmapMeshRendere.cs : 171)

    That's the following lines of the script :

    for (int a = 0; a < m_Data.Length; a++)
    I guess that the problem is that nothing is recording, more i've got the following warning message :The aggregation process yielded no results. UnityEngine.Debut:Logwarning(Object) which confirm the fact that nothing is record to draw the heatmap..
    I was wondering why I've got this issue maybe it came from my conversion in float but I'm not sure. I really need it to works because I have to draw heatmap from my game and this way seems to be the better one.

    Thanks so much for helping
     
  30. erika_d

    erika_d

    Joined:
    Jan 20, 2016
    Posts:
    413
    Hi @amandine13,

    It sounds like you are trying to display your heatmaps during gameplay, is that correct? If so, currently that is not yet functionality our heatmaps plugin offers. Additionally, heatmaps is not yet intended for use in production, which I believe would be necessary for displaying heatmaps during gameplay.

    If that's not what you're trying to do, can you explain more what the purpose of the for loop you posted is?
     
    amandine13 likes this.
  31. amandine13

    amandine13

    Joined:
    Apr 4, 2016
    Posts:
    27
    Thanks, no I don't need to display the heatmap during gameplay it can be done after the session.
    The loop isn't mine, it is in a script of the plug-in for the heatmap. It's in HeatmapMeshRenderer.cs, so I guess this loop check if there's something recording or not.

    So I think that nothing is recording and that's why I've got this error but I don't understand why nothing is record.

    Thanks for this precious help
     
  32. erika_d

    erika_d

    Joined:
    Jan 20, 2016
    Posts:
    413
    Hi @amandine13,

    My misunderstanding! Sorry about that!

    Hmmmm....Ok a few thoughts for you to check out/double check, and if these don't work I suggest filling out a support ticket so I can look into it more detail for you.

    1. I guess first of all would be making sure we have heatmaps turned on for you...When you go to your project settings page, at the bottom right above the save button do you see a Raw Data Enabled checkbox and an Export API? And is the checkbox checked?

    2. In the heatmapper plugin in the Unity Editor, have you entered the Export API into the Data Export URL and clicked Fetch and Process with Local Only UNchecked?

    3. Have you followed all the steps in the Heatmaps Set Up Wiki, specifically this page: https://bitbucket.org/Unity-Technologies/heatmaps/wiki/Step 2: Retrieving & Aggregating data

    If you've done all of those and everything seems right you can fill out a support ticket here (https://analytics.cloud.unity3d.com/support) and I'll look into some more for you!
     
  33. _Adriaan

    _Adriaan

    Joined:
    Nov 12, 2009
    Posts:
    481
    Hello there!

    I'm not sure if this is the right place to ask questions like this but... let me know where else I should post them!

    1. My heatmaps custom events don't show up in the Unity Analytics custom event inspector. Not sure if thats expected behaviour...

    2. The latest version (on bitbucket) doesn't render in-editor (v5.3.5f1) for me, even though when I dive in the raw data, I am able to find the datapoints. I get the following error on Editor update:
    It does turn out I have been sending the wrong data (input position instead of world position... DOH), but that shouldn't cause this bug, right? Anything I can do to fix this?

    3. Does the aggregated data filter per scene? Couldn't find this anywhere.
     
    Last edited: Jun 5, 2016
  34. marc_tanenbaum

    marc_tanenbaum

    Unity Technologies

    Joined:
    Oct 22, 2014
    Posts:
    637
    Under the hood, heatmap events are no different from other custom events. I'm not quite sure what you mean by the "custom event inspector", but you should see them in the Custom Event Validator during testing, and (after a processing cycle) in the Event Manager.

    This is a known bug that I _think_ is solved in the new version that's about to be released (still undergoing QA). The workaround is to fiddle the 'time' controls. Once you've done this once, the problem seems to go away.

    Not in the released version. The new version allows you to send additional parameters (e.g., 'level') with which you can separate data into lists.
     
    _Adriaan likes this.
  35. _Adriaan

    _Adriaan

    Joined:
    Nov 12, 2009
    Posts:
    481
    I'm really glad this is coming up! This is pretty much an essential feature if you'd ask me! <3
     
  36. _Adriaan

    _Adriaan

    Joined:
    Nov 12, 2009
    Posts:
    481
    Hey @marc_tanenbaum,

    In my 2D game, I'd love to make sure that the heatmap particles are in front of my sprites so that they overlay the scene rather than being in between the render order pool of everything. Is there a way to always overlay the heatmap data?

    Thanks again!
     
  37. MauricioV

    MauricioV

    Joined:
    Jun 7, 2016
    Posts:
    1
    Sorry, I missed this yesterday. Not as such, but there's a super-convenient workaround: simply type the word 'heatmap' into the hierarchy.
     
  38. marc_tanenbaum

    marc_tanenbaum

    Unity Technologies

    Joined:
    Oct 22, 2014
    Posts:
    637
    Sorry...that was me above... :) Just working out of a different account and forgot to change back.
     
    mpinol likes this.
  39. knotFF

    knotFF

    Joined:
    Apr 13, 2013
    Posts:
    66
    I just installed the Heatmap today and I am getting these errors when I tried to open the raw data under Windows>>UnityAnalytics>>RawData (The Heatmapper Windows opens fine):
    Unity 5.4.B21, OSX latest, heatmaps-beta2-rc1

    Code (CSharp):
    1. LoadAssetAtPath is not allowed to be called from a ScriptableObject constructor (or instance field initializer), call it in OnEnable instead. Called from ScriptableObject 'RawDataInspector'.
    2. See "Script Serialization" page in the Unity Manual for further details.
    3. UnityEditor.EditorGUIUtility:Load(String)
    4. RawDataInspector:.ctor()
    5. UnityEditor.EditorWindow:GetWindow(Type)
    6. RawDataInspector:RawDataInspectorMenuOption() (at Assets/Editor/Heatmaps/Views/RawDataInspector.cs:120)
    Code (CSharp):
    1. UnityException: LoadAssetAtPath is not allowed to be called from a ScriptableObject constructor (or instance field initializer), call it in OnEnable instead. Called from ScriptableObject 'RawDataInspector'.
    2. See "Script Serialization" page in the Unity Manual for further details.
    3. UnityEditor.EditorGUIUtility.Load (System.String filename, System.Type type) (at /Users/builduser/buildslave/unity/build/artifacts/generated/common/editor/EditorGUIUtilityBindings.gen.cs:470)
    4. UnityEditor.EditorGUIUtility.Load (System.String path) (at /Users/builduser/buildslave/unity/build/artifacts/generated/common/editor/EditorGUIUtilityBindings.gen.cs:464)
    5. RawDataInspector..ctor ()
    6. UnityEditor.EditorWindow:GetWindow(Type)
    7. RawDataInspector:RawDataInspectorMenuOption() (at Assets/Editor/Heatmaps/Views/RawDataInspector.cs:120)
    Code (CSharp):
    1. NullReferenceException: Object reference not set to an instance of an object
    2. RawDataInspector.OnGUIFetchView () (at Assets/Editor/Heatmaps/Views/RawDataInspector.cs:333)
    3. RawDataInspector.OnGUI () (at Assets/Editor/Heatmaps/Views/RawDataInspector.cs:287)
    4. System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)
     
    Last edited: Jun 17, 2016
  40. marc_tanenbaum

    marc_tanenbaum

    Unity Technologies

    Joined:
    Oct 22, 2014
    Posts:
    637
    @FF1878 Thanks for the report! I wasn't seeing that in 5.3.5...but I also see it in 5.4.0bx builds. Will investigate.
     
  41. marc_tanenbaum

    marc_tanenbaum

    Unity Technologies

    Joined:
    Oct 22, 2014
    Posts:
    637
    @FF1878, pushed a fix, still considering this RC1, so same place, same branch. Let me know if this works for you.
     
  42. knotFF

    knotFF

    Joined:
    Apr 13, 2013
    Posts:
    66
    I updated the package. No errors this time around, but the Raw Data Window did not show up.

    EDIT: I restarted Unity, same problem. So I reset the Layout to Default and it worked!
    If I go back to my layout if gives me this:
    Code (CSharp):
    1. Failed to destroy views: #1
    2. EyeDropper
    3. UnityEditor.WindowLayout:LoadWindowLayout(String, Boolean)
    Restarted Unity and all good.
    Thanks.
     
    Last edited: Jun 17, 2016
  43. marc_tanenbaum

    marc_tanenbaum

    Unity Technologies

    Joined:
    Oct 22, 2014
    Posts:
    637
    Hmmm...works for me. Could you try in a blank project, just to eliminate any other issues?
     
  44. knotFF

    knotFF

    Joined:
    Apr 13, 2013
    Posts:
    66
    Blank Project = 100% fine.
     
  45. marc_tanenbaum

    marc_tanenbaum

    Unity Technologies

    Joined:
    Oct 22, 2014
    Posts:
    637
    Awesome...so this suggests that perhaps something didn't update correctly. Maybe try deleting the two folders in your project?

    Editor > Heatmaps
    Plugins > Heatmaps

    Then reinstall.
     
  46. knotFF

    knotFF

    Joined:
    Apr 13, 2013
    Posts:
    66
    It seems to be working. Got no errors. Thanks. :)
     
  47. marc_tanenbaum

    marc_tanenbaum

    Unity Technologies

    Joined:
    Oct 22, 2014
    Posts:
    637
    Woo hoo! Please send me feedback once you've had a chance to test out the new features.
     
  48. _Adriaan

    _Adriaan

    Joined:
    Nov 12, 2009
    Posts:
    481
    Hey @marc_tanenbaum, is that 'filter per scene' feature included in the heatmaps-beta2-rc1 branch? If not, have any indication on when that will make it in (and in which branch ;)? I'm trying to plan a large-scale playtest with external testers, and as this would add so much useful data to the playtest, I'm sort of waiting for that to be in ;)
     
  49. marc_tanenbaum

    marc_tanenbaum

    Unity Technologies

    Joined:
    Oct 22, 2014
    Posts:
    637
    There's no 'filter per scene' per se, but if you send a parameter like 'level' -- or scene name if you prefer -- then that will be filterable. That's on the heatmaps-beta2-rc1 branch...but note that we're in our final QA pass right now, so things on that branch are a still little bit in flux.
     
    _Adriaan likes this.
  50. _Adriaan

    _Adriaan

    Joined:
    Nov 12, 2009
    Posts:
    481
    Alright! Awesome, I'll play around with it, but I'll wait with pushing out anything for the QA pass. Other question; is the idea that heatmaps will be integrated into unity, or will they remain to be a package?
     
Thread Status:
Not open for further replies.