Giter Site home page Giter Site logo

duke-matsci / nanomine Goto Github PK

View Code? Open in Web Editor NEW
16.0 4.0 13.0 28.74 MB

NanoMine Nanocomposites Data Resource (master branch is production)

Home Page: https://materialsmine.org

JavaScript 23.83% Python 19.07% HTML 3.40% Vue 25.13% CSS 0.03% Shell 1.61% MATLAB 9.52% C 14.87% SCSS 2.47% M 0.08%

nanomine's Introduction

NanoMine

NanoMine Nanocomposites Data Resource

NOTE: Prototype code. Some approaches will change. Monitor this README for updates.

Installation

(REQUIRES ubuntu 16.04 -- 18.04 will not work yet)

Note: if installing on a virtual machine, be sure to allocate at least 8G Memory, 2 CPUs and 60G Disk if installing MATLAB otherwise 35GB will probably work.

Also, this is a DEVELOPMENT only install for a personal system (or vm). Don't use these instructions for QA or production environments.

  • whyis will be installed in /apps/whyis

  • Run these commands after adjusting the mongo dump location and your fork and branch in a terminal window on your Ubuntu VM or native Ubuntu install:

# NOTE: the ChemProps google config is optional, ChemProps is not started by default
export CHEMPROPS_GS_CONFIG_DOWNLOAD_LOCATION="http://somewhere.edu/chemprops.gs.config" # should be named chemprops.gs.config - installer will rename
export MONGO_DUMP_DOWNLOAD_LOCATION=http://somewhere.edu/mgi.tgz  # adjust this to the real download location
export NM_INSTALL_FORK='duke-matsci' # this should probably be YOUR github userid if you intend to push changes
export NM_INSTALL_BRANCH='dev' # usually, this should be 'dev' if you intend to push changes
sudo apt-get install -y curl
sudo apt-get install -y vim 
curl -skL https://raw.githubusercontent.com/${NM_INSTALL_FORK}/nanomine/${NM_INSTALL_BRANCH}/install/install.sh > ./nminstall.sh
chmod a+x ./nminstall.sh
sudo -E ./nminstall.sh 2>&1 | tee nminstall.log # Take a break. It will take a while.
  • IMPORTANT: Post install step - To set up email for job results

    • NOTE: most email vendors have a help page for setting up application access to send email. Consult your email provider's documentation for the proper values to use for the settings.
    • Edit /apps/nanomine_env
      • change the NM_SMTP_SERVER value to your email server i.e. smtp.gmail.com
      • NM_SMTP_PORT may need to change, but 587 usually works (TLS port)
      • NM_SMTP_TEST needs to be set to "false" instead of "true" to actually send emails
      • NM_SMTP_AUTH_USER="your email address or smtp server userid"
      • NM_SMTP_AUTH_PWD="your smtp server password"
        • Note that most email provider's servers will allow creation of application passwords that are easily revoked without revoking your personal password. An application password may be used here. To find out more about application specific passwords consult your email provider's documentation.
  • IMPORTANT: Post install step for MATLAB

    • To test jobs that require MATLAB
      • Edit /apps/nanomine_env
        • Enable calling MATLAB from scripts by setting 'NM_MATLAB_AVAILABLE="yes"'
      • ensure that MATLAB is in the system path for Ubuntu
        • You should be able to go to a terminal command line and type 'matlab' (with no additional path)
          • If MATLAB will not start this way, ensure that it has been installed and note the path to the binary
            • The path may be something like /opt/matlab/bin
            • Add a file called matlab.sh to the /etc/profile.d directory (sudo nano /etc/profile.d/matlab.sh)
              • Assuming the path is /opt/matlab/bin (test this with /opt/matlab/bin/matlab -- it should start)
              • The file should contain the single line 'export PATH=$PATH:/opt/matlab/bin'
              • Be sure the path entered is the path to YOUR matlab bin -- it could be different
            • Log out and login again
            • verify that entering 'matlab' on a command line executes MATLAB
      • Assuming MATLAB is marked enabled for the server runtime and it's accessible via the system path, MATLAB jobs should be able to execute successfully.
  • When loading data into whyis,

    • The load process can be monitored with 'sudo tail -f /var/log/celery/w1.log', but note that loading will usually not occur until upload via XMLCONV GUI

Use the server...

  • go to http://YOUR_VM_ADDRESS/nm to access NanoMine

Code changes

  • If code changes are made to the GUI
cd /apps/nanomine
npm run build
sudo systemctl restart apache2  # may be optional depending on what was changed. For nanomine javascript and job changes, it's not currently necessary.
  • If code changes are made to the rest server - be sure to stop the rest server and restart
  sudo systemctl restart nm-rest
  • NOTE: need both /etc/security/limits.conf settings and /etc/systemd/system.conf.d/limits.conf (system.conf.d may be new directory)
  • add to /etc/security/limits.conf (sudo vi /etc/security/limits.conf)
  whyis hard nofile 40000
  whyis soft nofile 40000
  • add to /etc/systemd/system.conf.d/limits.conf (sudo mkdir /etc/systemd/system.conf.d; sudo vi /etc/systemd/system.conf.d/limits.conf)
   [Manager]
   DefaultLimitNOFILE=40000

Components and Libraries Used

Development

Fork the nanomine repository and use the 'dev' branch for development (git checkout dev). Ensure that pull requests are for the dev branch and not master and not QA.

nanomine's People

Contributors

akshayiyer2610 avatar anqiclaire avatar atul-jalan avatar bingyinh avatar bluedevelz avatar bluedevil-oit avatar dependabot[bot] avatar mail4umar avatar tholulomo avatar tolulomo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.