"...ssh:/git@developer.sourcefind.cn:2222/tsoc/openmm.git" did not exist on "0b7d0cc147b69af2794c1a5b13761fa61790d6a0"
  1. 27 Aug, 2015 1 commit
  2. 23 Jun, 2015 3 commits
  3. 19 Jun, 2015 2 commits
    • Jason Swails's avatar
      Delete now out-of-date docs as well as adding __array_priority__ to Quantity. · ba1af1ee
      Jason Swails authored
      This should be *lower* than that of Unit (and ScaledUnit/BaseUnit), since we
      still want Units to take priority over Quantities (but Quantity to take
      precedence over regular ndarrays) for reasons like this:
      
      >>> a = np.array([1]) * u.angstroms
      >>> b = a * u.angstroms # should be np.array([1])*u.angstroms**2
      >>> np.arange(10) * a # utilize broadcasting
      [1 2 3 4 5 6 7 8 9 10] A**2
      ba1af1ee
    • Jason Swails's avatar
      A large number of unit cleanups and fix numpy wart · 4ae68749
      Jason Swails authored
      The main thing that's done here is that numpy arrays can be given units via the
      * operator, rather than relying on the Quantity constructor
      
      e.g.,
      
      >>> import numpy as np
      >>> np.zeros(10) * u.angstroms
      Quantity(value=array([ 0.,  0.,  0.,  0.,  0.,  0.,  0.,  0.,  0.,  0.]), unit=angstrom)
      
      yay!
      4ae68749
  4. 08 Dec, 2014 1 commit
  5. 06 Dec, 2014 1 commit
  6. 04 Nov, 2014 2 commits
    • Jason Swails's avatar
      Oops... Forgot unit on the reshape command. · 5b4abbb5
      Jason Swails authored
      Add a test for the various numpy attributes (and the arguments they take) for
      the unit module.
      5b4abbb5
    • Jason Swails's avatar
      Fix another small bug for unit handling with numpy arrays. Fixes the exception: · a5c00fa5
      Jason Swails authored
      Traceback (most recent call last):
        File ".../python/tests/TestNumpyCompatibility.py", line 87, in testNumpyAttributes
          d = self.data.reshape((100, 3))
        File ".../simtk/unit/quantity.py", line 575, in reshape
          return Quantity(self._value.reshape(shape, order=order))
        File ".../simtk/unit/quantity.py", line 142, in __init__
          if value == first_item:
      ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()
      
      Also add a test for new unit numpy capabilities.
      a5c00fa5
  7. 03 Nov, 2014 2 commits
  8. 15 Oct, 2014 1 commit
  9. 06 Oct, 2014 4 commits
  10. 16 Jul, 2014 1 commit
  11. 09 Dec, 2013 1 commit
  12. 06 Dec, 2013 1 commit
  13. 05 Dec, 2013 1 commit
  14. 12 Jul, 2013 1 commit
  15. 20 May, 2012 1 commit
  16. 07 May, 2012 1 commit
  17. 27 Mar, 2012 1 commit
  18. 13 Mar, 2012 1 commit
  19. 11 Feb, 2012 1 commit
  20. 08 Feb, 2012 1 commit
  21. 23 Jan, 2012 2 commits
  22. 15 Nov, 2011 1 commit
  23. 18 May, 2011 1 commit
  24. 12 Mar, 2011 1 commit
  25. 09 Mar, 2011 1 commit
  26. 08 Mar, 2011 1 commit
  27. 03 Mar, 2011 3 commits
  28. 26 Feb, 2011 1 commit