778e87c69c
* Long workload name layout fix (#269)
* changed layout to fit experiment names
- added span to show full name
- shortened name to fit dropwdown
- changed layout for added consistency
* layout Fixes
- refresh button is to the right
- header is more consistent across different width screens
* header layout update
- center div makes turns into multiple lines if not all items fit
* slight improvement for header/graph spacing
* Fixed refresh button shape and function
- moved find_causal_files to parser so that main and gui can access
- resized refresh width to allow for same shape across different screens
* all graphs now have the same width
- graphs now have same width
- chart headers start well below the header with filters
---------
Co-authored-by: Jonathan R. Madsen <jrmadsen@users.noreply.github.com>
* Causal GUI: Linting, synced y-range, remove unused imports/variables, and bug fixes (#274)
* GUI: python linting workflow
- runs flake8 on code in source/python/gui
* GUI: flake8 settings in source/python/gui/setup.cfg
- ignore E501 errors (line too long)
- ignore W503 errors (line break before binary operator)
* GUI: setup.py updates
- remove unused imports
* GUI: __main__.py updates
- stddev is float value
- remove unused imports
- effectively propagate the --stddev argument
* GUI: gui.py updates
- remove unused imports
- fix light mode
- sync initial y range of all causal plots
- fix error bars for causal data
- set x-ticks to 5
- set y-ticks to 10
- only display top 99% of samples
- separate global declarations and assignments to global values
- remove unused variable assignments
- fix mislabeled function_regex and exp_regex
- change if X == False to if not X
* GUI: header.py updates
- remove unused imports
- fix mislabeled function_regex and exp_regex
* GUI: parser.py updates
- add set_num_stddev function for manipulating global num_stddev value
- remove unused variables
- fix latency point object (duplicated __init__ function)
- fix handling latency in JSON
- fix formatting of validation format error message
- replace if X == False with if not X
- fix unused dataframe creation in add_latency
- fix flake8 do not assign lambda for name_wo_ext (use def)
* GUI: gui.py updates
- replace misnamed "func_list" with "experiment_list"
- replace misnamed "exp_list" with "progpt_list"
* GUI: fix python workflow
- quote python versions to avoid truncating 3.10 to 3.1
---------
Co-authored-by: JoseSantosAMD <87447437+JoseSantosAMD@users.noreply.github.com>
[ROCm/rocprofiler-systems commit: cc14b52584]
71 строка
1.9 KiB
Python
71 строка
1.9 KiB
Python
#!/usr/bin/env python3
|
|
|
|
import os
|
|
|
|
from setuptools import setup
|
|
|
|
|
|
def get_project_version():
|
|
# open "VERSION"
|
|
_cwd = os.path.dirname(__file__)
|
|
with open(os.path.join(_cwd, "source", "VERSION"), "r") as f:
|
|
data = f.read().replace("\n", "")
|
|
# make sure is string
|
|
if isinstance(data, list) or isinstance(data, tuple):
|
|
return data[0]
|
|
else:
|
|
return data
|
|
|
|
|
|
def get_long_description():
|
|
long_descript = ""
|
|
try:
|
|
long_descript = open("README.md").read()
|
|
except Exception:
|
|
long_descript = ""
|
|
return long_descript
|
|
|
|
|
|
def parse_requirements(fname="requirements.txt"):
|
|
_req = []
|
|
requirements = []
|
|
# read in the initial set of requirements
|
|
with open(fname, "r") as fp:
|
|
_req = list(filter(bool, (line.strip() for line in fp)))
|
|
# look for entries which read other files
|
|
for itr in _req:
|
|
if itr.startswith("-r "):
|
|
# read another file
|
|
for fitr in itr.split(" "):
|
|
if os.path.exists(fitr):
|
|
requirements.extend(parse_requirements(fitr))
|
|
else:
|
|
# append package
|
|
requirements.append(itr)
|
|
# return the requirements
|
|
return requirements
|
|
|
|
|
|
setup(
|
|
name="omnitrace-causal-viewer",
|
|
version=get_project_version(),
|
|
description="GUI for viewing causal profilers",
|
|
long_description=get_long_description(),
|
|
long_description_content_type="text/markdown",
|
|
author="AMD Research",
|
|
packages=["omnitrace_causal_viewer"],
|
|
package_dir={"omnitrace_causal_viewer": "source"},
|
|
package_data={
|
|
"omnitrace_causal_viewer": [
|
|
"source/assets/*",
|
|
"source/workloads/*",
|
|
"source/VERSION",
|
|
]
|
|
},
|
|
install_requires=parse_requirements(),
|
|
python_requires=">=3.6",
|
|
entry_points={
|
|
"console_scripts": ["omnitrace-causal-plot=omnitrace_causal_viewer.__main__:main"]
|
|
},
|
|
)
|