<commit_before>const _       = require('lodash');
const CronJob = require('cron').CronJob;
const fs      = require('fs');
const gm      = require('gm');
const logger  = require('winston');
const moment  = require('moment');

const bme280       = require('./bme280');
const config       = require('../config');
const camera       = require('./camera');
const db           = require('./db');
const dropbox      = require('./dropbox');
const photocell    = require('./photocell');
const SocketServer = require('../server/api/socket');

function captureTimelapseImage() {
    let { light } = photocell.getLatest();

    if (light > 150) {
        logger.debug('its dark, skipping a photoop');
        return;
    }

    const filename = `${moment().format('YYYYMMDDhhmmss')}.jpg`;
    camera.captureImage()
    .then((image) => {
        let values = _.extend({}, bme280.getLatest(), photocell.getLatest());

        return new Promise((resolve, reject) => {
            let date = moment().format('dddd MMM Do, YYYY');<commit_msg>:bug: fix: use 24hour time naming<commit_after>const _       = require('lodash');
const CronJob = require('cron').CronJob;
const fs      = require('fs');
const gm      = require('gm');
const logger  = require('winston');
const moment  = require('moment');

const bme280       = require('./bme280');
const config       = require('../config');
const camera       = require('./camera');
const db           = require('./db');
const dropbox      = require('./dropbox');
const photocell    = require('./photocell');
const SocketServer = require('../server/api/socket');

function captureTimelapseImage() {
    let { light } = photocell.getLatest();

    if (light > 150) {
        logger.debug('its dark, skipping a photoop');
        return;
    }

    const filename = `${moment().format('YYYYMMDDHHmmss')}.jpg`;
    camera.captureImage()
    .then((image) => {
        let values = _.extend({}, bme280.getLatest(), photocell.getLatest());

        return new Promise((resolve, reject) => {
            let date = moment().format('dddd MMM Do, YYYY');
{'fraction_non_alphanumeric': 0.1750241080038573, 'fraction_numerical': 0.01253616200578592, 'mean_word_length': 3.0213178294573644, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3159374', 'n_tokens_mistral': 648, 'n_tokens_neox': 605, 'n_words': 148}