This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// ContentView.swift | |
// coremlsd2test | |
// | |
// Created by Yasuhito Nagatomo on 2022/12/03. | |
// | |
// A sample code using Apple/ml-stable-diffusion library. | |
// Preparation: | |
// 1. convert the PyTorch Stable-Diffusion v2 model to coreml models using Apple's tools. | |
// 2. import the coreml models into the iOS project. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Connector, ConnectorNotFoundError, Chain } from 'wagmi'; | |
import { sequence, Wallet } from '0xsequence'; | |
type SequenceConnectorOptions = { | |
// see more info at https://docs.sequence.build/getting-started | |
network?: string; // 'polygon' or 'mumbai' | |
app: string; | |
}; | |
const normalizeChainId = (chainId: string | number) => { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getEncodedAccessControlError(address account, bytes32 role) | |
public | |
pure | |
returns (bytes memory) | |
{ | |
return | |
abi.encodePacked( | |
"AccessControl: account ", | |
Strings.toHexString(uint160(account), 20), | |
" is missing role ", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Install linux update, followed by GCC and Make | |
sudo yum -y update | |
sudo yum install -y gcc make | |
# Install Nginx and PHP-FPM | |
sudo yum install -y nginx php-fpm | |
# Install PHP extensions | |
sudo yum install -y php-devel php-mysql php-pdo \ | |
php-pear php-mbstring php-cli php-odbc \ |