Package: lccserver
LCC-Server is a Python framework to serve collections of light curves. The code
here forms the basis for theHAT data server. See
theinstallation notesbelow for how to install and
configure the server.FeaturesInstallationSQLite requirementUsing the serverDocumentationChangelogScreenshotsLicenseFeaturesLCC-Server includes the following functionality:collection of light curves from various projects into a single output format
(text CSV files)HTTP API and an interactive frontend for searching over multiple light curve
collections by:spatial cone search near specified coordinatesfull-text search on object names, descriptions, tags, name resolution using
SIMBAD's SESAME resolver for individual objects, and for open clusters,
nebulae, etc.queries based on applying filters to database columns of object properties,
e.g. object names, magnitudes, colors, proper motions, variability and
object type tags, variability indices, etc.cross-matching to uploaded object lists with object IDs and coordinatesHTTP API for generating datasets from search results asychronously and
interactive frontend for browsing these, caching results from searches, and
generating output zip bundles containing search results and all matching light
curvesHTTP API and interactive frontend for detailed information per object,
including light curve plots, external catalog info, and period-finding results
plus phased LCs if availableAccess controls for all generated datasets, and support for user sign-ins and
sign-upsInstallationNOTE:Python >= 3.6 is required. Use of a virtualenv is recommended;
something like this will work well:$python3-mvenvlcc
$sourcelcc/bin/activateThis package isavailable on PyPI. Install
it with the virtualenv activated:$pipinstallnumpy# to set up Fortran bindings for dependencies$pipinstalllccserver# add --pre to install unstable versionsTo install the latest version from Github:$gitclonehttps://github.com/waqasbhatti/lcc-server
$cdlcc-server
$pipinstall-e.If you're on Linux or MacOS, you can install theuvlooppackage to optionally speed up
some of the eventloop bits:$pipinstalluvloopSQLite requirementThe LCC-Server relies on the fact that the system SQLite library is new enough
to contain thefts5full-text search module. For some older Enterprise Linux
systems, this isn't the case. To get the LCC-Server and its tests running on
these systems, you'll have to install a newer version of theSQLite
amalgamation. I recommend downloading the
tarball with autoconf so it's easy to install; e.g. for SQLite 3.27.2, use this
file:sqlite-autoconf-3270200.tar.gz.To install at the default location/usr/local/lib:$tarxvfsqlite-autoconf-3270200.tar.gz
$./configure
$make
$sudomakeinstallThen, override the default location that Python uses for its SQLite library
usingLD_LIBRARY_PATH:$exportLD_LIBRARY_PATH='/usr/local/lib'# create a virtualenv using Python 3# here I've installed Python 3.7 to /opt/python37$/opt/python37/bin/python3-mvenvenv# activate the virtualenv, launch Python, and check if we've got a newer SQLite$sourceenv/bin/activate(env)$python3
Python3.7.0(default,Jun282018,15:17:26)[GCC4.8.520150623(RedHat4.8.5-28)]onlinux
Type"help","copyright","credits"or"license"formoreinformation.
>>>importsqlite3
>>>sqlite3.sqlite_version'3.27.2'You can then run the LCC-Server using this virtualenv. You can use anEnvironmentdirective in the systemd service files to add in theLD_LIBRARY_PATHoverride before launching the server.Using the serverSome post-installation setup is required to begin serving light curves. In
particular, you will need to set up a base directory where LCC-Server can work
from and various sub-directories.To make this process easier, there's an interactive CLI available when you
install LCC-Server. This will be in your$PATHaslcc-server.A Jupyter notebook walkthough using this CLI to stand up an LCC-Server instance,
with example light curves, can be found in theastrobase-notebooksrepo:lcc-server-setup.ipynb(Jupyter
nbviewer).DocumentationDocumentation for how to use the server for searching LC collections is hosted
at the HAT data server instance:https://data.hatsurveys.org/docs.The HTTP API is documented at:https://data.hatsurveys.org/docs/api.A standalone Python module that serves as an LCC-Server HTTP API client is
available in the astrobase repository:lccs.py(Docs).Server docs are automatically generated from theserver-docsdirectory in the git repository. Sphinx-based documentation for the Python
modules is on the TODO list and will be linked here when done.ChangelogPlease see:https://github.com/waqasbhatti/lcc-server/blob/master/CHANGELOG.mdfor a list of changes applicable to tagged release versions.ScreenshotsThe search interfaceDatasets from search resultsPer-object informationLicenseLCC-Server is provided under the MIT License. See the LICENSE file for the full
text.