andrei-zgirvaci / expo-stable-diffusion Goto Github PK
View Code? Open in Web Editor NEWRun Stable Diffusion using Core ML on iOS within your Expo & React Native App
Run Stable Diffusion using Core ML on iOS within your Expo & React Native App
I would like to obtain the progress information of the image generation process.
How about adding a function like getCurrentStep
?
Thanks for your great work, it is much appreciated.
I am using expo-dev-client. I have build a develop client for the simulator. I imitated your example.
After await ExpoStableDiffusion.loadModel(MODEL_PATH)
followed by await ExpoStableDiffusion.generateImage()
, after a few minutes "File "GeneratedImages/image .jpeg" does not exist" error.
What is wrong?
hi, could we run this project on windows
Hey, first, great work on your module! I like it!
Can I use this module in Expo Go, or do I need an development build?
Hi and thank you for this great idea of making SD available in react-native with iOS.
I have tried to run the example you have given in the repository in my iPhone 13 Pro Max but I do not get any response from 'loadModel' method it awaits there forever no errors,warnings or whatsoever. its stuck at loading model log
What am I missing ? @andrei-zgirvaci
const MODEL_PATH = FileSystem.documentDirectory + "coreml-stable-diffusion-2-1";
const SAVE_PATH = FileSystem.cacheDirectory + "image.jpeg";
export default function App() {
const loadModel = async () => {
console.log("loading model");
await ExpoStableDiffusion.loadModel(MODEL_PATH);
console.log("loaded model");
};
const generateImage = async () => {
console.log("generating");
await ExpoStableDiffusion.generateImage({
prompt: "a photo of an astronaut riding a horse on mars",
stepCount: 25,
savePath: SAVE_PATH,
});
console.log("generated");
};
return (
<View style={styles.container}>
<Text>Testing Expo Stable Diffusion</Text>
<Button onPress={loadModel} title="Load the Model" />
<Button onPress={generateImage} title="Generate the image" />
</View>
);
}
I found out about a project recently that restores photos of stillborn infants so that parents get to see their child the way they were meant to be born.
https://www.babyangelpics.com/
I know Stable Diffusion can do Img2Img on Hugging Face, and I was wondering how you could do the same with this library so that you could make an app that gives parents photos of their children from the ones taken from the birth while letting the parents keep their privacy.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.