diff --git a/README.md b/README.md index 8e52c50..2ec0593 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,20 @@ HASHpy ------ +This fork contains two minor bug fixes that are necessary to get hashpy up and running smoothly in 2021: +* in hashpy/hashpype.py, change 'class HashError(StandardError):' to 'class HashError(Exception):' +* in hashpy/__init__.py, add a dot before 'hashpype' and 'doublecouple' + +That's it. Thank you Luca Scarabello for figuring this out. Now let's go compute some FMs (\\__/) +- - - - + + + + + + +#### Original README: #### + [![DOI](https://zenodo.org/badge/3723/markcwill/hashpy.png)](http://dx.doi.org/10.5281/zenodo.9808) This is a fork of HASH v1.2, the first motion focal mechanism program by Hardebeck and Shearer. The subroutines (in Fortran 77, which I did not write) are compiled into a python module, 'libhashpy.so', which will import all the subs and common blocks into the python namespace. There is a base class, HashPype, that contains attributes which hold data for a HASH calculation, and methods which can be called to do the HASH calculation. This class facilitates easily writing a 'hash driver' script in python. See below for details. diff --git a/hashpy/__init__.py b/hashpy/__init__.py index 4aa71b0..8ed14c8 100644 --- a/hashpy/__init__.py +++ b/hashpy/__init__.py @@ -10,8 +10,8 @@ """ -from hashpype import HashPype, HashError -from doublecouple import DoubleCouple +from .hashpype import HashPype, HashError +from .doublecouple import DoubleCouple __version__ = "0.5.6" diff --git a/hashpy/hashpype.py b/hashpy/hashpype.py index a0d8644..4b1a0e6 100644 --- a/hashpy/hashpype.py +++ b/hashpy/hashpype.py @@ -514,7 +514,8 @@ def driver3(self, check_for_minimum_picks=True, check_for_maximum_gap_size=True) self.calculate_quality(use_amplitudes=True) -class HashError(StandardError): +#class HashError(StandardError): +class HashError(Exception): """Throw this if something happens while running""" pass