Comments (7)
Wonder if this can easily be made case-insensitive?
from rebench.
My reading of https://python.readthedocs.io/en/latest/library/importlib.html and https://peps.python.org/pep-0235/ is that Python is a case-sensitive language, and I didn't see any option to use case insensitive semantics for the import.
So, I fear that's a documentation bug. 🙁
from rebench.
Hmm. I imagine it could be done with some string checking machinery, a masterlist of strings to gauge formats (instead of importing dynamically). Is that worthwhile, or should I amend the docs and add a help message for when Python gets an invalid gauge adapter?
from rebench.
Hm, right. We could intercept well known names, check them case insensitive, and map them to the corresponding and correctly cased name.
Perhaps there's even no need for the dynamic import.
The current model is designed to make it easy to just drop in a suitable file.
But, in practice, none has a custom one.
It's also not really practical since if one would install ReBench via pip, one probably would want to have the gauge adapter somehow separate, possibly next to the benchmark config.
Give that rather suboptimal situation, we could try something like looking for gauge adapters on the disk, and then check case insensitively whether the names match, and use the file name we found on the disk for import.
from rebench.
And, yeah, one could possibly indeed drop the dynamic import altogether until someone actually asks for it.
from rebench.
It wasn't immediately apparent how to make gauge adapter resolution case insensitive (it's done by attempting to import packages until one hits, not comparing strings/filenames), so I amended some docs and added a more useful error message on failure in #200 .
from rebench.
Now implemented as case-insensitive with #202.
from rebench.
Related Issues (20)
- [T.4.1] 5min Tutorials
- [T.4.3] Improve Documentation and Tutorials
- Parser for perf output fails on some input HOT 4
- Include CSV header in data files HOT 1
- ReBench environment variable inconsistency HOT 6
- Fast abort of benchmarks when same binary is missing HOT 1
- Parse git branch info when running in developer checkout
- Could we use hwnoise to assess whether performance fluctuations are coming from hardware noise?
- Can we drop Python 2 support? HOT 1
- Add option to explicitly disable all use of denois HOT 4
- There seem to be 'None' string values for extraArgs that are send to ReBenchDB HOT 1
- Make invocation number accessible in command line. HOT 2
- Add support for single-value metrics
- Add support to capture custom version details
- Making environment handling more user-friendly HOT 3
- CSV Headers should be added only exactly once, to avoid being confused with data
- Reenable testing on PyPy on GitHub Actions once the PyYAML issue is resolved HOT 1
- ReBench commandline exit code should not be non-zero when there's nothing to do
- The ~ in a path should be replaced by the home directory HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rebench.