Bug 429157

Summary: CPU Clock Frequency: Legend naming is redundant.
Product: [Applications] plasma-systemmonitor Reporter: Richard Llom <richard.llom>
Component: generalAssignee: KSysGuard Developers <ksysguard-bugs>
Status: RESOLVED FIXED    
Severity: wishlist CC: ahiemstra, alex765, kde, nate, plasma-bugs
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Other   
OS: Linux   
See Also: https://bugs.kde.org/show_bug.cgi?id=432703
Latest Commit: Version Fixed In: 5.23
Sentry Crash Report:

Description Richard Llom 2020-11-15 15:34:46 UTC
When using a chart with cpu clock frequencies, one has "CPU Clock" in title, but each data point (thread) is also labeled with "CPU x Clock Frequency x GHz".
The "Clock Frequency" part is redundant and blows up unnecessarily the legend.

I know this probably stems from sysfs and isn't so much an actual bug in systemmonitor (hence marking as wishlist). But it would be nice if their could be some custom vodoo here.


For an example view, see attachment in bug 429156.
Comment 1 Nate Graham 2021-04-21 19:55:27 UTC
Still an issue even with the new legends.
Comment 2 David Redondo 2021-04-23 07:06:32 UTC
Hi, that's actually a hard problem in general.
We don't know what your chart setup will look like in advance.

In your chart setup like yours it will be redundant at least but that even requires that an user has setup a related title.

But imagine a different chart where I have different sensors of the same CPU (system usage, user usage, wait usage...) there actually the "CPU x" part will be redundant iff I have a title like "CPU x".
Comment 3 Nate Graham 2021-04-23 13:42:42 UTC
Perhaps for charts where all sensors are the same, the legend can automatically remove the parts of the sensor description that are the same across all of them.

For example if you would have:

Core 1 total usage
Core 2 total usage
Core 3 total usage
Core 4 total usage

It would be automatically shortened to:

Core 1
Core 2
Core 3
Core 3

The rationale would be that "total usage" is implicit and obvious when all of the sensors are showing the same thing.
Comment 4 David Redondo 2021-04-26 06:50:45 UTC
(In reply to Nate Graham from comment #3)
> Perhaps for charts where all sensors are the same, the legend can
> automatically remove the parts of the sensor description that are the same
> across all of them.
> 
> For example if you would have:
> 
> Core 1 total usage
> Core 2 total usage
> Core 3 total usage
> Core 4 total usage
> 
> It would be automatically shortened to:
> 
> Core 1
> Core 2
> Core 3
> Core 3
> 
> The rationale would be that "total usage" is implicit and obvious when all
> of the sensors are showing the same thing.

Only if we would know that the chart has a related title, otherwise if you had two such charts one for user usage and one for system usage, there's no sign which is which
Comment 5 Nate Graham 2021-04-26 11:03:33 UTC
Well, I think we can make that assumption.

All the built-in charts will have a good title. And if the user creates their own chart using all the same sensors, it's up to them to set a good title, and I think we can assume that they'll do it.
Comment 6 Bug Janitor Service 2021-07-08 10:14:42 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/libksysguard/-/merge_requests/174
Comment 7 David Redondo 2021-07-21 12:08:50 UTC
Git commit 5ce5e7e8456d4a3b456df8c0d5e6ff72d049eb00 by David Redondo.
Committed on 09/07/2021 at 12:44.
Pushed by davidre into branch 'master'.

Allow renaming of sensors

Users can now change the displayed name of sensors on a per face basis.
Saving/loading works the same as the sensor colors.
Resetting of the labels can be done by setting an empty label.
Related: bug 433950, bug 391500, bug 431552
FIXED-IN:5.23

M  +92   -31   faces/Choices.qml
M  +24   -0    faces/ConfigSensors.qml
M  +32   -0    faces/SensorFaceController.cpp
M  +10   -0    faces/SensorFaceController.h
M  +1    -0    faces/SensorFaceController_p.h
M  +1    -0    faces/facepackages/barchart/contents/ui/BarChart.qml
M  +3    -3    faces/facepackages/horizontalbars/contents/ui/FullRepresentation.qml
M  +1    -0    faces/facepackages/linechart/contents/ui/LineChart.qml
M  +1    -0    faces/facepackages/piechart/contents/ui/PieChart.qml
M  +2    -2    faces/facepackages/piechart/contents/ui/UsedTotalDisplay.qml
M  +1    -0    faces/facepackages/textonly/contents/ui/CompactRepresentation.qml
M  +1    -0    faces/facepackages/textonly/contents/ui/FullRepresentation.qml
M  +3    -2    faces/facepackages/textonly/contents/ui/GroupedText.qml
M  +2    -2    faces/import/ExtendedLegend.qml
M  +24   -2    sensors/SensorDataModel.cpp
M  +10   -0    sensors/SensorDataModel.h

https://invent.kde.org/plasma/libksysguard/commit/5ce5e7e8456d4a3b456df8c0d5e6ff72d049eb00