import scala.io.StdIn.readLine
import scala.annotation.tailrec

object Main extends App {
  val n = readLine.toInt

  def candidates(n: Int) = if (n < 4) Nil else 2 +: (3 to math.sqrt(n).toInt by 2)
  def isPrime(n: Int) = candidates(n).forall(n % _ != 0)
  def primeFactorize(n: Int): List[Int] =
    if (isPrime(n)) List(n)
    else {
      @tailrec def recur(n: Int, res: List[Int]): List[Int] =
        candidates(n).reverse.find(k => n % k == 0 && isPrime(k)) match {
          case Some(p) => recur(n / p, p :: res)
          case None => n :: res
        }
      recur(n, Nil)
    }

  def buildPQs(pqs: Map[Int, Int], xs: Seq[Int]): Map[Int, Int] = {
    def helper(pqs: Map[Int, Int], ps: Seq[Int]): Map[Int, Int] =
      if (ps.isEmpty) pqs
      else {
        val p = ps.head
        val q = if (pqs isDefinedAt p) pqs(p) else 0
        helper(pqs + (p -> (q + 1)), ps.tail)
      }
    if (xs.isEmpty) pqs
    else buildPQs(helper(pqs, primeFactorize(xs.head)), xs.tail)
  }

  val pqs = buildPQs(Map[Int, Int](), 2 to n)
  var res = 1L
  pqs foreach {
    case (p, q) => res = res * (q + 1) % 1000000007
    case _ =>
  }
  println(res)
}
