Comments (5)
In which file do you see the above lines? Are you using any of the scimath.units code in a GUI? I'm curious to know since the the traitsui dependencies should be optional and only needed if you are already using traitsui.
from scimath.
This line is from http://docs.enthought.com/scimath/units/unit_numpy.html
google for this import line. first three hits links to scimath documentation. Thanks for fixing the dependencies. Is this package still recommended for working with unit objects ? Any suggestions?
Sorry for have missed the ImportError in the first report. Was kind of misleading you.
from scimath.units.api import UnitScalar
Traceback (most recent call last):
File "", line 1, in
File "/home/gottfried/buildouts/temp/lib/python2.6/site-packages/scimath/units/api.py", line 21, in
from quantity import Quantity
File "/home/gottfried/buildouts/temp/lib/python2.6/site-packages/scimath/units/quantity.py", line 39, in
class Quantity(HasPrivateTraits):
File "/home/gottfried/buildouts/temp/lib/python2.6/site-packages/traits/has_traits.py", line 645, in new
mhto = MetaHasTraitsObject( cls, class_name, bases, class_dict, False )
File "/home/gottfried/buildouts/temp/lib/python2.6/site-packages/traits/has_traits.py", line 767, in init
value = _check_trait( value )
File "/home/gottfried/buildouts/temp/lib/python2.6/site-packages/traits/has_traits.py", line 331, in _check_trait
return trait_factory( trait )
File "/home/gottfried/buildouts/temp/lib/python2.6/site-packages/traits/traits.py", line 519, in trait_factory
_trait_factory_instances[ tid ] = trait()
File "/home/gottfried/buildouts/temp/lib/python2.6/site-packages/traits/traits.py", line 487, in call
return self.maker_function( _args, *_metadata )
File "/home/gottfried/buildouts/temp/lib/python2.6/site-packages/scimath/units/family_name_trait.py", line 94, in family_name_traits_factory_function
from traitsui.api import EnumEditor
ImportError: No module named traitsui.api
steps to reproduce
- Create a virtualenv with access to numpy
- pip install scimath
- run python interpreter
- from scimath.units.api import UnitScalar
from scimath.
This is helpful. We are taking a look at the dependency situation and will report back here.
We still make use of scimath units for some of our applications where appropriate. It works fairly well when implemented as unitted functions and for physical units. It can be a little inconvenient to use the UnitScalars and UnitArrays directly since some part of the value ends up getting stored in the unit, but that it certainly manageable. The biggest limitation of scimath units is that it is not easily extended non-physical units in a useful way. For example, it would not work well to use it for dollars to euros conversion; also it would inappropriately allow operations between any two non-dimensional units like radians and refractive index. We have ideas for how to fix it, but it is not a high priority with current time and resource constraints.
from scimath.
Thanks for your notes on features and limits of scimath.
from scimath.
Closing as the issue seems to have been fixed in #57
from scimath.
Related Issues (20)
- Remove "scimath.units.unit_converter.convert_quantity_old" HOT 1
- Improve module docstrings in "scimath.units" HOT 1
- Address deprecation warnings raised in the testsuite HOT 1
- Warnings when compiling "scimath.interpolate._interpolate" HOT 2
- Have unit names with `ยต` for micro- prefix and allow other symbolic unit names
- Can "scimath.units.unit_array.__newobj__" be removed? HOT 2
- Remove `*`-imports or use `__all__`
- Use "observe" instead of "on_trait_change" HOT 1
- [5.0.0] Release Checklist
- Update "setup.py" to ship release candidates
- Test fail with Python 3.8
- Update copyright header dates
- Investigate compatibility with Python 3.11 HOT 13
- Update documentation of scimath to include test environment setup HOT 4
- Add new SI prefixes HOT 1
- When we test pypi with python 3.6 and ubuntu 22.04, a architecture not found error will happen HOT 2
- Tracebacks in test output HOT 5
- Github actions: add doc generation workflow HOT 1
- Error during installation HOT 2
- Bleeding edge workflow reinstalls packages into the bootstrap edm environment, not the dev environment
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 scimath.