Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds info prints, SC3 logs backups, db exports, specific SC3 install … #1

Merged
merged 4 commits into from
May 24, 2017

Conversation

FMassin
Copy link
Collaborator

@FMassin FMassin commented May 15, 2017

…and specific data dir. As well as two utilities:

  • event.py can be used to make a list of event ID to be played-back afterwards,
  • plot.py makes a rudimentary timeline plot of the results, current version being still very specific to Mvs, to be updated soon.

misc/event.py Outdated
maxnumber=10,
catalog=None):

from obspy import UTCDateTime
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a particular reason to have the imports inside the function? I don't want to impose pep8 on you but I think their guidelines on imports and indenting make a lot of sense https://www.python.org/dev/peps/pep-0008/#imports

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Totally agree.

misc/event.py Outdated
if catalog:
cat = client.get_events(limit=maxnumber, orderby="magnitude",starttime=starttime, endtime=endtime, minmagnitude=minmag, maxmagnitude=maxmag, catalog="ISC")
else:
cat = client.get_events(limit=maxnumber, orderby="magnitude",starttime=starttime, endtime=endtime, minmagnitude=minmag, maxmagnitude=maxmag)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the reason to hardwire the request to the ISC catalog?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My mistake.

playback.sh Outdated
@@ -3,14 +3,15 @@
PLAYBACKROOT="$( dirname "$( readlink -f "$0")")/"
MAKEMSEEDPLAYBACK="${PLAYBACKROOT}make-mseed-playback.py"
RUNPLAYBACK="${PLAYBACKROOT}playback.py"
PLAYBACKDATA="${PLAYBACKROOT}data"
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This requires someone to remember the trailing '/'. I think two '/' are not a problem but a missing one is.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Corrected.

playback.sh Outdated
MSFILE=`ls "${PBDIR}"/*sorted-mseed`
EVNTFILE=`ls "${PBDIR}"/*_events.xml`
"$RUNPLAYBACK" "${PBDIR}/${PBDB}" "${MSFILE}" "${DELAYS}" -c "${CONFIGDIR}" -m ${MODE} -e "${EVNTFILE}"

"$RUNPLAYBACK" "${PBDIR}/${PBDB}" "${MSFILE}" "${DELAYS}" -c "${CONFIGDIR}" -m ${MODE} #-e "${EVNTFILE}"
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the rational to take out the eventfile?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was trying something and forgot about it, sorry...

Copy link
Owner

@yannikbehr yannikbehr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi Fred, thanks for the pull request. Very nice new features! I just had a few minor comments

@FMassin
Copy link
Collaborator Author

FMassin commented May 16, 2017

Healthy review Yannik, thanks.

@yannikbehr yannikbehr merged commit 5a3fb02 into yannikbehr:master May 24, 2017
yannikbehr pushed a commit that referenced this pull request Oct 18, 2021
Adds info prints, SC3 logs backups, db exports, specific SC3 install …
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants