From 3761b488a01e0a300131044201c469a418b5b638 Mon Sep 17 00:00:00 2001 From: Marc Bonnici Date: Tue, 19 Dec 2017 17:22:19 +0000 Subject: [PATCH] Docs: Fixed typos --- doc/connection.rst | 12 +++++------ doc/derived_measurements.rst | 40 ++++++++++++++++++------------------ doc/overview.rst | 18 ++++++++-------- doc/platform.rst | 10 ++++----- 4 files changed, 40 insertions(+), 40 deletions(-) diff --git a/doc/connection.rst b/doc/connection.rst index 70d9e25..fdd35ce 100644 --- a/doc/connection.rst +++ b/doc/connection.rst @@ -104,14 +104,14 @@ Connection Types combination. To see connected devices, you can run ``adb devices`` on the host. :param timeout: Connection timeout in seconds. If a connection to the device - is not esblished within this period, :class:`HostError` + is not established within this period, :class:`HostError` is raised. .. class:: SshConnection(host, username, password=None, keyfile=None, port=None,\ timeout=None, password_prompt=None) - A connectioned to a device on the network over SSH. + A connection to a device on the network over SSH. :param host: SSH host to which to connect :param username: username for SSH login @@ -160,12 +160,12 @@ Connection Types raised. :param password_prompt: A string with the password prompt used by ``sshpass``. Set this if your version of ``sshpass`` - uses somethin other than ``"[sudo] password"``. + uses something other than ``"[sudo] password"``. :param original_prompt: A regex for the shell prompted presented in the Telenet connection (the prompt will be reset to a randomly-generated pattern for the duration of the connection to reduce the possibility of clashes). - This paramer is ignored for SSH connections. + This parameter is ignored for SSH connections. .. class:: LocalConnection(keep_password=True, unrooted=False, password=None) @@ -189,7 +189,7 @@ Connection Types A connection to a gem5 simulation using a local Telnet connection. .. note:: Some of the following input parameters are optional and will be ignored during - initialisation. They were kept to keep the anology with a :class:`TelnetConnection` + initialisation. They were kept to keep the analogy with a :class:`TelnetConnection` (i.e. ``host``, `username``, ``password``, ``port``, ``password_prompt`` and ``original_promp``) @@ -220,7 +220,7 @@ Connection Types There are two classes that inherit from :class:`Gem5Connection`: :class:`AndroidGem5Connection` and :class:`LinuxGem5Connection`. They inherit *almost* all methods from the parent class, without altering them. -The only methods discussed belows are those that will be overwritten by the +The only methods discussed below are those that will be overwritten by the :class:`LinuxGem5Connection` and :class:`AndroidGem5Connection` respectively. .. class:: LinuxGem5Connection diff --git a/doc/derived_measurements.rst b/doc/derived_measurements.rst index d56f94b..5038a35 100644 --- a/doc/derived_measurements.rst +++ b/doc/derived_measurements.rst @@ -45,19 +45,19 @@ Derived Measurements Process a :class:`MeasurementsCsv`, returning a list of :class:`DerivedMetric` and/or :class:`MeasurementsCsv` objects that have been - derived from the input. The exact nature and ordering of the list memebers - is specific to indivial 'class'`DerivedMeasurements` implementations. + derived from the input. The exact nature and ordering of the list members + is specific to individual 'class'`DerivedMeasurements` implementations. .. method:: DerivedMeasurements.process_raw(\*args) - Process raw output from an instrument, returnin a list :class:`DerivedMetric` + Process raw output from an instrument, returning a list :class:`DerivedMetric` and/or :class:`MeasurementsCsv` objects that have been derived from the - input. The exact nature and ordering of the list memebers is specific to - indivial 'class'`DerivedMeasurements` implewmentations. + input. The exact nature and ordering of the list members is specific to + individual 'class'`DerivedMeasurements` implementations. - The arguents to this method should be paths to raw output files generated by + The arguments to this method should be paths to raw output files generated by an instrument. The number and order of expected arguments is specific to - particular implmentations. + particular implementations. Derived Metric @@ -95,7 +95,7 @@ Available Derived Measurements ------------------------------- .. note:: If a method of the API is not documented for a particular - implementation, that means that it s not overriden by that + implementation, that means that it s not overridden by that implementation. It is still safe to call it -- an empty list will be returned. @@ -121,7 +121,7 @@ Energy average power for each power channel in the input CSV. The output will contain all energy metrics followed by power metrics. The ordering of both will match the ordering of channels in the input. The metrics will by named based on the - sites of the coresponding channels according to the following patters: + sites of the corresponding channels according to the following patters: ``"_total_energy"`` and ``"_average_power"``. @@ -130,20 +130,20 @@ FPS / Rendering .. class:: DerivedGfxInfoStats(drop_threshold=5, suffix='-fps', filename=None, outdir=None) - Produces FPS (frames-per-second) and other dervied statistics from + Produces FPS (frames-per-second) and other derived statistics from :class:`GfxInfoFramesInstrument` output. This takes several optional parameters in creation: :param drop_threshold: FPS in an application, such as a game, which this processor is primarily targeted at, cannot reasonably drop to a very low value. This is specified to this - threhold. If an FPS for a frame is computed to be - lower than this treshold, it will be dropped on the - assumption that frame rednering was suspended by the + threshold. If an FPS for a frame is computed to be + lower than this threshold, it will be dropped on the + assumption that frame rendering was suspended by the system (e.g. when idling), or there was some sort of error, and therefore this should be used in performance calculations. defaults to ``5``. - :param suffix: The name of the gerated per-frame FPS csv file will be + :param suffix: The name of the generated per-frame FPS csv file will be derived from the input frames csv file by appending this suffix. This cannot be specified at the same time as a ``filename``. @@ -170,7 +170,7 @@ FPS / Rendering As input, this takes a single argument, which should be the path to the raw output file of :class:`GfxInfoFramesInstrument`. The returns stats - accumulated by gfxinfo. At the time of wrinting, the stats (in order) are: + accumulated by gfxinfo. At the time of writing, the stats (in order) are: ``janks``, ``janks_pc`` (percentage of all frames), ``render_time_50th_ptile`` (50th percentile, or median, for time to render a frame), ``render_time_90th_ptile``, ``render_time_95th_ptile``, @@ -183,20 +183,20 @@ FPS / Rendering .. class:: DerivedSurfaceFlingerStats(drop_threshold=5, suffix='-fps', filename=None, outdir=None) - Produces FPS (frames-per-second) and other dervied statistics from + Produces FPS (frames-per-second) and other derived statistics from :class:`SurfaceFlingerFramesInstrument` output. This takes several optional parameters in creation: :param drop_threshold: FPS in an application, such as a game, which this processor is primarily targeted at, cannot reasonably drop to a very low value. This is specified to this - threhold. If an FPS for a frame is computed to be - lower than this treshold, it will be dropped on the - assumption that frame rednering was suspended by the + threshold. If an FPS for a frame is computed to be + lower than this threshold, it will be dropped on the + assumption that frame rendering was suspended by the system (e.g. when idling), or there was some sort of error, and therefore this should be used in performance calculations. defaults to ``5``. - :param suffix: The name of the gerated per-frame FPS csv file will be + :param suffix: The name of the generated per-frame FPS csv file will be derived from the input frames csv file by appending this suffix. This cannot be specified at the same time as a ``filename``. diff --git a/doc/overview.rst b/doc/overview.rst index 7a60fb8..e1af5e5 100644 --- a/doc/overview.rst +++ b/doc/overview.rst @@ -1,7 +1,7 @@ Overview ======== -A :class:`Target` instance serves as the main interface to the target device. +A :class:`Target` instance serves as the main interface to the target device. There currently three target interfaces: - :class:`LinuxTarget` for interacting with Linux devices over SSH. @@ -20,7 +20,7 @@ Acquiring a Target To create an interface to your device, you just need to instantiate one of the :class:`Target` derivatives listed above, and pass it the right ``connection_settings``. Code snippet below gives a typical example of -instantiating each of the three target types. +instantiating each of the three target types. .. code:: python @@ -89,7 +89,7 @@ executed as root. from devlib import LocalLinuxTarget t = LocalLinuxTarget() - # Execute a command + # Execute a command output = t.execute('echo $PWD') # Execute command via a subprocess and return the corresponding Popen object. @@ -100,7 +100,7 @@ executed as root. # Run the command in the background on the device and return immediately. # This will not block the connection, allowing to immediately execute another - # command. + # command. t.kick_off('echo $PWD') # This is used to invoke an executable binary on the device. This allows some @@ -125,7 +125,7 @@ File Transfer t.pull('/path/to/target/file.txt', '/path/to/local/file.txt') # Install the specified binary on the target. This will deploy the file and - # ensure it's executable. This will *not* guarantee that the binary will be + # ensure it's executable. This will *not* guarantee that the binary will be # in PATH. Instead the path to the binary will be returned; this should be # used to call the binary henceforth. target_bin = t.install('/path/to/local/bin.exe') @@ -133,7 +133,7 @@ File Transfer output = t.execute('{} --some-option'.format(target_bin)) The usual access permission constraints on the user account (both on the target -and the host) apply. +and the host) apply. Process Control ~~~~~~~~~~~~~~~ @@ -173,7 +173,7 @@ Super User Privileges It is not necessary for the account logged in on the target to have super user privileges, however the functionality will obviously be diminished, if that is -not the case. ``devilib`` will determine if the logged in user has root +not the case. ``devlib`` will determine if the logged in user has root privileges and the correct way to invoke it. You should avoid including "sudo" directly in your commands, instead, specify ``as_root=True`` where needed. This will make your scripts portable across multiple devices and OS's. @@ -193,7 +193,7 @@ working_directory by your script on the device and as the destination for all host-to-target file transfers. It may or may not permit execution so executables should not be run directly from here. - + executables_directory This directory allows execution. This will be used by ``install()``. @@ -249,7 +249,7 @@ You can collected traces (currently, just ftrace) using from devlib import AndroidTarget, FtraceCollector t = LocalLinuxTarget() - + # Initialize a collector specifying the events you want to collect and # the buffer size to be used. trace = FtraceCollector(t, events=['power*'], buffer_size=40000) diff --git a/doc/platform.rst b/doc/platform.rst index 3449db3..d4d6911 100644 --- a/doc/platform.rst +++ b/doc/platform.rst @@ -23,12 +23,12 @@ it was not specified explicitly by the user. inferred from core names (cores with the same name are assumed to be in a cluster). :param big_core: The name of the big core in a big.LITTLE system. If this is - not specified it will be inferred (on systems with exactly - two clasters). + not specified it will be inferred (on systems with exactly + two clusters). :param model: Model name of the hardware system. If this is not specified it will be queried at run time. :param modules: Modules with additional functionality supported by the - platfrom (e.g. for handling flashing, rebooting, etc). These + platform (e.g. for handling flashing, rebooting, etc). These would be added to the Target's modules. (See :ref:`modules`\ ). @@ -87,8 +87,8 @@ support additional configuration: :uefi-shell: Boot by going via the UEFI shell. :u-boot: Boot using Das U-Boot. :bootmon: Boot directly via Versatile Express Bootmon - using the values provided for ``image``, - ``initrd``, ``fdt``, and ``bootargs`` + using the values provided for ``image``, + ``initrd``, ``fdt``, and ``bootargs`` parameters. This defaults to ``u-boot`` for :class:`Juno` and