-
-
Save joeking11829/fdef16e5f5ea77cec5c2396a8e13763f to your computer and use it in GitHub Desktop.
Jetson TK1 performance max
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| # Set CPU to full performance on NVIDIA Jetson TK1 Development Kit | |
| if [ $(id -u) != 0 ]; then | |
| echo "This script requires root permissions" | |
| echo "$ sudo "$0"" | |
| exit | |
| fi | |
| # To obtain full performance on the CPU (eg: for performance measurements or benchmarking or when you don't care about power draw), you can disable CPU scaling and force the 4 main CPU cores to always run at max performance until reboot: | |
| cd /sys/devices/system/cpu | |
| grep -H . cpuquiet/tegra_cpuquiet/enable | |
| grep . cpu?/online | |
| grep . cpu?/cpufreq/scaling_governor | |
| echo 0 >cpuquiet/tegra_cpuquiet/enable | |
| for i in cpu?; do | |
| read online <$i/online | |
| [ "$online" = 1 ] && continue | |
| echo 1 >$i/online | |
| done | |
| for i in cpu?; do | |
| echo performance >$i/cpufreq/scaling_governor | |
| done | |
| grep -H . cpuquiet/tegra_cpuquiet/enable | |
| grep . cpu?/online | |
| grep . cpu?/cpufreq/scaling_governor |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| # Set CPU to full performance on NVIDIA Jetson TK1 Development Kit | |
| if [ $(id -u) != 0 ]; then | |
| echo "This script requires root permissions" | |
| echo "$ sudo "$0"" | |
| exit | |
| fi | |
| # If X11 isn't started, deviceQuery must be run to load GPU drivers | |
| # /home/ubuntu/NVIDIA_CUDA-6.5_Samples/1_Utilities/deviceQuery/deviceQuery >/dev/null 2>&1 | |
| cd /sys/kernel/debug/clock | |
| for clock in gbus emc; do | |
| grep -H . $clock/rate | |
| read rates <$clock/possible_rates | |
| for rate in $rates; do | |
| [ "$rate" = '(kHz)' ] && break | |
| max_rate=$rate | |
| done | |
| echo ${max_rate}000 >override.$clock/rate | |
| echo 1 >override.$clock/state | |
| grep . override.$clock/rate override.$clock/state | |
| done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment